PySpice-org / PySpice

Simulate electronic circuit using Python and the Ngspice / Xyce simulators
https://pyspice.fabrice-salvaire.fr
GNU General Public License v3.0
661 stars 175 forks source link

spice simulations not found #327

Open joamatab opened 2 years ago

joamatab commented 2 years ago

Hi!

im trying to add spice models into the skywater open source pdk

https://github.com/gdsfactory/skywater130/issues/16

what is the format for loading spice simulations in pyspice?

@proppy

joamatab commented 2 years ago

this is what i get

.title sky130_fd_sc_hd__a2111o_1
.lib /home/jmatres/sky130/sky130/spice/sky130_fd_sc_hd.spice sky130_fd_sc_hd__a2111o_1
Vgnd VGND 0 0
Vdd VPWR VGND 1.8
R VPWR DRAIN 10k
VVin GATE VGND DC 0V PULSE(0V 1.8V 1ns 10ps 10ps 1ns 2ns)

spinit was not found
Note: can't find init file.
Unsupported Ngspice version 36
ERROR, library file /home/jmatres/sky130/sky130/spice/sky130_fd_sc_hd.spice, section definition sky130_fd_sc_hd__a2111o_1 not found
Error: ngspice.dll cannot recover and awaits to be detached

@helgegehring

joamatab commented 2 years ago

related to issue https://github.com/google/skywater-pdk/issues/375

proppy commented 2 years ago

See https://gist.github.com/proppy/964fa4b9277c3baf9e731872bbad93e4 for an example that load the spice model from an "install"-ed version of the SKY130 pdk (either thru https://anaconda.org/LiteX-Hub/open_pdks.sky130a or https://github.com/efabless/volare).