Most simple circuit elements typically require only a few parameter values. However, some devices (semiconductor devices in particular) that are included in SPICE require many parameter values. Often, many devices in a circuit are defined by the same set of device model parameters. For these reasons, a set of device model parameters is defined on a separate .MODEL line and assigned a unique model name. The device element lines in SPICE then refer to the model name. The general form is:
MODEL <model name> <model type> [<param> = <value>]* |
- model name
-
The model name which is used to reference a particular model.
- model type
-
Specifies the type of model. Devices can only reference models of a corresponding type. Must be one of the types outlined in the table that follows:
Element Description Model type Description A
XSPICE device
XSPICE model
XSPICE code model
C
Capacitor
CAP
SPICE3 Capacitor model
PSPICE Capacitor modelD
Diode
D
Diode model
L
Inductor
IND
Inductor model
J
JFET
PJN
NJFP-channel JFET model
N-channel JFET modelM
MOSFET
PMOS
NMOSP-channel MOSFET model
N-channel MOSFET modelO
BJT
PNP
NPNPNP BJT model
NPN BJT modelR
Resistor
R
RESSPICE3 Resistor model
PSPICE Resistor modelS
Voltage controlled switch
SW
VSWITCHSPICE3 Voltage controlled switch
PSPICE Voltage controlled switchU
Uniform distributed RC
URC
Uniform distributed RC model
W
Current controlled switch
ISWITCH
SPICE3 Current controlled switch
PSPICE Current controlled switchX
Subcircuit model
Subcircuit name
Model defined by the user
Z
MESFET
PMF
NMFP-channel MESFET model
N-channel MESFET model
- param=value
-
Parameter values are defined by appending the parameter name followed by an equal sign and the parameter value. Model parameters that are not given a value are assigned the default values. The name must begin with an alphabetic character. The value can be a constant value or a numeric expression. The expressions must be enclosed in braces.
Examples
.MODEL QDEFAULT NPN
.MODEL QMOD PNP ( BF=80 )
.MODEL MURC URC RPERL=50 CPERL=5pF
.MODEL AMP GAIN(gain=5.0)
.MODEL NAND1 D_NAND (RISE_DELAY=0.1 FALL_DELAY=0.2)