Circuit simulation allows the designer to explore his ideas before engaging in production. Concepts can be verified and the circuit can be adjusted quickly and accurately. Circuit simulation also gives the designer the opportunity to perform measurements that may not be physically possible on the manufactured board.

The Simulator is a true mixed-signal simulator, meaning that it can analyze circuits that include both analog and digital devices. The Simulator is based on Berkeley SPICE3f5 code, which was developed by the Department of Electrical Engineering and Computer Sciences, University of California and XSPICE, which was developed by Georgia Tech Research Institude.

Getting Started with Simulation

Once you have created the circuit, there are four simple steps to perform to be able to run a simulation.

  1. Associate a simulation model to each component of the circuit. This step is not necessary if the circuit includes only components ready for simulation such as those contained in the Standard library.

  2. Add the appropriate sources to power and excite the circuit.

  3. Define the points that you wish to observe.

  4. Setup the analyses.

Specify the value of the components

The SPICE engine requires that numerical values should be written with scientific notation (a numerical value followed by an integer exponent such as 1.234e-5) or using the following scale suffixes:

Suffix Scale Description
f, F 10-15 femto
p, P 10-12 pico
n, N 10-9 nano
u, U, µ 10-6 micro
MIL 25.4*10-6 mil
m, M 10-3 milli
k, K 103 kilo
MEG 106 mega
g, G 109 giga
t, T 1012 tera

Characters that follow a number and do not represent a scale suffix and characters that follow a scale suffix are ignored. So the numbers: 1000, 1000.0, 1000Hz, 1e3, 1.0e3, 1KHz, and 1K all represent the same value.

AttenzioneWarning:

All suffixes can be entered either in lower case or upper case. Use MEG to indicate 106. The suffix m or M is always interpreted as milli (10-3). Scale suffixes must be entered immediately after the number, spaces between the number and scale suffixes are not allowed.

Adding the Source Components

Before you can run a simulation, you will need to add the appropriate source components to power ad excite the circuit. The generators can be placed from the Standard library. The sources folder includes DC, Sin, Pulse, Exponential, Piece Wise Linear and FM components, as well as linear and non-linear dependent source components. Once you have positioned the source, double-click on it to set the values.

Defining the Points to be Plotted

The circuit nodes and parameters for which you want to trace the waveform can be specified in three ways:

Setup the Analyses

  1. Choose the Schematic » Simulator » Analyses Setup command or click the tool in the toolbar. The Analyses Setup dialog box opens where you configure all options and analyses for the simulator. The dialog box has four tabs: in the first tab you can set the analyses to be performed, in the second you can define any global parameters, in the third tab you can set the options of the simulator, in the fourth tab are listed the defined I/O models. Each analysis is configured in a different dialog box and it is possible to define several versions of the same analysis by setting different parameters for each of them. Refer to each analysis topic for details on how to configure the simulator to perform that particular type of analysis.

  2. Once the analyses have been configured, you can run a simulation by clicking the Run button at the bottom of the Analyses Setup dialog, by clicking the Run button on the Simulator Toolbar, or by selecting Schematic » Simulator » Run from the menus.

Commands in the simulator toolbar

The commands for running simulations are available in the Schematic » Simulator submenu or in the Simulator toolbar.

Command Description

Analyses Setup 

Opens the Analyses Setup dialog box where the various analyses that can be performed by the Mixed Simulator are defined.

Run 

Starts the analysis. If more than one analysis is defined, the first in the list or the last performed analysis is started.

Setup 

If the circuit contains interactive devices such as switches and potentiometers, you can use the Setup command to set the position of these components before starting the simulation. Select the Setup command and set the status of switches and potentiometers and then select the Run command to start the simulation.

Pause 

Suspends the simulation.

Stop 

Stops the simulation.

Slow 

Slow down the simulation. The amount of slowing down can be set using the SLOWMODEDELAY option.

Operating Point 

Performs Operating Point analysis and sends the results to the schematic. An Operating Point analysis is used to determine the dc operating point of a circuit, with inductors shorted and capacitors opened. The voltages and currents in the circuit can be displayed simply by moving the mouse cursor over a wire or a symbol of an SPICE element (resistor, diode, mosfet, etc.).

Clear OP Results 

Deletes the results of the DC Operating Point analysis.

Use Breakpoints 

Enables or disables the use of breakpoints. A breakpoint is basically a tool that allows you to simulate a circuit with the ability to stop it when certain conditions occur. Breakpoints are available in the Debugging Tools folder in the simdevices.clxjob library.

See also