Hello unclejed613
The only dc component I know would be the dc offset, offset can be reduce to near 0.0 mv in a simulation.
What other possible dc components than the dc offset can happen in any simulated circuits ?
Thank
Bye
Gaetan
The only dc component I know would be the dc offset, offset can be reduce to near 0.0 mv in a simulation.
What other possible dc components than the dc offset can happen in any simulated circuits ?
Thank
Bye
Gaetan
Last edited:
Try this.
Common Issues Encountered By New Users - diyAudio
Input and output capacitors cause very small DC drift as they charge; this is the result of an inaccurate DC operating point solution. Simulate the circuit until the voltages across these caps stop drifting and then replace them with voltage sources of the same value. Then the FFT will lose that odd "slant".
- keantoken
Common Issues Encountered By New Users - diyAudio
Input and output capacitors cause very small DC drift as they charge; this is the result of an inaccurate DC operating point solution. Simulate the circuit until the voltages across these caps stop drifting and then replace them with voltage sources of the same value. Then the FFT will lose that odd "slant".
- keantoken
Hello keantoken
To give some times to those cap DC drifts to settle, I just did a simulation with the FFT start time at .001ms , and now the inverted harmonic peak are gone.
Thank you
Bye
Gaetan
To give some times to those cap DC drifts to settle, I just did a simulation with the FFT start time at .001ms , and now the inverted harmonic peak are gone.
Thank you
Bye
Gaetan
I'm trying to put a thermistor in a power supply circuit. I have the following 5spice subckt
* 5Spice/Spice3 model for NTC thermistor
* thermistor formula
* R = R25C * exp( Beta/T - Beta/To)
* note: temperature in degrees Kelvin. Tkelvin = Tcelsius + 273.15
* Beta is thermistor material constant
* R25C is resistance at 25C
* to use models with other Spices:
* remove the "PARAMS: xxxxxxxxxxxx" from .subckt line
* replace "{R25C}" with resistance value at 25C
* replace "{Beta}" with value of Beta
* replace "{Rthermal}" with value, if present in model
.SUBCKT Ntc 1 2
Btherm 1 3 V = I(Vsense)*10*exp(3548/(V(Temp)+273.15) - 3548/(25+273.15))
Vsense 3 2 DC 0
* determine circuit temperature(Celsius).
* Voffset subtracts out the value of Rtc, leaving just
* the temperature change from zero degrees C.
Voffset Temp 9 DC -1.0
I1 0 9 DC 1.0
Rtc 9 0 RTEMP 1.0
.MODEL RTEMP R(TC1 = 1 TNOM=0)
.ENDS
I made a symbol called NTC, put pins 1 and 2 on it, saved to the symbol directory, placed it in the schematic, but run give me the missing schematic of ntc error.
Any thoughts? help..
thanks,
Ken
* 5Spice/Spice3 model for NTC thermistor
* thermistor formula
* R = R25C * exp( Beta/T - Beta/To)
* note: temperature in degrees Kelvin. Tkelvin = Tcelsius + 273.15
* Beta is thermistor material constant
* R25C is resistance at 25C
* to use models with other Spices:
* remove the "PARAMS: xxxxxxxxxxxx" from .subckt line
* replace "{R25C}" with resistance value at 25C
* replace "{Beta}" with value of Beta
* replace "{Rthermal}" with value, if present in model
.SUBCKT Ntc 1 2
Btherm 1 3 V = I(Vsense)*10*exp(3548/(V(Temp)+273.15) - 3548/(25+273.15))
Vsense 3 2 DC 0
* determine circuit temperature(Celsius).
* Voffset subtracts out the value of Rtc, leaving just
* the temperature change from zero degrees C.
Voffset Temp 9 DC -1.0
I1 0 9 DC 1.0
Rtc 9 0 RTEMP 1.0
.MODEL RTEMP R(TC1 = 1 TNOM=0)
.ENDS
I made a symbol called NTC, put pins 1 and 2 on it, saved to the symbol directory, placed it in the schematic, but run give me the missing schematic of ntc error.
Any thoughts? help..
thanks,
Ken
You have to tell LTspice where to find the subckt.
1) ctl-right-click on the symbol, and set the SpiceModel parameter to be the name of the subckt e.g. ntc
2) add a .include statement to the schematic with the path to the model. If you put the .sub file in the C:\Program Files\LTC\LTspiceIV\lib\sub directory, you don't have to provide the entire path so you would add
.include ntc.sub
1) ctl-right-click on the symbol, and set the SpiceModel parameter to be the name of the subckt e.g. ntc
2) add a .include statement to the schematic with the path to the model. If you put the .sub file in the C:\Program Files\LTC\LTspiceIV\lib\sub directory, you don't have to provide the entire path so you would add
.include ntc.sub
Just saw this on the LTSpice group!
Now we can simulate reverse-bias E-B junctions... It seems avalanche mode is still out though.
I think we should gather the "undocumented" parameters and give them a page of their own?
- keantoken
RE: Body Diode Breakdown
Posted by: "Panama Mike"
Tue Feb 9, 2010 9:57 am (PST)
There are a number as otherwise undocumented parameters in
current release of LTspice's VDMOS DC characteristics. These
allow you to model body diode breakdown, subthreshold conduction,
and independent fits for the saturation and linear regions
of the output characteristics.
BV: breakdown voltag
IBV: breakdown current at breakdown voltage
NBV: breakdown emission coefficient
mtriode: A conductance multiplier for the triode
region. It allows you to independently
match the saturation and linear regions
of the MOSFET.
subthres: The current(per volt Vds) at which the
square law drain current vs Vgs switches
over to exponential.
I don't recommend modeling failure modes because that tends to
be more conducive to designing failures that practical circuits.
The simulator tells you how many volts/amps a part must handle
when it doesn't fail. But if you have an avalanche grade body
diode, then it's reasonable to model that intended breakdown.
Bipolar BE breakdown is also in LTspice:
BVbe: B-E breakdown voltage
IBVbe: breakdown current at breakdown voltage
NBVbe: breakdown emission coefficient
Bipolar BE breakdown is technically a failure mode also,
because it modifies the transistor doping and the gain
decreases. BTW, if ground the emitter of an NPN transistor,
leave the collector unconnected, and reverse bias the base
to breakdown, the collector tends to go negative because
the breakdown creates photons which are converted back to
current in the BC junction. Does anybody know the net quantum
efficiency of that process? I did a quick check on a 2N3904,
and found it less than 1ppm, which was the limit of my
multimeter.
Enjoy,
--Mike
____________ _________ _________ __
Subject: [LTspice] body diode break down
Hi
Without using a zener is there anyway of making the LT spice MOSFET models avalanche? Each time I use one of the devices then I find I have to add a zener.
Cheers
WayneL
Now we can simulate reverse-bias E-B junctions... It seems avalanche mode is still out though.
I think we should gather the "undocumented" parameters and give them a page of their own?
- keantoken
tnx, that was vety interesting i'll have to remember that when i do final runs on designs. i've often asked why LTSpice doesn't model failure modes. i think there should be an animation of "letting the smoke out" of a device. most of us would probably have too much fun with that feature...







