Discrete Device Libraries

Avant!'s Discrete Device Library (DDL) is a collection of Star-Hspice models of discrete components. The $installdir/parts directory contains the various subdirectories that make up the DDL. BJT, MESFET, JFET, MOSFET, and diode models are derived from laboratory measurements using Avant!'s ATEM discrete device characterization system. Behavior of op-amp, comparator, timer, SCR and converter models closely resembles that described in manufacturers' data sheets. Op-amp models are created using the built-in Star-Hspice op-amp model generator.


NOTE:  $installdir is an environment variable whose value is the path name to the directory in which Star-Hspice is installed. That directory is called the installation directory. The installation directory contains subdirectories such as / parts and /bin , as well as certain files, such as a prototype meta.cfg file and Star-Hspice license files.

DDL Library Access

To include a DDL library component in a data file, use the X subcircuit call statement with the DDL element call. The DDL element statement includes the model name that is used in the actual DDL library file. For example, the following Star-Hspice element statement creates an instance of the 1N4004 diode model:

X1 2 1 D1N4004

where D1N4004 is the model name. See Element and Source Statements and the chapters on specific types of devices for descriptions of element statements.

Optional parameter fields in the element statement can override the internal specification of the model. For example, for op-amp devices, the designer can override offset voltage and gain and offset current. Since the DDL library devices are based on Star-Hspice circuit level models, the effects of supply voltage, loading, and temperature are automatically compensated for in a simulation.

Star-Hspice accesses DDL models in several ways on most computers:

1. An hspice.ini initialization file is created when the installation script is run.
The search path for the DDL and vendor libraries is written into a
.OPTIONS SEARCH = `<lib_path>' statement to give all users immediate
access to all libraries. The models are automatically included on usage in the
input netlist. When a model or subcircuit is referenced in the input netlist,
the directory to which the = DDLPATH environment variable points is
searched for a file with the same name as the reference name. This file is an
include file, so its filename has the suffix .inc. The DDLPATH variable is
set in the meta.cfg configuration file when Star-Hspice is installed.

2. Set .OPTIONS SEARCH = `<library_path>' in the input netlist. This
method allows you to list personal libraries to be searched. The default
libraries referenced in the hspice.ini file are searched first. Libraries are
searched in the order in which they are encountered in the input file.

3. Directly include a specific model using the .INCLUDE statement. For
example, to use a model named T2N2211, store the model in a file named
T2N2211.inc and put the following statement in the input file:

.INCLUDE <path>/T2N2211.inc

Since this method requires that each model be stored in its own .inc file, it is not generally useful, but it can be used for debugging new models when the number of models to be tested is small.

Vendor Libraries

The interface between commercial parts and circuit or system simulation is the vendor library. ASIC vendors provide comprehensive cells corresponding to inverters, gates, latches, and output buffers. Memory and microprocessor vendors generally supply input and output buffers. Interface vendors supply complete cells for simple functions and output buffers for generic family output. Analog vendors supply behavioral models. To avoid name and parameter conflicts, vendor cell libraries should keep their models within the subcircuit definitions.

Figure 3-6: Vendor Library Usage

Subcircuit Library Structure

Your library structure must adhere to the Star-Hspice implicit subcircuit .INCLUDE statement specification feature. This Star-Hspice function allows you to specify the directory that the subcircuit file (<subname>.inc) resides in, and then reference the name <subname> in each subcircuit call.

Component naming conventions require that each subcircuit be of the form <subname>.inc and stored in a directory that is accessible through the .OPTIONS SEARCH = `<libdir>' statement.

Create subcircuit libraries in a hierarchical structure. This typically implies that the top-level subcircuit describes the input/output buffer fully and any hierarchy is buried inside. The buried hierarchy can include lower level components, model statements, and parameter assignments. Your library cannot use the Star Hspice .LIB or .INCLUDE statements anywhere in the hierarchy.

Star-Hspice Manual - Release 2001.2 - June 2001