Wednesday, May 23, 2012

Design Notes: Op-amp Stability Analysis in SPICE

Op-amp stability analysis involves getting an DC operating point with the amplifier running normally then opening the feedback loop and getting small-signal AC information. This can be done by using a very large inductor to pass DC and block AC and a very large capacitor to pass AC and block DC, but I've only seen it done that way once (and that was just last week, go figure).
HSPICE and many of its relatives, including SmartSpice, have the ability for a resistor to have a different value depening on if the simulation is DC (like an operating point analysis) or AC. The schematic below shows a simple way to accomplish this. This even works with Cadence's analogLib res, but I have not gotten it work with Cadence's analogLib resBias. But if you have access to Cadence you probably want to use the stb analysis and skip all of this. 


The listing shown here is for Silvaco's SmartSpice. HSPICE isn't that different. 


.option
+ post=1
+ measout
+ nomod
+ unwrap=1
+ usedegrees
+ savemfiles=1
+ savemodelslog
+ ingold=1
.temp 25
.AC DEC 50 10 10000meg
.LET AC mGAIN = vdb(out)-vdb(pos)
.LET AC mGAINM = -(vdb(out)-vdb(pos))
.LET AC mPHASE = vp(out, pos)
.LET AC mPHASEM = 180+(vp(out, pos))
.MEAS AC mGANMRG FIND mGAINM WHEN mPHASE=-180
.MEAS AC mPHSMRG FIND mPHASEM WHEN mGAIN=0
.MEAS AC mUGF WHEN mGAIN=0



There have been some some health problems in my family, so this was just a quick note to keep this blog weekly. I expect to have assembly and operation notes on the LED drivers next week. 

Bruce McLaren

No comments:

Post a Comment