LT Spice Getting Started Very Quickly. First Get the Latest Software!

Similar documents
LTSpice Basic Tutorial

EE 2274 RC and Op Amp Circuit Completed Prior to Coming to Lab. Prelab Part I: RC Circuit

EE320L Electronics I. Laboratory. Laboratory Exercise #2. Basic Op-Amp Circuits. Angsuman Roy. Department of Electrical and Computer Engineering

Introduction to LT Spice IV with Examples

ECE 201 LAB 6 INTRODUCTION TO SPICE/PSPICE

Lab 4: Analysis of the Stereo Amplifier

Introduction to PSpice

EE 210 Lab Exercise #3 Introduction to PSPICE

Lab Reference Manual. ECEN 326 Electronic Circuits. Texas A&M University Department of Electrical and Computer Engineering

Engineering 3821 Fall Pspice TUTORIAL 1. Prepared by: J. Tobin (Class of 2005) B. Jeyasurya E. Gill

10: AMPLIFIERS. Circuit Connections in the Laboratory. Op-Amp. I. Introduction

Since transmission lines can be modeled using PSpice, you can do your analysis by downloading the student version of this excellent program.

EE431 Lab 1 Operational Amplifiers

Introduction to NI Multisim & Ultiboard Software version 14.1

Activity P52: LRC Circuit (Voltage Sensor)

LABORATORY 2: Bridge circuits, Superposition, Thevenin Circuits, and Amplifier Circuits

ECE Lab #4 OpAmp Circuits with Negative Feedback and Positive Feedback

ECE4902 Lab 5 Simulation. Simulation. Export data for use in other software tools (e.g. MATLAB or excel) to compare measured data with simulation

Control System Circuits with Opamps

Integrators, differentiators, and simple filters

Physics 303 Fall Module 4: The Operational Amplifier

Hello, and welcome to the TI Precision Labs video series discussing comparator applications. The comparator s job is to compare two analog input

Laboratory 8 Operational Amplifiers and Analog Computers

LAB 8: Activity P52: LRC Circuit

Lab #2 First Order RC Circuits Week of 27 January 2015

LAB EXERCISE 3 FET Amplifier Design and Linear Analysis

AN-1106 Custom Instrumentation Amplifier Design Author: Craig Cary Date: January 16, 2017

CHARACTERIZATION OF OP-AMP

EE 233 Circuit Theory Lab 3: First-Order Filters

Chapter 12: Electronic Circuit Simulation and Layout Software

EK307 Active Filters and Steady State Frequency Response

Lab 6: Instrumentation Amplifier

A Brief Handout for Introduction to

EXPERIMENT NUMBER 10 TRANSIENT ANALYSIS USING PSPICE

Using LTspice a Short Intro with Examples

Ph 3455 The Franck-Hertz Experiment

Laboratory 6. Lab 6. Operational Amplifier Circuits. Required Components: op amp 2 1k resistor 4 10k resistors 1 100k resistor 1 0.

Amplification. Objective. Equipment List. Introduction. The objective of this lab is to demonstrate the basic characteristics an Op amplifier.

Physics 310 Lab 6 Op Amps

Week 1: Preparing for PSpice Simulations

PSPICE T UTORIAL P ART I: INTRODUCTION AND DC ANALYSIS. for the Orcad PSpice Release 9.2 Lite Edition

EE320L Electronics I. Laboratory. Laboratory Exercise #3. Operational Amplifier Application Circuits. Angsuman Roy

ENGR 201 Homework, Fall 2018

An Introductory Guide to Circuit Simulation using NI Multisim 12

Pre-Lab. Introduction

ECE3204 D2015 Lab 1. See suggested breadboard configuration on following page!

ESE 150 Lab 04: The Discrete Fourier Transform (DFT)

Lab 13 AC Circuit Measurements

Precalculations Individual Portion Filter Lab: Building and Testing Electrical Filters

Operational Amplifiers

Physics 334 Notes for Lab 2 Capacitors

EE 1210 Op Amps, Gain, and Signal Integrity Laboratory Project 6

EE 3305 Lab I Revised July 18, 2003

Sensor Interfacing and Operational Amplifiers Lab 3

Revised: Summer 2010

Laboratory 3 (drawn from lab text by Alciatore)

EE 2274 DIODE OR GATE & CLIPPING CIRCUIT

EXPERIMENT 7 The Amplifier

Resonant Frequency of the LRC Circuit (Power Output, Voltage Sensor)

Electronics. RC Filter, DC Supply, and 555

