how to simulate an audio amplifier using ltspice - Page 2 - diyAudio
Go Back   Home > Forums > Design & Build > Software Tools

Software Tools SPICE, PCB CAD, speaker design and measurement software, calculators

Please consider donating to help us continue to serve you.

Ads on/off / Custom Title / More PMs / More album space / Advanced printing & mass image saving
Reply
 
Thread Tools Search this Thread
Old 24th October 2012, 12:26 AM   #11
diyAudio Member
 
Join Date: Jun 2011
Quote:
Originally Posted by AndrewT View Post
...it came back saying cannot find model for ONE transistor. The text file includes that transistor and I don't expect the file to be corrupted.
That's a different matter. You may not expect it to be corrupted, but it almost certainly has some error that has crept in somehow. Software can be very fussy, and the omission of as little as a period or semicolon is sufficient to cause errors such as 'not found' errors.
Of course it's possible that it's bugging out on the first error found, and that if this is corrected it will go on to find subsequent errors, although I am an LTSpice user my memory is a bit vague on this point.

Substitute a transistor from the regular library and see if you can get the sim to run, if it works, then make some comparisons between working models and the nonfunctional one, there are many functional models you can download if you don't know how to peek at the existing ones you have. You have to make sure the format matches exactly, although this may not be easy. They are all text files. It's best to manipulate these in an editor specifically intended for editing code, other editors sometimes manipulate the formatting in unseen ways behind your back. Best to steer clear of Notepad, the Windows .txt editor. You want one that does not wrap lines. A good graphical free editor under Windows is PFE32, Programmers File Editor (32-bit).

Otherwise ask the supplier of the .asc file to verify his own copy and send you a new one.

Last edited by counter culture; 24th October 2012 at 12:32 AM.
  Reply With Quote
Old 24th October 2012, 12:50 AM   #12
fas42 is online now fas42  Australia
diyAudio Member
 
fas42's Avatar
 
Join Date: Jun 2012
Location: NSW, Australia
Blog Entries: 11
If you want to play around with the text file you don't have to go to the effort of a separate editor. LTspice will happily open the text file, with a nice syntax highlighting editor, you can do all the fiddling there.

A simple thing to try: open the text file, copy the model details you want -- the name should be blue, the parameters red, if they're not then you have a corruption of the file -- and paste into a Spice directive textbox in the .asc window just like the .include line I mentioned before, and then paste the model details on the schematic somewhere. The names should obviously match, if it still can't find the model then there's some really weird problem there ...

Frank
  Reply With Quote
Old 24th October 2012, 01:36 AM   #13
diyAudio Member
 
Join Date: Jun 2011
@fas42

Good input, I didn't know there was a syntax checking editor included.
  Reply With Quote
Old 24th October 2012, 09:32 AM   #14
AndrewT is offline AndrewT  Scotland
diyAudio Member
 
Join Date: Jul 2004
Location: Scottish Borders
will try these suggestions when I get back.
Thanks.
__________________
regards Andrew T.
  Reply With Quote
Old 24th October 2012, 02:27 PM   #15
macboy is offline macboy  Canada
diyAudio Member
 
Join Date: Oct 2003
Location: Ottawa, Canada
Lots of chatter in this thread, few addressing the OP questions. I'll take a crack at a couple.
Quote:
Originally Posted by davidel94 View Post
Then how to check the slew rate?
Usually a square wave input is used where the rise and fall time are really small like 10ns but how can i choose the right frequency and amplitude?
To find the slew rate is right to do a transient analysis and then put two cursors at a distance of 1us in the point of the plot where the output goes from the max value to the min and the slope of that is the slew rate?
Slew rate is the rate of change of output voltage. To measure it, you must use an input signal that induces slew-rate limiting, that is, the output can't change fast enough to track the input (that is very important). The output will increase at a fairly constant rate to catch up to the input signal, this is the slew rate. Just calculate the slope of the line. Slew rate is usually expressed in V/s.

Quote:
Last question, when i do a transient analysis with square wave input the output waveform presents spikes just after the rising edge and after the falling edge wich decay in a small time. What's that mean?
That is overshoot. If the signal bounces back too far (below the stable level) that is called undershoot. If the signal continues to bounce up and down several times before settling down, this is called ringing. The amount of time that it takes for the signal to settle down to the stable/desired level is called settling time. This is usually expressed with a percentage like 1%, meaning it takes that long for the response to settle to within 1% of the stable level. Excessive overshoot or ringing may indicate a (nearly) unstable, or under-compensated amp.

Now that you know what these are called you can Google overshoot, undershoot, ringing, settling time, slew rate, etc., and learn more. Add 'measure' and/or 'calculate' to the search to get practical information instead of just theory.
  Reply With Quote

Reply


Hide this!Advertise here!
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are Off
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How to simulate OPT in LTspice? Akita Tubes / Valves 15 29th December 2013 05:39 PM
how to simulate an audio amplifier using ltspice davidel94 Solid State 5 6th March 2013 05:10 PM
Anybody willing to simulate ? east electronics Solid State 28 24th January 2012 11:51 AM
LTspice square wave and audio amp test maouna Solid State 2 11th December 2010 10:34 AM
With which can i Simulate a Zen Amplifier! bulrot Parts 6 31st May 2006 03:14 PM


New To Site? Need Help?

All times are GMT. The time now is 11:00 AM.


vBulletin Optimisation provided by vB Optimise (Pro) - vBulletin Mods & Addons Copyright © 2014 DragonByte Technologies Ltd.
Copyright 1999-2014 diyAudio

Content Relevant URLs by vBSEO 3.3.2