Channels

#sky130

Title

# sky130

s

Stefan Schippers

09/15/2021, 11:52 AM Copy code

```
**.subckt test_res P M B
XR1 M net1 B sky130_fd_pr__res_iso_pw W=2.65 L=2.65 mult=1 m=1
Vr1 P net1 0
Vr2 P net2 0
R2 M net2 sky130_fd_pr__res_generic_nd W=1 L=1 mult=1 m=1
Vr3 P net3 0
R3 M net3 sky130_fd_pr__res_generic_pd W=1 L=1 mult=1 m=1
Vr4 P net4 0
R4 M net4 sky130_fd_pr__res_generic_po W=1 L=1 mult=1 m=1
Vr5 P net5 0
XR5 M net5 B sky130_fd_pr__res_high_po W=1 L=1 mult=1 m=1
Vr6 P net6 0
XR6 M net6 B sky130_fd_pr__res_high_po_0p35 L=1 mult=1 m=1
Vr7 P net7 0
XR7 M net7 B sky130_fd_pr__res_high_po_0p69 L=0.69 mult=1 m=1
Vr8 P net8 0
XR8 M net8 B sky130_fd_pr__res_high_po_1p41 L=1.41 mult=1 m=1
Vr9 P net9 0
XR9 M net9 B sky130_fd_pr__res_xhigh_po W=1 L=1 mult=1 m=1
Vr10 P net10 0
XR10 M net10 B sky130_fd_pr__res_xhigh_po_0p35 L=0.35 mult=1 m=1
Vr11 P net11 0
XR11 M net11 B sky130_fd_pr__res_xhigh_po_0p69 L=0.69 mult=1 m=1
Vr12 P net12 0
XR12 M net12 B sky130_fd_pr__res_xhigh_po_1p41 L=1.41 mult=1 m=1
Vr13 P net13 0
R13 M net13 sky130_fd_pr__res_generic_m1 W=1 L=1 m=1
vp P 0 1.8
vm M 0 0
vb B 0 0
.control
save all
dc temp -40 140 1
plot v(p,m) / vr4#branch
plot v(p,m) / vr5#branch
plot v(p,m) / vr6#branch
plot v(p,m) / vr9#branch
plot v(p,m) / vr10#branch
.endc
.lib ~/share/pdk/sky130A/libs.tech/ngspice/sky130.lib.spice tt
.param mc_mm_switch=0
.param mc_pr_switch=0
.end
```

leads to various error messages, as in attached log file. I have the .spiceinit file with the usual `set ngbehavior=hsa`

and `set ng_nomodcheck`

.
Any suggestions?Narrowing down the problem i am unable to simulate res_iso_pw. I am checking all resistors one by one, this one is problematic and i can't figure out why...

Copy code

```
**.subckt test_res P M B
XR1 M net1 B sky130_fd_pr__res_iso_pw W=2.65 L=2.65 m=1
Vr1 P net1 0
vp P 0 1.8
vm M 0 0
vb B 0 0
.control
save all
dc temp -40 140 1
.endc
.lib /mnt/sda7/home/schippes/share/pdk/sky130A/libs.tech/ngspice/sky130.lib.spice tt
.param mc_mm_switch=0
.param mc_pr_switch=0
.save I(Vr1)
.end
```

t

Tim Edwards

09/15/2021, 2:23 PMI'm looking into it as well, so I'll keep you posted.

s

Stefan Schippers

09/15/2021, 2:25 PMt

Tim Edwards

09/15/2021, 3:18 PMFor one, I did not notice that

`all.spice`

is being included by the corner model include file, so the redundant include is causing all the "duplicate subcircuit" warnings. That's easy to fix. I'm still not sure what causes the error with the res_iso_pw model.Okay, for unknown reasons, the duplicate includes are somehow screwing up the pwell resistor model. I'll get it all patched up right away.

s

Stefan Schippers

09/15/2021, 6:31 PMOk, very clear. Thanks

Copy code

```
test
r1 1 0 1k m=100
v1 1 0 1
.op
.end
```

t

Tim Edwards

09/15/2021, 7:28 PMOkay, thanks for checking!