ECE4902 C Lab 7

Group: Names: (1) In this step you will examine the effects of AC coupling of an oscilloscope.

ECE4902 C Lab 5 MOSFET Common Source Amplifier with Active Load Bandwidth of MOSFET Common Source Amplifier: Resistive Load / Active Load

Experiment P45: LRC Circuit (Power Amplifier, Voltage Sensor)

Name: First-Order Response: RC Networks Objective: To gain experience with first-order response of RC circuits

BME/ISE 3512 Bioelectronics. Laboratory Five - Operational Amplifiers

Lab 6: MOSFET AMPLIFIER

Week 7: Design a Logarithmic Voltmeter. A variation on Experiment 19 Validation by 8pm on October 14

ESE 150 Lab 04: The Discrete Fourier Transform (DFT)

I1 19u 5V R11 1MEG IDC Q7 Q2N3904 Q2N3904. Figure 3.1 A scaled down 741 op amp used in this lab

Common-source Amplifiers

Laboratory 4: Amplification, Impedance, and Frequency Response

Introduction to OrCAD. Simulation Program With Integrated Circuits Emphasis.

Lecture 2 Analog circuits. Seeing the light..

Figure 1. Main window (Common Interface Window), CIW opens and from the pull down menus you can start your design. Figure 2.

1. Hand Calculations (in a manner suitable for submission) For the circuit in Fig. 1 with f = 7.2 khz and a source vin () t 1.

AC Measurements with the Agilent 54622D Oscilloscope

University of Jordan School of Engineering Electrical Engineering Department. EE 204 Electrical Engineering Lab

Common-Source Amplifiers

BME 3512 Bioelectronics Laboratory Five - Operational Amplifiers

"Improve Instrument Amplifier Performance with X2Y Optimized Input Filter"

Week 8 AM Modulation and the AM Receiver

Introduction to SPICE. Simulator of Electronic devices

EECS 312: Digital Integrated Circuits Lab Project 1 Introduction to Schematic Capture and Analog Circuit Simulation

Testing Power Sources for Stability

University of Utah Electrical Engineering Department ECE 2100 Experiment No. 2 Linear Operational Amplifier Circuits II

University of North Carolina, Charlotte Department of Electrical and Computer Engineering ECGR 3157 EE Design II Fall 2009

Class #9: Experiment Diodes Part II: LEDs

Build Your Own Bose WaveRadio Bass Preamp Active Filter Design

EMG Electrodes. Fig. 1. System for measuring an electromyogram.

DEPARTMENT OF ELECTRICAL ENGINEERING AND COMPUTER SCIENCE MASSACHUSETTS INSTITUTE OF TECHNOLOGY CAMBRIDGE, MASSACHUSETTS 02139

Experiment P50: Transistor Lab 3 Common-Emitter Amplifier (Power Amplifier, Voltage Sensor)

ICL MHz, Four Quadrant Analog Multiplier. Features. Ordering Information. Pinout. Functional Diagram. September 1998 File Number 2863.

Introduction to SwitcherCAD

Mentor Graphics OPAMP Simulation Tutorial --Xingguo Xiong

Lab 4 - Operational Amplifiers 1 Gain ReadMeFirst

UNIVERSITY OF UTAH ELECTRICAL AND COMPUTER ENGINEERING DEPARTMENT ELECTROMYOGRAM (EMG) DETECTOR WITH AUDIOVISUAL OUTPUT

EE2210 Laboratory Project 1 Fall 2013 Function Generator and Oscilloscope

Ansoft Designer Tutorial ECE 584 October, 2004

Laboratory 4 Operational Amplifier Department of Mechanical and Aerospace Engineering University of California, San Diego MAE170

Transcription:

