This tutorial serves as documentation on the installation procedure for the SKY130A PDK and the required tooling for analog design under the Windows Subsystem for Linux (WSL). The tools tend to come with a bunch of bugs and its generally better to use their bleeding edge rather than older distro versions. Therefore, in this tutorial, I’ve opted to go for their bleeding edge, rather than older distro versions. The software will be installed under ~/tools and the pdk will be installed under ~/pdk.

WSL

Use a Windows terminal to run:

wsl --install -d Ubuntu-24.04
wsl

This will drop you into the Linux terminal. You can now update the installed distribution by running:

sudo apt update
sudo apt upgrade

Tools

Currently the tools used are:

  • Schematic editor: xschem
  • Simulator: ngspice
  • Layout: magic (TODO: klayout)

Development Environment Installation

Since most of the tools are going to be built from source, we first need to install basic build tooling

sudo apt install gcc g++ gdb make

TODO: There might be missing items here.

xschem

mkdir ~/tools/xschem; cd ~/tools/xschem
git clone https://github.com/StefanSchippers/xschem.git ./
# install prerequisites
sudo apt install tcl-dev tk-dev libx11-dev 
sudo apt install libxrender-dev libx11-xcb-dev 
sudo apt install libcairo2-dev bison libxpm-dev libjpeg-dev
# build and install
./configure --prefix=$HOME/tools
make
make install

ngspice

mkdir ~/tools/ngspice; cd ~/tools/ngspice
git clone https://git.code.sf.net/p/ngspice/ngspice ./
# install prerequisites
sudo apt install autoconf libtool automake 
sudo apt install libxaw7-dev bison flex libreadline-dev
# build and install
./autoconf.sh
mkdir release; cd release
../configure --prefix=$HOME/tools --with-x --enable-cider --enable-predictor --enable-openmp --enable-osdi --enable-pss
make -j 16
make install

magic

mkdir ~/tools/magic; cd ~/tools/magic
git clone https://github.com/RTimothyEdwards/magic ./
# install prerequisites
sudo apt install m4 python3 libx11-dev tcl-dev tk-dev 
sudo apt install libcairo2-dev mesa-common-dev 
sudo apt install libgl-dev libglu1-mesa-dev zlib1g-dev
# build and install
./configure --prefix=$HOME/tools
make -j 16
make install

PDK

mdkir ~/pdk
mkidr ~/pdk/open_pdks; cd ~/pdk/open_pdks
git clone https://github.com/RTimothyEdwards/open_pdks ./
# build and install
./configure --prefix=$HOME/pdk --enable-sky130-pdk --with-sky130-variants=A
make -j 16
make install

Workarea Setup

MVP Experimentation Workarea

Create a simple workarea

export PDK_ROOT=$HOME/pdk/share/pdk
export PDK=sky130A

Copy xschemrc into the local workarea and modify it to look for the correct location for the SKY130A libraries.

cp $HOME/pdk/share/pdk/sky130A/libs.tech/xschem/xschemrc ./
append XSCHEM_LIBRARY_PATH :${PDK_ROOT}/${PDK}/libs.tech/xschem

You can now start the schematic editor by:

xschem

TT10 Project Workarea Setup