PSpice - Model Editor 系列介绍( I )
OrCAD PSPICE仿真软件介绍

图 6.1 Capture 集成环境界面 1. 项目管理窗口(Project Manager)
项目管理窗口相当于资源管理器,每个项目对应一个项目管理窗口,它用于管理项目所涉 及的电路图、仿真设置、输出结果等文件。在项目管理窗口中有文件(File)和层次(Hierarchy)两
运行 Cadence OrCAD 16.2 版本软件,对计算机系统具有下列要求。 (1) 对计算机硬件的要求:CPU 为与 Intel IA-32 兼容的处理器,例如:Intel Pentium 4 and AMD Opteron(皓龙)微处理器,主频不低于 1.2 GHz。内存至少 1GB,推荐 2GB。可用硬盘 空间至少 10GB,推荐 50GB。显示器分辨率至少 1024×768,推荐 1280×1024。 (2) 对操作系统的要求:支持 Windows 2003 Server(32bit)、Windows XP Professional、 Windows XP Home、Windows Vista Enterprise(32bit)或 Windows Vista Home Premium。使用 Windows Vista 必须关闭控制台中“使用者账户内的 UAC(使用者账户控制)项”。不支持 Windows NT 4.0 及以前版本、Windows 2000 与 Windows Vista Home Basic。在 Windows server 不能以 Windows Remote Desktop(terminal services)的方式运行。 Cadence OrCAD 16.2 软件将 Demo 版与正式版整合在了一起,在使用时若无法连接到 license,则可选择进入 Demo 模式下操作。 随着 PSpice 版本不断升级,其功能和性能日趋完善,在收敛性和性能有了较大的改进与提 高,加快了分析电路的速度,扩大了被分析电路的规模,元器件库更加丰富。PSpice 软件不仅 具有很强的电路分析能力和图形显示处理能力,而且还可对模拟电路、数字电路和模数混合电
Pspice简介

电子电路CAD 电子电路CAD
1Hale Waihona Puke 1 PSpice软件的发展过程• 1972 年 , 由 美 国 加 州 大 学 伯 克 莱 分 校 研 制 出 SPICE
(Simulation Program with Integrated Circuit Emphasis)。
• 1975年,推出正式实用化版本SPICE 2G。 • 1988年,被定为美国国家标准。 被定为美国国家标准。 • 1984 年 , MicroSim 公 司 推 出 了 基 于 SPICE 的 微 机 版 本 PSpice(Personal- SPICE)。 • 此后各种版本的PSpice不断问世, 不断问世,功能也越来越强。 功能也越来越强。
电子电路CAD 电子电路CAD
第一章 Pspice程序 Pspice程序
PSpice是国际上著名的通用电路分析程序 PSpice是国际上著名的通用电路分析程序, 是国际上著名的通用电路分析程序, 是一个多功能的电路模拟实验平台, 是一个多功能的电路模拟实验平台 , 从 70年代 70 年代 问世以来, 问世以来 , 经过了近30 经过了近 30多年的不断改进 30 多年的不断改进、 多年的不断改进 、 完善, 完善 , 已成为国际上公认的一种工业标准工具。 已成为国际上公认的一种工业标准工具。
电子电路CAD 电子电路CAD
3.电子设计自动化EDA(Electronic Design
Automation)
就是以计算机硬件和系统软件为基本工 作平台, 作平台,继承和借鉴前人在电路、 继承和借鉴前人在电路、图论与 拓扑逻辑和优化理论等多学科的最新科技 成果, 成果,在开发电子电路与系统时, 在开发电子电路与系统时,利用计 算机进行设计、 算机进行设计、分析、 分析、仿真、 仿真、制造等工作。 制造等工作。
LTspice一简介