LT Spice Getting Started Very Quickly First Get the Latest Software! 1. After installing LT Spice, run it and check to make sure you have the latest version with respect to the latest version available on the Linear Technology website: www.linear.com 2. Open File > New Schematic. Next press File > Save As to name & save the design. Split Supply DC Coupled Inverting OpAmp Circuit Creation 1. We will now create a simple DC coupled inverting OpAmp amplifier for practice: a. Press Edit > Component and double click on the [Opamps] link and then scroll all the way to the right and select UniversalOpamp. Click to place on your breadboard and then hit the ESC key. b. Press Edit > Place Gnd to place a ground on the breadboard next to the positive input on the Opamp. You can also place a Gnd by pressing the Gnd symbol on the horizontal tool bar. c. Press the Pencil symbol on the toolbar and draw a wire from the Gnd symbol to the positive input on the opamp. If you draw too long a wire, you can always delete the wire with the Scissors symbol on the toolbar. Remember to always press the ESC key to get out of the tool mode you have selected. d. Press the Resistor icon to place two resistors for the feedback and series input on the negative terminal of the opamp. Connect wires between the resistors and opamp as required. If you want to move the resistors around, try pressing the Big Hand icon and then select the resistor you want to move. e. Right click on top of the feedback resistor to fill in 4000 ohms for the value, 10% tolerance and 0.25 W power rating. Repeat for the series resistor at the negative opamp input. However make this value 1000 ohms so that we will set opamp gain = 4. Resistor units are k for kilo and MEG for mega. i.e. 1000 could have been entered as 1k or 0.001MEG. f. Press Edit > Component and scroll al the way to the left and press the [..] button to go back up the component directory. Scroll to the right and you should see the voltage component listed. Select this and place one above and below the opamp. g. On the voltage source above the opamp, connect the negative side to a Gnd and the positive side to the positive supply pin on the opamp. On the lower voltage source, connect the negative side to the negative opamp power supply terminal and then connect the positive side of the voltage terminal to a Gnd. h. Right click the voltage sources and set them to 9V (just type in 9) and 1 series ohm resistance. i. Select another voltage source component (Edit > Component > voltage) and attach the positive side to the series resistor and the negative side to Gnd. Right click and set this souce at 5 volts, 1 series ohm resistance. j. We are almost ready for simulation but should name some nodes for easy identification later. Select the Label Net icon (it is a rectangle with an A inside) and type Out in the ABC row with the port set at none. Place this net on the output of the opamp. Repeat for the input going to the series input resistor, call this In. Note: We just created a DC coupled inverting amplifier with a gain = 4. There are no caps in the design to block DC signals. Because the amp input is tied to ground this is the bias point. i.e. our signal will swing about this point and can go from rail to rail with respect to the power supplies connected. Let s see the function and limitations by simulating the design.

Split Supply DC Coupled Inverting OpAmp Simulation 1. Press Edit > Simulation and you should see the Edit Simulation Command window pop up. Go to the DC Sweep tab. If you don t see the window pop up, try pressing Simulation > Edit Simulation Cmd (at the bottom of the pull down menu). 2. In the DC Sweep input area, fill in the name of first source as V3 or whatever you named the voltage supply connected to the circuit input. Sweep linearly from 9V to +9V in increments of 0.1V. Press OK to close this window and notice it puts the sweep info in text on your circuit. 3. Now press the little Simulate (running man) icon on the toolbar. A black window should open. Press the Pick Visible Traces icon on the toolbar and select out two nets we placed earlier: V(in) and V(out). You should see the screen snapshot below. Our input is in blue and from 2.5 to 2.5V on the horizontal scale we can see the output is linearly changing. The reason that it is flat initially and at the end is that we have pegged the rails with our gain. i.e. If the input is 3V we should expect the output to go to 4* 3 =12V. This exceeds our positive power supply value of 9V so we clip. Similarly, if the input is 3V we expect the output to be 12V which will clip our 9V power supply rail. To remedy this, we will knock down the input voltage swing. 4. Select the circuit window (*.asc file) and press Simulation > Edit Simulation Cmd and change the linear dc sweep from 9/+9V to 2.5 to +2.5V. 5. Now run the simulation again by pressing the running man icon. You should see the following graphic. Only a little clipping as expected when the input is greater than 2.25V and less than 2.25V.

Single Supply DC Coupled Inverting OpAmp Experimentation Split supply designs are acceptable at school in the lab where you have dual voltage supplies readily available. However they are painful in battery powered products. At my company we have several battery powered temperature and vibration products which run off of 3.6V lithium ion batteries. We usually put several of these batteries in parallel to get several years of run time out of the device before servicing. To facilitate this, our digital circuitry and analog preamplifiers must all run off of a single supply voltage which is usually 3.3V (regulated down from 3.6V). Let s see how the input biasing must changed on the inverting Opamp to accommodate the single supply design. 1. In the previous circuit, delete the negative power supply voltage source and in its place connect the negative opamp power supply rail to Gnd. Change the value of the positive rail supply to 3.3V. 2. Press Simulate > Edit Simulation Cmd and change the dc sweep to 0 to 3.3V. Run the simulation (you may have to select V(in) and V(out) for viewing again with the Pick Visible Traces icon) and you ll notice the output always stays at zero. This occurs because we still have an inverting amplifier and we are trying to produce a negative voltage created our gain = 4. We can switch to a non inverting amplifier or simply change the bias point for the opamp input. Presently, we have set the dc bias point at 0V by having connecting the positive input terminal of the opamp to Gnd. Ideally we would like to have the bias point in the middle of the 0 to 3.3V span or roughly ~ 1.65V. One way to do this is to use a resistive divider to set this bias point as described. 4. Delete the Gnd placed on the positive opamp input. Instead connect two 10K resistors in series where one end of the pair attaches to 3.3V and the other to Gnd. Then attach the node between the two resistors to the positive input terminal on the opamp. This sets the dc bias point halfway between the power supply rail (3.3V). Re run the simulation and see if it matches the following graphic.

