1
Virtuoso Schematic Editor Spectre Interface
This chapter describes how to use the Virtuoso® Schematic Editor Spectre® interface. The procedures described in this chapter are deliberately broad and generic. Requirements for your specific design might dictate procedures slightly different from those described here.
This product provides a solution for digital circuit designers to netlist a Virtuoso schematic editor transistor-level schematic for the Spectre circuit simulator. It also provides a batch and scripting solution for automating various tasks. Some of the key features are listed below.
-
Spectre Netlister
This solution provides an Open Simulation System (OSS) netlister for the Spectre circuit simulator from the Virtuoso schematic editor. The netlister works on devices withspectreviews in the Cadencesamplelibrary. The netlister produces a hierarchical parameterized netlist in native circuit simulator syntax. The netlister supports global parameters and design variables and netlist processor (NLP) inheritance of parameters. All devices are netlisted using native circuit simulator syntax. For information on the circuit simulator, see the Spectre Circuit Simulator and Accelerated Parallel Simulator User Guide and Spectre Circuit Simulator Reference. -
Updated Sample Library
Thesamplelibrary provided by Cadence for OSS netlisters has been enhanced for the Spectre circuit simulator. The devicesiprobe,phyres,phyresgnd,nmes, andpmeshave been added to the sample library to support additional circuit simulator models. In addition, most of the circuit simulator instance parameters have been added to the symbol cellview to aid in design creation. -
Improved Simulation Environment
The OSS simulation environment (SE) has been enhanced for the Spectre circuit simulator, which now appears on the menu bar. You can now directly edit netlisting and support files. You can enter model files and design variables through the UI. The combining of the netlist and support files is controlled by the environment. -
Access to Analog Waveform Display for Waveform Display
This solution provides access to the Analog Waveform Display (AWD) tool from the analog circuit design environment. The circuit simulator default format for writing data out is PSF, which is read in by the AWD tool. The simulation environment provides access to this tool and the Results Browser and Waveform calculator. You can choose which signals you want to plot using the Results Browser. For more information on these tools, see the analog circuit design environment documentation and the Cadence Online Support application note “Using AWD with Stand-alone Spectre.” -
OCEAN Batch and Scripting Capabilities
The Virtuoso schematic editor Spectre interface uses the OCEAN batch and scripting product to control the simulator with scripts or interactive commands. It also gives you access to the AWD tool, which allows you to make measurements of waveform data and print them to the screen or a file. All of the standard measurement capabilities of a signal calculator are available from the OCEAN command prompt, as are any macros that you create. You can output data files with either thefprintforocnPrintcommands. For more information on OCEAN, see the Ocean Reference.
This chapter discusses the following topics:
- Starting the Virtuoso Schematic Editor Spectre Interface
- Specifying Input for the Simulation
- Netlisting Your Design and Starting Simulations
- Displaying Results
- Name Mapping
- Checking the Status of Your Simulations
- Running a Simulation Remotely
Starting the Virtuoso Schematic Editor Spectre Interface
To start the Virtuoso® Schematic Editor Spectre® interface,
- Start the Cadence software.
- From the CIW, do one of the following:
- After correct setup, click the OK button to display the Virtuoso schematic editing window.
-
Choose Launch – Simulation – Spectre.
The Spectre menu is added to the menu bar.
If you have not accessed another design during this session or you have never created a circuit simulator run directory for this design, all but one of the commands in the Spectre menu are grayed out. -
Choose Spectre – Initialize.
The Initialize Environment form appears. -
In the Simulation Run Directory field, type the path to the directory where you want to place all of the simulation-related files.
By default, the files are placed inspectre.run1in your startup directory.
If the path defines a new directory, the Initialize Environment form expands:
You can change the name of the run directory or specify a different design. The Browse button brings up the Library Browser, which automatically fills in the Library Name, Cell Name, and View Name fields when you select a new design. - Click OK.
Specifying Input for the Simulation
The Virtuoso schematic editor Spectre interface offers you several ways to provide input to your simulation and to modify that input. Before simulation, you have the option of combining all of these files with the netlist file to create a run file.
After you set up your simulation options, you can specify all the input files for the simulation. The Stimulus menu lists each of these files.
When you select most of these commands, a text editor window opens up, displaying the file. If the editor is empty, you must create the file.
Specifying Input from a Stimulus File
To provide input from a stimulus file to your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Edit Stimulus File.
A text file opens in a text editor window, for exampleemacs. The file is saved asspectre.inpand is placed in the run directory. You do not have to add source statements if you have included sources in your designs.
Sources are specified as instance statements in Spectre syntax. See “Spectre Netlists” in the Spectre Circuit Simulator and Accelerated Parallel Simulator User Guide for more information. -
If you use the text file, connect the sources to the net names on the schematic.
Schematic names are mapped to lowercase. If you use circuit simulator syntax, you must use the lowercase form of net names you are connecting to. Connect to global nets such asgroundfrom the stimulus file. Global nets use a!at the end of the net name and that character must be escaped. In addition, any escaped characters entered in this file must be escaped twice (gnd\\!) because one escape is removed during the merging of netlist files. For more information, see Netlisting Overview.
\[ and \]. For example, a sweep function line must like this:sweep1 sweep param=slope values=\[0.5n 1.0n 1.5n\]
By default, the file should have Spectre circuit simulator syntax. If you use SPICE syntax, the line
simulator lang=spice
must precede the SPICE syntax.
Specifying Input from a Netlist File
To provide input from a netlist file to your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Edit Netlist File.
If you have already netlisted your design using this product, a text editor window opens to display the netlist file, which you can then modify. The netlist file produced in this way is located in the circuit simulator run directory you must create.
If the text editor window opens with an empty file, you have yet to netlist this design.
The file is called netlist and is located in the run directory. This is not the final netlist: it does not include any of the data from the other stimulus files. If netlisting has occurred, it will contain connectivity information for the associated schematic. If you modify this file, you might have to escape certain characters. Also, the next time you netlist this file, all modifications to this file will be lost.
Specifying Input from a Analyses/Options File
To specify circuit simulator analyses and output options for your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Edit Analyses/Options File.
A text file comes up in a text editor. The file starts with some suggested default values that you can use with most designs. You can keep these, delete them, or modify them. However, you must put at least one analysis statement into this file for a simulation to occur. This file is calledspectre.simand is placed in the run directory. This is the default sample file:// Spectre Analyses and Output Options Statements // Output Options // simOptions options // + reltol = 1.00000000E-03 // + vabstol = 1.00000000E-06 // + iabstol = 1.00000000E-12 // + temp = 27 // + save = allpub // + currents = selected // Analyses // dc1 dc oppoint=logfile homotopy=all // tran1 tran stop=1 errpreset=moderate
\[ and \]. For example, a sweep function line must like this:sweep1 sweep param=slope values=\[0.5n 1.0n 1.5n\]
Specifying Input from a Model Include File
To provide input from a model include file to your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Model Include Files.
The Model Include Files form appears. -
Click Add File.
The File Name (Full Path) field is displayed. - Type the complete path to the model file.
- Repeat this process for each model file required.
The files that you specify in this form are placed in include statements in a file called spectre.include in the run directory.
Specifying Input from a Model Include Path
To provide input from a model include path to your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Model Include Paths.
The Model Include Paths form appears. - Enter the path to the files to be used for input into the simulation.
- Click the OK button.
Specifying Input from a Design Variable
To provide input from design variables to your simulation,
-
From the schematic editor window, choose Spectre – Stimulus – Design Variables.
The Design Variables form appears. -
Click Add Variable.
A text field is added at the bottom of the form.
A file calledspectre.varis created in the run directory.
“Design variables” are global parameters that are used throughout your design. You must define all of the global parameters in this form. If you try to access these parameters in included data in SPICE format (.model), you need to limit your parameters to lowercase. Refer to Parameters for more information.
Specifying Input from a Configuration File
To provide input from a configuration file to your simulation,
The configuration file identifies the files the system uses to create the final run file for the simulation. The file, called control, starts with a default list of files from the run directory. You can add another file by copying the syntax shown and placing that file into the run directory for this design. You can also delete a file.
This is the default file content:
// Default Spectre Simulation run title card.
[?netlist]
[?spectre.include]
[?spectre.inp]
[?spectre.sim]
// End of Netlist
The order listed in this file controls the order in which files are included in the final netlist.
Specifying Input from Other Files
To provide input to your simulation that is not covered by the other files provided,
This is a miscellaneous file. It can have any name, but if it is located outside of the run directory, you must provide the full path to its location.
Netlisting Your Design and Starting Simulations
To netlist your design and start simulations,
-
From the schematic editor window, choose Spectre – Netlist/Simulate.
The Netlist and Simulate form appears.
The Simulation Run Directory field is not editable: It displays the run directory you are working with.
To change to a different directory, - Verify that the Simulator Name cyclic field is set to spectre.
-
Turn on the appropriate Run Actions buttons.
create run file is optional. Refer to Netlisting Overview for details on netlisting and the order of run actions. -
(Optional) Set the simulation job to run in the background or foreground of your machine or the remote machine you have selected. Select foreground by turning the Run In Background button off.
If you run the simulation job in background mode, you can use the Job Priority slider to control the job’s access to the processor. A job with a lower priority number gets run sooner. The system tells you when your simulation has finished by displaying a message box.
If you run the simulation job in foreground mode, you are locked out of menus until the task is complete; the status is displayed in the CIW.
Showing Outputs
Once you have tried to create a netlist or a run file, or run a simulation, the system produces the following output files, stored in the run directory.
Each simulation run produces a log. You select background and foreground logs with separate commands. These logs list all the details of the operation of this product. Normally you do not need to read these files, but they are helpful for debugging problems.
-
To examine the output files, do one of the following:
-
To examine the run log file, choose Spectre – Show Outputs – Show Run Log.
These files are useful for debugging. -
To examine the simulation output file, choose Spectre – Show Outputs – Simulation Output.
The system displays thesi.outfile. This is the output log from the Spectre simulator. This is the same information that is printed into thespectre.outfile when running Spectre as a standalone product.
This is a typical example of a short Spectre log:spectre (ver. 4.4.2.60 -- 10 Oct 1997). Simulating `si.inp' on cds9886 at 5:52:23 PM, Mon Nov 10, 1997. Convergence achieved in 2 iterations. Total time required for dc analysis `dc1' was 450 ms.
***********************************************
Transient Analysis `tran1': time = (0 s -> 1 s)
***********************************************
......9......8......7......6......5......4......3......2......1......0 Number of accepted tran steps = 105. Initial condition solution time = 20 ms. Intrinsic tran analysis time = 290 ms. Total time required for tran analysis `tran1' was 320 ms. Aggregate audit (5:52:30 PM, Mon Nov 10, 1997): Time used: CPU = 2.3 s, elapsed = 7 s, util. = 32.9%. Virtual memory used = 1.37 Mbytes.
spectre completes with 0 errors, 0 warnings, and 0 notices.
-
To examine the run file, choose Spectre – Show Outputs – Show Run File.
A form for viewing your final netlist appears. The default name for your final netlist issi.inp.
-
To examine the run log file, choose Spectre – Show Outputs – Show Run Log.
Displaying Results
The Virtuoso schematic editor Spectre interface includes a waveform display tool suite that includes a waveform window, a calculator, and a results browser. This is the same tool suite available to users in the analog design environment.
The Waveform Tool menu varies according to the executable used to start the software.
For more information refer to the refer to the
Name Mapping
To map instance terminals (currents) at device level (nmos, pmos, npn, pnp, etc.), the Virtuoso schematic editor Spectre interface needs to map information from the pins of those primitives in the samples library to the nodes of their models in the Spectre circuit simulator, which are not created by the netlister. If you customize components from the samples library, you need to override the _dcdfTermMapList variable to provide the pin-name–to–model-node name-mapping information for these customized devices. The _dcdfTermMapList variable has the following format:
_dcdfTermMapList=list(list("device_cell_name_1"
list('("pin_name_1"
"model_node_name_in_Spectre_1")
'("pin_name_2"
"model_node_name_in_Spectre_2")
…))
list("device_cell_name_2"
list('("pin_name_"
"model_node_name_in_Spectre_1")
'("pin_name_2"
"model_node_name_in_Spectre_2")
…))
…
)
To view the current value of the _dcdfTermMapList variable,
Use the Results Browser to view the currents saved at subcircuit level.
You can avoid using the Results Browser if you use a current probe (iprobe) to measure the currents between instance terminals at subcircuit level. You can select an instance terminal of iprobe, and the current flowing through the current probe is plotted. If you do not use an iprobe, but select an instance terminal at subcircuit level instead, the voltage signal of the net connected to that instance terminal will be plotted in error.
Checking the Status of Your Simulations
You can use the job monitor to track simulations, even if they are being run remotely. The job monitor identifies the location of the run directory; the day and time the simulation was started; on which computer the simulation is running; whether the simulation is running, has succeeded, or has failed, and what the simulation job priority is.
The commands on the job monitor’s Command menu affect only jobs whose check box is on.
Show Run Log
Set Priority opens the Set Priority dialog box, which allows you to change the priority of a job, even while it is running.
Kill stops any job whose check box is on.
Suspend suspends any job whose check box is on.
Continue resumes any suspended job whose check box is on.
Remove Entry deletes any line whose check box is on from the job monitor window.
Running a Simulation Remotely
To run simulations on a remote workstation, you must configure the remote host. For remote workstations made by different manufacturers, with different operating systems, additional steps are needed.
The Virtuoso schematic editor Spectre interface can find and use all of the standard files in the local directory and run directory for each design, but special additions, such as include files, require that you provide a path to the location of the file. If you cannot specify a path from the target machine back to the source machine, you must copy the file to the target machine and specify a path local to that machine.
- Establish an account on the remote workstation.
-
From the schematic editing window, choose Spectre – Options.
The Simulation Environment Options form appears. - Turn on Run Simulation Remotely.
- In the Simulation Host Name field, type the name of the remote workstation.
-
Turn on Simulation Host is Different Type if the remote workstation is not the same brand or operating system as the local computer.
You do not have to do this to simulate on another machine with a different version of the same operating system. -
If the remote workstation is a different type, create a
.rhostsfile in the remote workstation’s home directory and add this line to it:source_hostname user_name -
Test the remote connect by choosing any file on the local workstation and typing
rcp
Ifsome_fileremote_workstation:/tmprcpdoes not work, edit or disable your.loginfile and/or your shell file (such as.cshrc) on the remote workstation. Oncercpworks, remote simulation should work.-
If you get an error message similar to
account disabled
make sure you have an account on the remote workstation. If you have an active account, your password might have expired. -
If you get an error message similar to
login incorrect
make sure that you have the.rhostsfile in your account on the remote workstation and that it has the correct entry as described above.
-
If you get an error message similar to
Return to top