introduction to elementary circuit simulations with pspice circuit laboratory ee. dept., national...

65
Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Upload: alannah-morris

Post on 18-Jan-2016

247 views

Category:

Documents


6 download

TRANSCRIPT

Page 1: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Introduction to Elementary Circuit Simulations with PSpice

Circuit Laboratory

EE. Dept., National Taiwan University

September 2013

Page 2: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Outline• Where can you access PSpice?• To Get PSpice via Cadence OrCAD Site• Introduction to OrCAD Demo• Drawing Circuits with Capture CIS• Bias Point Analysis with PSpice• DC Analysis with PSpice• Transient Analysis with PSpice• AC Analysis with PSpice• FAQ

Page 3: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Where can you access PSpice?

• Two way to get PSpice– http://www.cadence.com/

• You can find OrCAD 16.6 Demo here.

– Your disc in Sedra/Smith• You can find OrCAD 9.2 Lite here.

• Which one to use?– They are almost the same.– You can choose one of them.– The following shows the use of OrCAD

16.6 Demo.

Page 4: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 5: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 6: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Example for Filling the Form

• First Name: (Yours)• Last Name: (Yours)• Company/University:

National Taiwan University

• Address: No. 1, Sec. 4, Roosevelt Road

• City: Taipei• Country: Taiwan• State/Province: 00-TW

• Postal Code: 10617• Telephone: +886-2-

33663700• Job Title: Student

Page 7: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 8: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 9: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 10: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 11: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Introduction to OrCAD Demo (1)

• Free version? No free meal, of course!• Limits exist since it is a lite version or a demo

The following limits apply to the Demo/Lite Version of the

products: – PSpice A/D

Circuit simulation is limited to circuits with up to: • 64 nodes • 10 transistors • 65 digital primitive devices • 10 transmission lines in total (ideal or non-ideal) • 4 pairwise coupled transmission lines.

Page 12: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

• Limits [cont'd]– PSpice A/D [cont'd]

• The sample library includes 39 analog and 134 digital parts.

• Device characterization in the PSpice Model Editor is limited to diodes.

• Stimulus generation in the PSpice Stimulus Editor is limited to sine waves (analog) and clocks (digital).

• Circuit optimization with the PSpice Optimizer is limited to one goal, one parameter, and one constraint.

• You can not create CSDF format data files. • You can only display simulation data from simulations

performed with the Demo/Lite Version of the simulator.

Introduction to OrCAD Demo (2)

Page 13: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

