Manuals >Reference >SPECTRE Simulator
Print version of this Book (PDF file)
prevnext

Circuit Model Descriptions

The following section describes the type of circuit page netlists required when using the SPECTRE interface. Please refer to Circuit Model Descriptions for the netlist requirements for the SPECTRE443, SPECTRE442, or the SPICE3 OSI interfaces.

For valid circuit syntax descriptions, see the Cadence SPECTRE simulator user's documentation.

Specifying Simulator Options

For information on available simulator options and their syntax, refer to the Cadence SPECTRE simulator user's documentation.

Simulator options are specified in the first line of the circuit definition using the following syntax:

 options OPT1 = OPTVAL1 OPT2 = OPTVAL2 ... OPTN = OPTVALN 

where

OPT denotes the option keyword used by the simulator.

OPTVAL is the corresponding option value. Some options do not require a value. This field may or may not be specified, depending on the option.

A space is the only delimiter required between options.

The nominal and operating temperatures, TNOM and TEMP, are commonly used options. TNOM is the temperature at which the model parameters are extracted. TEMP is the temperature at which the simulation is performed.


Note


When performing an optimization to extract model parameters, TEMP and TNOM should be set to the same value so that simulations during optimization are performed at TNOM. TNOM must be defined to guarantee consistency between simulation and extraction.


You can also specify these variables by entering a value (in °C) for the global variables TNOM and TEMP in the System Variables table in the Utilities application.

In general, TNOM and TEMP can be in any variable table, allowing different Models, DUTs or Setups to use different nominal and operating temperatures.

IC-CAP checks for these global variables before running a simulation. If it does not find the variable, IC-CAP uses the value set in the Circuit Editor options statement. Otherwise, IC-CAP analyzes the circuit using the simulator's default values.

Valid SPECTRE Netlist Syntax for IC-CAP

The SPECTRE interface parses netlists written in native SPECTRE syntax.

During a simulation using the SPECTRE template, IC-CAP examines the netlist entered on the Circuit page for:

    • The name of the device to be modelled
    • The external nodes of the device
    • The model-level parameters
    • The device-level parameters

IC-CAP is intended for single-device model extractions. Therefore, not all valid SPECTRE netlists are accepted by IC-CAP.

Valid SPECTRE Constructs

IC-CAP uses 3 SPECTRE constructs:

    • the device statement
    • the subcircuit (subckt) block
    • the model statement

Valid SPECTRE Circuit Page Configurations

There are 3 valid Circuit page configurations:

    • A single device statement and a single model card
    • A single subcircuit block
    • A single device statement followed by a single subcircuit block


Note


Other supporting statements can be added in and around the configurations mentioned above. This includes all valid SPECTRE syntax statements other than the device, subckt, and model statements. These 3 constructs are limited in number and combination as described above.


Describing a Device

A device statement describes a single SPECTRE element of any type. The general form of device statement is:

 DNAME NODE1 NODE2...NODEN MNAME DPAR1=DVAL1 DPAR2=DVAL2

where

DNAME is the device name with the first letter being a simulator-defined key letter, denoting the type of model being specified.

NODE denotes the node name for the device connection.

MNAME is the name of a built-in device, or the name of a model or subcircuit definition. This is the same MNAME specified in the model definition described below.

DPAR is a predefined DUT parameter name.

DVAL is the specified DUT parameter value. Refer to the MNS and SPICE Reference for the DUT parameter names available for each model.

A plus sign ( + ) that appears as the first character of a line or a back slash ( \ ) that appears as the last character in a previous line denotes a continuation of the previous line. This continuation character is often used for easier readability when specifying the model card.

Describing the Model

A model definition specifies the parameters of a particular model that is referenced by a device statement (see Describing a Device). When a parameter is not specified, the default value in the model is used. The general form of the model definition is:

 model MNAME TYPE PNAME1=PVAL1 PNAME2=PVAL2 ...PNAMEN=PVALN 

where