Last edited:
MOSFET model generator LTspice
This came about a few years ago but I'm not certain it has been brought up here.
"Hello,
Anyone who is interrested to make there own power mosfet model for
spice can now easily do this with a tool i made.
It's a windows application and can be found on the yahoo groups
LTspice.
The programs needs dot net framework 2.0 to be installed on your
computer in order let it run.
Features:
1 Datasheet information of the mosfet to be modeled is entered in the
program.
2 This data can be saved for later use.
3 The model created is a .model statement which only will work in
LTspice because it makes use of the VDmos device in LTspice not
pressent in any other spice.
4 The program has a library manager to keep all your models in one .lib
file.
The model generated by the program matches the datasheet ouput graph,
transfer graph and all the capacitances of the device. Especialy the
nonlinear gate drain capacitor which is the power of VDmos model in
LTspice.
It now allso includes the reverse recovery of the body diode. (only
basicly because the spice diode only covers the storage time)
Best regards,
Hendrik Jan Zwerver"
I tried this out, it works. BTW why does SPICE not have it's own forum category here at DIYAUDIO? Weird in these times, don't ya think?
Carry on...
This came about a few years ago but I'm not certain it has been brought up here.
"Hello,
Anyone who is interrested to make there own power mosfet model for
spice can now easily do this with a tool i made.
It's a windows application and can be found on the yahoo groups
LTspice.
The programs needs dot net framework 2.0 to be installed on your
computer in order let it run.
Features:
1 Datasheet information of the mosfet to be modeled is entered in the
program.
2 This data can be saved for later use.
3 The model created is a .model statement which only will work in
LTspice because it makes use of the VDmos device in LTspice not
pressent in any other spice.
4 The program has a library manager to keep all your models in one .lib
file.
The model generated by the program matches the datasheet ouput graph,
transfer graph and all the capacitances of the device. Especialy the
nonlinear gate drain capacitor which is the power of VDmos model in
LTspice.
It now allso includes the reverse recovery of the body diode. (only
basicly because the spice diode only covers the storage time)
Best regards,
Hendrik Jan Zwerver"
I tried this out, it works. BTW why does SPICE not have it's own forum category here at DIYAUDIO? Weird in these times, don't ya think?
Carry on...
Hey, that's nice.
With this we could devote a page to MOSFET modeling. We could in fact make models for all the most common devices.
I edited in the information in my last post (quite some time ago actually), but something happened and it never got saved (on my end).
- keantoken
With this we could devote a page to MOSFET modeling. We could in fact make models for all the most common devices.
I edited in the information in my last post (quite some time ago actually), but something happened and it never got saved (on my end).
- keantoken
The tool can be found here:
LTspice - SwitcherCAD III | Google Groups
And here are some related files, for those who have already joined the group:
http://tech.groups.yahoo.com/group/LTspice/files/ Attached files sorted by message number/msg_20712/
http://tech.groups.yahoo.com/group/LTspice/files/ Attached files sorted by message number/msg_15283/
- keantoken
LTspice - SwitcherCAD III | Google Groups
And here are some related files, for those who have already joined the group:
http://tech.groups.yahoo.com/group/LTspice/files/ Attached files sorted by message number/msg_20712/
http://tech.groups.yahoo.com/group/LTspice/files/ Attached files sorted by message number/msg_15283/
- keantoken
MOS Tool
For MOS Tool to work on a PC, you gotta load Microsoft's "dot frame Network" software. I think there is a better way around this but that would include the author writing alot more code. Mos Tool uses the Bill Gates stuff to work from.
Also, I still had errors running MOS Tool even after the dot frame stuff was loaded and running. 😕 There were still some dll and ocx files missing and in need of registration. When that stuff starts up, I figure folks will back away but with some minor tinkering it all gets settled.
I used the older version of dot frame network...version 2 without service pack. Perhaps if you download the latest and greatest version from Microsoft's site, then perhaps the dll and ocx files don't give hassle?
If you take it on and start messing with those dll and ocx files in your win32 folder, be careful. A clean registry is required or it can bring you down.
For MOS Tool to work on a PC, you gotta load Microsoft's "dot frame Network" software. I think there is a better way around this but that would include the author writing alot more code. Mos Tool uses the Bill Gates stuff to work from.
Also, I still had errors running MOS Tool even after the dot frame stuff was loaded and running. 😕 There were still some dll and ocx files missing and in need of registration. When that stuff starts up, I figure folks will back away but with some minor tinkering it all gets settled.
I used the older version of dot frame network...version 2 without service pack. Perhaps if you download the latest and greatest version from Microsoft's site, then perhaps the dll and ocx files don't give hassle?
If you take it on and start messing with those dll and ocx files in your win32 folder, be careful. A clean registry is required or it can bring you down.
Attachments
Also regarding Mos Tool
The specifications required to build an accurate Mosfet Model in this program do not usualy exist in data sheets of "audio grade" mosfets. Some of the data can be derived and some will be left open for interpretation. As always simulators simulate; they put out what you put in...really...kind of🙄
My favourite use of this tool was building "
Superman
" type devices with ultimate specifications. This allowed me to look at other factors in circuit design and not worry what the final output stage was doing to "color" the result. Still I'm just painting it my way when I use those models.
I hope that helps and my comment earlier about diyaudio needing a spot for spice was a sarcastic compliment about the wonderful expansion of the site and all the expansion of forum categories. I think the software/spice thingy has been here for years? Oh well. As you were...
The specifications required to build an accurate Mosfet Model in this program do not usualy exist in data sheets of "audio grade" mosfets. Some of the data can be derived and some will be left open for interpretation. As always simulators simulate; they put out what you put in...really...kind of🙄
My favourite use of this tool was building "