LTspice一简介免费电路图仿真软件LTspice 一简介(中文教程)欢迎转载,转载请说明出处-DPJ关键字:PSpice仿真,电路图,LTspice仿真,pspice模型,spice,电路仿真,功放电路图仿真,信号放大仿真1.LTspice电路仿真软件简介LTspice电路图仿真软件简介(支持PSpice和Spice库的导入)LTspiceIV是一款高性能SpiceIII仿真器、电路图捕获和波形观测器,并为简化开关稳压器的仿真提供了改进和模型。
我们对Spice所做的改进使得开关稳压器的仿真速度极快,较之标准的Spice仿真器有了大幅度的提高,从而令用户只需区区几分钟便可完成大多数开关稳压器的波形观测。
这里可下载的内容包括用于80%的凌力尔特开关稳压器的Spice和MacroModel,200多种运算放大器模型以及电阻器、晶体管和MOSFET模型。
在电路图仿真过程中,其自带的模型往往不能满足需求,而大的芯片供应商都会提供免费的SPICE模型或者PSpice 模型供下载,LTspice可以把这些模型导入LTSPICE中进行仿真。
甚至一些厂商已经开始提供LTspice模型,直接支持LTspice的仿真。
这是其免费SPICE电路仿真软件LTspice/SwitcherCADIII所做的一次重大更新。
这也是LTspice 电路图仿真软件在欧洲,美国和澳大利亚,中国广为流传的根本原因。
LTspiceIV具有专为提升现有多内核处理器的利用率而设计的多线程求解器。
另外,该软件还内置了新型SPARSE矩阵求解器,这种求解器采用汇编语言,旨在接近现用FPU(浮点处理单元)的理论浮点计算限值。
当采用四核处理器时,LTspiceIV可将大中型电路的仿真速度提高3倍,同等设置的精度,电路仿真时间远远小于PSpice的计算时间(本来你要等待3个小时,现在一个小时就结束了)。
功能强大而且免费使用仿真工具,何乐而不为呢这里不是贬低pspice软件,cadence的Pspice软件具有更加丰富的配置和应用,可以进行更加繁多的电路仿真和设置,因为大多数工程师不需要非常复杂的应用,所以,免费的LTspice可以满足基本的应用。
PSPICE课件第1讲

Probe -图形后处理程序
Probe程序是PSpice软件包中的图形后处 理程序 它可以在屏幕上绘出仿真结果的曲线、 波形。
图3:对图2所示电路进行直流扫描分析 (V1=0V-10V, 步长 =0.1V)后,用Probe 绘出的电压V(R2) vs V1曲线。
Stimulus Editor -信号源编辑程序
课程内容
课堂学习 18个学时 (9周) 上机实验 18个学时 (5周)
5个上机实验
课程考核
随堂小考
实验报告
30%
70%
什么是PSpice?
首先什么是Spice?
全称: Simulation Program with Integrated Circuit Emphasis (侧重于集 成电路的模拟程序) 主要用于大规模集成电路的计算机辅助 设计。 历史
电路仿真软件
由于计算机速度快,精度高,所以用计 算机辅助电路分析,更快,更正确,更 经济, 而且可以完成数学方法和物理方法 不能或不易完成的分析工作。 PSpice就像一个模拟“实验台”,几乎 可以完全取代电路电子实验中的元件、 面包板、示波器、万用表、信号发生器 等。在它上面可以做各种电路实验和测 试。
PSpice
1998年OrCAD公司与Microsim公司合并 ,PSpice成为OrCAD PSpice。 OrCAD被Cadence购买后,PSpice成为 Cadence公司的EDA软件产品之一。
PSpice
本课程所用软件版本: Cadence OrCAD PSpice 9.2
Cadence OrCAD PSpice 9.1 student version可以免费下载。
PSpice仿真软件使用指南说明书