MNAME is the model name. Regardless of the model name entered in the MNAME field of the model definition statement, IC-CAP substitutes the name of the Model as it is called in the Model List when the simulator input deck is built.


Note


Noise is a reserved word in SPECTRE and must not be used in naming components of the netlist. Do not use the name "noise" for DUTs or Models. IC-CAP substitutes the Model/DUT name for the name in the Circuit or Test Circuit folders respectively.


TYPE is a valid SPECTRE component type.

PNAME is a parameter name for the particular model type.

PVAL is the parameter value.

A plus sign ( + ) that appears as the first character of a line or a back slash ( \ ) that appears as the last character in a previous line denotes a continuation of the previous line. This continuation character is often used for easier readability when specifying the model card.

Describing Subcircuits

A subcircuit model is used to describe a circuit that contains more than 1 element.

The syntax is similar to the syntax in SPICE. The subcircuit description must begin with a subckt and end with an ends declaration. Statements between these 2 declarations describe the subcircuit components.

The general form of a subcircuit definition is:

 subckt SUBNAME (NODE1 NODE2...NODEN)
     parameters PAR1=PARVAL1 PAR2=PARVAL2 ...PARN=PARVALN
 
    <subcircuit devices and/or models listed here>
 
    ends SUBNAME

where

SUBNAME is the subcircuit name. Regardless of the subcircuit name entered in the SUBNAME field of the subckt definition statement, IC-CAP substitutes the name of the Model being simulated when the simulator input deck is built.


Note


Noise is a reserved word in SPECTRE and must not be used in naming components of the netlist. Do not use the name "noise" for DUTs or Models. IC-CAP substitutes the Model/DUT name for the name in the Circuit or Test Circuit folders respectively.


NODE denotes the node name for the device connection.

PAR1 ... PARN are subcircuit parameters that can be passed through subcircuit calls. If a subcircuit is used in conjunction with a device statement, then the parameters specified on the device line will also need to be listed here. In this case, those parameters are added to the DUT Parameters table. All other parameters not listed in the device statement will be added to the Model Parameters table. If the subcircuit description is used without an associated device statement, then all parameters listed here will be entered in the DUT Parameters table.

PARVAL1 ... PARVALN are the corresponding parameter values. Depending on the context (see previous paragraph), these parameters become either DUT parameters or model parameters which can be modified in the DUT Parameters table of the Model Parameters table.

The body of the subcircuit model description contains the components of the subcircuit using element and model statements.

Using a Device Statement and Model Card Configuration

The device statement and model card is the simplest circuit page configuration. The template parses the model card into the Model Parameters page and the device parameters into the DUT Parameters page. The device statement provides the external nodes.

Example syntax:
q1 C B E S NPN area = 1.0
model NPN bjt
+ is = 1E-16
+ bf = 100

In this case, is and bf will appear on the Model Parameters page, and area will appear in the DUT Parameters page.


Note


The device statement and model card may appear in any order.


Using a Single Subcircuit Block Configuration

This circuit page configuration interprets the subcircuit as a single device. If the subcircuit includes a Parameters statement, the template parses these parameters as device parameters, where they appear in the DUT Parameter Table. All parameters on model or device statements within the subcircuit appear in the Model Parameter Table in the form:

<inst/model>.<parameter>
Example syntax:
subckt realnpn (C B E)
parameters area=1
LE E 4 inductor l=.35n
LB B 5 inductor l=.2n
CC C 0 capacitor c=.255p
Q1 C 5 4 NPN area = area
model NPN bjt
+ is = 1E-16
+ bf = 100
ends realnpn

In this case, LE.l, LB.l, CC.c, NPN.is, and NPN.bf will appear in the Model Parameters table and area will appear in each DUT Parameters table.


Note


Note, Q1.area does not appear because its value is not a simple number. IC-CAP only identifies parameters with simple numbers for extraction.


When this circuit is simulated, IC-CAP outputs the subcircuit as well as an device statement to call the subcircuit.

See the example file model_files/bjt/spectre_ncehf.mdl for a working model.

