Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
T- Spice Pro is part of a complete integrated circuit design tool suite for layout,
verification and simulation offered by Tanner EDA. It includes:
• S- Edit: Schematic editor that can generate netlists directly usable in T-Spice.
• T- Spice: analog/ digital circuit simulator
• W- Edit ™: waveform viewer
In this tutorial a brief flow chart from schematic drawing to simulation will be given out. i
SEDIT Tutorial
To learn more about S-Edit, follow the tutorial that makes up the balance of this chapter.
Each section takes only a few minutes to complete.
§ Use the File > Open command to open the supplied file G:\WIN32\TannerT\
Tutorial\schematic\schemex.sdb. This file contains some modules that you
can use to get started.
§ Use the Module > Open command to examine the module list for
schemex.sdb.
Click on the Files pull-down list to view a list of modules in the file. They are as
follows:
To copy a module from a source file to a destination file, the destination file and
module must be displayed.
§ Use the Module > Symbol Browser command to view a list of available
modules. You will see the following dialog:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -2-
§ The file spice.sdb is a library containing modules for various SPICE primitives.
If it is not already loaded, click on Add Library to obtain a Windows file
browser. Navigate to the file G:\WIN32\Tanner EDA\Sedit\Library\spice
.sdb tspro\library directory and select the file spice.sdb.
Click on OK.
§ In the Symbol Browser dialog, select capacitor from the module list and click
on Place. S-Edit will copy the module capacitor in spice.sdb into
schemex.sdb.
§ Click on Close to close the Symbol Browser dialog box. The current file and
module will be schemex.sdb:Module0.
§ Use Module > Open to examine the module list for schemex.sdb. The list
will contain the module capacitor. The letter C next to the module’s name
means that the module has been changed (or added) since the file was last saved.
§ Use the File > Save As command to save the changes, specifying a drive,
directory, and new name for the file (for example, schemex1.sdb).
In this subsection, you will begin the design by creating an inverter module.
§ Use the Module > New command to create a new module named Inv. The new
module is now the current module, as indicated in the Title Bar.
Creating a Schematic
In this subsection, you will instance modules and connect them by wire to create
a schematic.
§ Activate the Module Instance tool , then click with the DRAW button in the
Work Area. The resulting dialog box contains a list of available modules.
Highlight N_4 and click OK. Select this transistor and drag it to the lower half of
the Work Area (using the MOVE-EDIT button).
§ Instance module P_4 in the same way, but position it in the upper half of the
Work Area.
Both transistors are now visible in the schematic. The four open circles on the
ends of the transistors represent pins, at which other schematic objects can be
connected to the instances.
§ Drag the two transistors together so that the top pin of the NMOS transistor lies
over the bottom pin of the PMOS transistor. The open circles will disappear,
indicating that the transistors are connected. The schematic will look like this:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -4-
§ Activate the Wire tool and draw wires to connect the transistors: PMOS gate to
NMOS gate, PMOS bulk to PMOS drain, and NMOS bulk to NMOS drain. The
Wire tool looks like this:
For each wire, click the DRAW mouse button to place the first vertex; move the
mouse and click the DRAW button again to place another vertex, and so on; click
the END mouse button to place the last vertex and finish the wire.
§ When you have drawn the wires, the schematic will look like this:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -5-
§ There are four types of regular ports. Each has a different appearance for the sake
of design readability, but in function they are identical.
§ Activate the appropriate Port tool and add create the input and output nodes to
the schematic. To draw a port, click any mouse button over the desired port
location. In the resulting dialog box, name the port and click OK.
Position the input port on the left side of the schematic and the output port on the
right side.
§ Activate the Wire tool and connect these ports to the instances. When you have
finished, the schematic will look like this.
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -6-
In this subsection, you will create a global symbol representing Ground and add
it to the design.
§ Select Module > New and name the module Gnd. Click OK.
§ Activate the Global Port tool and place a global port at the origin (0,0). Name this
global port Gnd. The coordinate origin will be marked by cross hairs. If the
coordinate origin is not displayed, use the command View > Origin.
§ Using the Line and Polygon tools, draw the symbol for ground. To draw a line or
polygon, click the DRAW button to place the first vertex; move the pointer and
click the DRAW button to place the next vertex, and so on; finally, click the
END button to place the last vertex. Leave the schematic page (the part of the
module viewable in Schematic mode) empty. When you have finished drawing
the Ground symbol, it will look like this:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -7-
Both the module representing Vdd and Gnd should appear in the resulting dialog
box. If not, the global symbols were created incorrectly.
§ Using the Global Instance tool, place the Vdd symbol on the node representing
Vdd.
When you have placed both the Gnd and Vdd symbols, the schematic will look
like this:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -8-
§ Place the capacitor between Gnd and Out, set the capacitor value to be 1pf.
Creating a Symbol
§ Using lines, an all- angle polygon, and ports, draw the inverter symbol shown
above, except for the circle.
§ Activate the Circle tool. Hold the DRAW button at the circle’s center, drag the
circumference to the desired radius, and release the DRAW button.
§ Use the Port tools to place input and output ports on the symbol. Make sure the
names and types of the ports (Input, Output, Bidirectional, or Other) correspond
exactly to the ports in Schematic mode. When you have finished drawing the
module symbol, it should look like this:
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials -9-
§ Use the Module > Open command to open module N_4. Switch to Symbol
mode (see figure below).
All of the text objects in this symbol are properties. On the right side of the symbol
are several transistor parameters: PD, AD, W, L,and so on. When you create a
property, you can choose whether to show or hide its name, value, or name and value
when the module is instanced. In the originating module, S-Edit will enclose hidden
properties or property elements by square brackets, and they will be invisible in
instances of the module. Both L and W are without brackets, so they are visible in
instances.
Output Properties
Above the symbol is a property named SPICE OUTPUT. An output property defines
how instances of this transistor will appear in a SPICE- format file. The value of this
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 10 -
property (or any other property) obeys a special syntax. The SPICE OUTPUT string
is: M${Instance} %{D} %{G} %{S} %{B} NMOS W=${W} L=${L}
AS=${AS} AD=${AD} PS=${PS} PD=${PD}
The table below shows the output results of the various parts of the SPICE
OUTPUT string.
Properties in Instances
§ Use Module > Open to open the module Inv. Switch to Schematic mode.
§ Select the N_4 module instance and use the Edit > Edit Object command to
edit the instance’s properties (see figure below).
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 11 -
§ The value of a property in its instanced module (the originating module) is its
default value. When the Default switch next to a property is on, the property will
take its value from the symbol page of the instanced module. You can also
override the values assigned in the symbol for this instance—if you do, S-Edit
will clear the Default check box for you.
For this instance, the property named L represents the length of the transistor and
the property named W represents the width of the transistor. The default values
for these properties are 2u and 22u, respectively. Now, change the width and
length for this instance only.
If necessary, scroll down until the properties L and W are visible. Change the
value of L from 2u to 5u. Change the value of W from 22u to 8u. Click OK.
Since L and W are visible, the changed values appear on the schematic.
§ Make a similar change to the PMOS transistor. Change the length and width of
the P_4 instance to 5u and 12u, respectively.
§ When you change the values of a property in an instance, the changes affect that
instance only. To change the property value for all instances of a module, you
must edit the property directly in the instanced, or originating, module. Open the
module, switch to Symbol mode, select the property whose value is to be
changed, and use the Edit > Edit Object command to change the value. When
you have changed the value of a property in the instanced module, the value
changes for that property in all instances of that module except those in which the
Default switch has been turned off for the property. You can show or hide
properties in the symbol for this instance.
§ Select the N_4 module instance and use the Edit > Edit Object command.
Scroll down until the SPICE OUTPUT property for this instance is visible. The
property’s viewing parameter is set to None, meaning that the property is not
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 12 -
visible in the schematic. Click All to show the SPICE OUTPUT property’s
name and value. Click OK.
The SPICE OUTPUT property now appears—with node names and property
values substituted for the %{…} and ${…} strings—above the transistor in the
schematic. Only this particular instance shows the SPICE OUTPUT property;
other instances of the N_4 module are unaffected.
Exporting a Netlist
In this section, you will export a SPICE-format file describing the inverter circuit. Before
you export a SPICE- format file, you must define the primitive devices in your design.
Primitive devices are basic circuit elements such as resistors, capacitors, and transistors
for which there exist no further subcircuit descriptions in SPICE. You define a primitive
device when you create a SPICE OUTPUT property for it. S-Edit treats all modules
with SPICE OUTPUT properties as primitives. The library symbols contained in the file
spice.sdb already have such output properties, so you do not need to create them.
§ If you plan to simulate the SPICE file with T-Spice, turn on the Suppress
.END in SPICE output switch.
When this option is switched off, S-Edit writes an .END command at the end of
the SPICE file. Without the .END command, the resulting file can be included in
other SPICE files.
The finished SPICE file resides in the same directory as schemex.sdb, and
looks something like this:
---------------------------------------------------------------------------------------------------
* SPICE netlist written by S-Edit Win32 7.00
* Written on Sep 17, 2001 at 22:32:13
§ Select Analysis and click the Transient button to open the transient analysis
dialog.
§ In simulation length , type 500n . Use default values for the other fields.
§ Select Output and click Transient results to open the Print transient
analysis results dialog.
§ In Node name, type out and A . Use default values for the other fields.
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 14 -
§ Click Add and then click Insert command. The SPICE statement .print tran
v(A) v(Out) will appear in the inv. sp file.
§ Select Files and click Include to open the Include file dialog.
Use Browse to locate model file ml2_ 125. md. This file is located at
<G:\WIN32\TannerT\models\ml2_125.md >. The modelfile with its path
will appear in Include file.
§ Select Voltage source and click the Constant button to open the Constant
source dialog.
§ Click Insert command . The SPICE statement Vdd Vdd GND 5 will appear
in the inv.sp file.
§ Select Voltage source and click the Pulse button to open the Pulse source
dialog.
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 15 -
Run a Simulation
§ Use File > Save to save the file.
§ T- Spice will open a new window displaying the simulation results. It looks like
Parameter Sweeps
In a parameter sweep , a specified parameter is held or initialized at a given value, all
analyses requested by the input file are performed, and the results are recorded. Then the
parameter is incremented by a set amount, and the same analyses are repeated. The cycle
continues as the parameter is incremented through a defined range of values. Parameter
values may be swept linearly —in identical increments, typically through a limited
range— or logarithmically —in exponential increments, typically through a range
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 17 -
spanning multiple orders of magnitude. You can also specify a sweep over a list of
values. Parameter sweeping is performed by using the sweep option with one of the
following commands (all page references are to the T- Spice User Guide and
Reference ):
.ac
.dc
.step
.tran
In this example, instead of keeping the load capacitor in the inverter subcircuit constant,
the capacitor is defined as a variable cap and T- Spice sweeps it over a range of 0.1pF
to 2pF . The .param statement sets a nominal value for cap and the .step command
sweeps cap linearly from 0.1pF to 2pF in increments of 0.1pF .
ECE755 VLSI System Fall 2001 Design Tanner Tools Tutorials - 18 -
i
If you have any problems about the tutorial, please contact Qian Zhang by email
qianz@cae.wisc.edu