https://open-source-silicon.dev logo
Title
m

Mudasir

05/16/2023, 4:37 PM
If I want to generate a lookup table for an nfet then I would need to perform nested dc simulations of all the transistor ports along with parametric sweeps of 'W' and 'L', is there an simple way to do it in ngspice.
s

Stefan Schippers

05/16/2023, 4:43 PM
there is a testbench
sky130_tests/test_sweep_mos_w.sch
that sweeps the width of a transistor in a loop and performs dc sims. You can add a second nested loop varying L and collect the data with
wrdata
or
.print
Good sources are the ngspice control language tutorial and the ngspice user manual.