Using a Device Statement Followed by a Subcircuit Block

In some situations, you must extract parameters from a device defined by a subcircuit whose parameters listed in the Parameters statement within the subcircuit are your model parameters and not your device parameters. Use the "device statement followed by a subcircuit block" configuration.

In this configuration, all parameters listed with the subcircuit parameters statement are parsed as model parameters, unless they are referenced on the device statement, in which case they are treated as device parameters.

Example syntax:
q1 C B E S realnpn area=1.0
subckt realnpn C B E S
parameters area=1.0 is=1e-16 bf=100 lb=1
lb1 B 1 inductor l=lb
q1 C 1 E S NPN area=area
model NPN bjt is=is bf=bf
ends realnpn

In the this example, there are 3 model parameters, is, bf and lb, and 1 device parameter, area.

Note the difference between this configuration and the single-subcircuit configuration which has only a subckt definition and no device.

Test Circuits and Hierarchical Simulation

When characterizing a circuit, it is often necessary to add circuitry around a circuit or device to model the actual measurement Setup. IC-CAP provides a Test Circuit Editor to allow modeling of this additional bias circuitry. Select the DUT from the DUT/Setup panel. Click the Test Circuit tab and enter the test circuit description in the same manner you would enter a Circuit Description. The test circuit definition should include a call to the device or subcircuit defined in the Circuit Editor, as well as the additional circuitry needed to model the external parasitics of the measurement Setup.


Note


When you define a test circuit, the DUT Parameter table contains the values specified in the test circuit specification. Regardless of the subcircuit name entered in the SUBNAME field of the subckt declaration, IC-CAP uses the name of the DUT being simulated when the simulator input deck is built.



Note


Noise is a reserved word in SPECTRE and must not be used in naming components of the netlist. Do not use the name "noise" for DUTs or Models. IC-CAP substitutes the Model/DUT name for the name in the Circuit or Test Circuit folders respectively.


Subcircuit and device model specifications can be called from inside another model. This enables you to perform hierarchical simulations to study a circuit at different levels.

When making reference to another model, the model name must be used as it appears in the IC-CAP Model List. For example, assume you have defined 3 models, model1, model2, and model3. model1 has a circuit model description that is a device definition. The circuit model description for model2 is a subcircuit definition at the gate level that includes a call to model1 in a device call statement. And, the circuit model description for model3 is a subcircuit definition that includes a call to model2 in a subcircuit call statement. When you simulate a Setup in model3, IC-CAP traverses the Model hierarchy and uses the circuit model description defined in model3, which includes calls to model1 and model2. The syntax for calling a device model is identical to that described in the Device Model Description section.

The general form of the device call is:

 DNAME NODE1 NODE2...NODEN MNAME DPAR1=DVAL1 DPAR2=DVAL2

Calling a subcircuit specification allows you to insert an entire subcircuit into a circuit as if it were a single component. The call requires a syntax identical to that used in SPECTRE. The general form of the subcircuit call is:

 DNAME NODE1 NODE2...NODEN SUBNAME DPAR1=DVAL1 DPAR2=DVAL2

where

DNAME is the name of the subcircuit call statement. The only requirement for this name is that it must start with the letter D.

NODE denotes the node name for the device connection.

SUBNAME is the name of the subcircuit, previously described by a subckt definition. This must have the name of the model as it appears in the Model List if it is in a different model.

DPAR are passed in the parameter names.

DVAL are subcircuit parameter values. The order in which they are listed in the subcircuit call statement must match the parameters list in the subcircuit definition.


Note


When a test circuit is included in the Model, IC-CAP uses the test circuit description as the top level circuit definition. The node number connections defined in the test circuit description, not the circuit description, are used as the external nodes. Because of this, any node-number-to-node-name cross-referencing in the circuit description is not used. Only node names equated to node numbers in the test circuit description can be used when specifying Inputs and Outputs in the Setup Editor. When only node numbers are specified in the test circuit description, (that is, they are not equated to node names) these same node numbers must be used in the Input and Output node fields.



prevnext