High Profile Call Girls Dahisar Arpita 9907093804 Independent Escort Service ...
Lab 7 Report Voltage Comparators and Schmitt Triggers
1. 1
Katrina Little
Electronics II
Lab #7: Voltage Comparators and Schmitt Triggers
Goals:
To introduce the concepts of using an operational amplifier as a voltage comparator. The
theory of voltage comparator will be presented along with the design of several comparator
circuits. The Schmitt trigger comparator will be presented.
Equipment:
Oscilloscope: DPO 4034B
Function Generator: AFG3022B
Triple Power supply
Capacitors available in the laboratory
Resistors available in the laboratory
Multimeter
TL084 Operational Amplifier
LM 393 Comparator
Pre-Laboratory:
Read this laboratory experiment carefully to become familiar with the background and the
procedural steps in this experiment. Carefully read each section and become familiar with the
equations for each circuit.
Using the simulation package of your choice in which you are the most familiar with: Mulitsim,
Workbench or LTSpice IV simulate the linear regulator of Figure 2.
A. Download the National Semiconductor LM393 voltage comparator datasheet and
become familiar with this part.
B. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, simulate the
comparator circuit of Figure 3.
C. Use a 10 volts peak 500 Hz triangle waveform for the input Vin (DC offset =0 volts).
2. 2
D. Plot Vout as a function of time for Vref = 1volt.
E. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
When Vin = 1.095 V, Vout changes from +Vcc to –Vcc
F. Repeat Steps b - e for Vref = 2 volts, 5 volts and 8 volts.
Vref = 2 V: R1 = 1kΩ, R2 = 6.5kΩ
3. 3
When Vin = 1.605 V, Vout changes from +Vcc to –Vcc
Vref = 5 V: R1 = 1kΩ, R2 = 2kΩ
When Vin = 4.624V Vout changes from +Vcc to –Vcc
Vref = 8 V: R1 = 8kΩ, R2 = 7kΩ
4. 4
When Vin = 7.655 V, Vout changes from +Vcc to –Vcc
G. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, simulate the
comparator circuit of Figure 4.
H. Use a 10 volts peak 500 Hz triangle waveform for the input Vin (DC offset =0 volts).
I. Plot Vout as a function of time for Vref = 1 volt.
VRef = 1 V: R1 = 1kΩ, R2 = 14kΩ
5. 5
J. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
When Vin = 1.405 V, Vout changes from +Vcc to –Vcc
K. Repeat Steps g - j for Vref = 2 volts, 5 volts and 8 volts.
Vref = 2 V: R1 = 1kΩ, R2 = 6.5kΩ
When Vin = 2.321 V, Vout changes from +Vcc to –Vcc
Vref = 5 V: R1 = 1kΩ, R2 = 2kΩ
6. 6
When Vin = 5.144 V Vout changes from +Vcc to –Vcc
Vref = 8 V: R1 = 8kΩ, R2 = 7kΩ
When Vin = 8.360 V, Vout changes from +Vcc to –Vcc
L. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, simulate the
comparator circuit of Figure 8.
M. Let R2 =10k and R1 =1k.
N. Use a 5 volts peak 500 Hz triangle waveform for the input Vin (DC offset =0 volts).
7. 7
O. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
Vo is +Vcc when Vref is connected to –Vcc which is evident by equation (13)
When Vin = -1.459V Vout changes from +Vcc to –Vcc
P. Plot Vout as a function of time.
8. 8
Q. Determine Vout max and Vout min. Replace +Vcc with Vout max and -Vcc with Vout min
in Equations (22) - (25).
Vout max = 13.477 V and Vout min = -13.478 V
Our calculated values were then substituted into the given equations.
Vout = +Vcc when Vin > -Vcc(R1/(R1+R2)) → Vin> -1.348 V
Vout = -Vcc when Vin < +Vcc(R1/(R1+R2)) → Vin < 1.348 V
Vout(+Vcc→Vcc) when Vin < -Vcc(R1/(R1+R2)) → Vin < -1.348 V
Vout(-Vcc→+Vcc) when Vin > +Vcc(R1/(R1+R2)) → Vin > 1.348 V
R. Compare the Equations (22) - (25) with Step o.
When comparing values we were off by a few mV’s.
S. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, simulate the
comparator circuit of Figure 12.
T. Let R2 =10k and R1 =1k.
U. Use a 5 volts peak 500 Hz triangle waveform for the input Vin (DC offset =0 volts).
9. 9
V. Determine the voltage, Vin, where Vout switches from +Vcc to -Vcc.
When Vin = 1.346 V, Vout changes from +Vcc to –Vcc
W. Plot Vout as a function of time.
X. Determine Vout max and Vout min. Replace +Vcc with Vout max and -Vcc with Vout min
in Equations (30) - (33).
Vout max = 13.477 V and Vout min = -13.478 V
10. 10
Our calculated values were then substituted into the given equations.
Vout = +Vcc when Vin > -Vcc(R1/(R1+R2)) → Vin> -1.348 V
Vout = -Vcc when Vin < +Vcc(R1/(R1+R2)) → Vin < 1.348 V
Vout(+Vcc→Vcc) when Vin < -Vcc(R1/(R1+R2)) → Vin < -1.348 V
Vout(-Vcc→+Vcc) when Vin > +Vcc(R1/(R1+R2)) → Vin > 1.348 V
Y. Compare the Equations (30) - (33) with Step v.
The results are very close and are only a few mV’s apart.
Z. Simulate the pulse width modulator circuit of Figure 14.
AA.Use a 0 to 10 volt 1000 Hz sawtooth waveform. Vary Vin from 0 to 10 volts (0, 1, 2, 5, 8,
and 10 volts) and measure T1 the time Vout = +Vcc.
Voltage
(V)
Time difference
(µs)
0 0
1 17.9
2 42.7
5 109.2
8 190.1
10 236.6
11. 11
BB. Plot T1 versus Vin.
CC. Compare Step bb to Equation (36) with T=0.001 sec and K 10 volts.
Voltage
(V)
Time difference
(Sec)
0 0
1 0.0001
2 0.0002
5 0.0005
8 0.0008
10 0.001
The Time difference is greater than our calculated values from this step.
Procedure:
General Setup:
1. Record the model and serial number of the scope, power supply, multimeter and
function generator used in laboratory experiment.
2. Download the datasheet for the LM393 comparator. This will be needed to obtain the
pin-out of the comparator. When comparing datasheet data values to experimental data
use the typical values in the datasheet if given.
12. 12
3. When measuring any values make sure to measure all inputs as well as the output of the
circuit. Do not rely on the values indicated on the instruments. Always measure all signal
values.
4. Before turning any power on double check the wiring to make sure that it is correct.
5. Measure all resistors that are used in the amplifier circuits using the multimeter and
record these values.
6. Use all measured values to determine experimental results such as gain and current.
7. Comparing data means to calculate the percent difference between two values. For
example, theoretical values versus measured values.
8. Comparing data graphically means to plot the data on the same plot to see how the data
overlaps.
Comparator Circuits:
1. Build Download the National Semiconductor LM393 voltage comparator datasheet and
become familiar with this part.
2. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, build the
comparator circuit of Figure 3.
3. Use a 20 volt peak-to-peak 500 Hz triangle waveform for the input Vin (DC offset =0
volts).
4. Plot Vout as a function of time for Vref = 1volt using an oscilloscope.
13. 13
5. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
Vin = 997.7mV
6. Repeat Steps 3 - 5 for Vref = 2 volts and 8 volts.
(OMIT)
7. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, build the
comparator circuit of Figure 5.
14. 14
8. Use a 20 volt peak-to-peak 500 Hz triangle waveform for the input Vin (DC offset =0
volts).
9. Plot Vout as a function of time for Vref = 1volt using an oscilloscope.
10. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
Vin = 1V
11. Repeat Steps 8 - 10 for Vref = 2 volts and 8 volts.
(OMIT)
12. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, build the
comparator circuit of Figure 10.
15. 15
13. Let R2 =10k and R1 =1k.
14. Use a 10 volt peak-to-peak 500 Hz triangle waveform for the input Vin (DC offset =0
volts).
15. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
Vin = 1.3 V
16. Plot Vout as a function of time using an oscilloscope.
17. Determine Vout max and Vout min from the oscilloscope traces. Replace +Vcc with Vout
max and -Vcc with Vout min in Equations (22) - (25).
16. 16
V
V
V
V
18. Compare the Equations (22) - (25) with Step 15.
Comparing equations from the data collected from the oscilloscope we are a few mV’s
off.
19. Using an op-amp with +Vcc set to +15 volts and -Vcc set to -15 volts, build the
comparator circuit of Figure 12.
17. 17
20. Let R2 =10k and R1 =1k.
21. Use a 10 volt peak-to-peak 500 Hz triangle waveform for the input Vin (DC offset =0
volts).
22. Determine the voltage Vin where Vout switches from +Vcc to -Vcc.
Vin = 1 V
23. Plot Vout as a function of time using an oscilloscope.
24. Determine Vout max and Vout min from the oscilloscope traces. Replace +Vcc with Vout
max and -Vcc with Vout min in Equations (30) - (33).
18. 18
V
V
V
V
25. Compare the Equations (30) - (33) with Step 22.
Comparing equations from the data collected from the oscilloscope we are a few mV’s
off on the Vout max but we are off almost half a volt on the Vout min but that is
probably due to bad measuring on the oscilloscope.
26. Repeat steps 2-5 and steps 7-10 using the LM393 comparator with around a 2k pull-up
resistor.
Steps 2-5
20. 20
Vin = 1.223 V
27. Build the pulse width modulator circuit of Figure 14.
21. 21
28. Use a 0 to 10 volt 1000 Hz saw tooth waveform. Vary Vin from 0 to 10 volts (0, 2, 4, 8,
and 10 volts) and measure T1 the time Vout = +Vcc.
Voltage (V) Time difference (sec)
0 0
2 207.3 µ
4 403.2 µ
8 803.2 µ
10 1.019 m
29. Plot T1 versus Vin.
0
0.0002
0.0004
0.0006
0.0008
0.001
0.0012
0 2 4 6 8 10 12
Voltage
25. 25
30. Compare Step 29 to Equation (36) with T=0.001 sec and K 10 volts.
Voltage
(V)
Time difference
(sec)
0 0
2 0.0002
4 0.0004
8 0.0008
10 0.0010
The numbers we obtained from our data are nearly identical from the data we
collected during the pre-lab.
Conclusion:
Experiment 7 teaches us how the concepts of using an operational amplifier as a voltage
comparator. We are taught the theory behind the voltage comparator and multiple circuit designs with
operational amplifiers that can be used as voltage comparators. These concepts build on our previous
experiments as we already have a solid background in operational amplifiers now. We are taught when
we need to use voltage comparisons and how regularly they are actually used in circuit design and in
real world applications. We are also asked to design a circuit using an actual voltage comparator
component LM393. We are also taught what a Schmitt trigger is and how it uses the phenomena
hysteresis. We also were taught and then designed a pulse width modulator with the main component
being the voltage comparator.
When looking at our results and verifying them with our data collected in the pre-lab we can
come to the conclusion that our circuit design results are fairly accurate. Especially accounting for the
most common losses and not a hypothetically idea situation.