Analog Innovations

Tools

CreateS-ParameterSubcircuitsForSpice.pdf    Several AppNotes which discuss how to measure and/or create subcircuit equivalencies to S-Parameter data.

HSpice2PSpiceNewEdit.pdf  Instructions for using a text editor to convert HSpice CMOS Library & Netlist Files to PSpice compatibility.

The primary differences between HSpice and PSpice are syntactical.  For example, '...' in HSpice must be rewritten as {...} in PSpice.   Likewise there are naming differences for various CMOS device model parameters.   This note addresses what changes are necessary.

Efforts have been made to automate these tasks (by Brian Hirasuna, while at MicroSim, now at Cadence), but it remains a manual task at the moment... too many syntactical variations.  I have found that a text editor with good find and replace, particularly when they can be implemented in macro form (such as with my favorite editor, UltraEdit) to be invaluable for converting large libraries.

LayoutRoutingInstructions.pdf    Helpful schematic notation methods to indicate chip layout requirements for metalization layers.

LogicStepTable.pdf    Simulate a uP/uC stepping control signals into your Analog circuitry.

LoopGain.zip   ACCURATE LOOP GAIN and PHASE ANALYSIS with Spice and PSpice

Two methods of Loop Gain and Phase Analysis are presented.  The mathematical derivation of an automated method useable in PSpice is shown, accompanied by a symbol library and appropriate macros to add to your PSpice.prb file.

LTspiceTutorials.zip    A collection of LTspice Manuals and Tutorials that I've found useful.

NOdBm.zip  Handy tool for keeping track of signal levels in volts peak-to-peak when data is presented in dBm and an impedance level (or vice versa).

RealPulse.pdf   A realistically shaped voltage pulse source for Spice simulators.  See also RisetimeMeasurement.pdf below.

RisetimeMeasurement.pdf   Measure & Display Risetime During a Spice Simulation Run.  See also RealPulse.pdf above.

Spice3F3.pdf  The venerable Berkeley Spice Reference.  Useful for remembering now-undocumented functions, or the Spice concept in general.

Macros

Noise Figure the easy way.....

Add the following two lines in the [MACROS] section of pspice.prb.  Do it in the "Common" Directory to make it valid for all of your designs.

VSRCSQ = 16.5757565E-21*V(RSRC:1,RSRC:2)/I(RSRC)
NF = 10*LOG10((V(INOISE)*V(INOISE))/VSRCSQ)

In your schematic make sure you name the source resistance "RSRC".
Setup your AC analysis, checking the "Noise enabled" box and designating an "Output Node".
Perform the AC analysis, then, in Probe, Add, Trace, "NF".  Voila!   Noise Figure is automatically plotted in Probe.

Displaying dBm values in PSpice Probe.....

Add the following line in the [MACROS] section of pspice.prb.  Do it in the "Common" Directory to make it valid for all of your designs.

dBm(N,Z) = VdB(N)*sqrt(500/Z)

Where "N" is the node name where you have placed a (regular) voltage marker and "Z" is the reference impedance (normally 50 ohms).  In Probe, go to Plot/X Axis Settings/Process Options and check the Fourier box before calling this macro.

Return Loss and VSWR.....

Add the following three lines in the [MACROS] section of pspice.prb.  Do it in the "Common" Directory to make it valid for all of your designs.

MAGGAMMA=M(2*V(IN_NODE)-V(SRC_NODE))
RET_LOSS=20*LOG10(MAGGAMMA)
VSWR=(1+MAGGAMMA)/(1-MAGGAMMA)

Follow the naming conventions as given in the NF section above.  In addition name the node adjacent to the AC source "SRC_NODE" and the node following RSRC as "IN_NODE".  VSWR and RET_LOSS can then be called in Probe after an AC analysis.

Contributed Topics

FEMM Analysis of PCB Structures (Courtesy of Robert Macy)...  FEMM_Analysis_of_PCB_Structure.zip  

Descriptions/explanations, femm models, and LTspice schematics showing the step-by-step process of using free femm 4.2 to analyze a simple PCB structure to calculate values to then use in circuit simulation, LTspice/PSpice. The sequence can be modified for use in analyzing really complex structures, structures where there are NO formulas.