April 2016© 2013Cadence Design Systems, Inc. All rights reserved.Portions © Apache Software Foundation, Sun Microsystems, Free Software Foundation, Inc., Regents of the University of California, Massachusetts Institute of T echnology, University of Florida. Used by permission. Printed in the United States of America.Cadence Design Systems, Inc. (Cadence), 2655 Seely Ave., San Jose, CA 95134, USA.Product PSpice contains technology licensed from, and copyrighted by: Apache Software Foundation, 1901 Munsey Drive Forest Hill, MD 21050, USA © 2000-2005,Apache Software Foundation. Sun Microsystems, 4150 Network Circle, Santa Clara, CA 95054 USA © 1994-2007, Sun Microsystems, Inc. Free Software Foundation, 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA © 1989, 1991, Free Software Foundation, Inc. Regents of the University of California, Sun Microsystems, Inc., Scriptics Corporation, © 2001, Regents of the University of California. Daniel Stenberg, © 1996 - 2006, Daniel Stenberg. UMFPACK ©2005,TimothyA.Davis,UniversityofFlorida,(**************.edu).KenMartin,WillSchroeder,Bill Lorensen © 1993-2002, Ken Martin, Will Schroeder, Bill Lorensen. Massachusetts Institute of Technology, 77 Massachusetts Avenue, Cambridge, Massachusetts, USA © 2003, the Board of Trustees of Massachusetts Institute of Technology. All rights reserved.Trademarks: Trademarks and service marks of Cadence Design Systems, Inc. contained in this document are attributed to Cadence with the appropriate symbol. For queries regarding Cadence’s trademarks, contact the corporate legal department at the address shown above or call 800.862.4522.Open SystemC, Open SystemC Initiative, OSCI, SystemC, and SystemC Initiative are trademarks or registered trademarks of Open SystemC Initiative, Inc. in the United States and other countries and are used with permission.All other trademarks are the property of their respective holders.Restricted Permission: This publication is protected by copyright law and international treaties and contains trade secrets and proprietary information owned by Cadence. Unauthorized reproduction or distribution of this publication, or any portion of it, may result in civil and criminal penalties. Except as specified in this permission statement, this publication may not be copied, reproduced, modified, published, uploaded, posted, transmitted, or distributed in any way, without prior written permission from Cadence. Unless otherwise agreed to by Cadence in writing, this statement grants Cadence customers permission to print one (1) hard copy of this publication subject to the following conditions:1.The publication may be used only in accordance with a written agreement between Cadence and itscustomer.2.The publication may not be modified in any way.3.Any authorized copy of the publication or portion thereof must include all original copyright,trademark, and other proprietary notices and this permission statement.4.The information contained in this document cannot be used in the development of like products orsoftware, whether for internal or external use, and shall not be used for the benefit of any other party, whether or not for consideration.Disclaimer: Information in this publication is subject to change without notice and does not represent a commitment on the part of Cadence. Except as may be explicitly set forth in such agreement, Cadence does not make, and expressly disclaims, any representations or warranties as to the completeness, accuracy or usefulness of the information contained in this document. Cadence does not warrant that use of such information will not infringe any third party rights, nor does Cadence assume any liability for damages or costs of any kind that may result from use of such information.Restricted Rights: Use, duplication, or disclosure by the Government is subject to restrictions as set forth in FAR52.227-14 and DFAR252.227-7013 et seq. or its successor.ContentsBefore you begin. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 Welcome . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 21 How to use this guide . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 Symbols and conventions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22 Related documentation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 23 What this user’s guide covers . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 PSpice overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26 Add-on options . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 PSpice Smoke Option . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 PSpice Advanced Optimizer Option . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 PSpice Advanced Analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 27 SLPS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 If you don’t have the standard PSpice A/D package . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 Comparison of the different versions of PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28 If you have PSpice Lite . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 31 Minimum hardware requirements for running PSpice: . . . . . . . . . . . . . . . . . . . . . . . . 32 PSpice Samples and T utorials . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 32 Part one: Simulation primer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 33 1Things you need to know . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 35 What is PSpice? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 36 Analyses you can run with PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 Basic analyses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40 Advanced multi-run analyses . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 43 Analyzing waveforms with PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 What is waveform analysis? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 45 Using PSpice with other programs . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47 Using design entry tools to prepare for simulation . . . . . . . . . . . . . . . . . . . . . . . . . . 47What is the PSpice Stimulus Editor? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48 What is the PSpice Model Editor? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 Files needed for simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 49 Files that design entry tool generates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 50 Other files that you can configure for simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 53 Files that PSpice generates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 55 Directory structure for analog projects in Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 58 How are files configured at the design level maintained in the directory structure for analog projects? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 59 How are files configured at the profile level maintained in the new directory structure for analog projects? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 61 What happens when I convert an analog project that uses a design from another project or from another location? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 What should I do if the schematic for a converted analog project uses FILESTIM n parts from the SOURCE library? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 63 Design Entry HDL libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 64 Reference Libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 66 Local libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 68 PSpice model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 The cds.lib file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 69 Encrypting PSpice Models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 71 Using PSpiceEnc . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 72 Using Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 722Simulation examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75 Example circuit creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 Using Capture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76 Using Design Entry HDL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85 Using Design T emplates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 93 Finding out more about setting up your design . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 Running PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 95 Performing a bias point analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96 Using the simulation output file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98 Finding out more about bias point calculations . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99DC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Setting up and running a DC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99 Displaying DC analysis results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101 Finding out more about DC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107 T ransient analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108 Finding out more about transient analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 115 AC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116 Setting up and running an AC sweep analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 116 AC sweep analysis results . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 120 Finding out more about AC sweep and noise analysis . . . . . . . . . . . . . . . . . . . . . . . 122 Parametric analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 123 Setting up and running the parametric analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . 126 Analyzing waveform families . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 130 Finding out more about parametric analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 133 Performance analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 134 Finding out more about performance analysis . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 136Part two: Design entry . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1383Preparing a design for simulation. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 139 Checklist for simulation setup . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 T ypical simulation setup steps . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 140 Advanced design entry and simulation setup steps . . . . . . . . . . . . . . . . . . . . . . . . . 141 When netlisting fails or the simulation does not start . . . . . . . . . . . . . . . . . . . . . . . . 142 Using parts that you can simulate . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 143 Vendor-supplied parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 144 Passive parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 152 Breakout parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 153 Behavioral parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 154 Simulating asymmetric parts in PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 155 Simulating homogenous parts in PSpice . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 156 Specifying values for part properties . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 157 Using global parameters and expressions for values . . . . . . . . . . . . . . . . . . . . . . . . . . 158Global parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 158 Expressions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 162 Defining power supplies . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 For the analog portion of your circuit . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 For A/D interfaces in mixed-signal circuits . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 170 Defining stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172 Analog stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 172 Digital stimuli . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 176 Things to watch for . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178 Unmodeled parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 178 Unconfigured model, stimulus, or include files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 182 Unmodeled pins . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184 Missing ground . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 184 Missing DC path to ground . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 1854Creating and editing models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 187 What are models? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 189 How are models organized? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 190 Model library configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 191 Global vs. design vs. profile models and libraries . . . . . . . . . . . . . . . . . . . . . . . . . . 191 Nested model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 192 PSpice-provided models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193 Model library data . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 193 Device characteristic curves-based models vs. Template-based models . . . . . . . . 195 T ools to create and edit models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 197 Ways to create and edit models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 198 Using the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 200 Ways to use the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 201 Running the Model Editor alone . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 202 Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203 Creating models using the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 203 Creating models based on device characteristic curves . . . . . . . . . . . . . . . . . . . . . 203Creating models based on PSpice templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 209 Importing an existing model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 212 Enabling and disabling automatic part creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . 213 Running the Model Editor from the schematic editor . . . . . . . . . . . . . . . . . . . . . . . . 215 Model creation examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 218 Example: Creating a PSpice model based on device characteristic curves . . . . . . . 219 Example: Creating template-based PSpice model . . . . . . . . . . . . . . . . . . . . . . . . . . 228 Editing model text . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 234 Example: editing a Q2N2222 instance model . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 236 Using the Create Subcircuit Format Netlist command (Capture only) . . . . . . . . . . . . . . 237 Changing the model reference to an existing model definition . . . . . . . . . . . . . . . . . . . 239 Reusing instance models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 240 Reusing instance models in the same schematic . . . . . . . . . . . . . . . . . . . . . . . . . . 241 Making instance models available to all designs . . . . . . . . . . . . . . . . . . . . . . . . . . . 241 Configuring model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 243 The Configuration Files tab . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 244 How PSpice uses model libraries . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 245 Adding model libraries to the configuration . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 248 Changing the model library scope from profile to design, profile to global, design to global and vice versa . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 249 Changing model library search order . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 250 Changing the library search path . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 252 Handling smoke information using the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . 254 Adding smoke information to PSpice models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 254 Creating template-based PSpice models with smoke information . . . . . . . . . . . . . . 256 Using the Model Editor to edit smoke information . . . . . . . . . . . . . . . . . . . . . . . . . . 256 Examples: Smoke . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 257 Adding smoke information to the D1 diode model . . . . . . . . . . . . . . . . . . . . . . . . . . 257 Adding smoke information to the OPA_LOCAL operational amplifier model . . . . . . 259 Smoke parameters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 260 Diode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 261 Bipolar Junction Transistors . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 262 Magnetic Core . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264 Ins Gate Bipolar T ransistor (IGBT) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 264 Junction FET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 266 Operational Amplifier . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 268MOSFET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 270 Voltage Regulator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 271 Darlington T ransistor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2735Creating parts for models. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 275 What’s different about parts used for simulation? . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 276 Ways to create parts for models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 277 Preparing your models for part creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 279 Starting the Model Editor . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 280 Using the Model Editor to create parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 Batch mode of part creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 Interactive mode of part creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 281 Creating Design Entry T ool parts for all models in a library . . . . . . . . . . . . . . . . . . . . . . 282 Using batch mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 282 Using interactive mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 284 Setting up automatic part creation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 289 Example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 Creating parts in the batch mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 290 Creating parts using interactive mode . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 296 Basing new parts on a custom set of parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 300 Editing part graphics (Capture only) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303 How Capture places parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 303 Defining grid spacing . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 304 Attaching models to parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306 MODEL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 306 Defining part properties needed for simulation . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 308 PSPICETEMPLATE . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 310 IO_LEVEL . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 319 MNTYMXDL Y . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 320 PSPICEDEFAULTNET . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3216Analog behavioral modeling. . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323 Chapter overview . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 323 Overview of analog behavioral modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 324 The ABM part library file . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 325 Placing and specifying ABM parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 326 Net names and device names in ABM expressions . . . . . . . . . . . . . . . . . . . . . . . . . 326 Forcing the use of a global definition . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 327 ABM part templates . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 328 Control system parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 329 Basic components . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 332 Limiters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 333 Chebyshev filters . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 334 Integrator and differentiator . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 338 T able look-up parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 339 Laplace transform part . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 344 Math functions . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 348 ABM expression parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 349 An instantaneous device example: modeling a triode . . . . . . . . . . . . . . . . . . . . . . . 353 PSpice-equivalent parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 356 Implementation of PSpice-equivalent parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 357 Modeling mathematical or instantaneous relationships . . . . . . . . . . . . . . . . . . . . . . 358 Lookup tables (ET ABLE and GT ABLE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 362 Frequency-domain device models . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 364 Laplace transforms (LAPLACE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 364 Frequency response tables (EFREQ and GFREQ) . . . . . . . . . . . . . . . . . . . . . . . . . 366 Cautions and recommendations for simulation and analysis . . . . . . . . . . . . . . . . . . . . . 369 Instantaneous device modeling . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 369 Frequency-domain parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370 Laplace transforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 370 T rading off computer resources for accuracy . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 374 Basic controlled sources . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375 Creating custom ABM parts . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 375。
PSpice模型创建与应用实例

PSpice模型创建与应用实例主要内容:一、概述二、导入模型文件三、创建模型符号四、应用模型进行仿真时间拟制人修订版本备注2012/3/19 Ma.chong Wang.peng V16.5一、概述PSpice为用户提供了模型转换与编辑工具:Model Editor,用户自己下载的模型参数文件可以通过Model Editor转换成PSpice的模型文件,并且可以建立相应的模型符号。
本文以intersil公司的ISL28114元件模型为例介绍如何将下载的Spice模型文件导入到PSpice模型库中,并对模型进行模拟仿真。
一个完整的模型创建与应用实例包括以下几步:1、导入模型文件2、建立模型符号3、应用模型进行仿真二、模型文件的导入选择“程序\Cadence\Release 16.5\PSpice Accessories\Model Editor”如图1:图1选择PSpice A/D,如图2:图2点击“OK”,弹出原理图工具选择对话框,选择“Capture”,即采用Capture绘制原理图,如图3:图3这样即启动了PSpice Model Editor窗口。
选择“File->Open”打开下载的Spice模型参数文件(ISL28114.mod),如图4:图4选择“File->Save As”,将.mod文件改为.lib文件,如图5:图5点击“保存”。
在Model Editor窗口中,选择“File->Export to Capture part library”,如图6:图6点击“OK”,弹出日志文件,里面列出警告或错误信息,如图7:图7点击“OK”。
二、创建模型符号在Model Editor窗口中,选择“File->Model Import Wizard[Capture]”,如图8:图8点击“下一步”,如图9:图9 选择“Replace Symbol”,建立国标符号,如图10:图10 点击“下一步”,设置引脚信息,如图11:图11 点击“Save Symbol”,如图12:图12 点击“OK”。
PSpice
• 那么对于我们学习而言,PSPICE是一个强大的互动工具,我们 可以用它来分析我们的电路,与计算结果对照,以更为深刻地理 解电路的工作原理及相关知识。特别是在做实验之前,如果能够 对实验电路做一仿真分析,对于消化知识点、掌握电路的实质有 重要的指导作用。
电路仿真的精度主要由元器件所选用的模型和模型参数来决定。 PSPICE中选用了较精确的模型,其模型参数也很多,在多数情况 下,可以忽略其中许多参数。PSPICE在分析时使用这些参数的缺 省值(default value 计算机自动给出的值,也称为默认值)。
1.2 PSpice中的电路描述
3. 信号源及电源 在电路描述中,信号源和电源是必不可少的。实际上电源可以 看作是一种特殊的信号源。在PSPICE中,信号源被分为两类:独 立源和受控源。表1给出了几种主要独立源。在类型名前加V表示 电压源,加I表示电流源。受控源共分为四类如表2所示,它们可 用来描述等效电路。
运行于Windows环境下的PSPICE,均采用图形方式描述需要 仿真的电路。即在PSPICE提供的绘图编辑器中,画出电路图。这 如同我们使用的画笔功能,不同的是电路中用到的元器件、电源 和信号源可从PSPICE提供的符号库中直接调用,然后将其存为扩 展名为sch的图形文件(计算机自动生成扩展名),以供仿真使用。
PSpice 应用基础
主讲人:乌旭 xuwu@
大连海事大学信息科学技术学院 电子信息科学与技术教研室
1.1 PSPICE程序简介 1.2 PSPICE中的电路描述 1.3 一个具体仿真实例
1.1 PSPICE程序简介
1.1.1 什么是PSPICE
PSpice入门
V1初始值 TR上升时间 PW脉宽
V2峰值 TD延迟时间 TF下降时间 PER周期
方波
• t1>t2
t2>t3
4.电路分析设置
• PSpice有多种分析功能,电路分析需要在菜单Analysis的Setup选 项中进行参数设置,选中的分析选项打对号(Enabled)。 • 分析项的参数设置不正确,分析不能正常进行,PSpice程序将给出 错误(error)信息。 • 错误信息可从输出文件(*.out)读取。 • 分析设置完成,运行Simulate命令,程序对电路进行分析。
2.元件描述和参数设置
• 元件描述由三部分构成:符号名称、线性参数值和模型参 数。元件参数和电路标号在元件属性中(Attributes)描述, 非线性元件参数由元件模型语句(Model)来描述,元件 属性中只给出它的模型名称。 • ①元件关键字不能改写。线性元件R L C,非线性元件Q D J 等。元件名称可以由8个英文字母或数字构成,第一个字 母是关键字,由PSpice程序定义,字母大小写没有区别。 例如Rb1、Ce、Q1、D2、Vin。 • UA741 VSIN VPULSE GND-EARTH OFFPAGE
• ②元件参数采用实际工程单位制,电压用V、电流用A、时间 用S、电阻用Ω、频率用Hz等,元件参数的单位通常可以忽略。 V A S F H不用写, 数值要写成 10-6=u 10-3=m 103=k 106=meg,或者用字母E代表10,103 =1E+3、10-3=1E-3, PSpice不区分大小写。 • 元件属性的VALUE项可以定义元件参数值,元件属性的IC项 设置电容的初始电压、电感的初始电流。
PSpice 快速入门
前
言
• PSpice是SPICE应用在PC机上的程序,SPICE程序(Simulation Program with Integrated Circuit Emphasis)是美国加州大学 (U.C Berkeley)柏克莱分校1972年开发的,是一种通用电路分 析程序。能够分析和模拟一般条件下的各种电路特性。在众多的 CAD工具软件中,SPICE程序是精度最高10-6,最受欢迎的软件 工具,许多EDA系统软件的电路模拟部分是应用SPICE程序来完 成的。1988年SPICE被定为美国国家工业标准。 • PSPICE分为商业版和学生版(PSpice Student),学生版本可 以免费下载。限制64个节点。 • PSpice A/D能够进行模拟电路分析、数字电路分析和数模混合电 路分析。PSpiceA/D由六大功能模块组成:电路图绘制程序 Schematic Editor;电路仿真程序PSpice Simulator;元器件建模 程序Model Editor;信号源编辑器Stimulus Editor;输出波形后 处理程序Probe;电路设计优化程序PSpice Optimizer。
2 pspice介绍
PSPICE 简介1.1 PSPICE的发展与现状根据实际电路(或系统)建立模型,通过对模型的计算机分析、研究和试验以达到研制和开发实际电路(或系统)的目的,这一过程,称为计算机仿真(Simulation)的高效、高精度、高经济性和高可靠性,因此倍受业界喜爱。
在设计或分析各类开关电源时,计算机仿真起了重要的作用。
数字仿真手段可用以检验设计的系统是否满足性能要求。
应用数字仿真可以减少电路实验的工作,与电路实验相比,计算机仿真所需时间要少得多,并可以更全面、更完整地进行,以期改进设计质量。
用于模拟电路仿真的SPICE(Simulation Program with Integrated Circuit Emphasis)软件于1972年由美国加州大学伯克利分校的计算机辅助设计小组利用FORTRAN语言开发而成,主要用于大规模集成电路的计算机辅助设计。
SPICE的正式实用版SPICE 2G在1975年正式推出,但是该程序的运行环境至少为小型机。
1985年,加州大学伯克利分校用C语言对SPICE软件进行了改写,1988年SPICE被定为美国国家工业标准。
与此同时,各种以SPICE 为核心的商用模拟电路仿真软件,在SPICE的基础上做了大量实用化工作,从而使SPICE 成为最为流行的电子电路仿真软件。
PSPICE则是由美国Microsim公司在SPICE 2G版本的基础上升级并用于PC机上的SPICE 版本, PSPICE采用自由格式语言的5.0版本自80年代以来在我国得到广泛应用,并且从6.0版本开始引入图形界面。
PSpice软件具有强大的电路图绘制功能、电路模拟仿真功能、图形后处理功能和元器件符号制作功能,以图形方式输入,自动进行电路检查,生成网表,模拟和计算电路。
它的用途非常广泛,不仅可以用于电路分析和优化设计,还可用于电子线路、电路和信号与系统等课程的计算机辅助教学。
与印制版设计软件配合使用,还可实现电子设计自动化。
01-8.0 PSpice应用介绍
PSpice操作简介-以PSPice16.5为例
仿真分析的一般操作步骤: •编辑电路原理图 •设置分析类型 •查看仿真结果
编辑电路原理图操作步骤
一般操作步骤: •启动软件 •创建一个新项目 •选取和放置电路元件 •连接电路元件 •设置元件属性参数 •设置参考节点
Design)
•EDA:电子设计自动化(Electronic Design Automation)
常用的电路分析软件介绍
•PSpice:是1975年由美国加州大学伯克利分校开发 的通用模拟电路仿真器,现归属于Cadence公司。
•Multisim:最早ows的仿真工具,现归属于NI公司。
编辑电路原理图操作步骤
操作演示
PSpice操作小结
仿真分析的一般操作步骤: •编辑电路原理图 **必须设置参考节点 •设置分析类型 •查看仿真结果
Pspice简介
本节 内容 结束 , 谢谢!
PSpice应用介绍
主讲教师 杨旭强
PSpice应用介绍
•PSpice基本操作简介 • PSpice的直流分析 • PSpice的交流分析
CAA、CAD及EDA的概念
•CAA:计算机辅助分析(Computer Aided Analysis) •CAD:计算机辅助设计(Computer Aided