Académique Documents
Professionnel Documents
Culture Documents
Analog circuit simulation has been inseparable from analog IC LTspice is a new SPICE that was developed to simulate analog
design. SPICE simulators are the only way to check circuitry prior circuits fast enough to make simulation of complex SMPS systems
to integration onto a chip. Further, the SPICE simulation allows interactive. Incorporated into the new SPICE are circuit elements to
measurements of currents and voltages that are virtually impossible model practical board level components. Capacitors and inductors
to do any other way. can be modeled with series resistance and other parasitic aspects
The success of these analog circuit simulators has made circuit of their behavior without using sub-circuits or internal nodes.
simulation spread to board level circuit design.
Modern switch mode power supplies include controller logic with
It is easier in many cases to simulate rather than breadboard, and multiple modes of operation. For example, devices may change
the ability to analyze the circuit in the simulation for performance and from pulse switch modulation to burst-mode or to cycle skipping
problems speeds the design of well-understood, robust circuits. depending on the circuit’s operation.
Certain analog functions are extremely difficult to simulate with An original new mixed-mode compiler and simulator were written into
commercially available SPICE simulators. Switch-mode power LTspice that allows these products to be realistically modeled in a
supplies have fast high frequency switching square waves as well computationally fast manner.
as slow overall loop response. This means simulations must run for
thousands to hundreds of thousands of cycles in order to see the Due to the mixed mode simulation capability and many other
overall response of a switching regulator. Commercially available enhancements over previous SPICE programs, the simulation speed
SPICE’s simply take too long for this to be a useful simulation is greatly improved while simulation accuracy is retained. Detailed
method. Simulation times for a switch-mode power supply must be cycle-by-cycle SMPS simulations can be performed and analyzed
in minutes not hours for a simulator to be useful. in minutes. A user can get a detailed simulation of power systems
with a few mouse clicks without knowing anything about the device,
There have been analog circuit simulation methods that have shown SPICE or the schematic capture program. Pre-drafted demo circuits
some success in speeding up switch mode power supply simulation can be used as a starting point to build the custom circuit to fit
but at a cost of making simplifying assumptions which don’t allow different power supply requirements.
arbitrary control logic and fully simulate the complexity of the
switching waveforms. A new SPICE with integrated logic primitives A simulation circuit element was developed for power MOSFET’s
that perform the switch mode control provides a better answer. It that accurately exhibits their usual gate charge behavior without
can give fast simulation times, yield detailed waveforms, and still using sub-circuits or internal nodes. Reducing the number of nodes
allows the flexibility for arbitrary circuit modifications. the simulator needs to solve significantly reduces the computation
required for a given simulation without compromising the accuracy
or detail of the switching waveforms. Another benefit is that
convergence problems are easier to avoid since they, like the board
level component the model, have finite impedance at all frequencies.
Figure 1: LTspice Example Showing Transient Response for a Simple Switching Power Supply Circuit
command. Notice that if you click on a terminal or another wire a connection will be made to the wire being drawn. Experiment with the Draw
Wire command by connecting the PLLIN terminal to the Vin wire. Once you have finished exploring the Draw Wire command use the Undo
command to return the jig to its original state.
If you put a component next to a terminal or wire connection the component will be automatically connected to the circuit. Try this with a
capacitor. Select Edit, Add Capacitor and then place the capacitor just below the wire connection to R4 on the left hand side of the schematic.
Once the capacitor is placed, press the esc key to end the Add Capacitor command. The added capacitor will now be connected into the
circuit.
Summary
The above commands should be enough to allow you to create your own simple schematics. Review the other commands in the Edit pull down
window and try them out. In a few minutes you should be able to create any schematic you need. Don’t forget to look over the supplied jigs and
educational circuits. In most cases the majority of your work has been done already- you just need to make changes.
Now let’s move on to the main use of LTspice- Simulation- in the next section.
Figure 6: Simulation results for Vin and Vout in the Example Circuit
Measuring current is easy as well. Just position the cursor over a component and tit turns into a current measuring probe. On the example circuit
position the probe over the capacitor between the Vosns+ and Vosns- signals and click. The current across the capacitor is displayed in the
upper window. Notice that the signal is switching so fast it is difficult to see easily. You can zoom-in on the signal to see it better by positioning
the cursor on the bottom axis label. The cursor icon switched to a ruler. Right click and you will get a menu of commands. Select the Zoom Area
command and then select the beginning of the display (from 0us to 160us) by clicking on the upper left of the display and then at the top of the
160us point in the display. The display will zoom to the section selected. You should see a display similar to that shown in Figure 7 below.
Figure 7: Zoomed Display of Current thru C2
You can easily edit the signals displayed in the upper window. Click on the upper window and then position the cursor over the signal label at
the top of the window. The cursor will switch to the pointing hand icon when you are positioned correctly. Right click to bring up the edit window
for the signal. You can change display characteristics or delete the signal by clicking on the Delete This Trace button. If you delete I(C2) and then
change the display via the Zoom to Fit command (by Right Clicking on the bottom axis label and selecting Zoom to Fit) you should get back to
the display shown in Figure 6.
Encrypted Libraries
LTspice supports the use of Vendor Encrypted Libraries to protect
sensitive design information. Such libraries would be supplied by a
third party.
Wave
LTspice can convert waveform outputs to .wav audio files so you can
listen to the results. This is a big help with audio processing circuits.
Step
This command causes an analysis to be repeatedly performed while
stepping the temperature, a model parameter, a global parameter,
or an independent source. Steps may be linear, logarithmic, or
specified as a list of values.
Param
Figure 8: LTspice Simulation Commands The param directive allows the creation of user defined variables.
This is useful for associating a name with a value for the sake of
Transient Analysis clarity and parameterized sub-circuits so that abstract circuits can
Perform a transient analysis. This is the most direct simulation of be saved in libraries. A large number of standard arithmetic and logic
a circuit. It basically computes what happens when the circuit is functions are available to create very powerful expressions.
powered up. Test signals are often applied as independent sources.
Measure
AC Analysis This command is used to find values from simulation results so they
The small signal (linear) AC portion of LTspice computes the AC can be saved for further analysis or as a record of key results.
complex node voltages as a function of frequency. First, the DC
operating point of the circuit is found. Next, linearized small signal Control Panel
models for all of the nonlinear devices in the circuit are found for The LTspice control panel allows you to customize many of the
this operating point. Finally, using independent voltage and current aspects of LTspice. Click on the Tools menu and select Control
sources as the driving signal, the resultant linearized circuit is solved Panel from the pull down menu. You will see a list similar to that
in the frequency domain over the specified range of frequencies. shown in Figure 9.
This mode of analysis is useful for filters, networks, stability analyses,
and noise considerations.
DC Analysis
This performs a DC analysis while sweeping the DC value of a
source. It is useful for computing the DC transfer function of an
amplifier or plotting the characteristic curves of a transistor for model
verification.
Click on the tab to access the desired group of settings. You can
experiment with various settings and then restore the defaults by
clicking on the Reset to Default Values if you need to recover the
initial settings.
Summary
LTspice has many powerful commands and options. We have only
been able to cover a few of them in this app note but it should give
you an appreciation for the power of this easy to use tool.
Conclusion
This application note has provided a step-by-step guide to LTspice. It demonstrated how to download, install, use the schematic editor and
run simple simulations. This should provide you with enough background to make it easy to use LTspice to simulate your own Switching Mode
Power Supply or any of a host of circuits using Linear Technology products.
For the reader who wants additional levels of detail on the Linear Technology products used in this app note a list of valuable documents is given
in the Reference section at the end of this document.
References
1) LTspice Landing Page - http://www.linear.com/designtools/software/#Spice
2) LTspice User Guide - http://ltspice.linear.com/software/scad3.pdf
3) LTspice Getting Started Guide - http://www.linear.com/designtools/software/LTspiceGettingStartedGuide.pdf
4) Powering a Virtex-5 FPGA with LTC Power Devices App Note - http://www.nuhorizons.com/application_notes/application.asp?id=14
5) LTC Demo Circuits - http://www.linear.com/designtools/software/demo_circuits.jsp
Notice Of Disclaimer
Nu Horizons is disclosing this Application Note to you “AS-IS” with no warranty of any kind. This Application Note is one possible implementation
of this feature, application, or standard, and is subject to change without further notice from Nu Horizons. You are responsible for obtaining
any rights you may require in connection with your use or implementation of this Application Note. Nu Horizons makes no representations or
warranties, whether express or implied, statutory or otherwise, including, without limitation, implied warranties of merchantability, noninfringement,
or fitness for a particular purpose. In no event will Nu Horizons be liable for any loss of data, lost profits, or for any special, incidental,
consequential, or indirect damages arising from your use of this application note.