Open AhmedLilah opened 1 month ago
@AhmedLilah thank you for reporting this issue.
Our MOS devices use PSP103 model, which is included in ngspice control
section as a binary file using the following command: 'pre_osdi ./psp103_nq.osdi' Because of the license agreement we can not distribute the osdi
binary but we do redistribute source code of the PSP103 model. The Verilog-A code can be compiled using opencaf (the install.py
script does it). The potential issue is that since your PDK_ROOT
points to the /usr/local/share/pdk
running install.py
does not take effect. Try first export the PDK_ROOT
to point to the actual place where you clone it, execute install.py
. It is mandatory to have openvaf
installed.
@AhmedLilah was the above comment helpful ?
Unfortunately no, I installed it according to what you said and it still doesn't work.
Did you try our latest updates, where .spiceinit
is used to let the simulator know about the models and the osdi
file ?
If no try to update the dev
branch and run install.py
once more.
@KrzysztofHerman
I did pull the dev branch and run the python script and opened xschem in the pdk example file and ran the moslv test and got this
Make sure that you have exported the env variables
export PDK_ROOT=/home/$USER/your_directory/IHP-Open-PDK
export PDK=ihp-sg13g2
export KLAYOUT_PATH="/home/$USER/.klayout:$PDK_ROOT/$PDK/libs.tech/klayout"
export KLAYOUT_HOME=/home/$USER/.klayout
Note that the klayout
related stuff is not used in the simulation but you will need this when making layout.
after running $PDK_ROOT/$PDK/libs.tech/xschem/install.py
make sure that .spiceinit
symbolic link is created in /home/$USER
and it points to the $PDK_ROOT/$PDK/libs.tech/ngspice/.spiceinit
file
make sure that the file $PDK_ROOT/$PDK/libs.tech/ngspice/openvaf/psp103_nqs.osdi
exists
run xschem in $PDK_ROOT/$PDK/libs.tech/xschem
directory
Alternatively you can run this netlist directly in ngspice
*
.lib cornerMOSlv.lib mos_tt
Vgs net1 GND 0.4
Vds net3 GND 1.0
Vd net3 net2 0
.param temp=27
XM1 net2 net1 GND GND sg13_lv_nmos w=1.0u l=0.13u ng=1 m=1
.control
save all
op
let Id = @n.xm1.nsg13_lv_nmos[ids]
print Id
.endc
.GLOBAL GND
.end
Environment
Expected Behavior
provided MOS tests to run.
Actual Behavior
when I run any of the tests in xschem for the most devices I get an error while running ngspice saying
this is not the case with passives and BJTs it only happens with most devices the rest are working fine.
Steps to Reproduce the Problem
xschem