5. Our input signal is too large, more clipping, but otherwise it is functioning like a usual inverting amplifier. Change the dc sweep value from 1.25V to 2.05V and you should see a linear result output with respect to this input. 1.25V should correspond to an output = 3.3V while 2.05V produces ~ 0V out. To understand this we must take the input and subtract it by the dc bias point and then multiply by the 4 gain and then add it to the dc bias point. All inputs and outputs are referenced around the dc bias in a dc coupled circuit! i.e. dc bias point = 3.3V/2 = 1.65V. Expected Output w/1.25v input = (1.25V 1.65V)* 4 + 1.65V = 3.25V. Expected Output w/2.05v input = (2.05V 1.65V)* 4 + 1.65V = 0.05V. This result is now shown. As long as we keep the input relatively small compared to the output (due to the Gain = 4), we get a nice linear output. In a dc coupled opamp design, the big problem arises when we have a small signal riding on a large dc value. i.e. Let s say you are given a microphone that has a 2V

dc offset and an audio signal that spans +/ 100 mv. The mic signal will swing from 1.9V to 2.1V. If we continue with a gain of 4 we will create an output that wants to swing between: (1.9V 1.65V)* 4 + 1.65V = 0.65V to (2.1V 1.65V) = 0.15V The dc offset on the source kills us because the difference between it and our dc bias point is multiplied by the gain. Imagine trying to digitize this mic signal at the output of the opamp with an A/D. We want it centered around 3.3V/2. Our source (mic) dc offset needs to be exactly the same as our pre amp dc bias. If we move our pre amp s dc bias point to 2V, our output can only swing +/ 1.3V around this point whereas when it was set at 1.65V it can swing +/ 1.65V. The solution is to get rid of the dc coupling on the opamp and block dc signals with a big capacitor in series on the input (ac coupled system). Single Supply AC Coupled Inverting OpAmp Experimentation 1. Starting with the typical dc coupled inverting opamp circuit created earlier, we simply have to move the input voltage source to the left and insert a 1uF cap between the voltage source a series input resistor. 2. Right click over the capacitor and type in a value of 1u for 1 micro farad. Units relating to capacitors are p for pico, n for nano and u for micro. 3. Change the gain from 4 to 10 by increasing the feedback resistor from 4000 ohms to 10K ohms. This gain will be useful when we have to compute the 20*log of the voltage output later. 4. If you now run the dc sweep you will see there is no output because the input is being blocked (dc value) to the series input resistor. Instead of a dc sweep we now need to chance the simulation to AC Analysis. First use the Scissor icon and delete the.dc V3 1.25 2.05 0.1 LT Spice directive on the breadboard. Then go into Simulation > Edit Simulation Cmd and remove the spice directive at the bottom of the DC Sweep tab. This removes the DC Sweep simulation which in no longer meaningful since we now have an AC coupled circuit. 5. Next select the AC Analysis tab. Select a linear sweep from 20 to 20K Hz by typing 20 in the Start Frequency: field & 20k in Stop Frequency: field. As in resistive input k = kilo and MEG = mega. Also, type the Number of points: to be 1000. 6. We have to change the dc voltage source to be an ac source. Right click the input voltage source and set Functions to radio button Sine, DC offset[v]: to 0, Small signal AC analysis AC Amplitude: to 0.1 and Phase: to 0. Note: All the Small signal AC analysis parameters are the initial settings used by the AC Analysis portion of the Simulator. 7. Now press the Simulate running man icon. Press the Pick Visible Traces icon and make sure V[in] and V[out] are selected. You should see the following graphic.

