LTSpice External Components
Introduction
There is a chance that some of the components that you will be using during your labs are not modeled under LTSpice. On the other hand, there is also a good chance that those components are industry standard and it is easy to find spice models around.
Note: If you can't find the model for the component that you are trying to include in your project, your only option is to build your own PSpice model for it.
After you get the desired PSpice model, there are a couple different ways to import that model into your LTSpice design. If you are interested in knowing the different ways to import external libraries besides the one covered in this article, check [Ref 1].
We are going to keep it simple and include the PSpice models in a way that you can share your projects around, and all PSpice models dependencies are easy to manage.
UA741 Op Amp
We are going to use the UA741 Op Amp. There are better options for industry standard Op Amps [Ref 2], but for now this is sufficient to demonstrate the concept.
Let's build an inverter amplifier configuration with Gain = -2.
- To keep things clean and easy to read, we are going to connect the power supplies of the Op Amp with labels (V+ and V-, respectively).
- We are going to use the generic opamp2 component from the LTSpice library.
- We will be simulating the circuit for a DC and AC signal. For now, we keep the AC simulation directive commented.
Download the PSpice model for the UA741 Op Amp.
Unzip the file and copy the UA741.301 file to the same working directory of your project. PSpice files are just text files, and LTSpice doesn't care much about the extension that you give to those files. We like to give a more descriptive extension so we know what it is. Rename UA741.301 to UA741.lib
Note: You don't need to change the extension name of PSpice files. Just make sure that you include the file with the correct name into your projects.
All it is left to do is to include the spice directive ".inc UA741.lib" into your schematic and rename opamp2 to UA741. This name, UA741, needs to be the same name inside the PSpice model file.
Simulations
Let's simulate the DC operating point of the circuit in Figure 4. We should get a Vo = -4 V for a Vin = 2 V.
Let's run a transient analysis for an input sine wave with a frequency of 1 kHz, DC offset and 1 Vpeak.
Other Examples
Example 1
LTSpice Simulation Files
Spice Components
Directions: Download the spice model and place it in the same project folder that you are working.
References
- [Ref 1] "LTSpice Tutorial - EP 4 How to import libraries and component models", FesZ Electronics YouTube Channel [Video]
- [Ref 2] "EEVBlog 1436 - The TOP 5 Jellybean OPAMP's", EEVBlog YouTube Channel [Video]