I have seen that the native 3v3 nfet has no model....
# analog-design
m
I have seen that the native 3v3 nfet has no model. Has this been fixed in more recent versions of skywater130?
t
It has a model. It's in
sky130A/libs.ref/sky130_fd_pr/spice/sky130_fd_pr__nfet_03v3_nvt.pm3.spice
in the installed PDK. It has always been there.
m
I have tried using the native mos toaday and spice didn't find a model for it. Do i have to do something in particular for it to work?
t
No. I was simulating a circuit with the
nfet_03v3_nvt
just a few days ago. The standard
.lib
statement should include the model. Are you doing this from xschem? How is your testbench set up to include the model files?
Oh, there is one issue that might be the problem here: The
nfet_03v3_nvt
model is much more restricted in the range of widths and lengths available for the device model. You may need to change W and L and/or NF to get something that is in a characterized range. I'll post the available ranges.
Here are the valid ranges for `nfet_03v3_nvt`: L=0.5um, W=0.42, 0.7, 1.0, 4.0, 10.0 to 100.0um. L=0.6um, W=0.42, 0.7, 1um. L=0.8um, W=0.42um. All values other than the W=10 to 100um range are very specific and must be exact values, although of course you can make a multiple of any width value by using multiple fingers.
🙌 1
👍 1
Very recently, I merged the pull request for the continuous-valued models into the sky130_fd_pr library fork on efabless, which is the fork of the open PDK used by the open_pdks installer. So with a recent installation of open_pdks, you should be able to use any W and L value for the device; the difference is that you need to run with, e.g.,
.lib _$PDK_ROOT_/sky130A/libs.tech/combined/sky130.lib.spice tt
(in xschem, this needs a bit of extra work since this is a different directory than that pointed to by `SKYWATER_MODELS`; I need to update the xschemrc file to include a path for the continuous models).
(Which reminds me to point this out to @Stefan Schippers because I don't think he (or anybody else, really) knows that I added the continuous-valued models to the open_pdks installation. I didn't make a big announcement about it because it still hasn't been thoroughly tested. For example, the other day I discovered that there are some missing include statements that prevent monte carlo simulation from working with the continuous models.)
👍 1
m
Thank you very much! I think the lengths and widths were the problem.
s
@Tim Edwards Continuous models are a great milestone, getting rid of W / L boundary discontinuities that are annoying, expecially in optimization algorithms. My questions: • Do you plan to set up an environmental variable to tell if Continuous or Binned model sets are to be used? (similarly to already existing PDK_ROOT and PDK variables) • Are the two model sets interchangeable? Or something must be changed in the circuit netlist? On xschem side just the SKYWATER_MODELS variable needs to be set correctly to use continuous or binned models without (hopefully) any further editing on testbenches.
t
@Stefan Schippers: The model sets are interchangeable. The way I have it currently set up, the old models are in
sky130A/libs.tech/ngspice
while the new ones are in
sky130A/libs.tech/combined
("combined" meaning a combination of the new continuous-valued models and the old models for all the devices that were not part of the continuous-valued set; e.g., the bipolar transistors are still the old models and still valid only for the specific layouts). The models in the
combined
path are largely self-contained inside that path, and don't include model files from
sky130A/libs.ref/sky130_fd_pr
(except, as just mentioned, the devices that weren't in the set of continuous-valued models). The models in the
libs.ref/sky130_fd_pr
path are all the old discrete-valued models. The bottom line is that switching between them is (or should be---as I said, there are a few errors that need to be fixed) simply a matter of changing
ngspice
to
combined
in the path name. The implementation is largely up to you based on what you think works best within xschem; you can either change
SKYWATER_MODELS
based on another setting, or have another variable name for the path to the continuous-valued models.
If I get the several errors fixed and there is no reason to believe that the combined models set is worse in any sense than the original set of models, then the simplest solution would be just to replace the old models with the new ones, and relegate the old models to the dustbin of history.
👌 1
s
Ok, thank you for the explanation. I think I will redefine SKYWATER_MODELS based on some other setting (either an explicit xschemrc setting or an environment variable) to point to the right models. This allows to re-simulate old designs with the new models without changing the testbenches (Using another variable requires a change, albeit minimal).
m
I am trying to creat a monte carlo testbench but the 'mc' corners produces this error. It is similar to the error i got for the native NFET that didn't have the right W/L. Is there a way to fix this? And I have another question. Is there a way to sweep corners?
s
@Tim Edwards I have rebuilt and installed open_pdks but i see no combined/ directory for the continuous models. I ran a a
make veryclean
followed by a
./configure --enable-gf180mcu-pdk --prefix=/home/schippes
,
make
and
make install
. Do I need to add some options to configure? The git log of the sources show that installation of combined should be done. (commit cbfa592c66d3331d59cce58b6b553858a55a0137)
t
@Stefan Schippers: The continuous models are part of the sky130 PDK, not the GF180 PDK.
@Medinceanu Paul-Catalin: The Monte Carlo
mc
corner uses different models than the other corners (
tt
,
ss
, etc.), and those models are all discretely binned, even when the other corner models aren't. The continuous models should, in theory at least, get around that limitation, once I figure out which include statements are missing.
s
@Tim Edwards Oh so when I specify
--enable-gf180mcu-pdk
in the configure script only gf180mcu will be installed. I thought sky130 was always installed. So I will try again also with
--enable-sky130-pdk
t
@Stefan Schippers: That might have been the default at some time, but currently there are no "default" enabled PDKs, and each one you want to generate needs an
--enable-*
entry.
Please let me know if any of the documentation says otherwise.