Reviewing what we have just set up, the input voltage has an amplitude of 0.1 V and sweeps from 20 20K Hz. The corresponding output therefore is 10*0.1V = 1V. LT Spice computes 20 log (X/1V) for whatever signal X, you want to look at. i.e. The input is shown as 20 dbs because they have computed 20 log (0.1V/1V) over the frequency sweep. Similarly, they computed 20 log (1V/1V) or 0 dbs for the output voltage swept over the range. All voltages probed in AC Sweep are always referenced to 1V. If you want to look at the gain of your amp you have to subtract the two curves. i.e. 0 ( 20 dbs) = 20 dbs which corresponds to our desired Gain = 10. The dotted lines are phase. The input has zero phase (in between 30 & 30 degrees) and the opamp then has a negative gain which causes the expected phase to change from 0 to 180 degrees. 8. We can also look at the output voltage in terms of an oscilloscope (voltage versus time) view. Go back to Simulation > Edit Simulation Cmd and open the Transient tab. Type in 10m (10 msec) in the Stop Time: field. Press Ok and exit the window. 9. Now right click over the input voltage source and set the DC Offset [V] = 0, Amplitude [V] = 0.1 and Freq[Hz] = 1000. This section of the voltage source called Functions is used to set the initial conditions for when we look at the circuit with an O scope (voltage vs. time). It does not change the AC Sweep simulation. 10. Run the simulation and select V[in] and V[out] with the Pick Visible Traces icon if you don t see any signals in the window. If you still see the AC Sweep simulation results go back into Simulation > Edit Simulation Cmd and make sure the selected tab is Transient. You should see 10 sine waves as found in the following graphic. This is because we set the Transient simulation time to be 10 msec and the period of our sine is 1 msec. i.e. T= 1/Freq, T= 1/1000 Hz = 1 msec. Notice that the dc offset for the sine waves is ~ 1.65V which we created with our resistive divider in the circuit and that the output swings +/ 1V from this offset point due to our input being +/ 0.1V and gain = 10. Also notice that the sine waves are 180 degrees out of phase due to the inverting amplifier gain = 1 * 10.

11. If you want to look at other voltages in the circuit over time, you can select them via the Pick Visible Traces icon or you can go back to the circuit (select this window) and hold your cursor over a node in the circuit and click your mouse once. If you click twice you lose the other signals you had in the simulation O scope window and just add in the new one you double clicked on. Pretty damn nice for free software! Single Supply DC Coupled Inverting OpAmp Cheesy Filter 1. In the previous circuit simply add a 10 uf capacitor from the output (Out node) of the opamp to Gnd. 2. Chose the AC Sweep tab in Simulation > Edit Simulation Cmd and re run the simulation. You should see the following graphic. The input signal remains unchanged at 20 db (20 log [0.1V/1V] where the input 0.1V amplitude signal is referenced automatically to 1V by LT Spice). However the output now starts at the usual 0 db (20 log [1V/1V] where the output is 10 * 0.1V = 1V referenced to 1V automatically by LT

Spice) and then the output begins to attenuate due to the Cap beginning to act more like a short at higher frequencies. This is a first order low pass filter that slowly attenuates high frequencies. If you put your cursor over the output signal around 6K Hz, you will see at the bottom of the simulation window the output has attenuated ~ 3dBs. 3. Let s say you want to design a fast roll off high order low pass filter to prevent aliasing. Check out this TI link where you can plug in the parameters for the filter and they crank out the multi opamp design with all resistors & capacitors included. Texas Instrument s FilterPro tool: http://focus.ti.com/docs/toolsw/folders/print/filterpro.html#toolssoftware Other Subjects I Should Talk About When Designing/Laying Out Analog Circuits Not all capacitors are created equal. DC blocking caps should be Mylar or similar for high grade audio and at least 10uF or greater to pass signals above 20 Hz. To reduce noise we use a split plane for analog circuits for isolation from the digital circuits. Digital signals are run across the analog split plane and opto isolators can be used to keep as much digital noise as possible out of the analog planes. A/D reference pins and other voltage references require closely placed caps of various sizes (0.1, 1 & 10 uf) butted up against the reference pins. Analog power should be regulated down from a separate supply or if you use the digital supply use several sizes & types of caps across power & gnd. Ferrite beads should be used on all analog power transfer to the analog plane with several caps again between this signal and gnd on the analog plane side. Analog ground can be obtained from digital ground but it should be a single path (wire). Clocks run long distances should be done with differential line drivers to cancel phase. Gnd poly fill should be used around digital signals running across or on top of the analog plane. For low power designs use FET High Impedance opamps and keep all your resistors large (100K and up). Also don t light up any LEDs.