Stefan Schippers
10/19/2023, 10:43 PMtb_reram.sch
schematic.
The XR1
symbol is a subcircuit. The subcircuit instantiates the 'N... element that is a verilog-A primitive.
This element calls a model that sets some parameter values and binds to a verilog-A module:
• XR1
--> subcircuit sky130_fd_pr_reram__reram_cell
• subcircuit sky130_fd_pr_reram__reram_cell
--> instantiates the '`N`' line with sky130_fd_pr_reram__reram_model
model.
• The sky130_fd_pr_reram__reram_model
model sets some parameter values and binds to the sky130_fd_pr_reram__reram_module
Verilog-A code.
• The sky130_fd_pr_reram__reram_module
code placed in a <http://sky130_fd_pr_reram__reram_module.va|sky130_fd_pr_reram__reram_module.va>
file is compiled with openvaf
and the generated .osdi file is placed in a place known by ngspice.
• In the netlist there is a pre_osdi
/path/to/sky130_fd_pr_reram__reram_module.osdi
that allows ngspice to link in the compiled module.Tim Edwards
10/20/2023, 1:18 PMopen_pdks
and install the model into the PDK where it can be used automatically without requiring the end user to go to all the trouble of doing it themselves.Stefan Schippers
10/20/2023, 5:16 PMopenvaf
. It is available precompiled for Linux and is extremely simple, it unpacks an openvaf
executable
schippes@asus:~$ tar ztvf Downloads/openvaf_23_5_0_linux_amd64.tar.gz
-rwxr-xr-x 0/0 221692776 2023-05-16 13:51 openvaf
• Doing openvaf <http://xxx.va|xxx.va>
generates xxx.osdi
• Place these lines in the testbench
.control
pre_osdi /path/to/xxx.osdi
.endc
• The boring part is the wrapping: VerilogA device --> subcircuit --> N line --> N model -->osdi moduleTim Edwards
10/20/2023, 5:35 PM/path/to/xxx.osdi
is always in, e.g., $PDK_PATH/libs.tech/ngspice/
or maybe $PDK_PATH/libs.tech/osdi/
.Linen is a search-engine friendly community platform. We offer integrations with existing Slack/Discord communities and make those conversations Google-searchable.
Powered by