Chris
07/13/2023, 3:10 AMvpbp_10x10
(I also wonder why its called pbp
, and I assume 10x10
that is the emitter area? In addition, why its name is different to NPN which is called npn_10p00x10p00
), it says this subckt is unknown. Noted that I included the BJT model in my .LIB
statement.Tim Edwards
07/13/2023, 12:41 PMpnp_10p00x10p00
.
Please note, however, that there is currently an issue in Magic's device generator code where it does not handle a layout cell filename that is different from the device name. It is throwing some errors, although I was able to create the layout.
Getting access to the updates requires pulling the most recent version of open_pdks, which will also require pulling and compiling the most recent version of magic.Chris
07/13/2023, 8:35 PMm
in the transistor model.
First, I think in the xschem test example test_nfet_03v3.sch
, the attribute mult=1
is not the correct keyword and I think it should be corrected to m
; possibly @Amro Tork could elaborate this a bit, as I assume you guys created these testbenches (correct me if I am wrong).
Second, even if you correct the keyword name, I do not think this parameter m
is passed to the actual device spice model and taking any effect at all. For example, if I change m
from 1 to 2, I should expect my Id current to double in the saturation region, whereas with the current model, it doesn't (see pictures 2 and 3). What it should generate, is something equivalent to picture 4.Tim Edwards
07/13/2023, 8:53 PMm
and mult
is due to the fact that according to the long-standing syntax of SPICE, m
can be used to specify the number of devices in parallel but cannot itself be used as a parameter name inside the device model. That leads to most people using the tactic of creating another parameter, typically mult
, which is set to the same value as m
but can be used within the model. The reason that the multiplier shows up in the model is specifically for device mismatch. Mismatch is averaged over m
devices, so the mismatch equation needs to account for the total area of m
devices, or else you cannot simulate the effect of using an array of devices to reduce the total mismatch.
Since by definition m
and mult
must equal the same number, often a tool like xschem will set up the symbol so that only one appears (so that it is impossible for the end user to incorrectly give them different values), but will output both parameter names in the output netlist.Chris
07/13/2023, 8:56 PMm
is not taking any effect here (unlike SKY130). Noted that yes the exported netlist has only m
defined through xschem (no mult
)Tim Edwards
07/13/2023, 9:12 PM.subckt nmos_3p3 d g s b w=1e-5 l=2.8e-7
+ as=0 ad=0 ps=0 pd=0 nrd=0 nrs=0 par=1 dtemp=0
+ sa=0 sb=0 nf=1 sd=0 m=1
In fact, m
is not supposed to be passed as a parameter to a subcircuit because it shadows the normal use of the m
parameter as a device multiplier.
This is something that comes from the original Hspice sources from GF, so it might be something that is allowed in Hspice but not in ngspice, which means that the parameter must be removed from the subcircuit definitions (I recall we did something like that when converting the sky130 models, but I didn't do the gf180mcu model conversion).
@Amro Tork: This looks like your issue to handle. . .Tim Edwards
07/13/2023, 9:14 PMmult
is not a parameter that is used in the GF models (and I can't see that they handle multiplicity at all within the models), and that the schematic should define and use m
and not mult
.Tim Edwards
07/13/2023, 9:16 PMChris
07/13/2023, 9:18 PMTim Edwards
07/13/2023, 9:18 PMAmro Tork
07/13/2023, 9:30 PMChris
07/17/2023, 7:02 PMAmro Tork
07/18/2023, 8:27 AMFarag Elsayed
07/18/2023, 11:30 AMm
parameter for FETs. You could use models in Mabrains PR repo
https://github.com/mabrains/globalfoundries-pdk-libs-gf180mcu_fd_prAmro Tork
07/18/2023, 11:31 AMAmro Tork
07/18/2023, 11:32 AMdonn
07/18/2023, 12:10 PMopen_pdks
first. Otherwise, volare builds are going to be the same.Tim Edwards
07/18/2023, 12:52 PMChris
07/19/2023, 12:00 AMTim Edwards
07/19/2023, 12:02 AMStefan Schippers
07/19/2023, 6:51 AMmult=#
is given on the instance but the symbol expects a m
.
The correction is to change the symbols to use for multiplier the mult
instance parameter (as is done also in sky130).
Currently the symbol has the following format
and lvs_format
netlist rules:
format="@spiceprefix@name @pinlist @model L=@L W=@W
+ nf=@nf ad=@ad as=@as pd=@pd ps=@ps
+ nrd=@nrd nrs=@nrs sa=@sa sb=@sb sd=@sd
+ m=@m"
lvs_format="@name @pinlist @model L=@L W=@W nf=@nf m=@m"
You see m=@m, it means set the m
parameter to the instance given m
parameter. The correct definition is:
format="@spiceprefix@name @pinlist @model L=@L W=@W
+ nf=@nf ad=@ad as=@as pd=@pd ps=@ps
+ nrd=@nrd nrs=@nrs sa=@sa sb=@sb sd=@sd
+ m=@mult"
lvs_format="@name @pinlist @model L=@L W=@W nf=@nf m=@mult"
I tried the correction locally but even with the fix no change was observed in simulation. So I will update my open_pdks install for the updatedd spice models and if there are still issues and if needed I will submit a correction to the xschem FET symbols.donn
07/20/2023, 4:57 AMStefan Schippers
07/21/2023, 8:46 AMopen_pdks
and giving '`m=2`' (or whatever other multiplier) on gf180mcu
FET instances now works. ( @Tim Edwards, @Amro Tork) there is no mult
parameter in xschem gf180mcu
symbols. we will probably need that if we plan to evaluate mismatch parameters inside the FET models. If this is the case I will submit a pull request and add mult instance parameters in test circuits. FET Models will get m
and mult
from instance mult
. If there is not such a plan the current xschem symbols are just fine. Give m=<number>
on instances and you get multiplied devices.Tim Edwards
07/21/2023, 1:16 PMmult
used in any of the models. . . I'm not sure how mismatch analysis is supposed to work in the GF PDK. @Amro Tork might know the answer to that.