PSPICE Edit Model Library and Parametric Sweep Guide...

21
PSPICE Edit Model Library and Parametric Sweep Guide When you open PSPICE in lab, you should see a screen like this: Select OrCAD_Capture_CIS_option with OrCAD EE Designer Plus and select OK I am titling this PSPICE project Simulation 2. Select the Analog or Mixed A/D option. You can specify the location you choose to save the file in if you click on the Browse button.

Transcript of PSPICE Edit Model Library and Parametric Sweep Guide...

Page 1: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

PSPICE Edit Model Library and Parametric Sweep Guide

When you open PSPICE in lab, you should see a screen like this:

Select OrCAD_Capture_CIS_option with OrCAD EE Designer Plus and select OK

I am titling this PSPICE project Simulation 2. Select the Analog or Mixed A/D option. You can specify the location you choose to save the file in if you click on the Browse button.

Page 2: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Your screen should now look like the following:

Create a blank project and press OK.

Page 3: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Now we can start adding parts. You can place a part by pressing P or by selecting part from the Place menu.

To add libraries to your part database, click on the Add library icon on the right side of the screen, or press (Alt A).

It is best to not leave anything out so select all the PSPICE libraries in the Browse File window that pops up. The breakout library should be included in the libraries on the right.

Page 4: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

We are using a VDC source here:

Page 5: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Find mbreakP3D in your parts list on the right side of your screen. Place it on your schematic.

Be sure to mirror the PMOS transistors vertically or your source and drain will be backwards. For the sake of this demonstration, I will be mirroring one of the transistors horizontally as well.

Page 6: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Press G on your keyboard or select Ground from the Place drop down menu. Select the 0/CAPSYM option. We are using R/ANALOG resistors in this project:

Page 7: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Now to edit the PSPICE library parameters, select one of the transistors, and select Edit Pspice Model.

Your screen should look like this.

Page 8: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Click Extract Model from the View drop down menu.

Click Yes:

Page 9: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Your screen should now look like this:

Click Edit Model from the View drop down menu:

Page 10: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

And now your screen should look like this:

Page 11: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Here you can change the PSPICE model parameters to whatever you wish.

Save your library As:

Page 12: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Take note of the folder you save your library in. I am titling this library PMOS_Sim2.

Take note of the top left of screen in the following screen shot. It now says PMOS_Sim2/MbreakPD. Now that the file is saved we can exit the Model Editor.

Page 13: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Double click on a transistor and a screen similar to this one should appear.

Page 14: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Click the small button by implementation path and select the library you just saved and click open. Click Apply near the top of the screen.

We wish to do a parametric sweep on R for simulation 1. This is a little bit different than doing a simple DC sweep. First, double click on the resistor you wish to do a sweep on:

Page 15: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Under Value only, give your resistor a title with {} around it, such as above.

Now place the part PARAM/SPECIAL in your schematic.

Page 16: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Double click on PARAM/SPECIAL and click New Row.

Type in the name you titled your resistor, and under value, type any number, as long as it is in the range of values you wish to sweep. Click Apply.

Page 17: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Click on the R2 row, click Display, and select name and value:

Page 18: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

The screen should look something like this when you go back to your schematic.

Create a New simulation Profile.

Page 19: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

Under DC Sweep, Primary Sweep, click global parameter, type in the name of your resistor, and specify the value range and increment.

I added the net alias ‘vo’ to my schematic. You can do this by pressing N or clicking Net Alias from the Place drop down-menu. The following screen shot is cropped because I changed the value of R1 in the schematic to the value I calculated in my analysis. Do your own analysis to find the R value!

Page 20: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

To plot I vs V, we must change the axis settings in our plot. Click Axis Setting under the Plot drop down menu. Click on Axis Variable and select V[vo]

Page 21: PSPICE Edit Model Library and Parametric Sweep Guide …aries.ucsd.edu/.../12-F/Homework/PSPICE_part_v3.pdf · PSPICE Edit Model Library and Parametric Sweep Guide . When you open

We can now generate an IV curve for the load by adding a trace for current: