Hi, I'm not sure what channel to post this in, but...
# magic
j
Hi, I'm not sure what channel to post this in, but is there a currently an irsim .tcl/.so file to handle sky130 transistor subcircuits. I'm trying to use irsim with the magic ext2sim command, so I would need either a way to simulate the transistor subcircuits digitally, or a way to have magic extract the transistors directly to M instead of X cards. Looking at my options, I guess it would be easier to write behavioral representations of the transistors in tcl or something for irsim than to rewrite the msubcircuit portion of the sky130.tech...
m
I believe if you set
extract style ngspice(orig)
before extracting, you get normal spice models.
j
Thanks!
t
"IRSIM version 9.7.112: October 12, 2021 at 3:00am Added support for the format recently added to magic for creating sim files that can deal with many device types by using the "x" sim file record. This was previously supported in IRSIM with the "user subckt" package. User subcircuits are still supported, but now subcircuits which represent basic types such as transistors, capacitors, resistors, and diodes can be specified in the .prm file and converted directly into IRSIM simulation types when reading in the .sim file." I have not updated the .prm files that I created for using IRSIM with sky130, though. The syntax in the .prm file is:
Copy code
device <type> <name> [<value>]
where
<type>
is one of:
nfet
,
pfet
,
capacitor
,
resistor
, or
diode
.
<name>
is the name of the device, e.g.,
sky130_fd_pr__nfet_01v8
, and
<value>
is only given for capacitors, resistors, and diodes, and is the capacitance per unit area, resistance per unit length, or the capacitance per unit area of a reverse-biased diode. I seem to have forgotten that updating the .prm files in the PDK was on my to-do list. . .
Adding the following to the .prm file for IRSIM should work for all devices in the sky130 standard cells:
Copy code
device nfet sky130_fd_pr__nfet_01v8
device nfet sky130_fd_pr__nfet_01v8_lvt
device nfet sky130_fd_pr__nfet_g5v0d10v5
device pfet sky130_fd_pr__pfet_01v8
device pfet sky130_fd_pr__pfet_01v8_lvt
device pfet sky130_fd_pr__pfet_01v8_mvt
device pfet sky130_fd_pr__pfet_01v8_hvt
device pfet sky130_fd_pr__pfet_g5v0d10v5
; Capacitor values are in pF/centimicron^2
device capacitor sky130_fd_pr__cap_mim_m3_1 2.0E-7
device capacitor sky130_fd_pr__cap_mim_m3_2 2.0E-7
; Resistor values are in ohms/square
device resistor sky130_res_high_po_0p35   320
device resistor sky130_res_high_po_0p69   320
device resistor sky130_res_high_po_1p41   320
device resistor sky130_res_high_po_2p85   320
device resistor sky130_res_high_po_5p73   320
device resistor sky130_res_xhigh_po_0p35 2000
device resistor sky130_res_xhigh_po_0p69 2000
device resistor sky130_res_xhigh_po_1p41 2000
device resistor sky130_res_xhigh_po_2p85 2000
device resistor sky130_res_xhigh_po_5p73 2000
device resistor sky130_res_generic_nd     120
device resistor sky130_res_generic_pd     197
Please note that I have not tested this yet. This has been tested and works. I am now adding it to the open_pdks build.
🌍 1
Please be aware that the parameter values in all the parameter files correspond to the device types used in the HD standard cell library. Without the ability to represent different transistor types simultaneously within IRSIM, I really need a different parameter file for each of the standard cell libraries that use different device types.
j
Thanks, this is exactly what I was looking for