SPICE (Simulation Program with Integrated Circuit Emphasis) is a widely-used circuit simulation program. It was developed as public domain software at the University of California and versions 2G6 (vanilla SPICE) and 3.0 are still used. The device models and simulation algorithms in vanilla SPICE are excellent but the user interface is unacceptable by today's standards (for example the graphical output is intended for line-printers). There are now numerous commercial variants of SPICE available which have large libraries of device models, more sophisticated analysis options and, most importantly, modern graphical tools for interpreting the simulation results. At Aston two commercial variants of SPICE are available:

PSPICE by MicroSim Corporation. This is available at Aston on IBM PC-compatibles and Apple Macintoshes but both are restricted versions which will only operate on very small circuits. The PC version does not require a maths coprocessor but will use one if it is present. It runs extremely slowly without a coprocessor. The Macintosh version requires a coprocessor or a coprocessor emulator. It runs unbelievably slowly with an emulated coprocessor. These restricted versions of PSPICE are public domain software and you can take copies to run on your own machines if you wish. Refer to the document 'PSPICE User Guide' for more information.

HSPICE by Meta Software. This is available at Aston on the Sun Workstations. This is probably the most powerful version of SPICE available. It is highly optimised and will take advantage of specialised floating point hardware in Sparc1, Sparc2 and Sparc10 processors. It will handle circuits of almost any size (e.g. 250,000 gate simulations at transistor level) and runs very quickly. This document covers the basic information required to prepare a circuit description for HSPICE simulation on a Sun workstation, run the simulation and then examine the results using the graphical analysis program ViewTrace. It assumes you have a working knowledge of the use of Sun SPARC workstations (logging on, file handling, window manipulation using the Open Look Window Manager etc.). An on-line tutorial is provided for using the OpenWindows system on the Suns.

