Académique Documents
Professionnel Documents
Culture Documents
com
Workshops Objectives
Workshops Objectives
1. To educate & introduce PSpice in basic level 2. To familiarized with the PSpice environment: Design components Analysis types Output Display 3. To able student use PSpice for circuit design &
Introduction to PSpice
Developed at UC Berkeley in the 60s Common SPICEs include HSPICE, PSPICE, LTSpice and B2SPICE. It takes a circuit netlist and performs mathematical simulation of the circuit's behavior. A netlist describes the components in the circuit and how they are connected.
Netlists are rather non-intuitive, and difficult to create, debug, and modify.
PSpice Introduction
1.
PSPICE uses a schematic capture program to generate the netlist, so you simply have to draw your circuit in order to simulate it.
The PSpice simulator itself uses netlists (text files that contain the circuit description) as input.
2.
point and transient time domain simulations. 4. Allows simulation of circuits without building physical prototypes. 5. Its like your breadboard, without touching the real one.
R = Rotate parts I = Zoomed-in O = Zoomed-out W = Wire P = to Place Parts @ find components Ctrl + X = Cut Ctrl + V = Paste Esc = to end current task F11 = to RUN the simulation G = GND N = to Name your wire Insert = Add Trace (simulation o/p)
Additional reminder:
1.
2. 3. 4. 5.
Mega in PSpice = meg PSpice accepts (m = e-3) Its not a case-sensitive : m as well as M denote milli (1e-3) Unit can be omitted: e.g: Change the resistor value to 1k Change the resistor name to R_load (no spaces allowed!)
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
1. Opening PSpice
Orcad 16.0 > OrCAD Capture CIS > New > Project >
Name : RC ckt > Analog or Mixed A/D > Create a Blank Project
1. Opening PSpice
Orcad Family Release 9.2 Lite Edition > Capture CIS
Lite Edition > New Project > Analog or Mixed A/D > Create a blank project
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
R1 1k
R2 1k
R3 1k
R1 1k V1 0Vdc
R2 1k
R3 1k
R1 1k
V I V
R2 1.5k
V
R3 6.8k
I
VSource 15Vdc
Click PSpice > Run ..or.. Press F11.. or.. Press the triangle button.
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
3) Probe
a) Before you do the probe
b) To start the Probe c) Graphing
d) Adding/deleting Traces
e) Doing Math f) Labelling g) Finding Points h) Saving
3) Probe
a) Before you do the probe: You have to have your circuit properly drawn & saved. There must not be any floating parts on your page (i.e. unattached devices). You should make sure that all parts have the values that you want. You have a ground on your circuit. Make sure that you have done the Analysis Setup
3) Probe
b) To start the Probe Click on the simulation run button or F11. It will check, to make sure you don't have any errors. If you do have errors, correct them. Then a new window will pop up. Here is where you can do your graphs.
R1 1k VSource 15Vdc R2 1.5k R3 6.8k
3) Probe
c) Graphing If you don't have any errors, you should get a window with a black background to pop up (even with errors, it will be OrCAD PSpice A/D Demo).
3) Probe
c) Graphing If you did have errors, in the bottom, left hand side, it will say what your errors were (these may be difficult to understand, so go To "View - Output File").
3) Probe
d) Adding/deleting Traces PSpice will automatically put some traces in. You will probably want to change them. Go to Trace - Add Trace or on the toolbar. Then select all the traces you want. To delete traces, select them on the bottom of the graph and push Delete.
3) Probe
e) Doing Maths In Add Traces, there are functions that can be performed, these will add/subtract (or whatever you chose) the lines together. Select the first output then either on your keyboard or on the right side, click the function that you wish to perform. There are many functions here that may or may not be useful. If you want to know how to use them, you can use PSpice's Help Menu. It is interesting to note that you can plot the phase of a value by using IP(xx), where xx is the name of the source you wish to see the phase for.
3) Probe
f) Labelling Click on Text Label on top tool bar. Type in what you want to write. Click OK You can move this around by single clicking and dragging.
3) Probe
g) Finding Points There are Cursor buttons that allow you to find the maximum or minimum or just a point on the line. These are located on the toolbar (to the right). Select which curve you want to look at and then select "Toggle Cursor" . Then you can find the max, min, the slope, or the relative max or min ( is find relative max).
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
4) Analysis Menu
a) Time Domain /Transient Analysis
b) DC Sweep Analysis c) AC Sweep/ Noise Analysis
0PARAMETERS:
Rv al
5.0V
0V
The DC sweep allows you to do various different sweeps of your circuit to see how it responds to various conditions. For all the possible sweeps:
4) Analysis Menu
DC Sweep Analysis
5.0V
2.5V
Vin 5Vdc
1.000uA
0.875uA 0 C 50 C
100 C 0.750uA
0.625uA
0.500uA 150mV
200mV ID(M1)
250mV V_Vgs
300mV
350mV
These three choices describe the X-axis scaling which will be produced in probe. 4. For example, if you choose decade then a sample of your X-axis might be 10Hz, 1kHz, 100kHz, 10MHz, etc.... 5. Therefore if you want to see how your circuit reacts over a very large range of frequencies choose the decade option.
3.
50
-50
To display a phase :
PSpice > Markers > Advance > Phase of Voltage
GAIN = 0.5 d Vin E3 d
-50d
(1.8102M,-87.172)
+ -
+ -
INP
1Vac 0Vdc
0 0 0Vdc
Vcm E4 d
+ -
+ -
INN
0 GAIN = 0.5
4.
5.
Opening PSpice Drawing the circuit Probe Analysis Menu Libraries & Types of Sources
5) Libraries
10 Basic Libraries : Analog, Source, Design Cache, Op Amp, Eval, Gate, Special, Breakout etc
1.
VPULSE
Vpulse
5.0V 0V
8.0V
b)
VDC
Vdc 5Vdc
4.0V 2.0V 0s V(Vin) 50us 100us 6.0V
VPWL
VPWL
5.0V
2.5V
d)
VSIN
5.0V
Idc 0Adc
I1 = I2 = TD = TR = TF = PW = PER =
Ipulse
Finish
PSpice Tutorial
Vout
C1 1n
5.0V
2.5V
Tutorial 3: RC Circuit
5.0V
{Rv al}
R1 Vin Vout
0V
V1
SEL>> -6.0V
C1 5.0V 1n
0V
V(Vin)
0V
Rval > Value : 1k > display Double click R1 value > change to {Rval} Transient > parameter sweep > Global Parameter > Name: Rval > Sweep from 1k to 5k increment 1k
R1 Vin {Rv al} V1 = -5 V2 = 5 TD = 0 TR = 0.1u TF = 0.1u PW = 25u PER = 50u Vin C1 1n
0V 5.0V
Vout
-5.0V
0s V(Vout)
50us Time
100us
5.0V
1k
5k
0V
5k 1k
0
-5.0V 0s V(Vout) 20us V(Vin) 40us Time 60us 80us 100us
C1 10p
60
50
40
480MHz
520MHz
560MHz
600MHz
Frequency
C1 10p
Vdd V1 5Vdc
Vdd
Vdd V1
MbreakP
5Vdc
0
Vout
M2 Vin Vpulse
V
0
Vout
M1 MbreakN
5.0V
2.5V
2.5V
>New Page (right click) > Page name : Inverter Rename Schematic Internal, Rename PAGE1 Internal
Tutorial 9: contd..
Make sure both of your page is correct
Tutorial 9: contd..
Save the design > right click on schematic: inverter >
make as a root
Tutorial 9: contd..
In Page: Internal > Place Hierarchical Port connector
Tutorial 9: contd..
Tutorial 9: contd..
In Page: Inverter > Place hierarchical Block >
internal Vinput V1 = 0 V2 = 5 TD = 0 TR = 0.1u TF = 0.1u PW = 25u PER = 50u Vpulse internal Vi Vo Voutput
5.0V
2.5V
2.5V
uA741 2 -
0
OS1 1
V-
+ 7 U2 +
V-
OUT OS2 V+
120
100
80
100Hz Frequency
1.0KHz
10KHz