Wiki

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
university:courses:electronics:electronics-lab-1 [24 May 2017 13:58] – remove adisim simulations Antoniu Miclausuniversity:courses:electronics:electronics-lab-1 [03 Nov 2021 20:25] (current) – [Activity 1. Simple Op Amps] Doug Mercer
Line 1: Line 1:
-====== Activity 1. Simple Op Amps ======+====== ActivitySimple Op Amps, For ADALM2000======
  
 ===== Objective: ===== ===== Objective: =====
Line 49: Line 49:
 === Procedure: === === Procedure: ===
  
-Use the first waveform generator as source Vin to provide a 1V amplitude (2 Vp-p), 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.Export a plot of the two resulting waveforms and include it your lab report, noting the parameters of the waveforms (peak values and the fundamental time-period or frequency). Your waveforms should confirm the description of this as a “unity-gain” or “voltage follower” circuit.+Use the first waveform generator as source Vin to provide a 2V amplitude peak-to-peak, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.Export a plot of the two resulting waveforms and include it your lab report, noting the parameters of the waveforms (peak values and the fundamental time-period or frequency). Your waveforms should confirm the description of this as a “unity-gain” or “voltage follower” circuit.
  
 A plot example is presented in Figure 1.4. A plot example is presented in Figure 1.4.
Line 65: Line 65:
 <WRAP centeralign> Figure 1.5 Slew Rate </WRAP> <WRAP centeralign> Figure 1.5 Slew Rate </WRAP>
  
-Set the waveform generator to a square wave signal with a 1V amplitude (2 Vp-p) and increase the frequency until you see a significant departure from ideal behavior, that is, when the output starts looking more like a trapezoid than a square wave. You will likely need to adjust the time scale (Sec/Div) on the scope display to see this. Export a plot of the output waveforms at this point and measure its 10-90% rise time (and 90-10% fall time) as defined in figure 1.5. Also note the peak-to-peak voltage of the output signal. Compute and record the slew rate for both rising and falling outputs according to your measurements. Comment on why the response to rising and falling edges might be different.+Set the waveform generator to a square wave signal with a 2V amplitude peak-to-peak and increase the frequency until you see a significant departure from ideal behavior, that is, when the output starts looking more like a trapezoid than a square wave. You will likely need to adjust the time scale (Sec/Div) on the scope display to see this. Export a plot of the output waveforms at this point and measure its 10-90% rise time (and 90-10% fall time) as defined in figure 1.5. Also note the peak-to-peak voltage of the output signal. Compute and record the slew rate for both rising and falling outputs according to your measurements. Comment on why the response to rising and falling edges might be different.
  
 A waveform that exemplifies the slew rate is presented in figure 1.6. A waveform that exemplifies the slew rate is presented in figure 1.6.
Line 83: Line 83:
 Turn off the power supplies and add the resistors to your circuit as shown in figure 1.7 (note we have not changed the op-amp connections here, we’ve just flipped the op-amp symbol relative to figure 1.2). Turn off the power supplies and add the resistors to your circuit as shown in figure 1.7 (note we have not changed the op-amp connections here, we’ve just flipped the op-amp symbol relative to figure 1.2).
  
-Turn on the power supplies and set the waveform generator to a 1 kHz sine signal with a 2 V amplitude (4 V p-p). Use the scope to simultaneously observe Vin and Vout and record the amplitudes in your lab report.+Turn on the power supplies and set the waveform generator to a 1 kHz sine signal with a 4V amplitude peak-to-peak. Use the scope to simultaneously observe Vin and Vout and record the amplitudes in your lab report.
  
 Remove the 10 kΩ load and substitute a 1 kΩ resistor instead. Record the amplitude. Remove the 10 kΩ load and substitute a 1 kΩ resistor instead. Record the amplitude.
Line 105: Line 105:
 Now assemble the inverting amplifier circuit shown in figure 1.9 using R<sub>2</sub> = 4.7kΩ . Remember to shut off the power supply before assembling a new circuit. Cut and bend the resistor leads as needed to keep them flat against the board surface, and use the shortest jumper wires for each connection (as in figure 1.1). Remember, the breadboard gives you a lot of flexibility. For example, the leads of resistor R<sub>2</sub> do not necessarily have to bridge over the op amp from pin 2 to pin 6; you could use an intermediate node and a jumper wire to go around the device instead. Now assemble the inverting amplifier circuit shown in figure 1.9 using R<sub>2</sub> = 4.7kΩ . Remember to shut off the power supply before assembling a new circuit. Cut and bend the resistor leads as needed to keep them flat against the board surface, and use the shortest jumper wires for each connection (as in figure 1.1). Remember, the breadboard gives you a lot of flexibility. For example, the leads of resistor R<sub>2</sub> do not necessarily have to bridge over the op amp from pin 2 to pin 6; you could use an intermediate node and a jumper wire to go around the device instead.
  