• Limits [cont'd]– Capture CIS

• The PSpice libraries are the only ones included. The standard Capture libraries are not included.

• Import facilities, netlisters, and accessories that are not relevant to PSpice are not included.

• You can not save a design that contains more than 60 parts. (You can view or create larger designs, but you can not save them.)

• You can not save a library that contains more than 15 parts.

Introduction to OrCAD Demo (3)

Page 14: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

• Minimum hardware requirements – Pentium 4 (32-bit) equivalent or faster – Windows XP, Windows Vista, or Windows 7– Minimum 512MB RAM (1GB recommended)– 300MB swap space (or more)– DVD-ROM drive– 65,000 color Windows display with minimum

1024x768 (1280x1024 recommanded)

Introduction to OrCAD Demo (4)

Page 15: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Notes When Set OrCAD Demo Up

• In the procedure installing…– Make sure you are connected to the internet.– Run “Product/Demo Installation” only.– Don’t set the control file.– Choose to install “Capture CIS” and “PSpice” only.– Keep “Footprint Viewer Options” to be “None.”– Cancel “License Client Configuration.”

• For the first time execution…– Run “PSpice AD” first, close it, and then you can

run “Capture CIS” and use the function of PSpice.

Page 16: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Agree, of course!

Page 17: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 18: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Check this if you feel troubled

Page 19: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Close it

Page 20: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 21: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Check this if you feel troubled

Page 22: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 23: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Drawing Circuits with Capture CIS

• To simulate a circuit, we need to figure out the structure of the circuit. Capture CIS helps us to do that.– Create a new project with Analog or Mixed

A/D wizard after selecting a proper folder to save.

– Place the elements (even if it is the ground) that are in the PSpice libraries.

– Place the tags (if needed) that are in capsym.olb .

Page 24: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 25: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Remember to select a proper folder (no Chinese!!) to saveC:\OrCAD_Data is welcome to be used

Page 26: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 27: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 28: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 29: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

%OrCAD%\tools\capture\library\pspice\demo

Add all of them

Page 30: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 31: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Frequently Used Elements

• R (resistor) / L (inductor) / C (capacitor)

• D (diode)– D1N4002– D1N750

• MBreakN / MBreakN4D (NMOS)

• MBreakP / MBreakP4D (PMOS)

• QBreakN (NPN BJT)– Q2N2222

Page 32: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

• QBreakP (PNP BJT)– Q2N2097A

• uA741

• VDC / VPULSE / VSin / VSRC

• IDC / IPULSE / ISin / ISRC

• GND

Frequently Used Elements

Page 33: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 34: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 35: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Bias Point Analysis with PSpice

• Where to find elements?– Place → Part or find the “Place Part”

button on the toolbar– Pick the element you want– Click OK button

• How to link the elements?– Find Place Wire button on the toolbar– Link the elements you want– NOTE:

wire crossing without big dot → openwire crossing with big dot → short

Page 36: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Place Wire

Page 37: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Bias Point Analysis with PSpice

• How to simulate?– PSpice → New Simulation Profile– Fill out the profile name– Select Bias Point in Analysis Type– Click OK– PSpice → Run

Page 38: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 39: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

profile name as your wish

Page 40: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 41: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 42: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

DC Analysis with PSpice• Note: VSRC or ISRC used!• How to simulate?

– PSpice → New Simulation Profile

– Fill out the profile name

– Select DC Sweep in Analysis Type

– Fill out Name, Start Value, End Value and Increment

– Never forget to check the type of the Sweep variable!

– PSpice → Run

• A/D window

Page 43: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 44: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 45: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 46: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 47: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

DC Analysis with PSpice• Add Trace?

– Trace → Add Trace...

Node Variable

Special Functions

Page 48: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 49: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Transient analysis with PSpice• NOTE: VSRC and ISRC not used!• Usually VSin/ISin/VPULSE/IPULSE used• How to simulate?

– PSpice → New Simulation Profile– Fill out the profile name– Select Time Domain(Transient) in

Analysis Type– Set Run to time, Start saving data after,

and Maximum Step Size– PSpice → Run

Page 50: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 51: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 52: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

PER

V1

V2

TD

TR TF PW

Page 53: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

Transient Analysis with PSpice

• Trick: Axis Settings– example: Lissajous

Figures Method– Plot → Axis

Settings...• Data Range• Scale• Fourier Analysis• Axis Variable

Page 54: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 55: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

AC Analysis with Pspice (1)• NOTE: VSRC or ISRC used!• How to simulate?

– PSpice → New Simulation Profile– Fill out the profile name– Select AC Sweep/Noise in Analysis Type– Select the frequency scale (linear or

logarithmic Decade/Octave)– Fill out Start frequency, End frequency,

and the information about sampling rate– PSpice → Run

Page 56: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 57: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 58: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 59: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

AC Analysis with PSpice (2)

• Trick: Multiple plots in one window– example: Bode plot– Plot → Add Plot to Window

• Trick: Y-Axis scale switch (linear or logarithmic)– Log Y Axis button on the toolbar

Page 60: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013
Page 61: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

FAQ

• I faced the dialogs as follows and cannot create or edit any PSpice simulation profile.

– If you are a WinXP user, you must forget to run “PSpice AD” first in the first-time execution. Close Capture CIS, run PSpice AD, close it, then try to run Capture CIS again.

– If you are a WinVista user, there are some OS options you need to modify. See another slides discussing the troubleshooting of installation on Windows Vista.

Page 62: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

FAQ

• How do I represent 10-3, 10-6 ,etc., by letter in PSpice?– Scale Symbol Name

10-15 F; f femto-

10-12 P; p pico-

10-9 N; n nano-

10-6 U; u micro-

10-3 M; m milli-

103 K; k kilo-

106 MEG; meg mega-

109 G; g giga-

1012 T; t tera-

Page 63: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

FAQ

• How do I change axis scale quickly?– Try these buttons:

Page 64: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

FAQ

• What's the differencebetween C1:1 and C1:2?– They represent the different pins

of your element. Distinguish thepins very carefully.

Page 65: Introduction to Elementary Circuit Simulations with PSpice Circuit Laboratory EE. Dept., National Taiwan University September 2013

FAQ• I tried my PSpice, and saved my circuit file upon

the desktop, and when I try to simulate the circuit, I get some simulation error about "file not exist" or so on. What's up?– It is a tricky bug of PSpice. A filename or folder /

directory name with Chinese is not accepted in PSpice. Try creating a new file, copying the original circuit to the new file, and save it in a folder not containing Chinese or spaces, such as C:\temp . Hope this works. Of course, files saved upon the desktop, which is at C:\Documents and Settings\eeuser\ 桌 面 if you use Windows in Chinese version, are not accepted.

– In Version 16.6, you are suggested to save your design files in OrCAD_Data folder. This helps.