Short Tutorial On PSpice
Short Tutorial On PSpice
Short Tutorial On PSpice
To put in a component, use the Draw drop-down menu, and select Get new
part (or use the shortcut Ctrl-G). This will bring up a dialog box which will allow
you to select pats from libraries. If the part you want is not on the list, try another
library parts such as transistors will probably be in eval.slb, while things such
as voltage sources will be in analog.slb. Select the part you want and place it on
the schematic:
Continue placing the components you need. (If need a component of the same
type as one you have already placed, you can use the Draw Place Part (CtrlP) shortcut.) You can rotate an object by clicking on it to highlight
it, then use Edit Rotate (or Ctrl-R). You can change the value of a component
by double-clicking on the component value, and entering a new value. You can
connect components together by placing wires Draw Wire (or Ctrl-W). Be
sure to place an analog ground (AGND). Use the component VDC for DC
power supplies, and VACfor signal sources. When done you will have
something which looks like this:
Be sure to save the file, then go to Analysis Setup. Here you will
tell PSpice what you want it to do. Always select Bias Point Detail. In this case
we will also select AC Sweep which will give the frequency response of the
circuit.
Here we will cover the frequencies from 100 Hz to 1 MHz. (Note: Use Meg for
106. If you use M, PSpice will interpret this as milli (10-3).) Now choose Analysis
Simulate and PSpice will run, and pop up an analysis window:
In this window choose Trace Add Trace. Since were interested in the gain of
the circuit, we want to plot the output voltage divided by the input voltage. The
output voltage is the voltage at the collector of Q1, and the input voltage is the
voltage at the + terminal of V3, so we plot VC(Q1)/V(V3+).
We see the circuit has a gain of about 1.5 at a frequency of 1 kHz. The
theoretical value is about (RL || RC)/RE, or 1.8.
To see the bias voltages and currents, you can look at the ASCII output
file. However, it is easier to go back to the Schematic program and
select Analysis Display Results on Schematicand then Enable Voltage
Display and/or Enable Current Display. Here is the schematic with the bias
voltages displayed:
Later on in the output file we find the specifications for the 2N2222 transistor:
Q2N2222
NPN
IS14.340000E15
BF255.9
NF1
VAF74.03
IKF.2847
ISE14.340000E15
NE1.307
BR6.092
NR1
RB10
RC1
CJE22.010000E12
MJE.377
CJC7.306000E12
MJC.3416
TF411.100000E12
XTF3
VTF1.7
ITF.6
TR46.910000E09
XTB1.5
CN2.42
D.87
The standard Spice model assumes the 2N2222 has a of 255.9. You can edit
the transistor model if you want to use a different value of
We can also see the bias voltages at the nodes:
NODEVOLTAGENODEVOLTAGE
($N_0001)5.3359($N_0002)3.7732
($N_0003)6.0390($N_0004)15.0000
($N_0005)0.0000($N_0006)0.0000
($N_0007)15.0000
and the frequency response shows the passband gain is about 280:
For some circuits the transient response is more important. For example,
consider the CMOS inverter:
The MOSFET models are located in the breakout.slb library, under the
names Mbreakn (NMOS) and Mbreakp (PMOS). We now need to define
the parameters of the MOSFETS: highlight the NMOS transistor and
select Edit Model:
In the Graph window, choose Trace Add Trace, and add V(R1:1), the voltage
at the load resistor:
Have the source change from 0 V at 99.9 ns to 5 V at 100 ns, then from 5 V at
200 ns to 0 V at 200.1 ns. This will give a pulse input with a 0.1 ns rise
time. Under Analysis Setup, choose Transient, and simulate the circuit. In the
graph window plot V(R1:1):
and we can see the rise and fall times of the CMOS inverter.