In order to simulate a circuit design using Altium Designer's Mixed-Signal Circuit Simulator, all components in the circuit need to be simulation-ready – that is, they each need to have a linked simulation model.
The type of model and how it is obtained will largely depend on the component and, to some extent, on the personal preference of the designer. Many device manufacturers supply simulation models corresponding to the devices they manufacture. Typically, it's as simple as downloading the required model file and hooking it up to the schematic component. Learn more about Adding Simulation Models to the Design.
Some models may need to be written from scratch – for example, using the hierarchical sub-circuit syntax to create the required sub-circuit model file (*.ckt).
Creating a New Simulation Model
Some models are provided by manufacturers and suppliers as downloadable text files. Sometimes the model detail is presented as text on a browser page instead of a download file; in this situation, you can create a new model file in Altium Designer and copy/paste the content from the browser page into your new model file. Use the relevant command in the File » New » Mixed Simulation sub-menu, as shown below.
Commands to create a new, empty model file.
To determine the correct type of model (*.MDL
, *.CKT
, etc), review the text content of the model.
You can then Copy / Paste the model file information into the model editor.
Example text content of a simulation model.
-
Use of currents through inductances is supported in a functional source value expression.
-
The initial condition directive (
.IC
) is supported within a subcircuit.
-
To simulate repeated bursts of transients, you can use the EXP
function in independent sources with the following parameters:
EXP(V1 V2 Td1 Tau1 Td2 Tau2 Tpulse Npulse Tburst)
,
where:
-
Tpulse
– pulse period
-
Npulse
– the number of pulses per burst
-
Tburst
– the repeat burst period
-
Output currents for P-channel transistors (BJT, JFET, MOSFET, MESFET) are treated as inflow currents, making them consistent with N-channel transistors.
-
When creating a model based on another model, you can now use the AKO
model keyword. In the example shown below, model QP
has all the same parameters as model QP350
, except that BF
is changed and VA
is set.
.MODEL QP350 PNP(IS=1.4E-15 BF=70 CJE=.012P CJC=.06P RE=20 RB=350 RC=200)
.MODEL QP AKO:QP350 PNP(BF=150 VA=100)
Error detection is applied when using the AKO
syntax, in cases where the model definition involves infinite recursion ( show image) or a missing base model ( show image).
Creating a Workspace Simulation Model
Altium Designer, in conjunction with a connected Workspace, caters for the ability to create and manage Workspace Simulation Models. Once a Workspace Simulation Models model has been created, it can be used in the creation of one or more Workspace Components.
While Workspace Simulation Models are created automatically when you add a simulation model file to a component being defined in the Component Editor in its Single Component Editing mode and then save that component to your Workspace, you can also create Workspace Simulation Models directly within the Workspace as described below.
-
Open the Components panel and enable visibility of models by clicking the button at the top of the panel and selecting Models.
Enable visibility of Models in the Components panel
-
Browse to the Simulations category and select Create Component from the button menu.
Browse to simulation models in the Components panel and select the command to create a new model
-
In the Create New Item dialog that opens, enter the required information, make sure that the Open for editing after creation option is enabled and click OK. The Workspace Simulation Models will be created and the temporary SimModel Editor will open, presenting a .SimModel
document as the active document in the design space. This document will be named according to the Item-Revision, in the format: <Item><Revision>.SimModel
(e.g., SIM-001-0001-1.SimModel
).
Example of editing the initial revision of a Workspace Simulation Model – the temporary SimModel Editor provides the document with which to define your simulation model.
-
Use the document to define the Workspace Simulation Model as required. For more information on doing this, see Defining the Simulation Model.
-
Save the model to the Workspace using the Save to Server control to the right of the simulation model's entry within the Projects panel. The Edit Revision dialog will appear, in which you can change Name, Description, and add release notes as required. The document and editor will close after the save.
-
The document containing the source simulation model definition, *.SimModel
, will be stored in the revision of the Workspace Simulation Model. The simulation model will be presented in the Components panel, in the Simulations category.
A saved Workspace Simulation Model in the Components panel
The saved data stored in the Workspace consists of the model definition in the .SimModel
file, as well as any referenced .mdl
or .ckt
file. In the Explorer panel, switch to the Preview aspect view tab, then click on a referenced file to view a preview of its content. Model-level parameters will also be presented, where applicable.
Browse the saved Workspace Simulation Model in the Explorer panel. Switch to the Preview aspect view tab to see the saved data.
A saved Workspace Simulation Model can then be linked to a Workspace Component when defining the component in the Component Editor in its Single Component Editing or Batch Component Editing mode.
-
From a designer's perspective, a Workspace Component gathers together all information needed to represent that component across all design domains, within a single entity. It could therefore be thought of as a container in this respect – a 'bucket' into which all domain models and parametric information is stored. In terms of its representation in the various domains, a Workspace Component doesn't contain the Workspace domain models themselves, but rather links to these models. These links are specified when defining the component.
-
Workspace Simulation Models can also be created in the Workspace as part of importing existing, older generation (SchLib, PcbLib, IntLib, DbLib, SVNDbLib) component libraries. The interface to this process – the Library Importer – presents an intuitive flow that takes initial selected libraries, and imports them to your Workspace. Learn more about the Library Importer.
Defining the Simulation Model
The information required to define the model in a SimModel file is as follows:
-
Model Name – use this field to specify the name of the model. When saved back into the Workspace, this entry will be used as the Simulation Model Item Revision's Name.
This must be the name, as it appears in any referenced model or subcircuit file.
When referencing an MDL file, the name must be that appearing in the .MODEL
line of the model's definition. Consider a model for a diode with the following definition:
.MODEL 1N4002 D(IS=2.55E-9 RS=0.042 N=1.75 TT=5.76E-6 CJO=1.85E-11 + VJ=0.75 M=0.333 BV=100 IBV=1E-5 )
The model name here is 1N4002
. This is the name that must be entered into the Model Name field.
When referencing a CKT file, the name must be that appearing in the .SUBCKT
line of the model's definition. Consider a model for a fuse with the following definition:
.SUBCKT FUSE 1 2 PARAMS: CURRENT=1 RESISTANCE=1m SW1 1 2 3 0 SMOD OFF BNLV 3 0 V=(abs(v(1,2)))
.MODEL SMOD SW (VT=\{(CURRENT*RESISTANCE)\} RON=1g ROFF=\{RESISTANCE\})
.ENDS FUSE
The model name here is FUSE
. This is the name that must be entered into the Model Name field.
-
Model File – for a model that has been defined using a
.mdl
or .ckt
file, use the Browse button to nominate the required file from an available library.
-
Description – enter a description of the model, for example its purpose. When saved back into the Workspace, this entry will be used as the simulation model revision's Description.
-
Parameters – model-level parameters for the model (see Model-Level Parameters).
-
Model Preview – read-only display of the content of the referenced
.mdl
or .ckt
file.
Model-Level Parameters
Where applicable, model-level parameters can be defined directly within the SimModel file, since they are naturally part of a model's definition. The Parameters region of the document will automatically populate with parameters applicable to the chosen model. Parameter values can be edited through the in-place editing - click on the Parameter Value field associated with a parameter in the list and enter the required value directly.
For the built-in SPICE3f5, supported PSpice, and subcircuit model kinds, the available parameters will automatically be listed in the Parameters region.
Define parameters for the model as part of its definition – directly using in-place editing.
When a simulation-ready component is placed in a design, a simulation parameter can have a different value at the component-level, to that for the same parameter at the model-level. When the netlist is generated, the component-level parameter will have priority. Component-level parameters are naturally defined as part of that component. For more detail, see
Creating a New Workspace Library Component.
Editing a Workspace Simulation Model
At any stage, you can come back to any Workspace Simulation Model and edit it directly. Select the Simulations category in the Components panel (the Models option must be enabled in the panel's menu for accessing this category), right-click on the entry for a simulation model and choose the Edit command from the context menu. Once again, the temporary editor will open, with the file (containing the source simulation model definition) contained in the Workspace Simulation Model, opened for editing. Make changes as required, then save the document into the next revision of the Workspace Simulation Model.
Updating Related Workspace Components
When you make a change to a Workspace domain model – be it a symbol, footprint model, or simulation model – the moment you save that change into a new revision of the model, any Workspace Components that use that model will become effectively out of date, still using the previous revision. In most cases, you will no doubt want to re-save those Workspace Components, with the respective model links updated to use the latest revisions available. To streamline this process, a Workspace, in conjunction with Altium Designer, facilitates the ability to update related components – at the point of re-saving a Workspace model – after having made any modifications to that model through the direct editing feature.
The option to perform this update to the parent components can be found in the Create Revision dialog that appears when saving the modified Workspace Simulation Model back to the target Workspace. This option – Update items related to <ModelItemRevision> – is enabled by default.
<ModelItemRevision>
is the current revision of the Workspace model, that is, the revision currently being used by any related Workspace Components. Once the Workspace model itself is saved, this would naturally be the previous (earlier) revision, and no longer the latest.
Accessing the option to update related Workspace Components that are referencing the Workspace Simulation Model being re-saved.
If you want to keep all related components using the current revision of the Workspace Simulation Model, disable this option. Only the Workspace model itself will then be saved.
Once you click OK in the Create Revision dialog, the modified simulation model definition is saved back to the Workspace, and its associated temporary editor is closed. All Workspace Components referencing that Workspace Simulation Model will be re-saved to use its new revision automatically (the next revision of each component is automatically created and the save performed).
Generating SimModel Files
SimModel files can be generated from the active schematic library document or database library document using the Tools » Generate SimModel Files command.
-
This feature is only available for standard Database Libraries (DbLibs). SimModel files cannot be generated from SVN Database Libraries (SVNDbLibs).
-
Only components in currently-enabled tables will be considered when generating SimModel files.
After launching the command, the Generate SimModel Files dialog will appear. Each SimModel file (and constituent simulation model definition) is created based on the simulation model link for a schematic component in the active schematic library (or the simulation information for a component record in the active database library). Use the controls in the dialog to configure generation of one or more SimModel files as required. By default, a sub-folder named Sim Models
will be created. Change this naming to something more suitable as required. If the nominated folder exists, it will be the one used; if not, it will be created.
The Generate SimModel Files dialog
After defining options as required, click OK. Generation will proceed and a confirmation dialog will appear when the process is complete, stating how many SimModel files were generated. Any referenced .mdl
, .ckt
, or .scb
files will also be stored alongside the SimModel files.
A generated SimModel file itself can then be used to create a new revision of a Simulation Model Item in your connected Workspace. Open a SimModel file and use the File » Save to Server command to choose a planned item revision of a Simulation Model Item in your Workspace (or create one on the fly) via the Choose Planned Item Revision dialog that opens.
If migrating from an Integrated Library, the source schematic libraries (SchLib) can be obtained by opening the IntLib in Altium Designer, and electing to extract the source libraries. When generating SimModel files from a Database Library, only components in currently enabled tables will be considered.
SimModel file naming depends on the source library type:
-
Schematic Library - each SimModel file is named using the name of the simulation model. Where multiple schematic components include the same simulation model implementation (same named simulation model), only a single SimModel file will be generated, using that name.
-
Database Library - each SimModel file is named using the name of the simulation model, as specified in the Sim Model Name field for a component record. Where multiple component records (across enabled tables) include the same simulation model implementation (same entry in the Sim Model Name field) only a single SimModel file will be generated, using that name.
SPICE Model Wizard
Certain analog device models built-in to SPICE provide for an associated model file (*.mdl
) in which to parameterically define advanced behavioral characteristics (e.g. Semiconductor Resistor, Diode, BJT). Creation of this model file by hand and then linking it manually to the required schematic component can be quite laborious. The SPICE Model Wizard facilitates this task. Using the Wizard, the characteristics of such a device can be defined based on user-acquired data. The parameters – entered either directly or extracted from supplied data – are automatically written to a model file and that file linked to the nominated schematic component.
The SPICE Model Wizard provides a convenient, semi-automated solution to creating and linking a SPICE simulation model for a range of analog devices – devices that are built-in to SPICE, and that require a linked model file (*.mdl
). The behavioral characteristics of the model are defined based on information you supply to the Wizard. The extent of this information depends on the device type you wish to create a model for – ranging from the simple entry of model parameters, to the entry of device data obtained from a manufacturer's datasheet or by measurements gained from the physical device itself.
The following sections discuss the use of the Wizard – from access to verification.
Accessing the Wizard
The Wizard is accessed from the schematic symbol editor by choosing the Tools » XSpice Model Wizard command from the main menus.
The initial page of the SPICE Model Wizard
On the two subsequent pages of the Wizard, you will be able to choose:
-
Which particular device you wish to model, from the list of supported device types.
-
Whether to add the subsequently-generated SPICE model to an existing component in the library document or to a new component that is created by the Wizard and added to that document.
The SPICE Model Wizard is essentially a collection of wizards – one per device model supported.
Supported Device Types
The Wizard can be used to create SPICE models for the following analog device types:
-
Diode
-
Semiconductor Capacitor
-
Semiconductor Resistor
-
Current-Controlled Switch
-
Voltage-Controlled Switch
-
Bipolar Junction Transistor
-
Lossy Transmission Line
-
Uniform Distributed RC Transmission Line
Naming the Model
One of the most important steps as you follow the pages of the Wizard is to provide a name for the model you are creating. In fact, you will not be able to proceed to the parameter definition stage of the Wizard until you have entered a name.
After creation, this name will appear in the Model Name field of the Sim Model dialog. The model file itself is also created using this name (<ModelName>.mdl
). When using the Wizard to add a model to a new library component, the name specified for the model will be used to name the component also.
When naming the model, you also have the option to enter a short description for it. This could be the function of the model (e.g., Semiconductor Resistor
), or a more specific reference to a value or configuration (e.g., NPN BJT
).
Characteristics to be Modeled
After giving the model a name, you will proceed to one or more pages dealing with the characteristics to be modeled. The model types supported by the Wizard can be categorized into the following two groups:
A parameter specified in the model file for a device will override its default value (inherent to the SPICE engine).
-
Those models requiring the entry of data from which to extract the parameters that define the chosen device characteristics. The data entered is obtained either by direct measurement results from the physical device, or from a manufacturer's datasheet. For further information, see the Device Models Created by Parameter Extraction from Data section.
Only parameters definable within a model file are considered by the Wizard. Any parameters that are definable at the component level for a device should be addressed using the Parameters tab of the Sim Model dialog, once the Wizard has finished creating the model file.
Generating the Model
After defining the required data/parameters, the Wizard will display the generated model. This is the content that will be saved to the MDL file.
Previewing the generated model file content.
Editing of the model can be carried out directly on this page, giving you the utmost control over model specification.
Once you are satisfied with the model definition, click Next to pass to the end of the Wizard. Clicking Finish will allow you to save the model. Use the Save SPICE Model File dialog to determine where the resulting MDL file should be saved. By default, the file will be saved to the same directory as the schematic library document. You can also change the name of the file at this stage, should you wish.
If you have requested the model be attached to a new component, that component will be created and added to the library document.
Although the model is linked automatically to the component – new or existing – you should make a habit of verifying the mapping of schematic component pins to pins of the model. Access the Sim Model dialog for the attached model and check the pin mapping in the Pin Mapping region of the dialog – making any changes if required. Define the values of any additional parameters available for the model – on the Parameters tab of the dialog – as required.
Device Models Created by Direct Parameter Entry
For the following device models, the Wizard does not extract parameter information from entered data. Rather, the models are created based on direct entry of values for their associated parameters. When entering parameter values, there are a couple of things to bear in mind:
-
If a value for a parameter is not specified, there will be no entry for it in the model file that is created. In this case, the default value stored internally in SPICE will be used. Put another way, if a value for a parameter is specified in a model file, then the model file value overrides that parameter's default value.
-
If the default entry for a parameter in the Wizard is '-' and a value for that parameter is not specifically entered, a default value of zero will be used (internal to SPICE) for calculations.
Semiconductor Capacitor
The following parameters are definable for this device model, using the Wizard. Entering a value will cause that parameter to be written to the generated MDL file.
CJ
|
|
Junction bottom capacitance (in F/meters2).
|
CJSW
|
|
Junction sidewall capacitance (in F/meters).
|
DEFW
|
|
Default device width (in meters). (Default = 1e-6).
|
NARROW
|
|
Narrowing due to side etching (in meters). (Default = 0).
|
Semiconductor Resistor
The following parameters are definable for this device model, using the Wizard. Entering a value will cause that parameter to be written to the generated MDL file.
TC1
|
|
First order temperature coefficient (in Ohms/˚C). (Default = 0)
|
TC2
|
|
Second order temperature coefficient (in Ohms/˚C2). (Default = 0)
|
RSH
|
|
Sheet resistance (in Ohms).
|
DEFW
|
|
Default width (in meters). (Default = 1e-6).
|
NARROW
|
|
Narrowing due to side etching (in meters). (Default = 0).
|
TNOM
|
|
Parameter measurement temperature (in ˚C). If no value is specified, the default value assigned to TNOM on the Advanced tab of the Advanced Analyses Settings dialog will be used (Default = 27).
|
Current-Controlled Switch
The following parameters are definable for this device model, using the Wizard. Entering a value will cause that parameter to be written to the generated MDL file.
IT
|
|
Threshold current (in Amps). (Default = 0).
|
IH
|
|
Hysteresis current (in Amps). (Default = 0).
|
RON
|
|
ON resistance (in Ohms). (Default = 1).
|
ROFF
|
|
OFF resistance (in Ohms). By default, this is set to 1/GMIN. GMIN is an advanced SPICE parameter, specified on the Advanced tab of the Advanced Analyses Settings dialog. It sets the minimum conductance (maximum resistance) of any device in the circuit. Its default value is 1e-12 mhos, giving a default value for ROFF of 1000G Ohms.
|
Voltage-Controlled Switch
The following parameters are definable for this device model, using the Wizard. Entering a value will cause that parameter to be written to the generated MDL file.
VT
|
|
Threshold voltage (in Volts). (Default = 0).
|
VH
|
|
Hysteresis voltage (in Volts). (Default = 0).
|
RON
|
|
ON resistance (in Ohms). (Default = 1).
|
ROFF
|
|
OFF resistance (in Ohms). By default, this is set to 1/GMIN. GMIN is an advanced SPICE parameter, specified on the Advanced tab of the Advanced Analyses Settings dialog. It sets the minimum conductance (maximum resistance) of any device in the circuit. Its default value is 1e-12 mhos, giving a default value for ROFF of 1000G Ohms.
|
Lossy Transmission Line
The following parameters are definable for this device model, using the Wizard. Entering a value (or setting a flag) will cause that parameter to be written to the generated MDL file.
R
|
|
Resistance per unit length (in Ohms/unit). (Default = 0).
|
L
|
|
Inductance per unit length (in Henrys/unit). (Default = 0).
|
G
|
|
Conductance per unit length (in mhos/unit). (Default = 0).
|
C
|
|
Capacitance per unit length (in Farads/unit). (Default = 0).
|
LEN
|
|
Length of transmission line.
|
REL
|
|
Breakpoint control (in arbitrary units). (Default = 1).
|
ABS
|
|
Breakpoint control (in arbitrary units). (Default = 1).
|
NOSTEPLIMIT
|
|
A flag that, when set, will remove the restriction of limiting time-steps to less than the line delay. (Default = not set).
|
NOCONTROL
|
|
A flag that, when set, prevents limiting of the time-step, based on convolution error criteria. (Default = not set).
|
LININTERP
|
|
A flag that, when set, will use linear interpolation instead of the default quadratic interpolation, for calculation of delayed signals. (Default = not set).
|
MIXEDINTERP
|
|
A flag that, when set, uses a metric for determining whether quadratic interpolation is applicable and, if it isn't, uses linear interpolation. (Default = not set).
|
COMPACTREL
|
|
A specific quantity used to control the compaction of past history values used for convolution. By default, this quantity uses the value specified for the relative simulation error tolerance parameter (RELTOL), which is defined on the Advanced tab of the Advanced Analyses Settings dialog.
|
COMPACTABS
|
|
A specific quantity used to control the compaction of past history values used for convolution. By default, this quantity uses the value specified for the absolute current error tolerance parameter (ABSTOL), which is defined on the Advanced tab of the Advanced Analyses Settings dialog.
|
TRUNCNR
|
|
A flag that, when set, turns on the use of the Newton-Raphson iteration method to determine an appropriate time-step in the time-step control routines. (Default = not set, whereby a trial and error method is used – cutting the previous time-step in half each time).
|
TRUNCDONTCUT
|
|
A flag that, when set, removes the default cutting of the time-step to limit errors in the actual calculation of impulse-response related quantities. (Default = not set).
|
For the resultant model to simulate, at least two of the R, L, G, C parameters must be given a value and also a value must be entered for the LEN parameter. You will not be able to proceed further in the Wizard until these conditions are met.
Uniform Distributed RC Transmission Line
The following parameters are definable for this device model, using the Wizard. Entering a value will cause that parameter to be written to the generated MDL file.
K
|
|
Propagation constant. (Default = 2).
|
FMAX
|
|
Maximum frequency of interest (in Hertz). (Default = 1.0G).
|
RPERL
|
|
Redsistance per unit length (in Ohms/meter). (Default = 1000).
|
CPERL
|
|
Capacitance per unit length (in Farads/meter). (Default = 1.0e-15).
|
ISPERL
|
|
Saturation current per unit length (in Amps/meter). (Default = 0).
|
RSPERL
|
|
Diode resistance per unit length (in Ohms/meter). (Default = 0).
|
Device Models Created by Parameter Extraction from Data
For Diode and BJT devices, the Wizard extracts parameter information from the data you enter. The specific parameters extracted for inclusion in the model file will depend on the particular characteristics of the diode or BJT you have chosen to model.
The method of data entry varies between characteristics. In some cases, you will be required to enter direct data values, in others the entry of plot data. In any case, all data will be sourced from direct device measurements, a manufacturer's datasheet, or a combination of the two.
For plot-based data, entering more data points will provide the Wizard with a truer 'picture' of the source data, which in turn leads to the greater accuracy of extracted parameter values.
When you are required to enter plot data, enter a series of data points obtained from the graphical source data, into the grid provided by the Wizard. If you have the data stored in comma-separated value format (*.csv
), you can import the data using the available Import Data button. The Wizard will take the data you enter and use it to extract the required model parameters. The results of the extraction are presented on a subsequent page of the Wizard – in terms of the extracted parameter values themselves, and a comparison plot of the data entered and values calculated using the extracted parameters. The image below illustrates an example of such a display of parameter results.
Enter source data for the Wizard to be able to extract the required model parameters.
You can edit the extracted parameter values to further refine the accuracy of the diode model. The graphical comparison will be updated to reflect the changes.
Diode
The following sections detail each of the characteristics that you can choose to model for a diode device. Each section discusses the parameters extracted and the source data required by the Wizard to facilitate their extraction.
Forward-bias current flow
The following parameters are used to describe the DC current-voltage characteristics of the diode in the forward-bias region:
IS
|
|
Saturation current (in Amps).
|
N
|
|
Emission coefficient.
|
RS
|
|
Ohmic resistance (in Ohms).
|
To extract these parameters, a graph of the forward diode current (IF) versus the forward diode voltage (VF) is required. This graph can be obtained either from a manufacturer's datasheet or by measurements performed on a physical device.
The image below shows an example of such a graph, obtained from a datasheet, and also an example test circuit, from which direct measurements could be taken to obtain the required source data.
Example graph and circuit for diode I-V characteristics in the forward-bias region.
Data is entered into the Wizard as a series of data points obtained from the source graph.
Reverse-bias junction capacitance
The following parameters are used to describe the capacitance of the diode when operating in the reverse-bias region:
CJO
|
|
Zero-bias junction capacitance (in Farads).
|
M
|
|
Grading coefficient.
|
VJ
|
|
Junction potential (in Volts).
|
To extract these parameters, a graph of the reverse-biased capacitance (Cd) versus the reverse diode voltage (VR) is required. This graph can be obtained either from a manufacturer's datasheet or by measurements performed on a physical device.
The image shows an example of such a graph, obtained from a datasheet, and also an example test circuit, from which direct measurements could be taken to obtain the required source data. The latter can be used if a capacitance meter is not available.
Example graph and circuit for diode capacitance in the reverse-bias region.
Data is entered into the Wizard as a series of data points obtained from the source graph.
The example circuit in the image above is based on the equation:
I = C * (dv/dt)
Solving this equation for C gives:
C = I/(dv/dt)
The circuit produces a voltage ramp from the source V1. By calculating the slope of this ramp voltage the dv/dt
part of the equation can be obtained. By taking the measured diode current and dividing it by the slope of the ramp voltage, the diode capacitance curve can be obtained.
Reverse-bias current flow
The following parameters are used to describe the after-breakdown, reverse-bias current flow of the device:
BV
|
|
Reverse breakdown voltage (in Volts).
|
IBV
|
|
Current at breakdown voltage (in Amps).
|
To extract these parameters, the Wizard requires entry of the following two values:
These values can be obtained either from a manufacturer's datasheet or by measurements performed on a physical device. Datasheets will typically contain the electrical (DC) characteristics of a diode in tabular format, so it is just a question of locating these values and entering them exactly as they are reported.
If the source data is graphical – typical of measurements taken directly from a physical device – you will need to 'read-off' these two values at the point where the diode begins to break down. The image below shows an example of such a graph.
Graphically obtaining the current and voltage values at the reverse-breakdown point.
Although the values may be negative with respect to their display on the graph, when entered into the respective fields in the Wizard, they should be entered as positive values only.
Reverse recovery characteristics
The following parameter is used to model the reverse-recovery time of the diode while switching the diode from forward to reverse bias:
TT
|
|
Transit time (in seconds).
|
Direct measurement of this data is possible, but requires specialized equipment as the transit time of a diode can be as small as 1E-9s.
To extract this parameter, the Wizard requires entry of the reverse-recovery time of the diode (Trr
), at the point where the forward current is equal to the reverse current (i.e. IR/IF=1
). This data is typically found in the manufacturer datasheets for switching diodes in the form of simple numerical data.
The image below illustrates the appearance of this information in a manufacturer's datasheet. The value of interest in the image – the entry to be made into the Wizard – is 4ns.
Obtaining the reverse-recovery time for a diode.
Bipolar Junction Transistor (BJT)
When creating a Bipolar Junction Transistor (BJT) model, the SPICE Model Wizard requires you to choose the source data from which the parameter information will be extracted:
-
Measured Data – select this option if your source data comes from physical device measurements and you wish to develop an accurate model that describes all aspects of DC behavior.
-
Manufacturer Datasheet – select this option if your source data comes from a datasheet. Datasheets generally do not contain the level of information required to model all aspects of the BJT device. However, they will typically contain enough information to create a device model for use in the forward active region only.
When creating a BJT model, the Wizard also requires that you specify the transistor's polarity - NPN or PNP.
The differences between these two options mainly affect how the parameters modeling the DC current-voltage characteristics of the BJT are extracted. With respect to reverse-bias junction capacitances and transit times, the way in which the parameters are extracted are identical between the two.
The following sections detail each of the characteristics that you can choose to model for a BJT device, and in relation to the type of source data (measured data or datasheet). The parameters extracted in each case and the source data required by the Wizard to facilitate their extraction is discussed.
Characteristics Modeled using Measured Data
The following characteristics can be modelled when using data acquired from direct measurements made on the physical device.
-
Forward-Bias Parameters
The following parameters are used to describe the DC current-voltage characteristics of the BJT in the forward-bias region:
IS
|
|
Transport saturation current (in Amps).
|
BF
|
|
Ideal maximum forward beta.
|
NF
|
|
Forward current emission coefficient.
|
RB
|
|
Zero-bias base resistance (in Ohms).
|
RC
|
|
Collector resistance (in Ohms).
|
RE
|
|
Emitter resistance (in Ohms).
|
IKF
|
|
Corner for forward beta high current roll-off (in Amps).
|
ISE
|
|
B-E leakage saturation current (in Amps).
|
NE
|
|
B-E leakage emission coefficient.
|
VAF
|
|
Forward Early voltage (in Volts).
|
The following sections detail the measurement data required, entry from which will enable the Wizard to extract these parameters.
-
Base-Emitter Voltage versus Base Current
This data is used for initial extraction of the RC parameter. The image below shows an example graph of the Base-Emitter voltage (VBE) versus Base current (IB), and also an example test circuit, from which measurements could be taken to obtain the data. The circuit forces a current into the Base, while measuring the open-circuit base-emitter voltage.
Example graph and circuit for VBE vs. IB.
Data is entered into the Wizard as a series of data points obtained from the source graph.
-
Collector-Emitter Voltage versus Base Current
This data is used for initial extraction of the RE parameter. The image below shows an example graph of the Collector-Emitter voltage (VCE) versus Base current (IB), and also an example test circuit, from which measurements could be taken to obtain the data. The circuit forces a current into the Base, while measuring the open-circuit Collector-Emitter voltage.
Example graph and circuit for VCE vs. IB.
Data is entered into the Wizard as a series of data points obtained from the source graph.
-
Forward Gummel Plot
This data is primarily used to extract the IS, BF, NF, RB, IKF, ISE and NE parameters. It is also used to optimize the RC, RE and VAF parameters. The image below shows an example Gummel plot, and also an example test circuit, from which measurements could be taken to obtain the data. The Gummel plot illustrates:
The Base-Collector voltage (VBC) is held at zero volts.
Example forward Gummel plot and test circuit.
Data is entered into the Wizard as a series of data points obtained from the source Gummel plot. The raw IB and IC values must be entered – the Wizard will apply the LN function to the curve data.
-
Collector Current versus Base-Emitter Voltage
This data is used for initial extraction of the VAF parameter. The image below shows an example graph of the Collector Current (IC) versus Base-Emitter voltage (VBE), and also an example test circuit, from which measurements could be taken to obtain the data. The circuit is used to generate two curves of IC vs. VBE, for two different values of Base-Collector voltage (VBC). The curves should be measured at currents as low as possible and with VBC as close to zero volts as practical.
Example graphs and circuit for VBE vs. IC.
Data is entered into the Wizard as a series of data points into two tables – one for each source data curve. The value used for VBC also has to be entered in each case.
-
Reverse-Bias Parameters
The following parameters are used to describe the DC current-voltage characteristics of the BJT in the reverse-bias region:
IS
|
|
Transport saturation current (in Amps).
|
BR
|
|
Ideal maximum reverse beta.
|
NR
|
|
Reverse current emission coefficient.
|
RB
|
|
Zero-bias base resistance (in Ohms).
|
RC
|
|
Collector resistance (in Ohms).
|
RE
|
|
Emitter resistance (in Ohms).
|
IKR
|
|
Corner for reverse beta high current roll-off (in Amps).
|
ISC
|
|
B-C leakage saturation current (in Amps).
|
NC
|
|
B-C leakage emission coefficient.
|
VAR
|
|
Reverse Early voltage (in Volts).
|
The following sections detail the measurement data required, entry from which will enable the Wizard to extract these parameters.
-
Reverse Gummel Plot
This data is primarily used to extract the IS, BR, NR, RB, IKR, ISC and NC parameters. It is also used to optimize the RC, RE and VAR parameters. The image below shows an example Gummel plot, and also an example test circuit, from which measurements could be taken to obtain the data. The Gummel plot illustrates:
The Base-Emitter voltage (VBE) is held at zero volts.
Example reverse Gummel plot and test circuit.
Data is entered into the Wizard as a series of data points obtained from the source Gummel plot. The raw IB and IE values must be entered - the Wizard will apply the LN function to the curve data.
-
Emitter Current versus Base-Collector Voltage
This data is used for initial extraction of the VAR parameter. The image below shows an example graph of the Emitter Current (IE) versus Base-Collector voltage (VBC), and also an example test circuit, from which measurements could be taken to obtain the data. The circuit is used to generate two curves of IE vs. VBC, for two different values of Base-Emitter voltage (VBE). The curves should be measured at currents as low as possible and with VBE as close to zero volts as practical.
Example graphs and circuit for IE vs. VBC.
Data is entered into the Wizard as a series of data points into two tables – one for each source data curve. The value used for VBE also has to be entered in each case.
Characteristics Modeled using Data from a Manufacturer's Datasheet
The following characteristics can be modeled when using data acquired from a manufacturer's datasheet.
-
Forward-Bias Parameters
The following parameters are used to describe the DC current-voltage characteristics of the BJT in the forward-bias region:
IS
|
|
Transport saturation current (in Amps).
|
BF
|
|
Ideal maximum forward beta.
|
NF
|
|
Forward current emission coefficient.
|
RE
|
|
Emitter resistance (in Ohms).
|
IKF
|
|
Corner for forward beta high current roll-off (in Amps).
|
ISE
|
|
B-E leakage saturation current (in Amps).
|
NE
|
|
B-E leakage emission coefficient.
|
The following sections detail the data required, entry from which will enable the Wizard to extract these parameters.
-
Base-Emitter Voltage versus Collector Current
Datasheets typically have these curves in a 'forced beta' or 'saturated' condition.
This data is used to extract the IS, NF, RE and IKF parameters. The image below shows an example graph of the Base-Emitter voltage (VBE) versus the Collector current (IC), obtained from a datasheet.
Data is entered into the Wizard as a series of data points obtained from the source graph. The raw IC values must be entered - the Wizard will apply the LN function to the curve data.
The value for the forced beta ratio of the curve (β = IC/IB) also needs to be entered. In the example plot of the image above, this value is shown at the top-left of the graph, and so the value 10 would be entered.
-
DC Current Gain versus Collector Current
This data is used to extract the BF, NE, ISE and IKF parameters. The image below shows an example graph of the DC current gain (hFE) versus the Collector current (IC), obtained from a datasheet.
Data is entered into the Wizard as a series of data points obtained from the source graph. For accuracy, values for the DC current gain should be entered for low, medium and high values of Collector current.
-
Forward Early Voltage
The following parameter is used to model the effect of base-width modulation in the Gummel-Poon transistor model:
VAF
|
|
Forward Early voltage (in Volts).
|
To extract this parameter you will need to enter a point from the Output Admittance (hOE) versus Collector current (IC) curve. The image below shows an example of such a curve.
Read off any value on the curve. In the example of the image above, we can read off IC = 1mA and hOE = 30μmhos.
Typically, the data appears in tabular format, an example of which is shown in the image below.
Example tabular entry for Output Admittance.
The values of interest in the image – and the entries to be made in the Wizard – are 1mA for the Collector current and 30μmhos for the Output Admittance (the maximum value is typically used).
Characteristics Modeled using Measured or Manufacturer Data
Reverse-bias junction capacitance data is typically obtained from direct device measurements.
The following characteristics can be modeled when using data acquired from either a manufacturer's datasheet or from direct measurements made on a physical device.
-
Base-Emitter Capacitance
The following parameters are used to describe the reverse-bias junction capacitance of the Base-Emitter junction:
CJE
|
|
B-E zero-bias depletion capacitance (in Farads).
|
MJE
|
|
B-E junction exponential factor.
|
VJE
|
|
B-E built-in potential (in Volts).
|
To extract these parameters, a graph of the reverse-biased B-E junction capacitance (Cj) versus the voltage characteristics (VBE) is required. If a capacitance meter is not available, the example test circuit of the image below could be used to obtain the data. The image also shows example graphs obtained from such a circuit – plotting VBE and Cj against time respectively. From these graphs, the values for VBE and Cj at corresponding points in time can be easily read-off.
Example circuit and graphs for reverse-bias B-E junction capacitance.
Data is entered into the Wizard as a series of data points obtained from the source graph(s).
The example circuit in the image above is based on the equation:
I = C * (dv/dt)
Solving this equation for C gives:
C = I/(dv/dt)
The circuit produces a voltage ramp from the source V1. By calculating the slope of this ramp voltage the dv/dt
part of the equation can be obtained. By taking the measured diode current and dividing it by the slope of the ramp voltage, the diode capacitance curve can be obtained. The two graphs in the image above relate to the circuit as follows:
-
Base-Collector Capacitance
The following parameters are used to describe the reverse-bias junction capacitance of the Base-Collector junction:
CJC
|
|
B-C zero-bias depletion capacitance (in Farads).
|
MJC
|
|
B-C junction exponential factor.
|
VJC
|
|
B-C built-in potential (in Volts).
|
To extract these parameters, a graph of the reverse-biased B-C junction capacitance (Cj) versus the voltage characteristics (VBC) is required. If a capacitance meter is not available, the example test circuit of the image below could be used to obtain the data. The image also shows example graphs obtained from such a circuit – plotting VBC and Cj against time respectively. From these graphs, the values for VBC and Cj at corresponding points in time can be easily read-off.
Example circuit and graphs for reverse-bias B-C junction capacitance.
Data is entered into the Wizard as a series of data points obtained from the source graph.
The example circuit in the image above is based on the equation:
I = C * (dv/dt)
Solving this equation for C gives:
C = I/(dv/dt)
The circuit produces a voltage ramp from the source V1. By calculating the slope of this ramp voltage the dv/dt
part of the equation can be obtained. By taking the measured diode current and dividing it by the slope of the ramp voltage, the diode capacitance curve can be obtained. The two graphs in the image above relate to the circuit as follows:
-
Collector-Substrate Capacitance
The following parameters are used to describe the reverse-bias junction capacitance of the Collector-Substrate junction:
CJS
|
|
Zero-bias collector-substrate capacitance (in Farads).
|
MJS
|
|
Substrate junction exponential factor.
|
VJS
|
|
Substrate junction built-in potential (in Volts).
|
To extract these parameters, a graph of the reverse-biased C-S junction capacitance (Cj) versus the voltage characteristics (VCS) is required. If a capacitance meter is not available, the example test circuit of the image below could be used to obtain the data. The image also shows example graphs obtained from such a circuit – plotting VCS and Cj against time respectively. From these graphs, the values for VCS and Cj at corresponding points in time can be easily read-off.
Example circuit and graphs for reverse-bias C-S junction capacitance.
Data is entered into the Wizard as a series of data points obtained from the source graph.
The example circuit in the image above is based on the equation:
I = C * (dv/dt)
Solving this equation for C gives:
C = I/(dv/dt)
The circuit produces a voltage ramp from the source V1. By calculating the slope of this ramp voltage the dv/dt
part of the equation can be obtained. By taking the measured diode current and dividing it by the slope of the ramp voltage, the diode capacitance curve can be obtained. The two graphs in the image above 24 relate to the circuit as follows:
-
Transit Times
The following parameters are used to describe the transit time of the BJT:
TF
|
|
Ideal forward transit time (in seconds).
|
TR
|
|
Ideal reverse transit time (in seconds).
|
To extract these parameters, the Wizard requires entry of the transistor's unity gain frequency (fT). This is the frequency at which the current gain of the transistor becomes unity. This data is typically found in manufacturer datasheets in the form of simple numerical data.
fT is typically listed in the small signal characteristics area of a datasheet, and is also referred to as the Current Gain-Bandwidth Product, or Unity-Gain Bandwidth.
The image below illustrates the appearance of this information in a manufacturer's datasheet. The value of interest in the image – the entry to be made into the Wizard – is 100MHz.
Example tabular entry for Current Gain - Bandwidth Product.