-Turn on the power supplies and observe the current draw to be sure there are no accidental shorts. Now adjust the waveform generator to produce a volt amplitude, 1 kHz sine wave at the input (Vin), and again display both the input and output on the oscilloscope. Measure and record the voltage gain of this circuit, and compare to the theory that was discussed in class. Export a plot of the input/output waveforms to be included your lab report.+Turn on the power supplies and observe the current draw to be sure there are no accidental shorts. Now adjust the waveform generator to produce a volt amplitude peak-to-peak, 1 kHz sine wave at the input (Vin), and again display both the input and output on the oscilloscope. Measure and record the voltage gain of this circuit, and compare to the theory that was discussed in class. Export a plot of the input/output waveforms to be included your lab report.
  
 {{:university:courses:electronics:inverting_amp-bb.png|}} {{:university:courses:electronics:inverting_amp-bb.png|}}
Line 115: Line 115:
 === Procedure: === === Procedure: ===
  
-Use the first waveform generator as source Vin to provide a 1V amplitude, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.+Use the first waveform generator as source Vin to provide a 2V amplitude peak-to-peak, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.
  
 A plot example is presented in Figure 1.10. A plot example is presented in Figure 1.10.
Line 140: Line 140:
 With the power turned off, modify your inverting amplifier circuit as shown in figure 1.12. Use the second waveform generator output for Vin2. Turn the amplitude all the way down to zero so that you can adjust up from zero during the experiment. With the power turned off, modify your inverting amplifier circuit as shown in figure 1.12. Use the second waveform generator output for Vin2. Turn the amplitude all the way down to zero so that you can adjust up from zero during the experiment.
  
-Now apply a volt amplitude sine wave for Vin1 and 1 volts DC for Vin2. Observe and record the input/output waveforms on the oscilloscope screen. Pay close attention to the ground signal level of the output channel on the oscilloscope screen. When used in this way, such a circuit could be called a level shifter.+Now apply a volt amplitude peak-to-peak sine wave for Vin1 and 1 volts DC for Vin2. Observe and record the input/output waveforms on the oscilloscope screen. Pay close attention to the ground signal level of the output channel on the oscilloscope screen. When used in this way, such a circuit could be called a level shifter.
  
 Adjust the DC offset of waveform generator W1 (Vin1) until Vout has zero DC component. Estimate the required DC offset by observing the input waveform on the scope (note: it is not Vin2 , be sure to understand why). Adjust the DC offset of waveform generator W1 (Vin1) until Vout has zero DC component. Estimate the required DC offset by observing the input waveform on the scope (note: it is not Vin2 , be sure to understand why).
Line 154: Line 154:
 === Procedure: === === Procedure: ===
  
-Use the first waveform generator as source Vin to provide a 1V amplitude, 1 kHz sine wave excitation to the circuit. The second waveform generator is used to generate 1V constant voltage. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.+Use the first waveform generator as source Vin to provide a 2V amplitude peak-to-peak, 1 kHz sine wave excitation to the circuit. The second waveform generator is used to generate 1V constant voltage. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.
  
 A plot example is presented in Figure 1.13. A plot example is presented in Figure 1.13.
Line 176: Line 176:
 Assemble the non-inverting amplifier circuit shown in figure 1.15. Remember to shut off the power supplies before assembling the new circuit. Start with R<sub>2</sub> = 1kΩ. Assemble the non-inverting amplifier circuit shown in figure 1.15. Remember to shut off the power supplies before assembling the new circuit. Start with R<sub>2</sub> = 1kΩ.
  
-Apply a volt amplitude, 1 kHz sine wave at the input, and display both input and output on the scope. Measure the voltage gain of this circuit, and compare to the theory discussed in class. Export a plot of the waveforms and include it in your lab report.+Apply a volt amplitude peak-to-peak, 1 kHz sine wave at the input, and display both input and output on the scope. Measure the voltage gain of this circuit, and compare to the theory discussed in class. Export a plot of the waveforms and include it in your lab report.
  
 Increase the feedback resistor (R<sub>2</sub>) from 1 kΩ to about 5 kΩ. What is the gain now? Increase the feedback resistor (R<sub>2</sub>) from 1 kΩ to about 5 kΩ. What is the gain now?
Line 189: Line 189:
  
 === Procedure: === === Procedure: ===
-Use the first waveform generator as source Vin to provide a 1V amplitude, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.+Use the first waveform generator as source Vin to provide a 2V amplitude peak-to-peak, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1.
  
 A plot example is presented in Figure 1.16. A plot example is presented in Figure 1.16.
Line 196: Line 196:
  
 <WRAP centeralign> Figure 1.16. Non-Inverting Amplifier Waveforms </WRAP> <WRAP centeralign> Figure 1.16. Non-Inverting Amplifier Waveforms </WRAP>