This document is also available in PostScript format on the Aston University WWW server. (URL http://www.eeap.aston.ac.uk/eeap/documents/user-guides.html).


The following conventions are used throughout this guide:

Boldface Exact input or Menu items

Italics Variable user input

Courier File names and file extensions

Underline Used for emphasis only

The symbol n represents the Powerview Red-Square menu.

Sequences of menu choices are shown as a list of items linked by arrows (È). e.g.

Add Graphic È Box.


For those lacking the patience to read the whole of this user guide, this section provides an absolute minimum description of how to get started simulating a simple circuit. There is no explanation and it should not be regarded as a substitute for reading the rest of the documentation and learning to use the software properly.

1. Log on to a workstation with your own user name and password. Allow OpenWindows to start up.

2. In the command tool type powerview & to start the Powerview cockpit running (as a background process).

3. Using the Left mouse button select the Current toolbox menu. From the options choose the toolbox 'Aston Signals and Systems'.

4. Using the Left mouse button select Project È Create.

5. When the dialogue box appears, in the section Project type, select ViewDraw. Then enter a project name of the form ~/project-name, where project-name is your chosen name. Do not omit the tilde (~) character which refers to your home directory

6. Double click Left on the TextEdit icon in the cockpit. When prompted for an HSPICE source file name, Enter example1.hsp . The editor will ask you to confirm that you want to create a new file. Wait for the text editor to start up.

7. Enter the file below:

* RLC Passive Circuit


R1 1 2 20

L1 2 3 1mH

C1 3 0 1uF

VIN 1 0 AC PULSE(0 1 0 0 0 1 5)

.AC DEC 20 10 1MEG

.TRAN 5us 500us


8. Pull down the File menu of the text editor and select Save File.

9. Double-click the left mouse button on the HSPICE icon in the Powerview cockpit. You will be prompted for an HSPICE file name (if you have previously run HSPICE the filename will already be there). Enter the filename example1 and click on 'Accept'.

10. HSPICE will run and you will see a message in the Powerview cockpit log. If you see the message *** HSPICE job concluded then continue to step 12. If you see the message *** HSPICE job aborted then proceed to step 11.

11. In the TextEdit window use File Open to select the file example1.lis . Try and determine why HSPICE failed. If possible, correct example1.hsp with the text editor and repeat step 9.

12. Double-click the left mouse button on the ViewTrace icon in the Powerview cockpit. After a while you will see the ViewTrace File Open dialogue box. Select the 'All' box with the left mouse button. You should see (among others) the files example1.ac0 and example1.tr0. Select example1.ac0 and then click on 'Accept'.

13. A ViewTrace waveform window should appear with two vertical axes - A Voltage axis with three traces V(1), V(2) and V(3), and a Current axis with a single trace I(Vin).

14. Select File È Open from the ViewTrace menu bar. From the File Open dialogue box select example1.tr0 . When the waveform window opens you will see the transient response with the same voltage and current axes as the AC response.

15. Click the red square menu and quit each Powerview program in turn.

16. Now read the rest of this guide.


HSPICE can be run in command line mode but, since you will need to use the Viewlogic ViewTrace tool to analyse the simulation results, you may find it easier to perform all your HSPICE work from within the Viewlogic Powerview environment.

Start Powerview (as a background process) by entering the command:

powerview &.

You will then see the Powerview Cockpit.

Create a new project (or set your current project to an existing project) by pulling down the Project menu and select Project È Create or Project È Set Current. When you next run Powerview your previous project setting will be remembered.

Select the Current Toolbox to Aston Signals and Systems. The Powerview cockpit should then appear as in Fig. 3.1.

Fig 3.1. Aston Signals and Systems Toolbox

The Signals and Systems toolbox has just one drawer called Signals and Systems Design which holds three tools: TextEdit, HSPICE and ViewTrace. To launch a tool just double-click on the appropriate icon. You can leave both the editor and ViewTrace running and open different HSPICE source files and data files respectively from within them. You will need to re-launch the HSPICE simulator each time you use it.

The design flow is shown in Fig. 3.2. The programs are represented by rectangles. Circles represent files. The text inside the circles shows the appropriate file extension. Use the file extension .hsp for source files. All other file extensions are automatically generated.

Fig. 3.2. HSPICE Program and data flow

When you launch HSPICE you will see a prompt (see Fig. 3.3) for an HSPICE source file. Enter just the first part of the filename. Do not give a file extension such as .hsp.

Fig. 3.3. HSPICE source file prompt.

When HSPICE runs you will see a status message in the Powerview Cockpit log window. HSPICE should exit with a status code of zero. If this is not so then you will need to check the log file (.lis) to determine the cause.

When the simulation has finished you should always check the .lis file for errors (using the editor) before attempting any graphical analysis of the results. In addition the results of some analysis tools are reported in this file.

design-name.hsp (HSPICE source file)

design-name.lis (program statistics and error messages)

design-name.stn (DC analysis including device characteristics)

design-name.trn (Transient analysis)

design-name.acn (AC analysis, frequency response)


In the HSPICE syntax descriptions the following typographical conventions are used:

xxx, yyy, zzz Arbitrary alphanumeric strings

<...> Optional data fields

UPPERCASE Keywords, parameter names etc.

lower case Variables to be replaced with a numeric or symbolic value

... Indicates that the item may be repeated any number of times

+ A continuation of the preceding line


HSPICE uses a semi-free format for data with a few restrictions:

* Upper and lower case are not distinguished except in Unix filenames.

* Lines may be no longer than 80 characters. Lines may be continued by entering a plus sign (+) in column 1 of the next line

* Names must begin with a letter and must not contain spaces or other delimiters. Only the first 16 characters of names are significant.

* Numbers may be written as integers (2, -347), floating point (3.141, 4.6) or floating point with exponent (1E3, 5.62E6). Integer or floating point numbers may be followed by any of the scale factors below.

K = 10[3] MEG = 10[6] G = 10[9 ]T = 10[12 ]

M = 10[-3] U = 10[-6] N = 10[-9] P = 10[-12]

* Letters immediately following the number (which are not scale factors) and any letters following the scale factor are ignored.

* Comment statements may be indicated by an asterisk (*) in the first column.


The basic structure of an HSPICE file is:

Title Implicit first line; becomes input netlist title

* Comments to describe circuit

Netlist Circuit description (See Sect. 4.3)

.MODEL Detailed parameters of a device (See Sect.

.LIBRARY Specifies location of device models (See Sect.

Sources Sets input stimuli (See Sect. 4.3.2)

Analyses Statements to perform required analysis (See Sect. 4.4)

.OPTIONS Set simulation conditions (See Sect. 4.5)

.END Terminates file

The first statement in an HSPICE file must be a title statement and the last must be the end statement (.END). The other Statements may be in any order.


The elements in the circuit to be simulated are defined to HSPICE by numbering (or naming) all of the nodes (junctions of components). If node numbers are used they must be positive but need not be consecutive. The ground or reference node is indicated by node number 0 or node name GND. Every node (except transmission lines) must have at least two connections and must have a DC path to ground.

Each circuit element must have its characteristics defined to the HSPICE program. In general the type of element is indicated by the first letter of the component name. If more sophisticated device characteristics are used then a .MODEL statement is required.

4.3.1 Circuit elements

Resistor Rxxx n1 n2 <modelname> value

Capacitor Cxxx n+ n- <modelname> value

Inductor Lxxx n+ n- value

Mutual Inductors Kxxx Lyyy Lzzz value

Junction Diode Dxxx n+ n- modelname

Bipolar Transistor Qxxx nc nb ne modelname

Junction, MESFET and GASFET Jxxx nd ng ns modelname

MOSFET Mxxx nd ng ns modelname

Voltage controlled current source Gxxx n+ n- nc+ nc- value

Voltage controlled voltage source Exxx n+ n- nc+ nc- value

Current controlled current source Fxxx n+ n- vname value

Current controlled voltage source Hxxx n+ n- vname value

n1,n2 Nodes of unpolarised device.

n+,n- Positive and negative device nodes.

nc,nb,ne Collector, base and emitter nodes of bipolar transistor.

nd,ng,ns Drain, gate and source nodes of field-effect transistor

modelname Parameter which specifies which device model is to be used. The device description is given in the .MODEL statement.

nc+,nc- Positive and negative controlling nodes of dependent linear sources.

vname Name of the voltage source through which a controlling current flows.

value Component value in the appropriate units. Subcircuits

Circuits may be described in a hierarchical manner by using sub-circuit descriptions. There are two parts to this. First the sub-circuit is defined with the .SUBCKT statement. Then the sub-circuit is called with an element whose name starts with an X.

.SUBCKT subname n1 <n2 n3 ...> $ Sub-circuit definition

sub-circuit description here...

.ENDS <subname> $ End of definition

Xyyy n1 <n2 n3 ...> subname $ Instance of sub-circuit

For example, the RLC series section (rlc1) in Fig 4.1a is placed twice in the circuit shown in Fig. 4.1b. Note that nodes 1 and 2 (the terminals) of the sub-circuit are not the same as nodes 1 and 2 of the main circuit.

Fig.4.1a. RLC Sub-circuit. 4.1b. RLC sub-circuit in main circuit

.SUBCKT rlc1 1 2 R1 1 2 100

R1 1 3 100 X1 2 0 rlc1

C1 3 4 10n R2 2 3 100

L1 4 2 2m X2 3 0 rlc1

.ENDS R3 3 4 100 Device Models

The initial letter of a component only specifies that it is a generic resistor, capacitor, transistor etc. For some purpose this may suffice but there are thousands of different devices with widely varying properties. The .MODEL statement is used to specify device characteristics and which 'model' of the device is used.

The form of the .MODEL statement is given below:

.MODEL modelname type <parameter-name=value> ...

modelname User defined name for this model.

type Selects the model type which is one of:

AMP Operational amplifier

C Capacitor

D Diode

L magnetic core mutual inductor

NJF N-channel JFET


NPN NPN Bipolar junction transistor

PJF P-channel JFET


PNP PNP Bipolar junction transistor

R Resistor

parameter There are many possible parameters for each device type. It is beyond the scope of this document to describe these here.

Some simple examples:

Bipolar NPN transistor with forward Beta of 200

Q1 3 2 0 bjtmod1

.MODEL bjtmod1 NPN BF=200

Operational Amplifier (internal compensation) with gain of 100,000 and internal feedback compensation capacitance of 27 pF .

XA1 4 3 2 5 6 ampmod1

.MODEL ampmod1 AMP DEF=0 AV=1E5 C2=27P

In practice you can call up models for most devices from a library. See the next section. Device Libraries

HSPICE includes comprehensive libraries of standard parts. To use a library component you should use the .INCLUDE (abbreviated to .INC) statement to specify the filename of the library model to access.

.INC '<path>filename'

Some useful libraries provided are:

/usr/local/hspice/h93a/parts/bjt Bipolar transistors, e.g. t2n2222a.inc

/usr/local/hspice/h93a/parts/dio Diodes, e.g. d1n4001.inc

/usr/local/hspice/h93a/parts/behave Op-amps etc. e.g. alm741.inc

4.3.2 Independent linear sources

These sources are used to represent power supplies and to give time-dependent values for transient analysis.

Vxxx n+ n- <DC value> <AC AC-mag> <AC-phase> <Tran-func>

Iyyy n+ n- <DC value> <AC AC-mag> <AC-phase> <Tran-func>

DC specification

* Voltage sources need not be grounded.

* If a voltage source is time-invariant (e.g. a power supply) then the value may be preceded by the option DC.

Example: A DC supply of 6 Volts between nodes 10 and ground.

VCC 10 0 DC 6

AC specification

AC-mag is the magnitude and AC-phase is the AC phase (in degrees). The source is set to this value in the AC analysis. If the magnitude is omitted a value of unity is assumed. If the phase is omitted it is assumed to be zero.

Example: An AC current source of 1 Amp and 45 degrees phase from nodes 13 to 2.

ISRC 13 2 AC 1 45.0

Transient specification

Any independent source may be assigned a time-varying value for transient analysis. There are several useful specifications described below. Transient Pulse specification

PULSE (v1 v2 <td <tr <tf <pw <per>>>>>)

v1 Initial value in Volts or Amps.

v2 Pulsed value in Volts or Amps.

td Delay time in seconds. Default=0.0.

tr Rise time in seconds. Default=TSTEP.

tf Fall time in seconds. Default=TSTEP.

pw Pulse width in seconds. Default=TSTEP.

per Period in seconds. Default=TSTEP.

For example: Vpulse 1 0 PULSE (0 1 1m 1n 1n 2m) Transient Sinusoidal specification

SIN (vo va freq <td <theta <phi>>>)

vo Offset in Volts or Amps.

va Amplitude in Volts or Amps.

freq Frequency in Hertz.

td Delay in seconds. Default= 0.0.

theta Damping factor in 1/seconds. Default=0.0.

phi Phase delay in degrees. Default=0.0.

For example: Vsin 2 0 SIN (0 1 1k) Transient Exponential specification

EXP (v1 v2 <td1 <tau1 <td2 <tau2>>>>)

v1 Initial value in Volts or Amps

v2 Pulsed value in Volts or Amps

td1 Rise delay time in seconds. Default=0.0.

td2 Fall delay time in seconds. Default= td1 + TSTEP.

tau1 Rise time constant in seconds. Default=TSTEP

tau2 Fall time constant in seconds. Default=TSTEP.

For example: Vexp 4 0 EXP (0 1 1m 2m 50u 50u) Transient Piecewise Linear specification

PWL (t1 v1 <t2 v2> ...<R>)

t1, t2 ... Times of linear segments in seconds

v1, v2 ... Voltage or current values in Volts or Amps.

R Causes waveform to repeat.

For example: Vpwl 5 0 PWL (0 0 1m 1 2m 1 3m 0) Transient Frequency Modulation

SFFM (vo va <fc <mdi <fs>>>)

vo Offset in Volts or Amps

va Amplitude in Volts or Amps

fc Carrier frequency in Hz

mdi Modulation index. Default=0.0

fs Signal frequency in Hz

For example: Vfm 6 0 SFFM (0 1 1k 0.1 10k) Transient Amplitude Modulation

AM (sa oc fm fc td)

sa Signal amplitude

oc Offset constant

fm Modulation frequency

fc Carrier frequency

td Delay time.

For example: Vam 7 0 AM (0 0.1 100 1k 0)


There are three main forms of analysis. In a single run of the HSPICE simulator you may perform any combination of DC, AC and transient analysis. To request each type of analysis simply include a .DC , .AC or .TRAN statement. Each of these modes can include other, more specialised, analysis tools which are requested with additional statements.

4.4.1 DC analysis

The DC analysis statement defines a DC voltage or current range to an existing independent AC or DC source src-name. The circuit is then analysed at every increment incr within the specified DC voltage or current range start..stop. Optionally a second source src2 may be specified with associated sweep parameters. In this case the first source is swept over its range for each value of the second source. To invoke the DC analysis use the .DC statement described below.

.DC src1 start1 stop1 incr1 <src2 start2 stop2 incr2>

src1, src2 Name of independent voltage or current source.

start1, start2 Starting voltage or current

stop1, stop2 Final voltage or current

incr1, incr2 Voltage or current increment value Operating Point analysis

If this analysis is requested then details of the circuit DC operating point are written to the log file (.lis). The syntax of the .OP statement is:

.OP <format> <time> ...

format One of the following keynames (only the first letter is required)

All Full operating point information.

Brief One line summary for each element.

time Times at which the report is printed DC sensitivity analysis

.SENS ov1 <ov2> ...

ov1 Branch current or nodal voltages for DC component sensitivity analysis.

If this analysis is requested HSPICE calculates the DC small-signal sensitivities of each specified output variable relative to every circuit parameter. These measurements are the partial derivatives of each output variable with respect to the value of a given circuit element, taken at the operating point and normalised to the total change in output magnitudes. This may create large amount of information even for small circuits. DC Small-signal Transfer Function

.TF ov srcnam

ov Small-signal output variable

srcnam Small-signal input source.

If this analysis is requested HSPICE calculates the DC small-signal value of the transfer function (input/output), input resistance and output resistance.

4.4.2 AC analysis

The AC small-signal analysis statement is used to perform a circuit analysis over a specified frequency range. The program first solves the DC operating point of the circuit and then determines linearised small-signal models for all non-linear devices in the circuit. To make this analysis meaningful, at least one independent source must be specified with an AC value. The start and stop values need to be specified for this analysis. The circuit is then analysed at a number of points per decade, octave, or linear step over the specified frequency range. The analysis is insensitive to rail voltages so a unity voltage or current source is used. The form of the AC analysis statement is shown below.

.AC type np fstart fstop

type One of the following:

DEC - decade variation

OCT - Octave variation

LIN - Linear variation

POI - List of points.

np Number of points per decade, octave or just number of points, depending on type keyword.

fstart Starting frequency

fstop Final frequency Small-Signal Distortion

.DISTO Rload <inter <skw2 <refpwr <spwf>>>>

Rload The resistor element name of the output load resistor into which the output power is fed.

inter The number of frequency points at which a distortion measure summary is printed.

skw2 The ratio of the second frequency F2 to the nominal frequency F1. the default ratio is 0.9.

refpwr Reference power. The default is 1 mW measured in dBM.

spwf Amplitude of second frequency F2 . The default is 1.0.

Calculates the distortion characteristics of the circuit in an AC small-signal steady-state sinusoidal analysis. The analysis is performed assuming that one or two signal frequencies are imposed at the input. The first frequency F1 is the nominal analysis frequency set by the .AC statement. The optional second input frequency F2 is set implicitly by specifying skw2 (=F2/F1). The distortion analysis is written to the log file (.lis) and contains the following measures at the load resistor:

DIM2 Intermodulation distortion, difference. Relative magnitude and phase of F1-F2.

DIM3 Intermodulation distortion, second difference. Relative magnitude and phase of 2*(F1-F2).

HD2 Second order harmonic distortion. Relative magnitude and phase of 2*F1.

HD3 Third order harmonic distortion. Relative magnitude and phase of 3*F1.

SIM2 Intermodulation distortion, sum. Relative magnitude and phase of F1+F2. Noise

.NOISE ovv srcnam inter

ovv Nodal voltage output variable defining the node at which noise is summed.

srcnam Name of the independent voltage or current source to be used as the noise input reference.

inter Number of frequency points at which a noise summary is to be printed

Calculates the output noise based on the complex AC nodal voltages which in turn are based on the DC operating pint. A noise source is assumed to be not statistically correlated to the other noise sources in the circuit. The total output noise voltage is the RMS sum of the individual noise contributions.

4.4.3 Transient analysis

This analysis causes HSPICE to compute the output variables as a function of time. The circuit is analysed at each time increment within this period. This analysis is sensitive to rail voltages and therefore clipping occurs when supply voltages are exceeded. The transient analysis statement is shown below.

.TRAN tstep tstop <tstart>

tstep Suggested computing time increment. This is modified automatically by HSPICE if necessary.

tstop Time at which transient analysis stops.

tstart If tstart is omitted it is assumed to be zero. Fourier Analysis

.FOUR freq ov1 <ov2> ...

freq Fundamental frequency.

ov1, ov2 Output variables for which the analysis is required.

This causes HSPICE to perform Fourier analysis as part of the transient analysis.

4.4.4 Pole/Zero Analysis

.PZ output input

input Independent voltage or current input source.

output Output variable. Any node voltage or branch current.

This analysis uses the Muller method to calculate the roots of the network transfer function polynomials and reports the results in the HSPICE log (.lis) file.


There are many extra options for controlling simulation. These can usually be specified by adding a .OPTIONS statement (anywhere in the HSPICE file).

.OPTIONS option ...

Some of the more common options are:

CSDF Generate graphical output in Common Simulation Data Format

ACCT Generate accounting and run-time statistics

TNOM=x Sets nominal temperature (Default = 25 [[ring]]C, 298 K)

LIMPTS=x Sets the total number of points used for AC analysis. Default=2001.

NODE Causes a cross-check listing of all element nodes to be printed

INTERP Limits output file size for transient analysis by interpolating data


Example 1. RLC passive circuit.

RLC Passive Circuit

* Circuit elements

R1 1 2 20

L1 2 3 1mH

C1 3 0 1uF

* Voltage Source (A 5V pulse)

Vsupply 1 0 PULSE(0 5 0 0 0 1 2)

* Transient Analysis for 500 micro-seconds

.TRAN 100ns 500us

* The CSDF options statement ensures all data is captured



Example 2. Active Butterworth filter.



R1 1 2 1K

R2 2 3 1K

C1 2 4 226N

C2 3 0 113N


E1 4 0 3 4 100K

VIN 1 0 AC 1 PULSE(0 1 0 0 0 1 5)

.AC DEC 100 10 100K






This is an interactive digital waveform processor which may be used to display and manipulate the output from HSPICE simulations.

Invoke ViewTrace by double-clicking on the ViewTrace icon in the Powerview Cockpit. You will see a dialogue box (Fig. 5.1) where you can enter the name of your waveform file. You must enter a name here. The file extension must be included. If you click on the All box you will see all the valid HSPICE output files in the current project.

Fig. 5.1 ViewTrace Input dialogue box

When ViewTrace starts it displays the ViewTrace window such as the example shown in Fig 5.2. You can use the File commands to read and write other waveform files.

Fig. 5.2. ViewTrace Window

Note the following features of the ViewTrace window shown in Fig. 5.2.

Names Region Contains names of waveforms displayed in Waveforms region. Names which have been hidden or deleted do not appear. Names may be selected by clicking or dragging with the left mouse button.

Values Region Shows value of each waveform at the current 'Point'. You can adjust the 'Point' position.

Waveform Region Shows a graphic representation of each waveform.

(Y) Axis Vertical axis. For digital waveforms this is dimensionless and simply labelled 'Digital'.

(X) Axis Horizontal axis. Gives a time scale corresponding to the portion of the simulation in the wave region.

Point & Mark Moveable points which can be positioned anywhere in the Waveforms region. Used in conjunction with the Info box to measure coordinates and differences.


This section details some of the commands which you may find useful. Not all ViewTrace commands are relevant for HSPICE waveform analysis.

5.1.1 ViewTrace File Menu

The File commands are used to open and close HSPICE output files.

File È Open Allows you to open another waveform file for editing.

File È Write Allows you to save your waveform file. You will be given a list of filetypes (CSDF, PWL, GEN, CMD, BAD) which may be used. It is important that you save waveforms as CSDF (Common Simulation Data Format) files.

5.1.2 ViewTrace View Menu

This provides facilities to move around the waveforms but it is easier (and much quicker) to use the Function keys whose assignments are shown in Fig. 5.3.

Fig. 5.3. ViewTrace Function key assignments

5.1.3 ViewTrace Change Menu

Change È Signal È Name Renames a selected signal. The new name appears in the ViewTrace names region. This should be used to place meaningful names on traces ready for producing hard-copy.

Change È Axis È Type Allows you to change the form of the axis display. Select the axis in the ViewTrace window with the left mouse button. Then select a type from the dialogue box shown in Fig 5.4.

Fig. 5.4. ViewTrace Change Axis Type dialogue box

Change È Axis È Label Allows you change the name displayed on any vertical or horizontal axis. Select the axis in the ViewTrace window with the left mouse button.

Change È Axis È Grid Allows you to display or remove the grid for any vertical or horizontal axis. Select the axis in the ViewTrace window with the left mouse button.

Change È Signal È Colour Allows you to change the displayed colour for a selected signal. You can choose the colour from a palette.

Change È Display È Info Allows you to turn the Info box on or off. The Info box is a small, moveable box which displays the current X-Y coordinates of the Point, the Mark, their difference and their slope.

5.1.4 ViewTrace Signal Menu

Signal È Math Provides a variety of mathematical operation which can be used to modify and create signals. The available operations are presented in a dialogue box which is shown in Fig. 5.5.

Fig. 5.5. ViewTrace Maths dialogue box

Signal È FFT Performs a Fast Fourier Transform on all currently displayed signals and displays the transform in a new window.

5.1.5 ViewTrace Axis Menu

This menu provides facilities for splitting, merging various axes etc. so as to present the waveforms in the most suitable way.

Axis È Add Creates a new vertical axis containing only selected signals from the ViewTrace window. Before using this command select (with the left mouse button) the signals you want to appear on the new axis.

Axis È Join Joins two or more selected vertical axes, combining all signals. Before using this command select (with the left mouse button) the axes you want to join.

Axis È Remove Deletes a vertical axis from the ViewTrace window.

Axis È Split Splits signals on a selected axis into two groups, creating a new axis with the selected signals. Useful for displaying signals with widely varying ranges. Before using this command select (with the left mouse button) the signals you want to appear on the new axis.


Before creating any plots using ViewTrace you should ensure that you have a plot spooling directory defined. Unless you already have one, you will need to create a directory sysplt in your home directory by entering the command mkdir ~/sysplt from a command shell.


High quality A4 and A3 laser prints of simulation waveforms may be produced from the University central laser printers. You must first create a PostScript plot file for each waveform with the n È Plot Setup and n È Plot Go commands which are available within the ViewTrace facility under the red-square menu. You may then submit these files for printing as you would for any other files.

NB. You will be charged for laser printing. Refer to the documents produced by Information Systems.

1. Create your print files.

n È Plot Setup Define the plotting parameters:

Set the plotting device to POSTSCRIPT

Set the paper size to A4 or A3 as required

Set the output device to FILE and change the filename if required. The default filename will be name.001p.

Set the plot contents to FULL SHEET or ZOOMED VIEW as required.

Select APPLY to update parameter changes

Select ACCEPT to update parameter changes and create the plot.

n È Plot Go

Once you have defined the plotting parameters with Plot Setup and if the parameters have not changed you can use Plot Go directly from the red square menu.

Note that this also uses the same filename each time so it is only suitable if you have already printed the previous file.

Wait for the plotting process to complete. You will see messages showing its progress. It will rarely take longer than 30 seconds.

2. Send print files to printer

The print files are created in your current project directory. Each file may be printed with the lp command using the appropriate options or with the OpenWindows Print Tool.

e.g. lp -d paylaser name.001p

NB. The correct printer queues are paylaser for A4 Postscript files and a3ps for A3 PostScript files.

Your prints will be delivered to the pigeon holes by the computer room on the 4th floor of the main building.


Dot matrix printers are provided in each Sun laboratory for quick printing. You will not be charged for dot-matrix prints. Output can be sent directly to these printers from the n È Plot Setup and n È Plot Go commands which are available within the ViewDraw and ViewTrace facilities under the red-square menu.

n È Plot Setup Define the plotting parameters:

Set the plotting device to EPSON 5 (there are several EPSON print devices with varying dot resolutions. The higher resolutions take much longer to print).

Set the output device to SPOOL

Set the plot contents to FULL SHEET or ZOOMED VIEW as required.

Select APPLY to update parameter changes

Select ACCEPT to update parameter changes and create the plot.

n È Plot Go

Once you have defined the plotting parameters with Plot Setup and if the parameters have not changed you can use Plot Go directly from the red square menu.

Note that this also uses the same filename each time so it is only suitable if you have already printed the previous file.

Wait for the plotting process to complete. You will see messages showing its progress. It will rarely take longer than 30 seconds.

If you have any difficulties printing to the dot matrix printer (output quality is very poor, text is missing etc.) then create a plot file and use the command:

lp -d nw402dr filename

Return to EEAP Department Home Page.
Andy Wilton. a.p.wilton@aston.ac.uk