OrCAD_PSpice简明教程(免费下载.xiaoy)
OrCAD-PSpice混合电路仿真与基本使用教程
5.7 绘制总线BUS
绘制总线
OrCAD-PSpice混合电路仿真和基本 使用教程
总线连接线(bus entry)不具有电气意 义; 应用网络标号进行导线连接;
OrCAD-PSpice混合电路仿真和基本 使用教程
总线应用实例
OrCAD-PSpice混合电路仿真和基本 使用教程
OrCAD-PSpice混合电路仿真和基本 使用教程
OrCAD-PSpice混合电路仿真和基本 使用教程
生成新图纸
OrCAD-PSpice混合电路仿真和基本 使用教程
最大化
OrCAD-PSpice混合电路仿真和基本 使用教程
菜单栏 主工具栏
PSpice工具栏
绘图工具栏
OrCAD-PSpice混合电路仿真和基本 使用教程
方法2 Place Part Add Library
OrCAD-PSpice混合电路仿真和基本 使用教程
查找库文件
OrCAD-PSpice混合电路仿真和基本 使用教程
5.3 变更鼠标选取对象部方分选式中、
还是全部选中
OrCAD-PSpice混合电路仿真和基本 使用教程
Select选项卡
OrCAD-PSpice混合电路仿真和基本 使用教程
PAGE1(NEW)
OrCAD-PSpice混合电路仿真和基本 使用教程
OrCAD-PSpice混合电路仿真和基本 使用教程
PAGE1(OLD)
OrCAD-PSpice混合电路仿真和基本 使用教程
PAGE2(OLD)
OrCAD-PSpice混合电路仿真和基本 使用教程
OrCAD-PSpice混合电路仿真和基本 使用教程
PSPICE简明教程
PSPICE 教學講義製作王志升Install從實驗室網頁下載PSPICE student version 或自行上網搜尋或自行上網搜尋。
安裝時請勾選schematics 。
啟動啟動::從程式集點schematics 啟動程式啟動程式。
Create circuit(1/3)1.點擊Get New Part圖式2.鍵入r 找到電阻3.點選place4.在平面上放置電阻Create circuit(2/3)用同樣的方法找出電容c ,電桿L直流電源VDC ,以及GND_EARTH 。
並且將螢幕調整至適當尺寸適當尺寸。
Hint:名稱可以任意修改名稱可以任意修改,,不影響電路結構不影響電路結構,,我們在乎的是該原件的值我們在乎的是該原件的值。
Create circuit(3/3)1.點選Draw Wire 完成電路2.存檔3.按simulate 圖式圖式,,進行模擬4.出現Simulation complete代表模擬成功代表模擬成功。
DC bias(1/2)開一個新檔案完成此電路。
開一個新檔案完成此電路雙擊直流電源將其電壓改成2VDC bias(2/2)1.點擊simulate 進行模擬進行模擬。
2.點擊V ,I 以顯示電壓急電流以顯示電壓急電流。
觀察各點電壓電流DC SWEEP(1/3)開一個新檔案利用VAC ,VDC ,GND 以及電晶體Q2N3904完成此電路完成此電路,, 並將VDC 的值設為1.8V1.點選Current Marker 圖式圖式。
2.在電晶體的集極放置一個Current Marker 。
DC SWEEP(2/3)1.點選Setup Analysis2.勾選DC Sweep3.點擊DC Sweep4.設定框內的值Hint:黑色圈的名稱因人而異與VAC的名稱相同即可。
DC SWEEP(3/3)完成上頁設定後完成上頁設定後,,點擊Simulate 進行模擬進行模擬。
觀察此圖形觀察此圖形,,思考結果思考結果。
OrCADPSpice简明教程
xiaoyllyPSPICE简明教程宾西法尼亚大学电气与系统工程系University of PennsylvaniaDepartment of Electrical and Systems Engineering编译:陈拓2009年8月4日原文作者:Jan Van der Spiegel, ©2006 jan_at_Updated March 19, 2006目录1. 介绍2. 带OrCAD Capture的Pspice用法2.1 第一步:在Capture 中创建电路2.2 第二步:指定分析和仿真类型偏置或直流分析(BIAS or DC analysis)直流扫描仿真(DC Sweep simulation)2.3 第三步:显示仿真结果2.4 其他分析类型:2.4.1瞬态分析(Transient Analysis)2.4.2 交流扫描分析(AC Sweep Analysis)3. 附加的使用Pspice电路的例子3.1变压器电路3.2 使用理想运算放大器的滤波器交流扫描(滤波器电路)3.3 使用实际运算放大器的滤波器交流扫描(滤波器电路)3.4 整流电路(峰值检波器)和参量扫描的使用3.4.1 峰值检波器仿真(Peak Detector simulation)3.4.2 参量扫描(Parametric Sweep)3.5 AM 调制信号3.6 中心抽头变压器4. 添加和创建库:模型和元件符号文件4.1 使用和添加厂商库4.2 从一个已经存在的Pspice模型文件创建Pspice符号4.3 创建你自己的Pspice模型文件和符号元件参考书目1. 介绍是一种强大的通用模拟混合模式电路仿真器,可以用于验证电路设计并且预知 SPICE电路的行为,这对于集成电路特别重要,1975年SPICE最初在加州大学伯克利分校被开发时也是基于这个原因,正如同它的名字所暗示的那样:S imulation P rogram for I ntegrated C ircuits E mphasis.PSpice 是一个PC版的SPICE(Personal-SPICE),可以从属于Cadence设计系统公司的OrCAD公司获得。
OrCAD_PSPICE_仿真入门
印制版设计
6、生成电路板档案(*.max),在Save File As 菜单栏 内点保存
印制版设计
7、给你的器件查找并定义封装
Layout调入Netlist时,会自动运行AutoECO,检测Layout的 Library中是否有器件的封装,如果没有,您可以通过Link existing footprint to component来查找连接封装。如下所示:
电路图的仿真
在Analysis
Type栏,选TimeDomain(Transient) 在Start saving data栏填写0s 在Run to栏填写30s
在Maximum step栏, 填写0.1s,或不填, 由系统默认。 点击“确定”按钮
电路图的仿真
3、放置仪器探头 执行PSpice/Markers/Voltage Level命令 将电压探头拖至被测信号端,如运放U1的正负输入U1+、 U1-,U1的输出U1OUT;555U2的输出U2OUT,U2充放电电压 U2Discharge等节点处。 按ESC键,以结束 仪器探头放置
放置的器件如下图
元器件间的电连接
器件的移动:对准器件,点击鼠标左键,按住左键, 拖动鼠标到适合的位置。 器件的翻转,点中器件,按键盘上的“R”,或单击鼠 标的右键,点“Rotate”命令。 器件的删除,点中器件,按键盘上的删除键Delete 执行P1ace/Wire命令 将光标移至互连线的起始位置处,点击鼠标左键 移动鼠标,在互连线终点,单击鼠标左键进行连接 单击鼠标右键,选择End Wire子命令,结束互连线绘 制
放置阶层
放置阶层引脚
添加文字
Place Bus
Place part Place wire Place GND 绘制无电气性质符号
OrCAD-PSPICE-仿真入门
强大的分析工具
ORCAD-PSPICE提供了丰富 的分析工具,如波形分析、 频谱分析、噪声分析等,帮 助用户深入了解电路性能。
灵活的参数化分析
用户可以通过参数化分析功 能,对电路元件参数进行扫 描和优化,找到最佳的电路 性能。
THANKS FOR WATCHING
感谢您的观看
orcad-pspice仿真入门
目 录
• 引言 • ORCAD-PSPICE概述 • ORCAD-PSPICE仿真流程 • 常见电路仿真分析 • 高级仿真技术 • ORCAD-PSPICE仿真实例
01 引言
目的和背景
学习和掌握ORCAD-PSPICE仿真软件, 能够为电子工程师提供强大的电路设 计和分析工具,帮助他们快速验证电 路原理、优化电路参数和提高设计效 率。
ORCAD-PSPICE支持模拟、数字和混合信号电路的仿真,能够进行电路性能分析和优化,帮助工程师快速、准确地完成电路 设计和验证。
ORCAD-PSPICE的功能和特点
丰富的元件库
ORCAD-PSPICE提供了广泛 的元件库,包括各种模拟、 数字和混合信号元件,方便 用户进行电路设计和仿真。
高精度仿真
蒙特卡洛分析
蒙特卡洛分析是一种基于概率统计的 仿真技术,用于分析电路性能的统计 分布情况。在Orcad-Pspice中,可 以通过在仿真设置中设置蒙特卡洛分 析参数,对电路性能进行概率统计。
VS
蒙特卡洛分析可以帮助设计者了解电 路性能的统计分布情况,从而评估电 路性能的可靠性。
最坏情况分析
最坏情况分析是一种仿真技术,用于分析电 路性能在元件参数最坏情况下的表现。在 Orcad-Pspice中,可以通过在仿真设置中 设置最坏情况分析参数,对电路性能进行最 坏情况分析。
OrCAD PSPICE 仿真入门
原理图绘制
修改后原理图变为: 修改后原理图变为:
电路原理图保存
执行File/Save命令 执行File/Save命令
电路图的仿真 (三)电路的仿真(瞬态分析) 电路的仿真(瞬态分析)
1、建立电路网表(执行PSpice/Create Netlist命令)
电路图的仿真
2、仿真参数类型设置
执行PSpice/New 执行PSpice/New Simulation Profile命令 Profile命令
放置二极管符号
执行P1ace/Part命令 执行P1ace/Part命令 在 “Libraries”列表框中选 Libraries”列表框中选 择“diode”库 择“diode”库 在 “Part”列表框中选择 Part”列表框中选择 “ D1N4002”,单击“OK” D1N4002”,单击“OK” 将该二极管移至合适位置, (按键盘中的R (按键盘中的R键,器件旋 转)按鼠标左键放置 按ESC键(或鼠标右键点 ESC键(或鼠标右键点 end mode)结束绘制元器 mode)结束绘制元器ce/Part命令 执行P1ace/Part命令 在 “Libraries”列表框中 Libraries”列表框中 选择“SOURCE” 选择“SOURCE” 在 “Part”列表框中选择 Part”列表框中选择 “ VSIN”,或 VSIN”,或 “VPULSE”, 或“VPWL” 或“VPWL” 单击“OK” 单击“OK” 将激励源移至合适位置, 按鼠标左键 按ESC键或鼠标右键点 ESC键或鼠标右键点 end mode以结束绘制元 mode以结束绘制元 器件状态
放置电容符号
执行P1ace/Part命令 执行P1ace/Part命令 在 “Libraries”列表框中选 Libraries”列表框中选 择“ANALOG” 择“ANALOG” 在 “Part”列表框中选择 Part”列表框中选择 “ C” 单击“OK” 单击“OK” 将电阻C 将电阻C移至合适位置, (按键盘中的R (按键盘中的R键,器件旋 转)按鼠标左键放置 按ESC键(或鼠标右键点 ESC键(或鼠标右键点 end mode)结束绘制元器 mode)结束绘制元器 件状态
OrCAD PSPICE 仿真入门
放置集成块时基电路555 放置集成块时基电路555
同样在Anl_misc库内找到555B或555C,放置在原理图中 同样在Anl_misc库内找到555B或555C,放置在原理图中
原理图绘制
放置电阻符号
执行P1ace/Part命令 执行P1ace/Part命令 在 “Libraries”列表框中 Libraries”列表框中 选择“ANALOG” 选择“ANALOG” 在 “Part”列表框中选择 Part”列表框中选择 “ R”,单击“OK” R”,单击“OK” 将电阻R 将电阻R移至合适位置, (按键盘中的R (按键盘中的R键,器件 旋转)按鼠标左键放置 按ESC键(或鼠标右键 ESC键(或鼠标右键 点end mode)结束绘制 mode)结束绘制 元器件状态
其余元件属性参数修改
将R2的1k修改为1m R2的1k修改为1m 将R3的1k修改为1m R3的1k修改为1m 将R4的1k修改为82k R4的1k修改为82k 将R5的1k修改为2k R5的1k修改为2k 将C1的1n修改为0.1u C1的1n修改为0.1u 将C2的1n修改为220u C2的1n修改为220u Vi的VOFF值设定为6v Vi的VOFF值设定为6v Vi的VAMPL值设定为30mv Vi的VAMPL值设定为30mv Vi的FREQ值设定为2kHz Vi的FREQ值设定为2kHz V1的0Vdc更改为12Vdc V1的0Vdc更改为12Vdc
Analog or Mixed-signal Circuit 本工程以后将进行数/模混合仿真 PC Board Wizard 本工程以后将用来进行印刷版图设计
Programmable Logic Wizard
本工程以后将用于可编程器件的设计(在 9.2版本已经不支持) Schematic 本工程只进行原理图设计
OrCAD PSpice软件培训教材
OrCAD PSpice 培训教材培训目标:熟悉PSpice的仿真功能,熟练掌握各种仿真参数的设置方法,综合观测并分析仿真结果,熟练输出分析结果,能够综合运用各种仿真对电路进行分析,学会修改模型参数。
一、PSpice分析过程二、绘制原理图原理图的具体绘制方法差不多在Capture中讲过了,下面要紧讲一下在使用PSpice时绘制原理图应该注意的地点。
1、新建Project时应选择Analog or Mixed-signal Circuit2、调用的器件必须有PSpice模型首先,调用OrCAD软件本身提供的模型库,这些库文件存储的路径为Capture\Library\pspice,此路径中的所有器件都有提供PSpice模型,能够直接调用。
其次,若使用自己的器件,必须保证*.olb、*.lib两个文件同时存在,而且器件属性中必须包含PSpice Template属性。
3、原理图中至少必须有一条网络名称为0,即接地。
4、必须有激励源。
原理图中的端口符号并不具有电源特性,所有的激励源都存储在Source和SourceTM库中。
5、电源两端不同意短路,不同意仅由电源和电感组成回路,也不同意仅由电源和电容组成的割集。
解决方法:电容并联一个大电阻,电感串联一个小电阻。
6、最好不要使用负值电阻、电容和电感,因为他们容易引起不收敛。
三、仿真参数设置1、PSpice能够仿确实类型在OrCAD PSpice中,能够分析的类型有以下8种,每一种分析类型的定义如下:直流分析:当电路中某一参数(称为自变量)在一定范围内变化时,对自变量的每一个取值,计算电路的直流偏置特性(称为输出变量)。
交流分析:作用是计算电路的交流小信号频率响应特性。
噪声分析:计算电路中各个器件对选定的输出点产生的噪声等效到选定的输入源(独立的电压或电流源)上。
即计算输入源上的等效输入噪声。
瞬态分析:在给定输入激励信号作用下,计算电路输出端的瞬态响应。
差不多工作点分析:计算电路的直流偏置状态。
OrCAD PSpice 入门教程
University of PennsylvaniaDepartment of Electrical and Systems EngineeringPSPICEA brief primerContents1.Introductione of PSpice with OrCAD Capture2.1 Step 1: Creating the circuit in Capture2.2 Step 2: Specifying the type of analysis and simulationBIAS or DC analysisDC Sweep simulation2.3 Step 3: Displaying the simulation Results2.4 Other types of Analysis:2.4.1 Transient Analysis2.4.2 AC Sweep Analysis3. Additional Circuit Examples with PSpice3.1 Transformer circuit3.2 AC Sweep of Filter with Ideal Op-amp (Filter circuit)3.3 AC Sweep of Filter with Real Op-amp (Filter Circuit)3.4 Rectifier Circuit (peak detector) and the use of a parametric sweep.Peak Detector simulationParametric Sweep3.5AM Modulated Signal3.6 Center Tap Transformer4.Adding and Creating Libraries: Model and Part Symbol files4.1Using and Adding Vendor Libraries4.2Creating PSpice Symbols from an existing PSpice Model file4.3Creating your own PSpice Model file and Symbol PartsReferences1.INTRODUCTIONSPICE is a powerful general purpose analog and mixed-mode circuit simulator that is used to verify circuit designs and to predict the circuit behavior. This is of particular importance for integrated circuits. It was for this reason that SPICE was originally developed at the Electronics Research Laboratory of the University of California, Berkeley (1975), as its name implies:S imulation P rogram for I ntegrated C ircuits E mphasis.PSpice is a PC version of SPICE (which is currently available from OrCAD Corp. of Cadence Design Systems, Inc.). A student version (with limited capabilities) comes with various textbooks. The OrCAD student edition is called PSpice AD Lite. Information about Pspice AD is available from the OrCAD website: /pspicead.aspxThe PSpice Light version has the following limitations: circuits have a maximum of 64 nodes, 10 transistors and 2 operational amplifiers.SPICE can do several types of circuit analyses. Here are the most important ones: •Non-linear DC analysis: calculates the DC transfer curve.•Non-linear transient and Fourier analysis: calculates the voltage and current as a function of time when a large signal is applied; Fourier analysis gives the frequency spectrum.•Linear AC Analysis: calculates the output as a function of frequency. A bode plot is generated.•Noise analysis•Parametric analysis•Monte Carlo AnalysisIn addition, PSpice has analog and digital libraries of standard components (such as NAND, NOR, flip-flops, MUXes, FPGA, PLDs and many more digital components, ). This makes it a useful tool for a wide range of analog and digital applications.All analyses can be done at different temperatures. The default temperature is 300K.The circuit can contain the following components:•Independent and dependent voltage and current sources•Resistors•Capacitors•Inductors•Mutual inductors•Transmission lines•Operational amplifiers•Switches•Diodes•Bipolar transistors•MOS transistors•JFET•MESFET•Digital gates•and other components (see users manual).2. PSpice with OrCAD Capture (release 9.2 Lite edition)Before one can simulate a circuit one needs to specify the circuit configuration. This can be done in a variety of ways. One way is to enter the circuit description as a text file in terms of the elements, connections, the models of the elements and the type of analysis. This file is called the SPICE input file or source file and has been described somewhere else (see /%7Ejan/spice/spice.overview.html).An alternative way is to use a schematic entry program such as OrCAD CAPTURE. OrCAD Capture is bundled with PSpice Lite AD on the same CD that is supplied with the textbook. Capture is a user-friendly program that allows you to capture the schematic of the circuits and to specify the type of simulation. Capture is non only intended to generate the input for PSpice but also for PCD layout design programs.The following figure summarizes the different steps involved in simulating a circuit with Capture and PSpice. We'll describe each of these briefly through a couple of examples.Figure 1: Steps involved in simulating a circuit with PSpice.The values of elements can be specified using scaling factors (upper or lower case):T or Tera (= 1E12);G or Giga (= E9); MEG or Mega (= E6); K or Kilo (= E3);M or Milli (= E-3); U or Micro (= E-6); N or Nano (= E-9); P or Pico (= E-12) F of Femto (= E-15)Both upper and lower case letters are allowed in PSpice and HSpice. As an example, one can specify a capacitor of 225 picofarad in the following ways:225P, 225p, 225pF; 225pFarad; 225E-12; 0.225NNotice that Mega is written as MEG, e.g. a 15 megaOhm resistor can be specified as15MEG, 15MEGohm, 15meg, or 15E6. Be careful not to use M for Mega! When you write 15Mohm or 15M, Spice will read this as 15 milliOhm!We'll illustrate the different types of simulations for the following circuit:Figure 2: Circuit to be simulated (screen shot from OrCAD Capture).2.1 Step 1: Creating the circuit in Capture2.1.1 Create new project:1.Open OrCAD Capture2.Create a new Project: FILE MENU/NEW_PROJECT3.Enter the name of the project4.Select Analog or Mixed-AD5.When the Create PSpice Project box opens, select "Create Blank Project".A new page will open in the Project Design Manager as shown below.Figure 3: Design manager with schematic window and toolbars (OrCAD screen capture)2.1.2. Place the components and connect the parts1.Click on the Schematic window in Capture.2.To Place a part go to PLACE/PART menu or click on the Place Part Icon. This will opena dialog box shown below.Figure 4: Place Part window3.Select the library that contains the required components. Type the beginning of the namein the Part box. The part list will scroll to the components whose name contains the same letters. If the library is not available, you need to add the library, by clicking on the Add Library button. This will bring up the Add Library window. Select the desired library.For Spice you should select the libraries from the Capture/Library/PSpice folder.Analog: contains the passive components (R,L,C), mutual inductane, transmission line, and voltage and current dependent sources (voltage dependent voltage source E, current-dependent current source F, voltage-dependent current source G and current-dependentvoltage source H).Source: give the different type of independent voltage and current sources, such as Vdc, Idc, Vac, Iac, Vsin, Vexp, pulse, piecewise linear, etc. Browse the library to see what isavailable.Eval: provides diodes (D…), bipolar transistors (Q…), MOS transistors, JFETs (J…),real opamp such as the u741, switches (SW_tClose, SW_tOpen), various digital gates and components.Abm: contains a selection of interesting mathematical operators that can be applied tosignals, such as multiplication (MULT), summation (SUM), Square Root (SWRT),Laplace (LAPLACE), arctan (ARCTAN), and many more.Special:contains a variety of other components, such as PARAM, NODESET, etc.4.Place the resistors, capacitor (from the Analog library), and the DC voltage and currentsource. You can place the part by the left mouse click. You can rotate the components by clicking on the R key. To place another instance of the same part, click the left mousebutton again. Hit the ESC key when done with a particular element. You can add initialconditions to the capacitor. Double-click on the part; this will open the Property window that looks like a spreadsheet. Under the column, labeled IC, enter the value of the initial condition, e.g. 2V. For our example we assume that IC was 0V (this is the default value).5.After placing all part, you need to place the Ground terminal by clicking on the GNDicon (on the right side toolbar – see Fig. 3). When the Place Ground window opens, select GND/CAPSYM and give it the name 0 (i.e. zero). Do not forget to change the name to 0, otherwise PSpice will give an error or "Floating Node". The reason is that SPICEneeds a ground terminal as the reference node that has the node number or name 0 (zero).Figure 5: Place the ground terminal box; the ground terminal should have the name 06.Now connect the elements using the Place Wire command from the menu(PLACE/WIRE) or by clicking on the Place Wire icon.7.You can assign names to nets or nodes using the Place Net Alias command (PLACE/NETALIAS menu). We will do this for the output node and input node. Name these Out andIn, as shown in Figure 2.2.1.3. Assign Values and Names to the parts1.Change the values of the resistors by double-clicking on the number next to the resistor.You can also change the name of the resistor. Do the same for the capacitor and voltage and current source.2.If you haven't done so yet, you can assign names to nodes (e.g. Out and In nodes).3.Save the project2.1.4. NetlistThe netlist gives the list of all elements using the simple format:R_name node1 node2 valueC_name nodex nodey value, etc.1.You can generate the netlist by going to the PSPICE/CREATE NETLIST menu.2.Look at the netlist by double clicking on the Output/ file in the Project ManagerWindow (in the left side File window).Note on Current Directions in elements:The positive current direction in an element such as a resistor is from node 1 to node 2. Node1 is either the left pin or the top pin for an horizontal or vertical positioned element (.e.g aresistor). By rotating the element 180 degrees one can switch the pin numbers. To verify the node numbers you can look at the netlist:e.g. R_R2 node1 node2 10ke.g. R_R2 0 OUT 10kSince we are interested in the current direction from the OUT node to the ground, we need to rotate the resistor R2 twice so that the node numbers are interchanged:R_R2 OUT 0 10k2.2 Step 2: Specifying the type of analysis and simulationAs mentioned in the introduction, Spice allows you do to a DC bias, DC Sweep, Transientwith Fourier analysis, AC analysis, Montecarlo/worst case sweep, Parameter sweep and Temperature sweep. We will first explain how to do the Bias and DC Sweep on the circuit of Figure 2.2.2.1 BIAS or DC analysis1.With the schematic open, go to the PSPICE menu and choose NEW SIMULATIONPROFILE.2.In the Name text box, type a descriptive name, e.g. Bias3.From the Inherit From List: select none and click Create.4.When the Simulation Setting window opens, for the Analyis Type, choose Bias Pointand click OK.5.Now you are ready to run the simulation: PSPICE/RUN6. A window will open, letting you know if the simulation was successful. If there areerrors, consult the Simulation Output file.7.To see the result of the DC bias point simulation, you can open the Simulation Outputfile or go back to the schematic and click on the V icon (Enable Bias VoltageDisplay) and I icon (current display) to show the voltage and currents (see Figure 6).The check the direction of the current, you need to look at the netlist: the current ispositive flowing from node1 to node1 (see note on Current Direction above).Figure 6: Results of the Bias simulation displayed on the schematic.2.2.2 DC Sweep simulationWe will be using the same circuit but will evaluate the effect of sweeping the voltage source between 0 and 20V. We'll keep the current source constant at 1mA.1.Create a new New Simulation Profile (from the PSpice Menu); We'll call it DC Sweep2.For analysis select DC Sweep; enter the name of the voltage source to be swept: V1. Thestart and end values and the step need to be specified: 0, 20 and 0.1V, respectively (see Fig. below).Figure 7: Setting for the DC Sweep simulation.3.Run the simulation. PSpice will generate an output file that contains the values of allvoltages and currents in the circuit.2.3 Step 3: Displaying the simulation ResultsPSpice has a user-friendly interface to show the results of the simulations. Once the simulation is finished a Probe window will open.Figure 8: Probe window1.From the TRACE menu select ADD TRACE and select the voltages and current you liketo display. In our case we'll add V(out) and V(in). Click OK.Figure 9: Add Traces window2.You can also add traces using the "Voltage Markers" in the schematic. From the PSPICEmenu select MARKERS/VOLTAGE LEVELS. Place the makers on the Out and In node.When done, right click and select End Mode.Figure 10: Using Voltage Markers to show the simulation result of V(out) and V(in)3.Go to back to PSpice. You will notice that the waveforms will appear.4.You can add a second Y Axis and use this to display e.g. the current in Resistor R2, asshown below. Go to PLOT/Add Y Axis. Next, add the trace for I(R2).5.You can also use the cursors on the graphs for Vout and Vin to display the actual valuesat certain points. Go to TRACE/CURSORS/DISPLAY6.The cursors will be associated with the first trace, as indicated by the small smallrectangle around the legend for V(out) at the bottom of the window. Left click on the first trace. The value of the x and y axes are displayed in the Probe window. When you right click on V(out) the value of the second cursor will be given together with the difference between the first and second cursor.7.To place the second cursor on the second trace (for V(in)), right click the legend forV(in). You'll notice the outline around V(in) at the bottom of the window. When you right click the second trace the cursor will snap to it. The values of the first and second cursor will be shown in Probe window.8.You can chance the X and Y axes by double clicking on them.9.When adding traces you can perform mathematical calculations on the traces, asindicated in the Add Trace Window to the right of Figure 9.Figure 11: Result of the DC sweep, showing Vout, Vin and the current throughresistor R2. Cursors were used for V(out) and V(in).2.4 Other types of Analysis2.4.1 Transient AnalysisWe'll be using the same circuit as for the DC sweep, except that we'll apply the voltage and current sources by closing a switch, as shown in Figure 12.Figure 12: Circuit used for the transient simulation.1.Insert the SW_TCLOSE switch from the EVAL Library as shown above. Double click onthe switch TCLOSE value and enter the value when the switch closes. Lets makeTCLOSE = 5 ms.2.Set up the Transient Analysis: go to the PSPICE/NEW SIMULATION PROFILE.3.Give it a name (e.g. Transient). When the Simulation Settings window opens, select"Time Domain (Transient)" Analysis. Enter also the Run Time. Lets make it 50 ms. For the Max Step size, you can leave it blank or enter 10us.4.Run PSpice.5. A Probe window in PSpice will open. You can now add the traces to display the results.In the figure below we plotted the current through the capacitor in the top window andthe voltage over the capacitor on the bottom one. We use the cursor to find the timeconstant of the exponential waveform (by finding the 0.632 x V(out)max = 9.48. Thecursor gave a corresponding time of 30ms which gives a time constant of 30-5=25ms (5 ms is subtracted because the switch closed at 5ms).Figure 13: Results of the transient simulation of Figure 12.6.Instead of using a switch we can also use a voltage source that changes over time. Thiswas done in Figure 14 where we used the VPULSE and IPULSE sources from theSOURCE Library. We entered the voltage levels (V1 and V2), the delay (TD), Rise and Fall Times, Pulse Width (PW) and the Period (PER). The values are indicated in the figure below. For details on these parameters click here. A description of other Spice elements can be found in the User’s guide or in the Spice Tutorial.(/~jan/spice/)Figure 14: Circuit with a PULSE voltage and current source.7.After doing the transient simulation results can be displayed as was done before8.The last example of a transient analysis is with a sinusoidal signal VSIN. The circuit isshown below. We made the amplitude 10V and frequency 10 Hz.Figure 15: Circuit with a sinusoidal input.9.Create a Simulation Profiler for the transient analysis and run PSpice.10.The result of the simulation for Vout and Vin are given in the figure below.Figure 16: Transient simulation with a sinusoidal input.2.4.2 AC Sweep AnalysisThe AC analysis will apply a sinusoidal voltage whose frequency is swept over a specified range. The simulation calculates the corresponding voltage and current amplitude and phases for each frequency. When the input amplitude is set to 1V, then the output voltage is basically the transfer function. In contrast to a sinusoidal transient analysis, the AC analysis is not a time domain simulation but rather a simulation of the sinusoidal steady state of the circuit. When the circuit contains non-linear element such as diodes and transistors, the elements will be replaced their small-signal models with the parameter values calculated according to the corresponding biasing point.In the first example, we'll show a simple RC filter corresponding to the circuit of Figure 17.Figure 17: Circuit for the AC sweep simulation.1.Create a new project and build the circuit2.For the voltage source use VAC from the Sources library.3.Make the amplitude of the input source 1V.4.Create a Simulation Profile. In the Simulation Settings window, select AC Sweep/Noise.5.Enter the start and end frequencies and the number of points per decade. For our examplewe use 0.1Hz, 10 kHz and 11, respectively.6.Run the simulation7.In the Probe window, add the traces for the input voltage. We added a second window todisplay the phase in addition to the magnitude of the output voltage. The voltage can be displayed in dB by specifying Vdb(out) in the Add Trace window (type Vdb(out) in the Trace Expression box. For the phase, type VP(out).8.An alternative to show the voltage in dB and phase is to use markers on the schematics:PSPICE/MARKERS/ADVANCED/dBMagnitude or Phase of Voltage, or current. Place the markers on the node of interest.9.We used the cursors in Figure 18 to find the 3dB point. The value is 6.49 Hzcorresponding to a time constant of 25 ms (R1||R2.C). At 10 Hz the attenuation of Vout is11.4db or a factor of 3.72. This corresponds to the value of the amplitude of the outputvoltage obtained during the transient analysis of Figure 16 above.3. Additional Circuit Examples with PSpice3.1 Transformer circuitSPICE has no model for an ideal transformer. An ideal transformer is simulated using mutual inductances such that the transformer ratio N1/N2 = sqrt(L1/L2). The part in PSpice is called TFRM_LINEAR (in the Analog Library). Make the coupling factor K close to or equal to one (ex. K=1) and choose L such that wL >> the resistance seen be the inductor. Thesecondary circuit needs a DC connection to ground. This can be accomplished by adding a large resistor to ground or giving the primary and secondary circuits a common node. The following example illustrates how to simulate a transformer.Figure 3.1.1: Circuit with ideal transformerFor the above example, lets make wL2 >> 500 Ohm or L2> 500/(60*2pi) ; lets make L2 at least 10 times larger, ex. L2=20H. L1 can than be found from the turn ratio: L1/L2 =(N1/N2)^2. For a turn ratio of 10 this makes L1=L2x100=2000H. The circuit as entered in PSpice Capture is shown in Figure 3.1.2 and the result in Figure 3.1.3Figure 3.1.2: Circuit with ideal transformer as entered in PSpice Capture (the transformer TX is modeled by the part XFRM_LINEAR of the Analog Library).Figure 3.1.3: Results of the transient simulation of the above circuit.3.2 AC Sweep of Filter with Ideal Op-amp (Filter circuit)The following circuit will be simulated with PSpice.Figure 3.2.1: Active Filter Circuit with ideal op-amp.We have used off-page connectors (OFFPAGELEFT-R from the CAPSYM library; or by clicking on the off-page icon) for the input and outputs. The name of the connectors can be changed by double-clicking on the name of the off-page connector. By giving the same name to two connectors (or nodes), the two nodes will be connected (no wires are needed). For te voltage source we used the VAC from the SOURCE Library. We gave it an amplitude of 1V so that the output voltage will correspond to the amplification (or transfer function) of the filter. In the Simulation Analysis, select AC Sweep, and enter the starting, ending frequency and the number of points per decade.The result is given in the figure below. The magnitude is given on the left Y axis while the phase is given by the right Y axis. The cursors have been used to find the 3db points of the bandpass filters, corresponding to 0.63 Hz and 32 Hz for the low and high breakpoints,respectively. These numbers correspond to the values of the time constants given in Fig.3.2.1. The phase at these points is -135 and -224 degrees.Figure 3.2.2: Results of the AC sweep of the Active Filter Circuit of the figure above.3.3 AC Sweep of Filter with Real Op-amp (Filter circuit)The circuit with a real op-amp is shown below. We selected the U741 op-amp to build the filter. The simulation results are shown in Figure 3.3.2. As one would expect the differences between the filter with the real and ideal op-amps are minimal in this frequency range.Figure 3.3.1: Active Filter Circuit with the U741 Op-amp.Figure 3.3.2: Results of the AC sweep of the Active Filter Circuit with real Op-amp (U741) of the figure above.3.4 Rectifier Circuit (peak detector) and the use of a parametric sweep.3.4.1: Peak Detector simulationFigure 3.4.1: Rectifier circuit with the D1N4148 diode and a load resistor of 500 Ohm.The results of the simulation are given in Fig. 3.4.2. The ripple has a peak-to-peak value of 777mV as indicated by the cursors. The maximum output voltage is 13.997V which is one volt below the input of 15V.Figure 3.4.2: Simulation results of the rectifier circuit.3.4.2 Parametric SweepIt is interesting to see the effect of the load resistance on the output voltage and its ripple voltage. This can be done using the PARAM part.Figure 3.4.3: Circuit used for the parametric sweep of the load resistor.a. Adding the Parameter Parta.Double click on the value (500 Ohms) of the load resistor R1 to {Rval}. Use curlybrackets. PSpice interprets the text between curly brackets as an expression that itevaluate to a numerical expression. Click OK when done.b.Add the PARAM part to the circuit. You'll find this part in the SPECIAL library.c.Double click on the PARAM part. This will open a spreadsheet like windowshowing the PARAM definition. You will need to add a new column to thisspread sheet. Click on NEW COLUMN and enter for Property Name, Rlval(without the curly brackets).d.You will notice that the new column Rlval has been created. Below the Rlvalenter the initial value for the resistor: lets make it 500, as shown in Figure 3.4.4below.Figure 3.4.4: Property Editor window for the PARAM part, showing the newly created Rlval column.e.While the cell in which you entered the value 500 still selected click theDISPLAY button. You can now specify what to display: select Name and Value.Click OK.f.Click the APPLY button before closing the Property editor.g.Save the design.b. Create the Simulation Profile for the Parametric Analysisa.Select PSPICE/NEW_SIMULATION_PROFILEb.Type in the name of the profile, e.g. Parametricc.In the Simulation Setting window, select Analysis Tab if the window does notopen.d.For the Analysis type select Transient (or the type of analysis you intend toperform; in this example we'll do a transient analysis)e.Under Option, slect Parametric sweep as shown in Figure 3.4.5.f.For the Sweep Variable, select Global Parameter and enter the Parameter name:Rlval. Under sweep type give the start, end and increment for the parameter. We'llused 250, 1kOhm and 250, respectively (see Figure 3.4.5).g.Click OKFigure 3.4.5: Window for the Simulation Settings of the Parametric Sweep.c. Run Spice and Display the waveforms.a.Run PSpiceb.When the simulation is finished the Probe window will open and display a pop upbox with the Available Selection. Select ALL and OK.c.The multiple traces will show, as given in Figure 3.4.6.d.You can use the cursors to determined specific valueson the traces; you can alsoadjust the axis by double-clicking on the Y and X axes.Figure 3.4.6: Results of the parametric sweep of the load resistor, varying from 250 to 1000 Ohm in steps of 250 Ohm.3.5 AM Modulated Signal (AM Modulation)An Amplitude modulated (AM) signal has the expression,v am(t) = [(A + V m cos(2πf m t)] cos(2πf c t) = A[1 + m cos(2πf m t)] cos(2πf c t)in which a sinusoidal high frequency carrier waveform cos(2πf c t) is modulated by asinusoidal modulating of frequency f m. The modulating frequency can be any signal. For this example we’ll assume it is a sinusoid. The modulation index is called m.To generate a AM signal in PSpice we can make use of the Multiplication function MULT that can be found in the ABM library. Figure 3.51 shows the schematic that generates the AM signal over the resistor R1.Figure 3.5.1: Schematic for the generation of an AM signalThe result of a transient simulation is shown in the figure below. One can also look at the Fourier of the simulated output signal. In the Probe window click on the FFT icon, located on the top toolbar, or go to the PSPICE/FOURIER menu. The Fourier spectrum of the displayed trace will be shown. You can change the X axis by double-clicking on it. Figure 3.5.3 gives the Fourier spectrum with the main peak corresponding to the carrier frequency of 5kHz and two side peaks at 4.5 and 5.5 kHz, indicating that the modulating frequency is 500Hz. You can use the cursors to get accurate readings.Figure 3.5.2: Simulated waveform (transient analysis) of the circuit above, with (A=1V,f m=500 Hz, f c=5kHz and m=0.5)Figure 3.5.3: Fourier spectrum of the waveform of Figure 3.5.2.3.6. Center Tap TransformerThere is no direct model in PSpice for a center tap transformer. However, one can usemutually coupled inductors to simulate a center tap transformer. Figure 3.6.1 shows the schematic of the circuit. We used one primary inductor L1 and two secondary inductors L1 and L2 put in series. In addition we added a K-Linear element.Figure 3.6.1: Circuit with Center Tap Transformer with a ratio of 10:1.After placing the element on the schematic give each element its value. Use for the input voltage a sinusoid with amplitude of 100 V and frequency 60 Hz. Notice that we added a small resistor R1 in series with the voltage source and the inductor. This was needed to prevent a short circuit in DC (Spice would give en error without this resistor). We have kept it small equal to 1 Ohm. Assume that we want to have a step-down transformer with a ratio of 10:1 to each secondary output. The ratios of the inductors L2/L1 and L3/L1 must then be equal to 1/102 (or =sqrt(L2/L1)=0.1). We made L1=1000 and L2-L3=10H.Double-click on the K-Linear element and type under the column headings for L1, L2, L3, the values LP, Ls1, Ls2. When done, click the APPLY button and close the propertieswindow.Go to PSpice/CREATE_NETLIST to generate the netlist. To see the list, go to the Project Manager and double-click on OUTPUTs: file. The netlist looks as follows: * source CENTERTAPTRANSFOR2Kn_K1 L_Lp L_Ls1 L_Ls2 1L_Lp 0 N00241 1000L_Ls1 0 VO1 10L_Ls2 VO2 0 10V_V1 N00203 0+SIN 0V 100V 60 0 0 0R_R1 N00203 N00241 1kR_R2 0 VO1 1kR_R3 VO2 0 1kCreate a new Simulation Profile (Transient) with " Time to run = 50ms". The result is shown in Figure 3.6.2. Notice that the max output is 10V as one would expect from a transformer ratio of 10:1 with an input voltage of 100Vmax.. The two outputs are 180 degrees out of phase.。
OrCAD Pspice快速入门
2.2.1、 Pspice Schematics的标准工具栏
按钮符号
菜单提示 Redraw Zoom In Zoom Out Zoom Area
功能说明 刷新当前视图 放大视图 缩小视图 显示选定区域
Zoom to Fit Page 显示视图符合页面大小
2.2.2、 Pspice Schematics的绘图工具栏
一、Pspice开发软件的组成
1.Design Manager 2.Schematic 3.Pspice A/D 4.Probe 5.Stimulus Editor 6.Parts 7.Optimizer 8.TextEdit
1、Design Manager(设计管理器)
设计实际电路并不是绘制一个简单的电路原理图,并且往往所绘制 的电路大都是多层结构,包含了多个子电路的设计。OrCAD Pspice软件 提供了设计管理器Design Manager来帮助用户更有效地浏览、管理、编 辑和保存设计文件。
2、Schematics (绘图编辑器)
Schematics是Pspice 的组件之一,同时也是Pspice 软件的主窗口, 绘制电路图就在该窗口中进行。 通 过 执 行 Schematics 可 以 调 用 Pspice 的 其 他 基 本 模 块 , 包 括 使 用 Pspice A/D电路仿真分析程序进行指定的电路分析;通过 Probe图形后 处理程序观察分析结果;通过Schematics Editor建立信号激励源;调用 Model Editor元件编辑程序和Optimizer优化设置程序。
Pspice Schematics的工具栏中提供了常用命令的快捷 按钮,可以利用 这些快捷按钮方便高效地绘制各种电路图。如果需要添加工具栏或者关 闭不用的工具栏,可以执行“View”菜单中的“Toolbars” 命令,程序会 弹出下图所示的对话框,单击工具栏列表中的复选框就可以设置显示或 者隐藏相应的工具栏。
Orcad PSpice
Orcad PSpiceOrCAD PSpice培训教材培训目标:熟悉PSpice的仿真功能,熟练掌握各种仿真参数的设置方法,综合观测并分析仿真结果,熟练输出分析结果,能够综合运用各种仿真对电路进行分析,学会修改模型参数。
一、 PSpice分析过程设置仿真参数绘制原理图运行仿真观测并分析仿真结果二、绘制原理图原理图的具体绘制方法已经在Capture中讲过了,下面主要讲一下在使用PSpice时绘制原理图应该注意的地方。
1、新建Project时应选择Analog or Mixed-signal Circuit2、调用的器件必须有PSpice模型首先,调用OrCAD软件本身提供的模型库,这些库文件存储的路径为Capture\Library\pspice,此路径中的所有器件都有提供PSpice模型,可以直接调用。
其次,若使用自己的器件,必须保证*.olb、*.lib两个文件同时存在,而且器件属性中必须包含PSpice Template属性。
3、原理图中至少必须有一条网络名称为0,即接地。
4、必须有激励源。
原理图中的端口符号并不具有电源特性,所有的激励源都存储在Source和SourceTM库中。
5、电源两端不允许短路,不允许仅由电源和电感组成回路,也不允许仅由电源和电容组成的割集。
解决方法:电容并联一个大电阻,电感串联一个小电阻。
6、最好不要使用负值电阻、电容和电感,因为他们容易引起不收敛。
三、仿真参数设置2PSpice能够仿真的类型在OrCAD PSpice中,可以分析的类型有以下8种,每一种分析类型的定义如下:直流分析:当电路中某一参数(称为自变量)在一定范围内变化时,对自变量的每一个取值,计算电路的直流偏置特性(称为输出变量)。
交流分析:作用是计算电路的交流小信号频率响应特性。
噪声分析:计算电路中各个器件对选定的输出点产生的噪声等效到选定的输入源(独立的电压或电流源)上。
即计算输入源上的等效输入噪声。
OrCADPSpice培训教材
OrCADPSpice培训教材培训教材培训目标:熟悉PSpice的仿真功能,闇练操纵各类仿真参数的设置方法,综合不雅测并分析仿真成果,闇练输出分析成果,能够或许综合应用各类仿真对电路进行分析,学会修改模型参数。
一、PSpice分析过程二、绘制道理图道理图的具体绘制方法差不多在Capture中讲过了,下面重要讲一下在应用PSpice时绘制道理图应当留意的处所。
1、新建Project时应选择Analog or Mixed-signal Circuit2、调用的器件必须有PSpice模型起首,调用OrCAD软件本身供给的模型库,这些库文件储备的路径为Capture\Library\pspice,此路径中的所有器件都有供给PSpice 模型,能够直截了当调用。
其次,若应用本身的器件,必须包管*.olb、*.lib两个文件同时存在,同时器件属性中必须包含PSpice Template属性。
3、道理图中至少必须有一条收集名称为0,即接地。
4、必须有鼓舞源。
道理图中的端口符号并不具有电源特点,所有的鼓舞源都储备在Source和SourceTM库中。
5、电源两端不许可短路,不许可仅由电源和电感构成回路,也不许可仅由电源和电容构成的割集。
解决方法:电容并联一个大年夜电阻,电感串联一个小电阻。
6、最好不要应用负值电阻、电容和电感,因为他们轻易引起不收敛。
三、仿真参数设置1、PSpice能够或许仿确实类型在OrCAD PSpice中,能够分析的类型有以下8种,每一种分析类型的定义如下:直流分析:当电路中某一参数(称为自变量)在必定范畴内变更时,对自变量的每一个取值,运算电路的直流偏置特点(称为输出变量)。
交换分析:感化是运算电路的交换小旌旗灯号频率响应特点。
噪声分析:运算电路中各个器件对选定的输出点产生的噪声等效到选定的输入源(自力的电压或电流源)上。
即运算输入源上的等效输入噪声。
瞬态分析:在给定输入鼓舞旌旗灯号感化下,运算电路输出端的瞬态响应。
2024版orcadPspice教程
为电路输入端设置合适的信号源,如正弦波、方波、脉冲等,并调整 信号的幅度、频率等参数。
2024/1/24
16
运行仿真并查看结果
运行仿真
在完成仿真类型和参数设置后,运行仿真程序,等待 仿真完成。
查看仿真结果
仿真完成后,可以通过软件界面查看仿真结果,如波 形图、数据表等。
结果分析
根据仿真结果,分析电路的性能指标,如电压、电流、 功率等是否满足设计要求。
11
创建新原理图文件
2024/1/24
打开Orcad Pspice软件,选择“File”菜单下 的“New”选项,然后选择“Schematic”创 建一个新的原理图文件。
在弹出的对话框中,为新原理图文件命名并选 择合适的保存位置。
选择合适的图纸大小和方向,以及所需的网格 大小和捕获网格选项。
12
元器件库使用及元器件放置
22
CHAPTER 06
高级功能探索与实战案例
2024/1/24
23
蒙特卡罗分析应用举例
2024/1/24
蒙特卡罗分析介绍
01
简要说明蒙特卡罗分析的基本原理和其在电路仿真中的应用。
蒙特卡罗分析设置步骤
02
详细阐述在orcadPspice中进行蒙特卡罗分析的参数设置、仿真
运行及结果查看等步骤。
蒙特卡罗分析实例演示
06
输出制造文件 将设计完成的PCB文件输出为制造文件,包括 Gerber文件和钻孔文件等,以供制造商生产。
20
导入网络表和布局布线
导入网络表
将原理图设计完成后生成的网络 表导入到PCB设计软件中,以便
进行元器件布局和布线。
2024/1/24
orcadpspice仿真教程.ppt
5V
0V 1.1Hz
1.0KHz
1.0MHz
V(OUT2)
Frequency
1.0GHz
三条波形对应于三个不同的温度下电路对V(out2)节点的增益
1.2mA
0.8mA
0.4mA
0A 0V
2.0V IC(Q1)
4.0V V_V2
三条波形对应于三个不同的温度下的Ic
6.0V
8.0V
设置和运行参数分析(Parametric Sweep) 在Simulation Setting的Analysis type对话框中选择Time Domain(Transient),在Options中选中Parametric Sweep:
400V
0V
-400V
0s
10ms
V(D1:1) V(OUT)
400V
20ms
30ms
Time
40ms
50ms
200V
0V
0Hz
50Hz
100Hz
V(D1:1) V(OUT)
150Hz Frequency
200Hz
250Hz 300Hz
400V
0V
-400V 0s
400V
10ms V(OUT)
200V
例如,选择执行Trace/Add Trace子命令,并在Trace/Add Trace设置框中指定显示的信号为:I(L1)@9,即显示第9批 分析中(对应R1=1.5),流过电感L1的电流。
1.5A
1.0A
0.5A
0A
0s
5s
I(L1)@9
10s Time
15s
20s
“上升时间”以及“过冲”性能分析: 选择执行Plot/X Axis Settings子命令,并在屏幕上显示的x 轴设置框的Processing Options子框内,选中“电路性能分 析(Performance Analysis)”,然后单击OK按钮,启动电路 性能分析过程。屏幕上出现电路性能分析显示窗口,x轴成 为参数扫描分析中的变量,即电阻R。 选择执行Trace/Add子命令,并在屏幕上显示的Trace/Add Trace设置框中,确定显示的特征值函数及自变量为: genrise(I(L1)),然后单击OK按钮,屏幕上显示出上升时间 与R的关系曲线。
2024版OrCAD PSpice9实用教程
A 深入学习教程内容
建议学员在掌握基础操作的前提下, 深入学习教程中涉及的电路设计和
仿真分析知识,提高实际应用能力。
B
C
D
交流与分享经验
建议学员在学习过程中积极参与交流和分 享经验,与其他学员共同进步和提高。
实践与创新相结合
在学习过程中,鼓励学员将所学知识与实 践相结合,尝试创新性的设计项目,提高 解决问题的能力。
背景
随着电子技术的不断发展,电路设计和仿真已成为电子工程师必备的技能之一。 OrCAD PSpice9作为一款优秀的电路设计和仿真软件,被广泛应用于电子、通 信、自动化等领域。
OrCAD PSpice9简介
1
OrCAD PSpice9是OrCAD公司推出的一款电路 设计和仿真软件,具有强大的电路原理图绘制、 电路仿真、波形分析等功能。
目管理器、属性栏等。
界面定制
02
讲解如何根据个人习惯定制界
03
分享一些提高操作效率的技巧,如快捷键使用、拖拽操作等。
基本电路元件库
01
02
03
元件库概述
介绍OrCAD PSpice9中提 供的各类电路元件库,如 电阻、电容、电感、二极 管等。
元件库使用
需要确保电路在瞬态响应分析 中已经达到稳定状态,否则会 影响傅里叶变换结果的准确性。 同时,需要选择合适的采样率 和采样点数以获得更准确的频 域信息。
04 数字电路仿真与 分析
数字元件库介绍
基本逻辑门
包括与门、或门、非门 等基本逻辑门电路元件。
组合逻辑元件
如加法器、减法器、比 较器等组合逻辑电路元
06 高级功能与应用
参数扫描分析
定义扫描参数 在电路图中选择要扫描的元件参数,并设置扫描范围和步 长。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
xiaoyllyPSPICE简明教程宾西法尼亚大学电气与系统工程系University of PennsylvaniaDepartment of Electrical and Systems Engineering编译:陈拓2009年8月4日原文作者:Jan Van der Spiegel, ©2006 jan_at_Updated March 19, 2006目录1. 介绍2. 带OrCAD Capture的Pspice用法2.1 第一步:在Capture 中创建电路2.2 第二步:指定分析和仿真类型偏置或直流分析(BIAS or DC analysis)直流扫描仿真(DC Sweep simulation)2.3 第三步:显示仿真结果2.4 其他分析类型:2.4.1瞬态分析(Transient Analysis)2.4.2 交流扫描分析(AC Sweep Analysis)3. 附加的使用Pspice电路的例子3.1变压器电路3.2 使用理想运算放大器的滤波器交流扫描(滤波器电路)3.3 使用实际运算放大器的滤波器交流扫描(滤波器电路)3.4 整流电路(峰值检波器)和参量扫描的使用3.4.1 峰值检波器仿真(Peak Detector simulation)3.4.2 参量扫描(Parametric Sweep)3.5 AM 调制信号3.6 中心抽头变压器4. 添加和创建库:模型和元件符号文件4.1 使用和添加厂商库4.2 从一个已经存在的Pspice模型文件创建Pspice符号4.3 创建你自己的Pspice模型文件和符号元件参考书目1. 介绍是一种强大的通用模拟混合模式电路仿真器,可以用于验证电路设计并且预知 SPICE电路的行为,这对于集成电路特别重要,1975年SPICE最初在加州大学伯克利分校被开发时也是基于这个原因,正如同它的名字所暗示的那样:S imulation P rogram for I ntegrated C ircuits E mphasis.PSpice 是一个PC版的SPICE(Personal-SPICE),可以从属于Cadence设计系统公司的OrCAD公司获得。
学生版(功能受限)随教科书奉送。
OrCAD的学生版称为PSpice AD Lite。
有关PSpice AD Lite的信息可以从OrCAD的网站获得:/pspicead.aspxPspice的学生版有下面的限制:电路最多有64个节点,10个晶体管和2个运算放大器。
SPICE可以进行各种类型的电路分析。
最重要的有:z非线性直流分析:计算直流传递曲线。
z非线性瞬态和傅里叶分析:在大信号时计算作为时间函数的电压和电流;傅里叶分析给出频谱。
z线性交流分析:计算作为频率函数的输出,并产生波特图。
z噪声分析z参量分析z蒙特卡洛分析另外,Pspice有标准元件的模拟和数字电路库(例如:NAND,NOR,触发器,多选器,FPGA,PLDs和许多数字元件)。
这使得它成为一种广泛用于模拟和数字应用的有用工具。
所有分析都可以在不同温度下进行。
默认的温度是300K。
电路可以包含下面的元件:z Independent and dependent voltage and current sources独立和非独立的电压、电流源z Resistors电阻z Capacitors电容z Inductors电感z Mutual inductors互感器z Transmission lines传输线z Operational amplifiers运算放大器z Switches开关z Diodes二极管z Bipolar transistors双极型晶体管z MOS transistors金属氧化物场效应晶体管z JFET结型场效应晶体管z MESFET金属半导体场效应晶体管z Digital gates数字门z其他元件(见用户手册)。
2. 带OrCAD Capture 的PSpice(9.2 学生发行版)在开始仿真电路之前,你需要指定电路配置,这可以用多种方法进行。
方法之一是按照元件、连接、元件的模型和分析的以文本文件输入电路描述。
该文件被称为SPICE输入文件或源文件(可参考:/%7Ejan/spice/spice.overview.html )。
另一种方法是使用原理图输入程序,例如OrCAD CAPTURE 。
OrCAD Capture 与PSpice Lite AD 在随教科书提供的同一张光盘上。
OrCAD Capture CIS 版集成了具有器件信息系统(Component Information System ,简称CIS)的OrCAD Capture 原理图设计应用功能。
该软件的设计着重考虑了降低花在查询现有重复采用的器件上面的时间,以及减少手工登记元器件的信息内容和元器件数据库的维护。
对元器件的查询是基于它们所拥有的电性能参数,通过采用OrCAD Capture CIS 软件可以自动地检索相关联的器件情况。
Capture 是一个用法友好的程序,它允许你获取电路的原理图并且指定仿真的类型。
Capture 不但可以产生输入文件而且可以用于PCB 布局设计程序。
下面的图概要说明了有关用Capture 和PSpice 仿真一个电路的不同步骤。
我们将通过几个例子简要地描述这些步骤的每一步。
图1:用Pspice 仿真电路的步骤元件的值可以用下面的度量因子指定(大小写均可):T or Tera (= 1E12) U or Micro (= E-6)G or Giga (= E9) N or Nano (= E-9)MEG or Mega (= E6) P or Pico (= E-12)K or Kilo (= E3) F of Femto (= E-15)M or Milli (= E-3)在Pspice 和Hspice 中都允许大写和小写字母。
例如,可以下面的方法指定一个225pF 的电容:225P ,225p ,225pF ;225pFarad ;225E-12;0.225N 。
注意:兆被写为MEG ,例如一个15兆欧姆的电阻可以被指定为15MEG ,15MEGohm , 15meg 或15E6。
小心M 与Mega !如果你写15Mohm 或15M ,Spice 将会把它们读为15 milliOhm !作为例子,我们将对下面的电路进行不同类型的仿真。
第一步:用Capture 创建电路z 创建一个新的模拟,混合AD 项目z 放置电路元件z 连接元件z 指定值和名字第二步:指定仿真类型 z 创建一个仿真模板 z 选择分析类型: 偏置,DC 扫描,晶体管,AC 扫描 z 运行PSpice 第三步:观察结果z 添加曲线到探测窗口z 用光标分析波形描z 运行 Pspicez 保存或打印结果图2:要被仿真的电路(OrCAD Capture的屏幕快照)2.1第一步:在Capture 中创建电路2.1.1 创建新项目1.打开OrCAD Capture CIS Lite Edition。
2.创建一个新项目:File > New > Project。
3.输入项目的名字,例如Bias and DC Sweep。
项目文件的扩展名为.opj,双击项目文件可以打开项目。
4.选择Analog or Mixed-AD模拟或混合-AD。
5.在Location框中输入项目路径。
点击OK。
6.在Create PSpice Project对话框打开时,选择“Create Blank Project”。
一个新的页将在Project Design Manager中打开,如下所示。
图3:OrCAD Capture界面2.1.2. 放置元件并连接它们1. 在Capture中点击原理图窗口。
2. 用Place > Part命令放置元件或点击Place Part图标,打开如图4的对话框。
图4:放置元件窗口Place Part3.选择包含所需元件的库。
在Part 文本框中输入元件名字的开始部分,如图中的R,元件列表将卷动到其名字包含输入字母的元件处。
第一次使用Capture时如果没有库可用,你必须点击Add Library添加库按钮,打开Add Library窗口将,选择需要的库。
Spice库在路径Capture\Library\Pspice下。
常用的Library有下面几个:Analog:包含无源元件(R、L、C),互感器,传输线,以及电压和电流非独立的源(电压控制的调用源E、电流控制的电流源F、电压控制的电流源G和电流控制的电压源H)。
Source:给出不同类型的独立电压和电流源,例如:Vdc(直流电压),Idc(直流电流),Vac(交流电压),Iac(交流电流),Vsin(正弦电压),Vexp(指数电压),脉冲,分段线性,等。
先浏览一下库,看那些元件可用。
Eval:提供二极管(D…),双极型晶体管(Q…),MOS晶体管,结型场效应晶体管(J…),真实运算放大器;如u741,开关(SW_tClose, SW_tOpen),各种数字门和元件。
Abm:包含一个可以应用于信号的数学运算符选择,例如:乘法(MULT),求和(SUM),平方根(SWRT),拉普拉斯(LAPLACE),反正切(ARCTAN),等。
Special:包含多种其他元件,像参数、节点组,等。
4.从库中选择电阻、电容和直流电压以及电流源。
你可以用鼠标左键放置元件,用鼠标右键点击旋转元件。
如果要放置相同元件的另一个实例,可以再次点击鼠标左键。
对某个元件完成特定的操作后按ESC键, 或右击并选择End Mode。
可以给电容器添加初始化条件;双击该元件将打开看起来像电子表格的Property属性窗口,在IC 列的下面输入初始化条件的值,例如,2V。
对于我们的例子我们假定IC是0V(这是默认值)。
移动元件时Snap to grid工具控制元件是否吸附到网格上。
5.在放置好所有的元件后,你需要点击GND图标放置Ground地端子(在右边的工具栏中,见图3)。
当放置地窗口打开时,选择GND/CAPSYM 并且给它命名为0。
不要忘记改变其名字为0,否则PSpice 将给出一个错误或“Floating Node”。
原因是SPICE 需要一个地端子作为参考节点,其名字或节点号必须是0。
图5:放置低端子对话框;地端子的名字应该是06.现在用从菜单用Place > Wire命令或点击Place Wire图标连接元件。
7.你可以用PLACE > NET ALIAS菜单命令为网络或节点指定别名。
我们将输出和输入节点命名为Out 和In,见图2。