I hope that helps and my comment earlier about diyaudio needing a spot for spice was a sarcastic compliment about the wonderful expansion of the site and all the expansion of forum categories. I think the software/spice thingy has been here for years? Oh well. As you were...
This maybe dating me but, when I was in college studying computer programing(fortran 4) one of the first thing they taught was GIGO(garbage in garbage out).. I have simulation software that I am grappleing with , I can be quoted I think simulation is a good thing but nothing beats building an actual circuit...
Now back to our sponsors...
Regards E
Now back to our sponsors...
Regards E
The program works fine for me and loaded right at first startup, so maybe something else is wrong.
- keantoken
- keantoken
Hello
For those who may need one, here is a complete loudspeaker model, crossover, woofer and tweeter, here is the link.
http://www.diyaudio.com/forums/attac...rtion-ldc6.pdf
Bye
Gaetan
For those who may need one, here is a complete loudspeaker model, crossover, woofer and tweeter, here is the link.
http://www.diyaudio.com/forums/attac...rtion-ldc6.pdf
Bye
Gaetan
keantoken: thanks for all your hard work on this subject and the spice wiki. Now that our resident Spice expert Andy_C is gone, we need this more than ever.
My 2 cents on Help files: I use them (and the included Spice examples(which are a great learning tool)) all the time and I usually find what Im looking for. (and Im not a programer, but i am an EE). The catch is I scanned the help file top to bottom before I started using LTSpice so when I have a question I know if the answers going to be there or not before I look (there is stuff missing). Spice is a great way to HELP learn electronics but it dosnt replace the books. I wonder how many people that find the help files useless dont know there electronics very well.
Thanks again to all those that contribute to the Spice wiki.
Now I have a question, wheres the best place to learn how to use Laplace equations in LTSpice. (one of the things thats missing from the help)
My 2 cents on Help files: I use them (and the included Spice examples(which are a great learning tool)) all the time and I usually find what Im looking for. (and Im not a programer, but i am an EE). The catch is I scanned the help file top to bottom before I started using LTSpice so when I have a question I know if the answers going to be there or not before I look (there is stuff missing). Spice is a great way to HELP learn electronics but it dosnt replace the books. I wonder how many people that find the help files useless dont know there electronics very well.
Thanks again to all those that contribute to the Spice wiki.
Now I have a question, wheres the best place to learn how to use Laplace equations in LTSpice. (one of the things thats missing from the help)
keantoken: thanks for all your hard work on this subject and the spice wiki. Now that our resident Spice expert Andy_C is gone, we need this more than ever.
)
Does anyone know what happened to Andy_C - his work was so valuable...
Ken
- Status
- Not open for further replies.
- Home
- Design & Build
- Software Tools
- Things you should know about LTSpice