OrCAD PSpice®
User’s Guide
Copyright © 1998 OrCAD, Inc. All rights reserved.
Trademarks
OrCAD, OrCAD Layout, OrCAD Express, OrCAD Capture, OrCAD PSpice, and OrCAD PSpice A/D are registered trademarks of OrCAD, Inc. OrCAD Capture CIS, and OrCAD Express CIS are trademarks of OrCAD, Inc.
Microsoft, Visual Basic, Windows, Windows NT, and other names of Microsoft products referenced herein are trademarks or registered trademarks of Microsoft Corporation.
All other brand and product names mentioned herein are used for identification purposes only, and are trademarks or registered trademarks of their respective holders.
Part Number 60-30-636 |
|
First edition 30 November 1998 |
|
Technical Support |
(503) 671-9400 |
Corporate offices |
(503) 671-9500 |
OrCAD Japan K.K. |
81-45-621-1911 |
OrCAD UK Ltd. |
44-1256-381-400 |
Fax |
(503) 671-9501 |
General email |
info@orcad.com |
Technical Support email |
techsupport@orcad.com |
World Wide Web |
http://www.orcad.com |
OrCAD Design Network (ODN) http://www.orcad.com/odn
9300 SW Nimbus Ave.
Beaverton, OR 97008 USA
Before you begin xxiii
|
Welcome to OrCAD . . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . |
xxiii |
|
|
OrCAD PSpice overview . . . . . . . . . . . . . |
. . . . . . . . . . . . . |
xxiv |
|
|
How to use this guide . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . . xxv |
||
|
Typographical conventions . . . . . . . . . |
. . . . . . . . . . . . . . xxv |
||
|
Related documentation . . . . . . . . . . . . . . |
. . . . . . . . . . . . . |
xxvi |
|
|
Online Help . . . . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . |
xxvii |
|
|
If you have the demo CD-ROM . . . . . . . |
. . . . . . . . . . . . . xxviii |
||
|
OrCAD demo CD-ROM . . . . . . . . . |
. . . . . . . . . . . . . xxviii |
||
|
What’s New . . . . . . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . . xxix |
||
Part one |
Simulation primer |
|
|
|
Chapter 1 |
Things you need to know 1 |
|
|
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
1 |
||
|
What is PSpice? . . . . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . . . |
2 |
|
|
Analyses you can run with PSpice . . . . . . . . |
. . . . . . . . . . . . . . . |
3 |
|
|
Basic analyses . . . . . . . . . . . . . . . . . |
. . . . . . . . . . . . . . . |
3 |
|
|
DC sweep & other DC calculations . . . |
. . . . . . . . . . . . . . . |
3 |
|
|
AC sweep and noise . . . . . . . . . . . |
. . . . . . . . . . . . . . . |
4 |
|
|
Transient and Fourier . . . . . . . . . . . |
. . . . . . . . . . . . . . . |
5 |
|
|
Advanced multi-run analyses . . . . . . . . |
. . . . . . . . . . . . . . . |
6 |
|
|
Parametric and temperature . . . . . . . |
. . . . . . . . . . . . . . . |
6 |
|
|
Monte Carlo and sensitivity/worst-case |
. . . . . . . . . . . . . . . |
7 |
|
|
Analyzing waveforms with PSpice . . . . . . . |
. . . . . . . . . . . . . . . |
8 |
|
|
What is waveform analysis? . . . . . . . . . |
. . . . . . . . . . . . . . . |
8 |
|
|
Using PSpice with other OrCAD programs . . . |
. . . . . . . . . . . . . . . |
9 |
|
|
Using Capture to prepare for simulation . |
. . . . . . . . . . . . . . . |
9 |
|
|
What is the Stimulus Editor? . . . . . . . . |
. . . . . . . . . . . . . . . |
9 |
|
|
What is the Model Editor? . . . . . . . . . . |
. . . . . . . . . . . . . . . 10 |
Contents
|
Files needed for simulation . . . . . . . . . . . . . . . . . . . . . . . . . . |
10 |
|
Files that Capture generates . . . . . . . . . . . . . . . . . . . . . . . |
10 |
|
Netlist file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
11 |
|
Circuit file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
11 |
|
Other files that you can configure for simulation . . . . . . . . . . . |
11 |
|
Model library . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
12 |
|
Stimulus file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
13 |
|
Include file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
13 |
|
Configuring model library, stimulus, and |
|
|
include files . . . . . . . . . . . . . . . . . . . . . . . . . . |
13 |
|
Files that PSpice generates . . . . . . . . . . . . . . . . . . . . . . . . . . |
14 |
|
Waveform data file . . . . . . . . . . . . . . . . . . . . . . . . . . |
14 |
|
PSpice output file . . . . . . . . . . . . . . . . . . . . . . . . . . . |
14 |
Chapter 2 |
Simulation examples 15 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
15 |
|
Example circuit creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
16 |
|
Finding out more about setting up your design . . . . . . . . . . . . |
21 |
|
Running PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
22 |
|
Performing a bias point analysis . . . . . . . . . . . . . . . . . . . . . |
22 |
|
Using the simulation output file . . . . . . . . . . . . . . . . . . . . . |
24 |
|
Finding out more about bias point calculations . . . . . . . . . . . . |
25 |
|
DC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
26 |
|
Setting up and running a DC sweep analysis . . . . . . . . . . . . . . |
26 |
|
Displaying DC analysis results . . . . . . . . . . . . . . . . . . . . . . |
28 |
|
Finding out more about DC sweep analysis . . . . . . . . . . . . . . |
31 |
|
Transient analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
32 |
|
Finding out more about transient analysis . . . . . . . . . . . . . . . |
36 |
|
AC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
37 |
|
Setting up and running an AC sweep analysis . . . . . . . . . . . . . |
37 |
|
AC sweep analysis results . . . . . . . . . . . . . . . . . . . . . . . . |
39 |
|
Finding out more about AC sweep and noise analysis . . . . . . . . |
41 |
|
Parametric analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
42 |
|
Setting up and running the parametric analysis . . . . . . . . . . . . |
43 |
|
Analyzing waveform families . . . . . . . . . . . . . . . . . . . . . . |
45 |
|
Finding out more about parametric analysis . . . . . . . . . . . . . . |
48 |
|
Performance analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
49 |
|
Finding out more about performance analysis . . . . . . . . . . . . . |
51 |
iv
|
|
|
|
|
|
Contents |
Part two |
Design entry |
|
|
|
|
|
Chapter 3 |
Preparing a design for simulation |
55 |
|
|
|
|
|
Chapter overview |
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 |
||||
|
Checklist for simulation setup . . . . . . . . . . . . . . . . . . . . . . . . . 56 |
|||||
|
Typical simulation setup steps . . . . . . . . . . . . . . . . . . . . . . . 56 |
|||||
|
Advanced design entry and simulation setup steps . . . . . . . . . . . 57 |
|||||
|
When netlisting fails or the simulation |
|
|
|||
|
does not start . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 58 |
||||
|
Things to check in your design |
. . . . . . . . . . . . . . . . . . . . 58 |
||||
|
Things to check in your system configuration . . . . . . . . . . . . 59 |
|||||
|
Using parts that you can simulate |
. . . . . . . . . . . . . . . . . . . . . . . 60 |
||||
|
Vendor-supplied parts . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 |
|||||
|
Part naming conventions . . . . . . . . . . . . . . . . . . . . . . . . 61 |
|||||
|
Finding the part that you want |
. . . . . . . . . . . . . . . . . . . . 62 |
||||
|
Passive parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 |
|||||
|
Breakout parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 65 |
||||
|
Behavioral parts . . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 66 |
||||
|
Using global parameters and expressions for values |
. . . . . . . . . . . . 67 |
||||
|
Global parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 67 |
|||||
|
Declaring and using a global parameter . . . . . . . . . . . . . . . 67 |
|||||
|
Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 |
|||||
|
Specifying expressions . . . . . . . . . . . . . . . . . . . . . . . . . 69 |
|||||
|
Defining power supplies . . . . . . . . . . . . . . . . . . . . . . . . . . . . 74 |
|||||
|
For the analog portion of your circuit . . . . . . . . . . . . . . . . . . . 74 |
|||||
|
Defining stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 75 |
||||
|
Analog stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 |
|||||
|
Using VSTIM and ISTIM . . . . . . . . . . . . . . . . . . . . . . . . 76 |
|||||
|
If you want to specify multiple stimulus types |
. . . . . . . . . . . 77 |
||||
|
Things to watch for |
. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 |
||||
|
Unmodeled parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79 |
|||||
|
Do this if the part in question is from the OrCAD libraries |
. . . . 79 |
||||
|
Check for this if the part in question is custom-built . . . . |
. . . . 81 |
||||
|
Unconfigured model, stimulus, or include files . . . . . . . . . |
. . . . 81 |
||||
|
Check for this . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 82 |
||||
|
Unmodeled pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 82 |
|||||
|
Check for this . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 83 |
||||
|
Missing ground . . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 83 |
||||
|
Check for this . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 83 |
||||
|
Missing DC path to ground . . . . . . . . . . . . . . . . . . . . |
. . . . 84 |
||||
|
Check for this . . . . . . . . . . . . . . . . . . . . . . . . . . |
. . . . 84 |
v
Contents
Chapter 4 |
Creating and editing models 85 |
|
|
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
85 |
||
|
What are models? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
87 |
||
|
Models defined as model parameter sets . . . . . . . . . . . . . . |
87 |
||
|
Models defined as subcircuit netlists . . . . . . . . . . . . . . . . |
87 |
||
|
How are models organized? . . . . . . . . . . . . . . . . . . . . . . . . . |
88 |
||
|
Model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
88 |
||
|
Model library configuration . . . . . . . . . . . . . . . . . . . . . . . |
89 |
||
|
Global vs. design models and libraries . . . . . . . . . . . . . . . . . |
89 |
||
|
Nested model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . |
90 |
||
|
OrCAD-provided models . . . . . . . . . . . . . . . . . . . . . . . . . |
90 |
||
|
Tools to create and edit models . . . . . . . . . . . . . . . . . . . . . . . . |
91 |
||
|
Ways to create and edit models . . . . . . . . . . . . . . . . . . . . . . . . |
92 |
||
|
Using the Model Editor to |
|
|
|
|
edit models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
93 |
||
|
Ways to use the Model Editor . . . . . . . . . . . . . . . . . . . . . . |
94 |
||
|
Model Editor-supported device types . . . . . . . . . . . . . . . . . . |
95 |
||
|
Ways To Characterize Models . . . . . . . . . . . . . . . . . . . . . . |
96 |
||
|
Creating models from data sheet information . . . . . . . . . . . |
96 |
||
|
Analyzing the effect of model parameters |
|
|
|
|
on device characteristics . . . . . . . . . . . . . . . . . . . |
97 |
||
|
How to fit models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
97 |
||
|
Running the Model Editor alone . . . . . . . . . . . . . . . . . . . . . |
99 |
||
|
Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . . |
99 |
||
|
Enabling and disabling automatic part creation |
. . . . . . . . . . 100 |
||
|
Saving global models (and parts) |
. . . . . . . . . . . . . . . . . . 100 |
||
|
Running the Model Editor from the schematic page editor . . . . . . 101 |
|||
|
What is an instance model? . . . . . . . . . . . . . . . . . . . . . . 101 |
|||
|
Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . . 102 |
|||
|
Saving design models . . . . . . . . . . . . . . . . . . . . . . . . . 102 |
|||
|
What happens if you don’t save the instance model . . . . . . . . 103 |
|||
|
The Model Editor tutorial . . . . . . . . . . . . . . . . . . . . . . . . . 104 |
|||
|
Creating the half-wave rectifier design . . . . . . . . . . . . . . . 104 |
|||
|
Using the Model Editor to edit the D1 diode model . . . . . . . . 105 |
|||
|
Entering data sheet information |
. . . . . . . . . . . . . . . . . . . 105 |
||
|
Extracting model parameters . . . . . . . . . . . . . . . . . . . . . 107 |
|||
|
Adding curves for more than one temperature |
. . . . . . . . . . 108 |
||
|
Completing the model definition |
. . . . . . . . . . . . . . . . . . 109 |
||
|
Editing model text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
110 |
||
|
Editing .MODEL definitions . . . . . . . . . . . . . . . . . . . . . |
110 |
||
|
Editing .SUBCKT definitions . . . . . . . . . . . . . . . . . . . . . |
111 |
vi
Contents
|
Changing the model name . . . . . . . . . . . . . . . . . . . . . . |
111 |
|
Starting the Model Editor |
|
|
from the schematic page editor in Capture . . . . . . . . . . |
111 |
|
What is an instance model? . . . . . . . . . . . . . . . . . . . . . |
112 |
|
Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . |
112 |
|
Saving design models . . . . . . . . . . . . . . . . . . . . . . . . |
113 |
|
Example: editing a Q2N2222 instance model . . . . . . . . . . . . . . |
114 |
|
Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . |
114 |
|
Editing the Q2N2222-X model instance . . . . . . . . . . . . . . |
114 |
|
Saving the edits and updating the schematic . . . . . . . . . . . |
115 |
|
Using the Create Subcircuit command . . . . . . . . . . . . . . . . . . . |
115 |
|
Changing the model reference to an existing model definition . . . . . . 117 |
|
|
Reusing instance models . . . . . . . . . . . . . . . . . . . . . . . . . . . |
118 |
|
Reusing instance models in the same schematic . . . . . . . . . . . . |
118 |
|
Making instance models available to all designs . . . . . . . . . . . |
119 |
|
Configuring model libraries . . . . . . . . . . . . . . . . . . . . . . . . . |
120 |
|
The Libraries and Include Files tabs . . . . . . . . . . . . . . . . . . . |
120 |
|
How PSpice uses model libraries . . . . . . . . . . . . . . . . . . . . |
121 |
|
Search order . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
121 |
|
Handling duplicate model names . . . . . . . . . . . . . . . . . . |
122 |
|
Adding model libraries to the configuration . . . . . . . . . . . . . . |
122 |
|
Changing design and global scope . . . . . . . . . . . . . . . . . . . |
123 |
|
Changing model library search order . . . . . . . . . . . . . . . . . . |
124 |
|
Changing the library search path . . . . . . . . . . . . . . . . . . . . |
125 |
Chapter 5 |
Creating parts for models 127 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
127 |
|
What’s different about parts used for simulation? . . . . . . . . . . . . . |
129 |
|
Ways to create parts |
|
|
for models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
129 |
|
Preparing your models for part creation . . . . . . . . . . . . . . . . . . |
130 |
|
Using the Model Editor to create parts . . . . . . . . . . . . . . . . . . . |
131 |
|
Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . |
131 |
|
Setting up automatic part creation . . . . . . . . . . . . . . . . . . . |
132 |
|
Basing new parts on a custom set of parts . . . . . . . . . . . . . . . . . |
133 |
|
Editing part graphics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
135 |
|
How Capture places parts . . . . . . . . . . . . . . . . . . . . . . . . |
135 |
|
Defining grid spacing . . . . . . . . . . . . . . . . . . . . . . . . . . . |
136 |
|
Grid spacing for graphics . . . . . . . . . . . . . . . . . . . . . . |
136 |
|
Grid spacing for pins . . . . . . . . . . . . . . . . . . . . . . . . . |
136 |
|
Attaching models to parts . . . . . . . . . . . . . . . . . . . . . . . . . . |
138 |
vii
Contents
|
MODEL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 138 |
||||
|
Defining part properties needed for simulation |
. . . . . . . . . . . . . . 139 |
|||
|
PSPICETEMPLATE . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
140 |
|||
|
PSPICETEMPLATE syntax . . . . . . . . . . . . . . . . . . . . . . 140 |
||||
|
PSPICETEMPLATE examples . . . . . . . . . . . . . . . . . . . . 143 |
||||
Chapter 6 |
Analog behavioral modeling 147 |
|
|
|
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
147 |
|||
|
Overview of analog behavioral modeling . . . . . . . . . . . . . . . . . . 148 |
||||
|
The ABM.OLB part library file . . . . . . . . . . . . . . . . . . . . . . . . |
149 |
|||
|
Placing and specifying ABM parts . . . . . . . . . . . . . . . . . . . . . . 150 |
||||
|
Net names and device names in ABM expressions |
. . . . . . . . . . 150 |
|||
|
Forcing the use of a global definition . . . . . . . . . . . . . . . . . . |
151 |
|||
|
ABM part templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
152 |
|||
|
Control system parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153 |
||||
|
Basic components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
155 |
|||
|
Limiters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
156 |
|||
|
Chebyshev filters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157 |
||||
|
Integrator and differentiator . . . . . . . . . . . . . . . . . . . . . . . |
160 |
|||
|
Table look-up parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
160 |
|||
|
Laplace transform part . . . . . . . . . . . . . . . . . . . . . . . . . . |
164 |
|||
|
Math functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 167 |
||||
|
ABM expression parts . . . . . . . . . . . . . . . . . . . . . . . . . . |
168 |
|||
|
An instantaneous device example: modeling a triode . . . . . . . . . 171 |
||||
|
PSpice-equivalent parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
174 |
|||
|
Implementation of PSpice -equivalent parts |
. . . . . . . . . . . . . . 175 |
|||
|
Modeling mathematical or instantaneous relationships . . . . . . . . 176 |
||||
|
EVALUE and GVALUE parts |
. . . . . . . . . . . . . . . . . . . . 176 |
|||
|
EMULT, GMULT, ESUM, and GSUM . . . . . . . . . . . . . . . . 178 |
||||
|
Lookup tables (ETABLE and GTABLE) . . . . . . . . . . . . . . . . . 179 |
||||
|
Frequency-domain device models . . . . . . . . . . . . . . . . . . . . 181 |
||||
|
Laplace transforms (LAPLACE) |
. . . . . . . . . . . . . . . . . . . . . 181 |
|||
|
Frequency response tables (EFREQ and GFREQ) |
. . . . . . . . . . . 183 |
|||
|
Cautions and recommendations for simulation and analysis . . . . . . . 186 |
||||
|
Instantaneous device modeling |
. . . . . . . . . . . . . . . . . . . . . 186 |
|||
|
Frequency-domain parts . . . . . . . . . . . . . . . . . . . . . . . . . |
187 |
|||
|
Laplace transforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187 |
||||
|
Non-causality and Laplace transforms |
. . . . . . . . . . . . . . . 188 |
|||
|
Chebyshev filters . . . . . . . . . . . . . . . . . . . . . . . . . . . |
190 |
|||
|
Frequency tables . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 |
||||
|
Trading off computer resources for accuracy . . . . . . . . . . . . . . 191 |
viii
Contents
|
Basic controlled sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
192 |
|
|
Creating custom ABM parts . . . . . . . . . . . . . . . . . . . . . . . |
192 |
|
Part three |
Setting Up and Running Analyses |
|
|
Chapter 7 |
Setting up analyses and starting simulation 195 |
|
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
195 |
|
|
Analysis types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
196 |
|
|
Setting up analyses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
197 |
|
|
Execution order for standard analyses . . . . . . . . . . . . . . . . . |
198 |
|
|
Output variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
199 |
|
|
Modifiers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
200 |
|
|
Starting a simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
206 |
|
|
Starting a simulation from Capture . . . . . . . . . . . . . . . . . . . |
206 |
|
|
Starting a simulation outside of Capture . . . . . . . . . . . . . . . . |
207 |
|
|
Setting up batch simulations . . . . . . . . . . . . . . . . . . . . . . . |
207 |
|
|
Multiple simulation setups within one circuit file . . . . . . . . . |
207 |
|
|
Running simulations with multiple circuit files . . . . . . . . . . |
208 |
|
|
The PSpice simulation window . . . . . . . . . . . . . . . . . . . . . |
208 |
|
Chapter 8 |
DC analyses |
213 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
213 |
|
|
DC Sweep . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
214 |
|
|
Minimum requirements to run a DC sweep analysis . . . . . . . . . |
214 |
|
|
Overview of DC sweep . . . . . . . . . . . . . . . . . . . . . . . . . . |
216 |
|
|
Setting up a DC stimulus . . . . . . . . . . . . . . . . . . . . . . . . . |
218 |
|
|
Nested DC sweeps . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
219 |
|
|
Curve families for DC sweeps . . . . . . . . . . . . . . . . . . . . . . |
221 |
|
|
Bias point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
223 |
|
|
Minimum requirements to run a bias point analysis . . . . . . . . . |
223 |
|
|
Overview of bias point . . . . . . . . . . . . . . . . . . . . . . . . . . |
223 |
|
|
Small-signal DC transfer . . . . . . . . . . . . . . . . . . . . . . . . . . . |
225 |
|
|
Minimum requirements to run a small-signal DC transfer analysis . 225 |
||
|
Overview of small-signal DC transfer . . . . . . . . . . . . . . . . . . |
226 |
|
|
DC sensitivity . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
228 |
|
|
Minimum requirements to run a DC sensitivity analysis . . . . . . . |
228 |
|
|
Overview of DC sensitivity . . . . . . . . . . . . . . . . . . . . . . . . |
229 |
|
Chapter 9 |
AC analyses |
231 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
231 |
ix
Contents
|
AC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 232 |
||||
|
Setting up and running an AC sweep |
. . . . . . . . . . . . . . . . . . 232 |
|||
|
What is AC sweep? . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
232 |
|||
|
Setting up an AC stimulus . . . . . . . . . . . . . . . . . . . . . . . . |
233 |
|||
|
Setting up an AC analysis . . . . . . . . . . . . . . . . . . . . . . . . . 235 |
||||
|
AC sweep setup in example.opj |
. . . . . . . . . . . . . . . . . . . . . 237 |
|||
|
How PSpice treats nonlinear devices |
. . . . . . . . . . . . . . . . . . 239 |
|||
|
What’s required to transform a device into a linear circuit . . . . 239 |
||||
|
What PSpice does . . . . . . . . . . . . . . . . . . . . . . . . . . . |
239 |
|||
|
Example: nonlinear behavioral modeling block . . . . . . . . . . 239 |
||||
|
Noise analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 241 |
||||
|
Setting up and running a noise analysis . . . . . . . . . . . . . . . . . 241 |
||||
|
What is noise analysis? . . . . . . . . . . . . . . . . . . . . . . . . . . |
242 |
|||
|
How PSpice calculates total output |
|
|
||
|
and input noise . . . . . . . . . . . . . . . . . . . . . . . . |
242 |
|||
|
Setting up a noise analysis . . . . . . . . . . . . . . . . . . . . . . . . |
243 |
|||
|
Analyzing Noise in the Probe window |
. . . . . . . . . . . . . . . . . 245 |
|||
|
About noise units . . . . . . . . . . . . . . . . . . . . . . . . . . . |
246 |
|||
|
Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 246 |
||||
Chapter 10 |
Transient analysis 249 |
|
|
|
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
249 |
|||
|
Overview of transient analysis . . . . . . . . . . . . . . . . . . . . . . . . |
250 |
|||
|
Minimum requirements to run a transient analysis . . . . . . . . . . 250 |
||||
|
Minimum circuit design requirements |
. . . . . . . . . . . . . . . 250 |
|||
|
Minimum program setup requirements |
. . . . . . . . . . . . . . 250 |
|||
|
Defining a time-based stimulus . . . . . . . . . . . . . . . . . . . . . . . |
252 |
|||
|
Overview of stimulus generation |
. . . . . . . . . . . . . . . . . . . . 252 |
|||
|
The Stimulus Editor utility . . . . . . . . . . . . . . . . . . . . . . . . . . |
253 |
|||
|
Stimulus files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 253 |
||||
|
Configuring stimulus files . . . . . . . . . . . . . . . . . . . . . . . . |
254 |
|||
|
Starting the Stimulus Editor . . . . . . . . . . . . . . . . . . . . . . . |
254 |
|||
|
Defining stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
256 |
|||
|
Example: piecewise linear stimulus . . . . . . . . . . . . . . . . . 256 |
||||
|
Example: sine wave sweep . . . . . . . . . . . . . . . . . . . . . . 257 |
||||
|
Creating new stimulus symbols |
. . . . . . . . . . . . . . . . . . . . . 259 |
|||
|
Editing a stimulus . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
260 |
|||
|
To edit an existing stimulus . . . . . . . . . . . . . . . . . . . . . |
260 |
|||
|
To edit a PWL stimulus . . . . . . . . . . . . . . . . . . . . . . . . 260 |
||||
|
To select a time and value scale factor for PWL stimuli . . . . . . 260 |
||||
|
Deleting and removing traces . . . . . . . . . . . . . . . . . . . . . . |
261 |
x
Contents
|
Manual stimulus configuration . . . . . . . . . . . . . . . . . . . . . |
261 |
|
To manually configure a stimulus . . . . . . . . . . . . . . . . . |
261 |
|
Transient (time) response . . . . . . . . . . . . . . . . . . . . . . . . . . . |
263 |
|
Internal time steps in transient analyses . . . . . . . . . . . . . . . . . . |
265 |
|
Switching circuits in transient analyses . . . . . . . . . . . . . . . . . . . |
266 |
|
Plotting hysteresis curves . . . . . . . . . . . . . . . . . . . . . . . . . . . |
266 |
|
Fourier components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
268 |
Chapter 11 |
Parametric and temperature analysis 271 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
271 |
|
Parametric analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
272 |
|
Minimum requirements to run a parametric analysis . . . . . . . . . |
272 |
|
Overview of parametric analysis . . . . . . . . . . . . . . . . . . . . |
273 |
|
RLC filter example . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
274 |
|
Entering the design . . . . . . . . . . . . . . . . . . . . . . . . . . |
274 |
|
Running the simulation . . . . . . . . . . . . . . . . . . . . . . . |
275 |
|
Using performance analysis to plot overshoot and rise time . . . 275 |
|
|
Example: frequency response vs. arbitrary parameter . . . . . . . . |
278 |
|
Setting up the circuit . . . . . . . . . . . . . . . . . . . . . . . . . |
278 |
|
Temperature analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
281 |
|
Minimum requirements to run a temperature analysis . . . . . . . . |
281 |
|
Overview of temperature analysis . . . . . . . . . . . . . . . . . . . . |
282 |
Chapter 12 |
Monte Carlo and sensitivity/worst-case analyses 283 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
283 |
|
Statistical analyses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
284 |
|
Overview of statistical analyses . . . . . . . . . . . . . . . . . . . . . |
284 |
|
Output control for statistical analyses . . . . . . . . . . . . . . . . . . |
285 |
|
Model parameter values reports . . . . . . . . . . . . . . . . . . . . . |
285 |
|
Waveform reports . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
286 |
|
Collating functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
287 |
|
Temperature considerations in statistical analyses . . . . . . . . . . |
288 |
|
Monte Carlo analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
289 |
|
Reading the summary report . . . . . . . . . . . . . . . . . . . . |
291 |
|
Example: Monte Carlo analysis of a pressure sensor . . . . . . . . . |
293 |
|
Drawing the schematic . . . . . . . . . . . . . . . . . . . . . . . . |
293 |
|
Defining part values . . . . . . . . . . . . . . . . . . . . . . . . . |
294 |
|
Setting up the parameters . . . . . . . . . . . . . . . . . . . . . . |
295 |
|
Using resistors with models . . . . . . . . . . . . . . . . . . . . . |
296 |
|
Saving the design . . . . . . . . . . . . . . . . . . . . . . . . . . . |
297 |
|
Defining tolerances for the resistor models . . . . . . . . . . . . |
297 |
xi
Contents
|
Setting up the analyses . . . . . . . . . . . . . . . . . . . . . . . . |
299 |
|
Running the analysis and viewing the results . . . . . . . . . . . 300 |
|
|
Monte Carlo Histograms . . . . . . . . . . . . . . . . . . . . . . . . . |
301 |
|
Chebyshev filter example . . . . . . . . . . . . . . . . . . . . . . . 301 |
|
|
Creating models for Monte Carlo analysis . . . . . . . . . . . . . 302 |
|
|
Setting up the analysis . . . . . . . . . . . . . . . . . . . . . . . . |
302 |
|
Creating histograms . . . . . . . . . . . . . . . . . . . . . . . . . . 303 |
|
|
Worst-case analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
306 |
|
Overview of worst-case analysis . . . . . . . . . . . . . . . . . . . . . 306 |
|
|
Inputs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307 |
|
|
Procedure . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 307 |
|
|
Outputs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308 |
|
|
Caution: An important condition for |
|
|
correct worst-case analysis . . . . . . . . . . . . . . . . . . 308 |
|
|
Worst-case analysis example . . . . . . . . . . . . . . . . . . . . . . . |
309 |
|
Tips and other useful information . . . . . . . . . . . . . . . . . . . . 313 |
|
|
VARY BOTH, VARY DEV, and VARY LOT . . . . . . . . . . . . 313 |
|
|
Gaussian distributions . . . . . . . . . . . . . . . . . . . . . . . . |
314 |
|
YMAX collating function . . . . . . . . . . . . . . . . . . . . . . . |
314 |
|
RELTOL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
314 |
|
Sensitivity analysis . . . . . . . . . . . . . . . . . . . . . . . . . . |
314 |
|
Manual optimization . . . . . . . . . . . . . . . . . . . . . . . . . |
314 |
|
Monte Carlo analysis . . . . . . . . . . . . . . . . . . . . . . . . . |
315 |
Part four |
Viewing results |
|
Chapter 13 |
Analyzing waveforms 319 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
319 |
|
Overview of waveform analysis . . . . . . . . . . . . . . . . . . . . . . . 320 |
|
|
Elements of a plot . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
321 |
|
Elements of a Probe window . . . . . . . . . . . . . . . . . . . . . . . 322 |
|
|
Managing multiple Probe windows . . . . . . . . . . . . . . . . . . . 323 |
|
|
Printing multiple windows . . . . . . . . . . . . . . . . . . . . . . 323 |
|
|
Setting up waveform analysis . . . . . . . . . . . . . . . . . . . . . . . . . 324 |
|
|
Setting up colors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
324 |
|
Editing display and print colors in the PSPICE.INI file . . . . . . 324 |
|
|
Configuring trace color schemes . . . . . . . . . . . . . . . . . . . 326 |
|
|
Viewing waveforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
327 |
|
Setting up waveform display from Capture . . . . . . . . . . . . . . 327 |
|
|
Viewing waveforms while simulating . . . . . . . . . . . . . . . . . . 328 |
|
|
Configuring update intervals . . . . . . . . . . . . . . . . . . . . |
329 |
xii
Contents
|
Interacting with waveform analysis during simulation . . . . . |
329 |
|
Pausing a simulation and viewing waveforms . . . . . . . . . . |
330 |
|
Using schematic page markers to add traces . . . . . . . . . . . . . . |
331 |
|
Limiting waveform data file size . . . . . . . . . . . . . . . . . . . . |
334 |
|
Limiting file size using markers . . . . . . . . . . . . . . . . . . . |
334 |
|
Limiting file size by excluding internal subcircuit data . . . . . . 336 |
|
|
Limiting file size by suppressing the first part |
|
|
of simulation output . . . . . . . . . . . . . . . . . . . . . |
336 |
|
Using simulation data from multiple files . . . . . . . . . . . . . . . |
337 |
|
Appending waveform data files . . . . . . . . . . . . . . . . . . . |
337 |
|
Adding traces from specific loaded waveform data files . . . . . 338 |
|
|
Saving simulation results in ASCII format . . . . . . . . . . . . . . . |
339 |
|
Analog example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
341 |
|
Running the simulation . . . . . . . . . . . . . . . . . . . . . . . |
341 |
|
Displaying voltages on nets . . . . . . . . . . . . . . . . . . . . . |
343 |
|
User interface features for waveform analysis . . . . . . . . . . . . . . . |
344 |
|
Zoom regions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
344 |
|
Scrolling traces . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
346 |
|
Modifying trace expressions and labels . . . . . . . . . . . . . . . . . |
346 |
|
Moving and copying trace names and expressions . . . . . . . . . . |
347 |
|
Copying and moving labels . . . . . . . . . . . . . . . . . . . . . . . |
348 |
|
Tabulating trace data values . . . . . . . . . . . . . . . . . . . . . . . |
349 |
|
Using cursors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
350 |
|
Displaying cursors . . . . . . . . . . . . . . . . . . . . . . . . . . |
350 |
|
Moving cursors . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
351 |
|
Example: using cursors . . . . . . . . . . . . . . . . . . . . . . . . |
352 |
|
Tracking simulation messages . . . . . . . . . . . . . . . . . . . . . . . . |
354 |
|
Message tracking from the message summary . . . . . . . . . . . . . |
354 |
|
The Simulation Message Summary dialog box . . . . . . . . . . |
354 |
|
Persistent hazards . . . . . . . . . . . . . . . . . . . . . . . . . . . |
355 |
|
Message tracking from the waveform . . . . . . . . . . . . . . . . . . |
356 |
|
Trace expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
356 |
|
Basic output variable form . . . . . . . . . . . . . . . . . . . . . . . . |
357 |
|
Output variable form for device terminals . . . . . . . . . . . . . . . |
358 |
|
Analog trace expressions . . . . . . . . . . . . . . . . . . . . . . . . . |
364 |
|
Trace expression aliases . . . . . . . . . . . . . . . . . . . . . . . |
364 |
|
Arithmetic functions . . . . . . . . . . . . . . . . . . . . . . . . . |
364 |
|
Rules for numeric values suffixes . . . . . . . . . . . . . . . . . . |
365 |
Chapter 14 |
Other output options 367 |
|
|
Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
367 |
xiii
Contents
|
Viewing analog results in the PSpice window . . . |
. . . . . . . . . . . . 368 |
|||
|
Writing additional results to the PSpice output file |
. . . . . . . . . . . . 369 |
|||
|
Generating plots of voltage and current values |
. . . . . . . . . . . . 369 |
|||
|
Generating tables of voltage and current values |
. . . . . . . . . . . . 370 |
|||
Appendix A |
Setting initial state 373 |
|
|
|
|
|
Appendix overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
373 |
|||
|
Save and load bias point . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374 |
||||
|
Save bias point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
374 |
|||
|
Load bias point . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375 |
||||
|
Setpoints . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376 |
||||
|
Setting initial conditions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 378 |
||||
Appendix B |
Convergence and “time step too small errors” |
379 |
|
|
|
|
Appendix overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
379 |
|||
|
Introduction . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 380 |
||||
|
Newton-Raphson requirements |
. . . . . . . . . . . . . . . . . . . . . 380 |
|||
|
Is there a solution? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 381 |
||||
|
Are the Equations Continuous? |
. . . . . . . . . . . . . . . . . . . . . 382 |
|||
|
Are the derivatives correct? . . . . . . . . . . . . . . . . . . . . . |
382 |
|||
|
Is the initial approximation close enough? |
. . . . . . . . . . . . . . . 383 |
|||
|
Bias point and DC sweep . . . . . . . . . . . . . . . . . . . . . . . . . . . |
385 |
|||
|
Semiconductors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
385 |
|||
|
Switches . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 386 |
||||
|
Behavioral modeling expressions |
. . . . . . . . . . . . . . . . . . . . 387 |
|||
|
Transient analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
388 |
|||
|
Skipping the bias point . . . . . . . . . . . . . . . . . . . . . . . . . . |
389 |
|||
|
The dynamic range of TIME . . . . . . . . . . . . . . . . . . . . . . . 389 |
||||
|
Failure at the first time step . . . . . . . . . . . . . . . . . . . . . . . . 390 |
||||
|
Parasitic capacitances . . . . . . . . . . . . . . . . . . . . . . . . . . . |
391 |
|||
|
Inductors and transformers . . . . . . . . . . . . . . . . . . . . . . . . 391 |
||||
|
Bipolar transistors substrate junction . . . . . . . . . . . . . . . . . . |
392 |
|||
|
Diagnostics . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
393 |
Index 395
xiv
Figures
Figure 1 User-configurable data files that PSpice reads . . . . . . . . . . . . . . . . 11 Figure 2 Diode clipper circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16 Figure 3 Connection points. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 19 Figure 4 PSpice simulation output window. . . . . . . . . . . . . . . . . . . . . . . 22 Figure 5 Simulation output file. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 24 Figure 6 DC sweep analysis settings. . . . . . . . . . . . . . . . . . . . . . . . . . . 27 Figure 7 Probe window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Figure 8 Clipper circuit with voltage marker on net Out. . . . . . . . . . . . . . . . 29 Figure 9 Voltage at In, Mid, and Out. . . . . . . . . . . . . . . . . . . . . . . . . . . 29 Figure 11 Trace legend with cursors activated. . . . . . . . . . . . . . . . . . . . . . 30 Figure 12 Trace legend with V(Mid) symbol outlined. . . . . . . . . . . . . . . . . . 30 Figure 13 Voltage difference at V(In) = 4 volts. . . . . . . . . . . . . . . . . . . . . . 31 Figure 14 Diode clipper circuit with a voltage stimulus. . . . . . . . . . . . . . . . . 32 Figure 15 Stimulus Editor window. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 34 Figure 16 Transient analysis simulation settings. . . . . . . . . . . . . . . . . . . . . 34 Figure 17 Sinusoidal input and clipped output waveforms. . . . . . . . . . . . . . . 35 Figure 18 Clipper circuit with AC stimulus. . . . . . . . . . . . . . . . . . . . . . . . 37 Figure 19 AC sweep and noise analysis simulation settings. . . . . . . . . . . . . . . 38 Figure 20 dB magnitude curves for “gain” at Mid and Out. . . . . . . . . . . . . . . 40 Figure 21 Bode plot of clipper’s frequency response. . . . . . . . . . . . . . . . . . . 41 Figure 22 Clipper circuit with global parameter Rval. . . . . . . . . . . . . . . . . . 42 Figure 23 Parametric simulation settings. . . . . . . . . . . . . . . . . . . . . . . . . . 44 Figure 24 Small signal response as R1 is varied from 100Ω to 10 kΩ . . . . . . . . . . . 45 Figure 25 Small signal frequency response at 100 and 10 kΩ input resistance. . . . 47 Figure 26 Performance analysis plots of bandwidth and gain vs. Rval. . . . . . . . . 50 Figure 27 Relationship of the Model Editor to Capture and PSpice . . . . . . . . . . 93 Figure 28 Process and data flow for the Model Editor. . . . . . . . . . . . . . . . . . 96 Figure 29 Model Editor workspace with data for a bipolar transistor. . . . . . . . . 97 Figure 30 Design for a half-wave rectifier. . . . . . . . . . . . . . . . . . . . . . . . 104 Figure 31 Model characteristics and parameter values for DbreakX. . . . . . . . . 105 Figure 32 Assorted device characteristic curves for a diode. . . . . . . . . . . . . . 108 Figure 33 Forward Current device curve at two temperatures. . . . . . . . . . . . 109
Figures
Figure 34 Rules for pin callout in subcircuit templates. . . . . . . . . . . . . . . . . 146 Figure 35 LOPASS filter example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157 Figure 36 HIPASS filter part example. . . . . . . . . . . . . . . . . . . . . . . . . . . 158 Figure 37 BANDPASS filter part example. . . . . . . . . . . . . . . . . . . . . . . . 159 Figure 38 BANDREJ filter part example. . . . . . . . . . . . . . . . . . . . . . . . . 159 Figure 39 FTABLE part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Figure 40 LAPLACE part example one. . . . . . . . . . . . . . . . . . . . . . . . . . 165 Figure 41 Viewing gain and phase characteristics of a lossy integrator. . . . . . . . 165 Figure 42 LAPLACE part example two. . . . . . . . . . . . . . . . . . . . . . . . . . 165 Figure 43 ABM expression part example one. . . . . . . . . . . . . . . . . . . . . . 169 Figure 44 ABM expression part example two. . . . . . . . . . . . . . . . . . . . . . 169 Figure 45 ABM expression part example three. . . . . . . . . . . . . . . . . . . . . . 170 Figure 46 ABM expression part example four. . . . . . . . . . . . . . . . . . . . . . 170 Figure 47 Triode circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 171 Figure 48 Triode subcircuit producing a family of I-V curves. . . . . . . . . . . . . 173 Figure 49 EVALUE part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 Figure 50 GVALUE part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 177 Figure 51 EMULT part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178 Figure 52 GMULT part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 179 Figure 53 EFREQ part example. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 185 Figure 54 Voltage multiplier circuit (mixer). . . . . . . . . . . . . . . . . . . . . . . 186 Figure 55 PSpice simulation window . . . . . . . . . . . . . . . . . . . . . . . . . . 210 Figure 56 Example schematic EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . . 217 Figure 57 Curve family example schematic. . . . . . . . . . . . . . . . . . . . . . . 221 Figure 58 Device curve family. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 222 Figure 59 Operating point determination for each member of the curve family. . . 222 Figure 60 Circuit diagram for EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . . 237 Figure 61 AC analysis setup for EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . 238 Figure 62 Device and total noise traces for EXAMPLE.DSN. . . . . . . . . . . . . . 247 Figure 63 Transient analysis setup for EXAMPLE.OPJ. . . . . . . . . . . . . . . . . 263 Figure 64 Example schematic EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . . 264 Figure 65 ECL-compatible Schmitt trigger. . . . . . . . . . . . . . . . . . . . . . . . 266 Figure 66 Netlist for Schmitt trigger circuit. . . . . . . . . . . . . . . . . . . . . . . . 267 Figure 67 Hysteresis curve example: Schmitt trigger. . . . . . . . . . . . . . . . . . 268 Figure 68 Passive filter schematic. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 274 Figure 69 Current of L1 when R1 is 1.5 ohms. . . . . . . . . . . . . . . . . . . . . . 276 Figure 70 Rise time and overshoot vs. damping resistance. . . . . . . . . . . . . . . 277 Figure 71 RLC filter example circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . 278 Figure 72 Plot of capacitance versus bias voltage. . . . . . . . . . . . . . . . . . . . 280 Figure 73 Example schematic EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . . 282 Figure 74 Example schematic EXAMPLE.DSN. . . . . . . . . . . . . . . . . . . . . 288 Figure 75 Monte Carlo analysis setup for EXAMPLE.DSN. . . . . . . . . . . . . . . 290
xvi
Figures
Figure 76 Summary of Monte Carlo runs for EXAMPLE.OPJ. . . . . . . . . . . . . 291 Figure 77 Parameter values for Monte Carlo pass three. . . . . . . . . . . . . . . . 292 Figure 78 Pressure sensor circuit. . . . . . . . . . . . . . . . . . . . . . . . . . . . . 293 Figure 79 Model definition for RMonte1. . . . . . . . . . . . . . . . . . . . . . . . . 298 Figure 80 Pressure sensor circuit with RMonte1 and RTherm model definitions. . 299 Figure 81 Chebyshev filter. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 302 Figure 82 1 dB bandwidth histogram. . . . . . . . . . . . . . . . . . . . . . . . . . . 305 Figure 83 Center frequency histogram. . . . . . . . . . . . . . . . . . . . . . . . . . 306 Figure 84 Simple biased BJT amplifier. . . . . . . . . . . . . . . . . . . . . . . . . . 309 Figure 85 Amplifier netlist and circuit file. . . . . . . . . . . . . . . . . . . . . . . . 310 Figure 86 YatX Goal Function. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 311 Figure 87 Correct worst-case results. . . . . . . . . . . . . . . . . . . . . . . . . . . 312 Figure 88 Incorrect worst-case results. . . . . . . . . . . . . . . . . . . . . . . . . . 312 Figure 89 Schematic using VARY BOTH. . . . . . . . . . . . . . . . . . . . . . . . . 313 Figure 90 Circuit file using VARY BOTH. . . . . . . . . . . . . . . . . . . . . . . . 313 Figure 91 Analog and digital areas of a plot. . . . . . . . . . . . . . . . . . . . . . . 321 Figure 92 Two Probe windows. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 322 Figure 93 Trace legend symbols. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338 Figure 94 Section information message box. . . . . . . . . . . . . . . . . . . . . . . 339 Figure 95 Example schematic EXAMPLE.OPJ. . . . . . . . . . . . . . . . . . . . . . 341 Figure 96 Waveform display for EXAMPLE.DAT. . . . . . . . . . . . . . . . . . . 342 Figure 97 Cursors positioned on a trough and peak of V(1) . . . . . . . . . . . . . 352 Figure 98 Waveform display for a persistent hazard. . . . . . . . . . . . . . . . . . 355 Figure A-1 Setpoints. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 376
xvii
Figures
xviii
Tables
Table 1 |
DC analysis types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
3 |
|
Table 2 |
AC analysis types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
4 |
|
Table 3 |
Time-based analysis types . . . . . . . . . . . . . . . . . . . . . . . . . . . |
5 |
|
Table 4 |
Parametric and temperature analysis types . . . . . . . . . . . . . . . . . . |
6 |
|
Table 5 |
Statistical analysis types . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
7 |
|
Table 2-1 |
|
|
25 |
Table 10 |
Association of cursors with mouse buttons. . . . . . . . . . . . . . . . . . 30 |
||
Table 2-1 |
|
|
31 |
Table 2-1 |
|
|
36 |
Table 2-2 |
|
|
41 |
Table 2-3 |
|
|
48 |
Table 2-4 |
|
|
51 |
Table 5 |
|
|
58 |
Table 6 |
|
|
59 |
Table 7 |
Passive parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
64 |
|
Table 8 |
Breakout parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
65 |
|
Table 9 |
Operators in expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70 |
||
Table 10 |
Functions in arithmetic expressions . . . . . . . . . . . . . . . . . . . . . . 71 |
||
Table 11 |
System variables . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 73 |
||
Table 12 |
|
|
74 |
Table 13 |
|
|
75 |
Table 14 |
|
|
77 |
Table 15 |
|
|
78 |
Table 16 |
|
|
80 |
Table 17 |
Models supported in the Model Editor . . . . . . . . . . . . . . . . . . . 95 |
||
Table 1 |
Sample diode data sheet values . . . . . . . . . . . . . . . . . . . . . . . |
106 |
|
Table 2 |
Part names for custom part generation. . . . . . . . . . . . . . . . . . . . |
133 |
|
Table 3 |
|
139 |
|
Table 4 |
|
141 |
|
Table 5 |
|
142 |
|
Table 6 |
|
145 |
|
Table 7 |
Control system parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . |
153 |
Tables
Table 1 |
ABM math function parts . . . . . . . . . . |
. . . . . . . . . . . . . . . . . 167 |
||||
Table 2 |
ABM expression parts . . . . . . . . . . . . |
. . . . . . . . . . . . . . . . . 168 |
||||
Table 1 |
PSpice -equivalent parts . . . . . . . . . . |
. . . . . . . . . . . . . . . . . 174 |
||||
Table 1 |
Basic controlled sources in ANALOG.OLB |
. . . . . . . . . . . . . . . . . 192 |
||||
Table 2 |
Classes of PSpice analyses |
. . . . . . . . . . . . . . . . . . . . . . . . . . 196 |
||||
Table 3 |
Execution order for standard analyses . . . . . . . . . . . . . . . . . . . . 198 |
|||||
Table 4 |
PSpice output variable formats |
. . . . . . . . . . . . . . . . . . . . . . . 201 |
||||
Table 5 |
Element definitions for 2-terminal devices |
. . . . . . . . . . . . . . . . . 202 |
||||
Table 6 |
Element definitions for 3- or 4-terminal devices |
. . . . . . . . . . . . . . 203 |
||||
Table 7 |
Element definitions for transmission line devices |
. . . . . . . . . . . . . 204 |
||||
Table 8 |
Element definitions for AC analysis specific elements . . . . . . . . . . 205 |
|||||
Table 9 |
DC sweep circuit design requirements |
. . . . . . . . . . . . . . . . . . . 214 |
||||
Table 10 |
|
|
|
|
|
218 |
Table 11 |
|
|
|
|
|
218 |
Table 12 |
|
|
|
|
|
219 |
Table 1 |
Curve family example setup . . . . . . . . . . . . . . . . . . . . . . . . . 221 |
|||||
Table 2 |
|
|
|
|
|
233 |
Table 3 |
|
|
|
|
|
233 |
Table 4 |
|
|
|
|
|
234 |
Table 5 |
|
|
|
|
|
234 |
Table 6 |
|
|
|
|
|
236 |
Table 7 |
|
|
|
|
|
242 |
Table 8 |
|
|
|
|
|
244 |
Table 9 |
|
|
|
|
|
246 |
Table 10 |
Stimulus symbols for time-based input signals |
. . . . . . . . . . . . . . 252 |
||||
Table 1 |
Parametric analysis circuit design requirements |
. . . . . . . . . . . . . . 272 |
||||
Table 1 |
Collating functions used in statistical analyses . . . . . . . . . . . . . . . 287 |
|||||
Table 1 |
|
|
|
|
|
294 |
Table 2 |
|
|
|
|
|
295 |
Table 3 |
|
|
|
|
|
300 |
Table 1 |
Default waveform viewing colors. . . . . . . . . . . . . . . . . . . . . . . 325 |
|||||
Table 2 |
|
|
|
|
|
326 |
Table 3 |
|
|
|
|
|
328 |
Table 4 |
|
|
|
|
|
330 |
Table 5 |
|
|
|
|
|
332 |
Table 6 |
|
|
|
|
|
333 |
Table 1 |
|
|
|
|
|
346 |
Table 2 |
Mouse actions for cursor control |
. . . . . . . . . . . . . . . . . . . . . . . 351 |
||||
Table 3 |
Key combinations for cursor control |
. . . . . . . . . . . . . . . . . . . . 351 |
||||
Table 4 |
|
|
|
|
|
357 |
Table 5 |
|
|
|
|
|
358 |
Table 6 |
Output variable formats |
. . . . . . . . . . . . . . . . . . . . . . . . . . . 358 |
xx
|
|
Tables |
Table 7 |
Examples of output variable formats . . . . . . . . . . . . . . . . . . . . |
360 |
Table 8 |
Output variable AC suffixes . . . . . . . . . . . . . . . . . . . . . . . . . |
361 |
Table 9 |
Device names for two-terminal device types . . . . . . . . . . . . . . . |
361 |
Table 10 |
Terminal IDs by three & four-terminal device type . . . . . . . . . . . . |
362 |
Table 11 |
Noise types by device type . . . . . . . . . . . . . . . . . . . . . . . . . . |
363 |
Table 12 |
Analog arithmetic functions for trace expressions . . . . . . . . . . . . |
364 |
Table 13 |
Output units for trace expressions . . . . . . . . . . . . . . . . . . . . . |
366 |
Table 14 |
|
369 |
Table 15 |
|
370 |
xxi
Tables
xxii
OrCAD® offers a total solution for your core design tasks: schematicand VHDL-based design entry; FPGA and CPLD design synthesis; digital, analog, and mixed-signal simulation; and printed circuit board layout. What's more, OrCAD's products are a suite of applications built around an engineer's design flow--not just a collection of independently developed point tools. PSpice is just one element in OrCAD's total solution design flow.
With OrCAD’s products, you’ll spend less time dealing with the details of tool integration, devising workarounds, and manually entering data to keep files in sync. Our products will help you build better products faster, and at lower cost.
Before you begin
OrCAD PSpice simulates analog-only circuits. After you prepare a design for simulation, OrCAD Capture generates a circuit file set. The circuit file set, containing the circuit netlist and analysis commands, is read by PSpice for simulation. PSpice formulates these into meaningful graphical plots, which you can mark for display directly from your schematic page using markers.
xxiv
How to use this guide
This guide is designed so you can quickly find the information you need to use PSpice.
This guide assumes that you are familiar with Microsoft Windows (NT or 95), including how to use icons, menus, and dialog boxes. It also assumes you have a basic understanding about how Windows manages applications and files to perform routine tasks, such as starting applications, and opening and saving your work. If you are new to Windows, please review your Microsoft Windows User’s Guide.
Before using PSpice, it is important to understand the terms and typographical conventions used in this documentation.
This guide generally follows the conventions used in the
Microsoft Windows User’s Guide. Procedures for performing an operation are generally numbered with the following typographical conventions..
Notation |
Examples |
Description |
|
|
|
C+r |
Press C+r |
A specific key or key |
|
|
stroke on the keyboard. |
monospace |
Type VAC.... |
Commands/text entered |
font |
|
from the keyborad. |
xxv
Before you begin
Documentation for OrCAD products is available in both printed and online forms. To access an online manual instantly, you can select it from the Help menu in its respective program (for example, access the Capture User’s Guide from the Help menu in Capture).
|
Note |
The documentation you receive depends on the software |
|
|
configuration you have purchased. |
|
The following table provides a brief description of those |
|
|
manuals available in both printed and online forms. |
|
|
|
|
This manual... |
Provides information about how to use... |
|
|
|
|
OrCAD Capture |
OrCAD Capture, which is a schematic capture front-end program |
|
User’s Guide |
with a direct interface to other OrCAD programs and options. |
|
OrCAD Layout |
OrCAD Layout, which is a PCB layout editor that lets you specify |
|
User’s Guide |
printed circuit board sturcture, as well as the components, metal, |
|
|
and graphics required for fabrication. |
|
OrCAD PSpice & Basics |
PSpice with Probe, the Stimulus Editor, and the Model Editor, |
|
User’s Guide |
which are circuit analysis programs that let you create, simulate, |
|
|
and test analog and digital circuit designs. This manual provides |
|
|
examples on how to specify simulation parameters, analyze |
|
|
simulation results, edit input signals, and create models. (PSpice |
|
|
Basics is a limited version that does not include the Stimulus |
|
|
Editor.) |
|
OrCAD PSpice |
OrCAD PSpice with Probe is a circuit analysis program that lets |
|
User’s Guide |
you create, simulate, and test analog-only circuit designs. |
|
|
. |
|
OrCAD PSpice Optimizer |
OrCAD PSpice Optimizer, which is an analog performance |
|
User’s Guide |
optimization program that lets you fine-tune your analog circuit |
|
|
designs. |
The following table provides a brief description of those manuals available online only.
xxvi
|
Related documentation |
|
|
|
|
This online manual... |
Provides this... |
|
|
|
|
OrCAD PSpice |
Reference material for PSpice. Also included: detailed descriptions of the |
|
Online Reference Manual |
simulation controls and analysis specifications, start-up option |
|
|
definitions, and a list of device types in the analog and digital model |
|
|
libraries. User interface commands are provided to instruct you on each |
|
|
of the screen commands. |
|
OrCAD Application Notes |
A variety of articles that show you how a particular task can be |
|
Online Manual |
accomplished using OrCAD’s products, and examples that demonstrate |
|
|
a new or different approach to solving an engineering problem. |
|
OrCAD PSpice Library List |
A complete list of the analog and digital parts in the model and part |
|
|
libraries. |
|
|
|
|
Choosing Search for Help On from the Help menu displays an extensive online help system.
The online help includes:
∙step-by-step instructions on how to set up PSpice simulations and analyze simulation results
∙reference information about PSpice
∙Technical Support information
If you are not familiar with Windows (NT or 95) Help system, choose How to Use Help from the Help menu.
xxvii
Before you begin
If you have the demo CD-ROM
OrCAD demo CD-ROM
The OrCAD demo CD-ROM has the following limitations for PSpice:
∙circuit simulation limited to circuits with up to 64 nodes, 10 transistors, two operational amplifiers or 65 digital primitive devices, and 10 transmission lines (ideal or non-ideal) with not more than 4 pairwise coupled lines
∙device characterization using the Model Editor limited to diodes
∙stimulus generation limited to sine waves (analog) and clocks (digital)
∙sample library of approximately 39 analog and 134 digital parts
∙displays only simulation data created using the demo version of the simulator
∙PSpice Optimizer limited to one goal, one parameter and one constraint
∙designs created in Capture can be saved if they have no more than 30 part instances
xxviii
What’s New
New PSpice interface with integrated waveform analysis functionality Release 9 of PSpice includes all
of Probe’s features and adds to them. Included in one screen are tabbed windows for viewing plots, text windows for viewing output files or other text files, and a simulation status and message window. Also included is a new, self-documenting analysis setup dialog for creating simulation profiles (see below). PSpice now provides an editable simulation queue which shows you how many files are currently in line to be simulated. You can edit or re-order the list as needed. And the plotting features have been improved by providing user-controlled grid settings, grid and trace properties (style and color) and metafile format copy and paste functions.
Simulation profiles PSpice Release 9 introduces the concept of simulation profiles. Each simulation profile refers to one schematic in a design and includes one analysis type (AC, DC, or Transient) with any options (sensitivity, temperature, parametric, Monte Carlo, etc.). You can define as many profiles as you need for your design and you can set up multiple analyses of the same type. Simulation profiles help you keep your analysis results separate, so you can delete one without losing the rest.
New OrCAD Capture front-end Release 9 integrates OrCAD Capture as the front-end schematic entry tool for PSpice. Capture provides a professional design entry environment with many advanced capabilities that now work hand-in-hand with PSpice. These include a project manager, a new property editor spreadsheet, right mouse button support, and many other time-saving features.
To find out more, see Analyzing waveforms on page -319.
xxix
Before you begin
To find out more, see Creating and editing models on page -85.
New Model Editor interface The Model Editor (formerly known as Parts) has been improved and modernized for Release 9. It now provides a unified application for editing models either in text form or by modifying their specifications. The Model Editor now also supports Darlington modeling.
To find out more, refer to MOSFET devices in the A nalog Devices chapter of the online OrCA D PSpice A /D Reference Manual.
EKV version 2.6 MOSFET model The EKV model is a scalable and compact model built on fundamental physical properties of the device. Use this model to design low-voltage, low-current analog, and mixed analogdigital circuits that use sub-micron technologies.
Version 2.6 models the following:
∙geometrical and process related aspects of the device (oxide thickness, junction depth, effective channel length and width, and so on)
∙effects of doping profile and substrate effects
∙weak, moderate, and strong inversion behavior
∙mobility effects due to vertical and lateral fields and carrier velocity saturation
∙short-channel effects such as channel-length modulation, source and drain charge sharing, and the reverse short channel effect
∙thermal and flicker noise modeling
∙short-distance geometry and bias-dependent device matching for Monte Carlo analysis
Enhanced model libraries The model libraries supplied with PSpice Release 9 have been enhanced to include the latest models from various vendors, as well as models for popular optocouplers, Darlingtons, and DAC and ADC devices.
xxx