- 
-===== 1.3 Using an Op-Amp as a Comparator ===== 
- 
-=== Background: === 
- 
-The high intrinsic gain of the op-amp and the output saturation effects can be exploited by configuring the op-amp as a comparator as in figure 1.17. This is essentially a binary-state decision-making circuit: if the voltage at the “+” terminal is greater than the voltage at the “-” terminal, Vin > Vref , the output goes “high” (saturates at its maximum value). Conversely if Vin < Vref the output goes “low”. The circuit compares the voltages at the two inputs and generates an output based on the relative values. Unlike all the previous circuits there is no feedback between the input and output; we say that the circuit is operating “open-loop”. 
- 
-{{ :university:courses:electronics:a1_f1-8.png?500 |}} 
- 
-<WRAP centeralign> Figure 1.17 Op-Amp as Comparator </WRAP> 
- 
- 
- 
-=== Hardware Setup: === 
- 
-Comparators are used in different ways, and in future sections we will see them in action in several labs. Here we will use the comparator in a common configuration that generates a square wave with a variable pulse width: 
- 
-Start by shutting off the power supplies and assemble the circuit. As with the summing amplifier circuit earlier, use the second waveform generator output for the DC source Vref , and turn the amplitude to zero and the output offset all the way down so that you can adjust up from zero during the experiment. 
- 
-Again configure the waveform generator Vin for a 2V amplitude sine wave at 1 kHz. With the power supply on and Vref at zero volts, export the output waveform. 
- 
-Now slowly increase Vref and observe what happens. Record the output waveform for Vref = 1V. Keep increasing Vref until it exceeds 2V and observe what happens. Can you explain this? 
- 
-Repeat the above for a triangular input waveform and record your observations for your lab report. 
- 
-{{:university:courses:electronics:comp_amp-bb.png|}} 
- 
-<WRAP centeralign> Figure 1.18. Comparator Breadboard Circuit </WRAP> 
- 
-=== Procedure: === 
- 
-Use the first waveform generator as source Vin to provide a 1V amplitude, 1 kHz sine wave excitation to the circuit. Configure the scope so that the input signal is displayed on channel 2 and the output signal is displayed on channel 1. 
- 
-A plot example is presented in Figure 1.19. 
- 
-{{:university:courses:electronics:comp_amp-waveform.png|}} 
- 
-<WRAP centeralign> Figure 1.19. Comparator Waveforms </WRAP> 
- 
-==== Extra Credit ==== 
- 
-For experimenters who finish early or want an additional challenge, see if you can modify the comparator circuit using your red and green LEDs (from the last lab) at the output so that the red LED lights for negative voltages and the green LED lights for positive voltages. Turn down the frequency to 1Hz (or less) so you can see them turn on-and-off in real time. Don’t forget that the LEDs will need a current-limiting resistor so that the current through it is no more than 20mA. 
  
 === Congratulations! You have now completed Lab Activity 1 === === Congratulations! You have now completed Lab Activity 1 ===
Line 249: Line 207:
 ■ Slew rate: discuss how you measured and computed the slew rate in the unity-gain buffer configuration, and compare this with the value listed in the OP97 data sheet. ■ Slew rate: discuss how you measured and computed the slew rate in the unity-gain buffer configuration, and compare this with the value listed in the OP97 data sheet.
  
-■ Buffering: explain why the buffer amplifier in figure 1.allowed the voltage divider circuit to function perfectly with differently load resistances.+■ Buffering: explain why the buffer amplifier in figure 1.allowed the voltage divider circuit to function perfectly with differently load resistances.
  
 ■ Output saturation: explain your observations of output voltage saturation in the inverting amplifier configuration and your estimate of the internal voltages drops. How close does the output come to the supply rails in this experiment and also later when used as a comparator with different power-supply voltages? Can you guess what the output voltage swing would be for an op-amp that is advertised as a “rail-to-rail” device? ■ Output saturation: explain your observations of output voltage saturation in the inverting amplifier configuration and your estimate of the internal voltages drops. How close does the output come to the supply rails in this experiment and also later when used as a comparator with different power-supply voltages? Can you guess what the output voltage swing would be for an op-amp that is advertised as a “rail-to-rail” device?
Line 256: Line 214:
  
 ■ Comparator: discuss your measurements and what would happen if the polarity of Vref is reversed ■ Comparator: discuss your measurements and what would happen if the polarity of Vref is reversed
 +\\
 +\\
 +<WRAP round download>
 +**Resources:**
 +  * Fritzing files: [[downgit>education_tools/tree/master/m2k/fritzing/simple_op_amps_bb | opamp_bb]]
 +  * LTSpice files: [[downgit>education_tools/tree/master/m2k/ltspice/opamp_ltspice | opamp_ltspice]]
 +</WRAP>
 +
 +**Continue to next Op Amp Lab Activity: [[university:courses:electronics:electronics-lab-opamp-comparator|Op Amp as Comparator]]**
  
-**Return to Lab Activity [[university:courses:electronics:labs|Table of Contents]]**+**More on Op Amps in amplifier configuration: [[university:courses:electronics:electronics-lab-variable-gain-amplifier|Variable Gain Amplifiers]]** 
 +\\ 
 +\\ 
 +**Return to Lab Activity[[university:courses:electronics:labs|Table of Contents]]**
  
university/courses/electronics/electronics-lab-1.txt · Last modified: 03 Nov 2021 20:25 by Doug Mercer