Download Lauren Donohoe TA: Mike Barth EE 310, Fall 2012, Section 6

Survey
yes no Was this document useful for you?
   Thank you for your participation!

* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project

Document related concepts

Control system wikipedia , lookup

Dynamic range compression wikipedia , lookup

Electronic paper wikipedia , lookup

Power inverter wikipedia , lookup

Ohm's law wikipedia , lookup

Current source wikipedia , lookup

Pulse-width modulation wikipedia , lookup

Signal-flow graph wikipedia , lookup

Islanding wikipedia , lookup

Alternating current wikipedia , lookup

Surge protector wikipedia , lookup

Two-port network wikipedia , lookup

Rectifier wikipedia , lookup

Stray voltage wikipedia , lookup

Oscilloscope history wikipedia , lookup

Power electronics wikipedia , lookup

Analog-to-digital converter wikipedia , lookup

Voltage optimisation wikipedia , lookup

Integrating ADC wikipedia , lookup

Metadyne wikipedia , lookup

Buck converter wikipedia , lookup

Mains electricity wikipedia , lookup

Voltage regulator wikipedia , lookup

Resistive opto-isolator wikipedia , lookup

Network analysis (electrical circuits) wikipedia , lookup

Current mirror wikipedia , lookup

Switched-mode power supply wikipedia , lookup

Schmitt trigger wikipedia , lookup

Opto-isolator wikipedia , lookup

Transcript
Lauren Donohoe
EE 310, Fall 2012, Section 6
Experiment 8 Lab Report
TA: Mike Barth
Partners: Codie Altvader
& Alex Camara
“Depth Sensor Interfacing Circuits for SCUBA Diver Safety”
INTRODUCTION
In class we have been learning about different applications of operational amplifiers, or op
amps. In this laboratory experiment we were asked to use op amps to design the signal conditioning and
interfacing circuitry for a SCUBA diver safety system.
As an important note, throughout this experiment we assumed that the op amps operate
ideally. Although we realize that this is not a correct assumption, for the linear circuit applications (and
for the comparator) designs in this experiment, assuming the ideal model of the op amp will give us a
pretty close approximation to the desired behavior of the conditioning circuitry.
Our designs will consist of a few different pieces. As shown in the block diagram representation
of the circuitry below, the SCUBA diver will be equipped with an IC pressure sensor. As the diver swims
farther down, the pressure increases. The pressure sensor measures this pressure and supplies a signal
indicating the pressure. Using this signal from the pressure sensor as an input, we designed the signal
conditioning circuitry which could perform three different functions, therefore creating three different
output signals (the three signals can be found on the block diagram below).
The first of these three functions that the signal conditioning circuitry performs is to provide a
linear display of pressure. The output signal of this part of the circuitry is that labeled “Pressure (kPa)”
on the block diagram below. The next of the three functions is to provide a linear display of depth in
feet. The output signal of this part of the circuitry is labeled “Depth (ft)” on the block diagram. The
circuitry for both of these first two functions includes scaling and shifting the pressure input signal using
an op amp. For both of these signals we will use a DMM to display the pressure or depth. The last part
function of the signal conditioning circuitry is to signal, by lighting an LED, when the diver has exceeded
a certain settable limit. The input to this part of the circuitry is the “Depth (ft)” signal output from the
previous part and the output for this part is labeled “Depth Limit Exceeded” on the block diagram. The
circuitry for this function of the signal conditioning includes an op amp configured as a comparator.
Figure 1:
There are a few additional specifications and constraints that were placed on our designs for the
signal conditioning circuitry. The only allowed DC voltages are a 5V and the ±15V that we use to power
the op amps. We will need the 5V source to simulate the input pressure from the sensor, so we are left
with only the ±15V for offsetting with the op amps. In addition, we are limited to only one op amp per
function, three op amps total. The last restriction is that the current through the LED should be about
15mA. (We will be using LF412 IC op amps powered by ±15V.)
CIRCUIT DESIGN AND SUPPORTING ANALYSIS
Working through the design portion of this experiment before building the circuits or taking any
measurements, we first looked at the circuit description and design specifications for each component
of the signal conditioning subsystem individually. Before designing any of the three parts, we need to
figure out how to simulate the diver’s pressure sensor.
Transfer Function of the Sensor
We do not have the actual pressure sensor that the diver will be equipped with, but we can use
one of our allowed DC voltage sources to simulate the voltage output of the pressure sensor. In order to
find the test voltages that we need to simulate the output of the pressure sensor, we have to analyze
the transfer function of the sensor.
𝑉𝑂𝑈𝑇 = 𝑉𝑆 (0.0018 𝑃𝑇𝑂𝑇𝐴𝐿 + 0.04)𝑉
This is the transfer function of the pressure sensor where VS is +5V and P is the pressure in kPa.
For the extremes of the range of pressures that we want to represent, 0 and 500 kPa, we can find the
corresponding voltage output of the pressure sensor for each.
𝑉𝑂𝑈𝑇 = 5(0.0018 ∗ 0 + 0.04)𝑉
𝑉𝑂𝑈𝑇 = 5(0.04)𝑉
𝑉𝑂𝑈𝑇 = 0.2 𝑉
𝑉𝑂𝑈𝑇 = 5(0.0018 ∗ 500 + 0.04)𝑉
𝑉𝑂𝑈𝑇 = 5(0.9 + 0.04)𝑉
𝑉𝑂𝑈𝑇 = 5(0.94)𝑉
𝑉𝑂𝑈𝑇 = 4.7 𝑉
This means that we can use the adjustable up to +5V DC power supply to simulate the range of
output voltages from the pressure sensor. The low voltage at 0.2V corresponds to a pressure of 0 kPa
and the high at 4.7V corresponds to the highest pressure in the range, 500 kPa. Now that we know how
to simulate the voltage output signal from the pressure sensor, we can use it as the input for the signal
processing circuitry that we need to design.
Signal Conditioning Circuitry
Varying the DC voltage source from 0.2V to 4.7V, we can provide the equivalent of the pressure
sensor output voltage for the 0 to 500 kPa pressure range. Using this sensor output signal (sensor
voltage, VSENS) as the input signal for our signal conditioning circuitry, we can now individually design
each of the three parts. For the first two parts, the pressure and depth indicators, VSENS will be the input
signal to the circuit. In order to put the output voltage from the pressure sensor in a suitable form for a
display, we need to manipulate the VSENS signal using an op amp to both offset and scale the voltage
range.
The Pressure Sensor
For the pressure sensor, we are asked to present the output as a range of pressures from 0 to
500 kPa, linearly corresponding to 0 to 10V. This means that we need to scale our voltage range of 0.2V
to 4.7V at the input to be 0V to 10V at the output. This voltage range will still correspond to pressures
from 0 to 500 kPa, the output 0V meaning 0 kPa and the output 10V meaning 500kPa with a linear
relation between voltage and pressure between these maximum and minimum values.
We need VSENS, the input signal to this part of the circuitry, of 0.2V to correspond to an output
voltage of 0V, and VSENS of 4.7V from the pressure sensor to correspond to an output voltage of 10V.
Using these relations, we can find the linear equation representation of the circuit that we need to
design.
Input voltage range = (4.7 – 0.2) V = 4.5V
We need to scale this to an output voltage range of 10V:
10𝑉
= 2.22
4.5𝑉
Therefore, we need a voltage gain of 2.22 V/V.
We can also see that our input voltage starts at 0.2V rather than 0V. With the gain this would
correspond to an output voltage:
0.2𝑉 ∗ 2.22
𝑉
= 0.444𝑉
𝑉
Thus, our output voltage range will be shifted 0.444V above where we want it to be, so we need
to shift it down by 0.444V. This gain and offset together provide the linear equation to represent the
circuit that we need to design in order to linearly map the input voltage range to the desired output
voltage range.
𝑉𝑂 = 2.22 𝑉𝑖𝑛 − 0.444 𝑉
𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = 2.22 𝑉𝑠𝑒𝑛𝑠 − 0.444 𝑉
In order to realize this linear equation, we need a non-inverting op amp (for the positive gain)
and we need to use either the ±15V DC source to offset the voltage. (The op amp is powered by ±15V.)
Figure 2: Schematic for Pressure Display Conditioning Circuitry
Since we are connecting the offsetting voltage at the negative terminal, we need the +15V in
order to get a negative offset at the output. Using superposition, we can individually examine the effects
of the circuit on each of the inputs, VSENS and the +15V.
Disabling VSENS and viewing the effect of +15V only, (R1 has no effect)
−
𝑅𝐹1
(+15𝑉) = 𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,1
𝑅0
Disabling the +15V and viewing the effect of VSENS only,
(1 +
𝑅𝐹1
) (𝑉 ) = 𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,2
𝑅0 ||𝑅1 𝑠𝑒𝑛𝑠
And the total,
𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = 𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,2 + 𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,1
𝑅𝐹1
𝑅𝐹1
𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = (1 +
) (𝑉𝑠𝑒𝑛𝑠 ) −
(+15𝑉)
𝑅0 ||𝑅1
𝑅0
Which we can compare to our linear equation for the circuit operation that we need to design,
𝑉𝑃𝑟𝑒𝑠𝑠𝑢𝑟𝑒 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = 2.22 𝑉𝑠𝑒𝑛𝑠 − 0.444 𝑉
And realize that we can split this up the two parts:
1+
𝑅𝐹1
𝑅0 ||𝑅1
𝑅𝐹1
𝑅0 ||𝑅1
= 2.22
−
and
𝑅𝐹1
(+15𝑉)
𝑅0
𝑅𝐹1
𝑅0
= 1.22
= − 0.444 𝑉
0.444 𝑉
= (+15𝑉) = 0.296
Solving these two equations for a set of ratios, we get:
𝑅0 = 40.1883 𝑅1
and
𝑅𝐹1 = 0.0296 𝑅0
We had to choose three resistor values that were available, were in the range where the op amp
can operate linearly, and such that they fit these two ratios. The resistors that we choose were R0 =
1MΩ, RF1 = 29.6kΩ, and R1 = 24.883kΩ. Adding these three resistor values into the schematic in Figure 2
completes our signal conditioning circuitry for the pressure sensor.
The Depth Sensor
For the Depth sensor, we are asked to present output as range of depths corresponding to the
previous pressures, as pressure and depth are directly proportional. Taking the same pressure sensor
voltage output as we did with the previous circuitry, this time we need to scale our voltage range of 0.2V
to 4.7V at the input to be 0V to -13V at the output.
Now, the 0V output will correspond to the depth at 0 kPa pressure, which does not have a great
physical meaning due to the atmospheric pressure that exists even above sea level. (The depth when
the pressure is zero will technically be negative, because rather than below the water surface, the diver
would have to be on a rocket headed for the moon. The reason this is okay is that we are using the
linear equation for pressure based on atmospheric plus underwater pressure, so these depth values will
hold physical significance only for any positive depth, any number of feet below sea level. In other
words, the depth measurement holds significance for any depth corresponding to atmospheric pressure
or greater, 101.35kPa or more.) The output -13V corresponds to the input 4.7V which indicates the
depth at which the pressure sensor measures 500kPa. Using a little diving theory we can determine this
depth:
“The total pressure on a diver is the sum of both the atmospheric pressure and the pressure
produced by the water above the diver.
So the total presssure at any depth is:
”
Going backward, for the total pressure to be 500kPa,
500 𝑘𝑃𝑎 = 101.35 𝑘𝑃𝑎 + 2.99 (
𝑘𝑃𝑎
)𝐷
𝑓𝑡
𝑘𝑃𝑎
)𝐷
𝑓𝑡
𝐷 = 133.33 𝑓𝑡
398.65 𝑘𝑃𝑎 = 2.99 (
Therefore, an output voltage from this conditioning circuitry of -13V corresponds to the diver’s
depth of 133.33 ft below sea level, which is the maximum of the range that we will be measuring. In the
range from 0V to -13V, the depth changes linearly, as the pressure changes linearly. (The difference
being that depth 0 ft below sea level occurs somewhere in the middle of the range rather than right at
the beginning, so the depth values for the beginning of the range do not hold the same physical
significance as the rest.)
For this conditioning circuitry, we need VSENS, the input signal to this part also, of 0.2V to
correspond to an output voltage of 0V, and VSENS of 4.7V from the pressure sensor to correspond to an
output voltage of -13V. Using these relations, we can again find the linear expression for the circuit that
we need to design.
Input voltage range = (4.7 – 0.2) V = 4.5V
We need to scale this to an output voltage range (magnitude) of 13V:
13𝑉
= 2.889
4.5𝑉
Therefore, we need a voltage gain of magnitude 2.889 V/V, and since we want to go from a positive
input 4.7V to a negative output -13V, we need a negative gain. Thus, the gain of this circuit is -2.889 V/V.
We can also see that our input voltage starts at 0.2V rather than 0V. With the gain this would
correspond to an output voltage:
0.2𝑉 ∗ −2.889
𝑉
= −0.5778𝑉
𝑉
Thus, our output voltage range will be shifted 0.5778V below where we want it to be, so we
need to shift it up by 0.5778V. This gain and offset together will provide the linear equation
representation of circuit that we need in order to linearly map the input voltage range to the new
desired output voltage range.
𝑉𝑂 = −2.889 𝑉𝑖𝑛 + 0.5778 𝑉
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = −2.889 𝑉𝑠𝑒𝑛𝑠 + 0.5778 𝑉
In order to realize this linear expression, this time we need an inverting op amp (for the negative
gain) and we need to use either the ±15V DC source to offset the voltage. (The op amp is again powered
by ±15V.)
Figure 3: Schematic for Depth Display Conditioning Circuitry
Since we are connecting the offsetting voltage at the negative terminal, we need the -15V in
order to get a positive offset at the output. Using superposition, we can individually examine the effects
of the circuit on each of the inputs, VSENS and the -15V.
Disabling VSENS and viewing the effect of -15V only, (R2 has no effect)
−
𝑅𝐹2
(−15𝑉) = 𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,1
𝑅3
Disabling the -15V and viewing the effect of VSENS only, (R3 has no effect)
−
𝑅𝐹2
(𝑉 ) = 𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,2
𝑅2 𝑠𝑒𝑛𝑠
And the total,
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = 𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,2 + 𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,1
𝑅𝐹2
𝑅𝐹2
(𝑉𝑠𝑒𝑛𝑠 ) −
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = −
(−15𝑉)
𝑅2
𝑅3
Which we can compare to our linear expression for the circuit operation that we need to design,
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦 = −2.889 𝑉𝑠𝑒𝑛𝑠 + 0.5778 𝑉
And realize that we can split this up the two parts:
𝑅𝐹2
𝑅2
= −2.889
𝑅𝐹2
𝑅2
= 2.889
−
and
−
𝑅𝐹2
(−15𝑉)
𝑅3
𝑅𝐹2
𝑅3
=
𝑅𝐹2 = 2.889𝑅2
0.5778 𝑉
15𝑉
= 0.5778 𝑉
= 0.03852
𝑅𝐹2 = 0.03852𝑅3
Choosing the resistor values that were available, in the range where the op amp can operate
linearly, and such that they fit these two ratios, the resistors that we choose were R2 = 13.331kΩ, R3 =
1MΩ, and RF2 = 38.5kΩ. Adding these three resistor values into the schematic in Figure 3 completes our
signal conditioning circuitry for the depth sensor.
The Depth Limit Monitor
It is not safe for a diver’s health to exceed a certain depth. This maximum depth is different for
different divers, so a depth alarm would have to be adjustable. We need to design an alarm in the form
of an LED that lights up, in order to alert the diver, when the maximum depth is exceeded. We need the
depth limit adjustable between 65 and 95 ft, and with the adjustment made and the limit preset, the
LED should be lit when the maximum depth is exceeded.
The first thing we need to do is determine the voltage values of the pressure sensor output,
then the depth display output for the indicated depths. We know that we want the limit to be adjustable
between 65 and 95 ft, but we need to know which depth display voltages these depths correspond to.
Using the same diving theory calculations as before, we had the final equation that the total pressure at
any depth D is
At 65 ft depth,
𝑘𝑃𝑎
𝑃𝑇𝑂𝑇𝐴𝐿 = 101.35 𝑘𝑃𝑎 + 2.99 (
) (65 𝑓𝑡)
𝑓𝑡
𝑃𝑇𝑂𝑇𝐴𝐿 = 101.35 𝑘𝑃𝑎 + 194.35 𝑘𝑃𝑎
𝑃𝑇𝑂𝑇𝐴𝐿 = 295.7 𝑘𝑃𝑎
Then, using the total pressure and the transfer function of the pressure sensor,
𝑉𝑂𝑈𝑇 = 𝑉𝑆 (0.0018 𝑃𝑇𝑂𝑇𝐴𝐿 + 0.04)𝑉 = 𝑉𝑠𝑒𝑛𝑠
𝑉𝑠𝑒𝑛𝑠 = 5(0.0018 ∗ 295.7 + 0.04)𝑉
𝑉𝑠𝑒𝑛𝑠 = 5(0.53226 + 0.04)𝑉
𝑉𝑠𝑒𝑛𝑠 = 5 ∗ 0.57226 𝑉
𝑉𝑠𝑒𝑛𝑠 = 2.8613 𝑉
Then, using the linear expression describing the depth display circuitry (the actual expression, not the
theoretical one described above – this equation will be found in the data and results below the designs,
but we need this equation here for more precision since we will be using the output of the depth display
circuitry for the input to the depth alarm circuitry)
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,𝑒𝑥𝑝𝑒𝑟𝑖𝑚𝑒𝑛𝑡𝑎𝑙 = −3.0329 𝑉𝑠𝑒𝑛𝑠 + 0.5722 𝑉
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,𝑒𝑥𝑝𝑒𝑟𝑖𝑚𝑒𝑛𝑡𝑎𝑙 = −3.0329 ∗ 2.8613 𝑉 + 0.5722 𝑉
𝑉𝐷𝑒𝑝𝑡ℎ 𝐷𝑖𝑠𝑝𝑙𝑎𝑦,𝑒𝑥𝑝𝑒𝑟𝑖𝑚𝑒𝑛𝑡𝑎𝑙 = −8.106 𝑉
For a depth of 65 feet below sea level, the input voltage to the depth alarm will be about -8.1V.
Using the exact same three equations as above, for a depth of 95 feet the input voltage to the depth
alarm will be about -10.55V.
The signal conditioning circuitry for this depth alarm will therefore consist of an op amp
configured as a comparator. The comparator will be comparing the depth display voltage to a set, but
adjustable value. This means that we will need a voltage ladder with a potentiometer that will produce
nodes with the two values we found above, -8.1V and -10.55V corresponding to 65 ft and 95 ft,
respectively. At the output of the op amp will be an LED, with a current limiting resistor.
A comparator powered by ±15V will provide +15V at the output if the voltage at the v + terminal
is greater than that at the v- terminal. If the voltage at the v- terminal is greater than the voltage at the v+
terminal, than the op amp will supply -15V at the output. Therefore, if we want to orient the diode such
that +15V turns the diode on, we need to put the voltage output of the depth display at the v- terminal
and the adjustable maximum voltage at the v+ terminal. This way, when voltage output from the depth
display is greater than the adjustable maximum (negative voltage), the output of the op amp is -15V,
and the LED is not lit. Only once the depth display voltage becomes less (a more negative number,
indicating a farther depth below the surface) than the adjustable maximum does the LED turn on. The
schematic for this depth alarm can be found below, followed by the calculations for the resistor values.
Figure 4: Schematic for Depth Alarm Conditioning Circuitry
We chose to use a 20kΩ potentiometer, so we had to calculate the values for R4 and R5 such that
the node voltage below the pot is -10.55V and the node voltage above the pot is -8.10V. We used
voltage division to get two different equations, each with two unknowns. Then we could find R4 and R5.
In order to find RLED we had to realize that when the LED is on, the op amp supplies +15V at its output
terminal. Taking into consideration the about 1V drop across the LED when it is on, we can find the value
of RLED using the voltage dropped across it, the specification for 15mA through the LED, and Ohm’s law.
𝑅5
(15𝑉)
𝑅5 +𝑅4 +𝑅𝑝𝑜𝑡
𝑅5
𝑅5 +𝑅4 +20𝑘Ω
= −10.55𝑉 − (−15𝑉)
=
𝑅4
(15𝑉)
𝑅5 +𝑅4 +𝑅𝑝𝑜𝑡
4.45𝑉
15𝑉
= 0 − (−8.10𝑉)
𝑅4
𝑅5 +𝑅4 +20𝑘Ω
=
8.10𝑉
15𝑉
15𝑉 ∗ 𝑅5 = 4.45𝑉 ∗ (𝑅5 + 𝑅4 + 20𝑘Ω)
15𝑉 ∗ 𝑅4 = 8.10𝑉 ∗ (𝑅5 + 𝑅4 + 20𝑘Ω)
10.55𝑉 ∗ 𝑅5 = 4.45𝑉 ∗ 𝑅4 + 89𝑘Ω ∗ 𝑉
6.9𝑉 ∗ 𝑅4 = 8.10𝑉 ∗ 𝑅5 + 162𝑘Ω ∗ 𝑉
Solving these two equations for two unknowns, 𝑅4 = 66.1224𝑘Ω and 𝑅5 = 36.3265𝑘Ω.
𝑉𝑅𝐿𝐸𝐷 = 15𝑉 − 𝑉𝐿𝐸𝐷,𝑂𝑁
𝑉𝑅𝐿𝐸𝐷 = 15𝑉 − 1.0𝑉
𝑉𝑅𝐿𝐸𝐷 = 14𝑉
𝑉𝑅𝐿𝐸𝐷 = 𝐼𝑅𝐿𝐸𝐷 ∗ 𝑅𝐿𝐸𝐷
14𝑉 = 15𝑚𝐴 ∗ 𝑅𝐿𝐸𝐷
𝑅𝐿𝐸𝐷 = 0.933𝑘Ω ≈ 1𝑘Ω
Thus, the resistors that we choose were Rpot = 20kΩ, R4 = 66.1224kΩ, R5 = 36.3265kΩ, and RLED ≈ 1kΩ.
Adding these resistor values into the schematic in Figure 4 completes our signal conditioning circuitry for
the depth alarm.
Figure 5: Schematic for All Signal Conditioning Circuitry
The circuit schematic above with the resistor values R0 = 1MΩ, R1 = 24.883kΩ, RF1 = 29.6kΩ, R2 =
13.331kΩ, R3 = 1MΩ, and RF2 = 38.5kΩ, Rpot = 20kΩ, R4 = 66.1224kΩ, R5 = 36.3265kΩ, and RLED ≈ 1kΩ
represents the signal conditioning circuitry for all three functions together.
DATA
During the lab session, we built the three different components of the signal conditioning
circuitry. As we built the circuits for the schematics provided above, we took the necessary
measurements to ensure that each of the three components was properly designed. For the pressure
and depth indicators, this necessary measurement consisted of simulating the pressure sensor output at
the input to the signal conditioning circuitry. For the range of pressure sensor voltages at the input we
had to make sure that the output voltage from the op amp matched the specifications for the design. To
test the depth alarm, we had to adjust the input voltage simulating the pressure sensor and make sure
that the LED comes on at the correct voltages for both extremes of the adjustable maximum setting.
Pressure Display Measurements
As we built the signal conditioning circuitry for the pressure display, we measured the actual
values for our resistors before we put them into place. The actual resistances were R0 = 0.988MΩ, RF =
29.4kΩ, and R1 = 23.5kΩ. Once the circuit was built, we used the DC power supply to simulate the
voltage output of the pressure sensor VSens by varying the DC voltage from 0.2V to 4.7V. We started with
0.2V and increased in small increments, each time measuring the output of the pressure display circuitry
VPressure Display. The values for both the input and the corresponding output to the signal conditioning
circuitry for the pressure display can be table below.
Figure 6: Pressure Display Measurements
Vin, VSens
Vout, VPressure Display
0.21
0.52
0.78
1.08
1.41
1.71
1.91
2.08
2.38
2.65
2.93
3.2
3.62
3.89
4.14
4.45
4.7
0.03
0.74
1.34
2.03
2.76
3.45
3.91
4.29
4.98
5.6
6.25
6.86
7.85
8.43
9.01
9.71
10.26
From these values we can see that the circuit we designed is working as we expected. For an
input range of 0.2V to 4.7V, we see a corresponding output range from about 0V to about 10V, which is
the result that we desired. In order to determine whether the circuit is performing a linear mapping for
all of the values between the minimum and maximum of the range, we have to plot the pressure display
voltage output from the circuit versus the pressure sensor output, the input to this circuit.
Figure 7: Pressure Display Graph
Pressure Display (Vo vs Vin)
12
10
y = 2.2828x - 0.4471
R² = 1
8
y = 2.22x - 0.444
6
Vout (V)
4
2
0
0
-2
0.5
1
1.5
2
2.5
Vin (V)
3
3.5
4
4.5
5
In the graph above, Figure 7, we can see the measured experimental data, in blue,
superimposed over the theoretical linear function that we used to design the circuitry. The slope of the
experimental data, 2.2828, is positive (as is that of the theoretical expression), and is close in magnitude
to the slope of the theoretical line. The experimental offset is also very close to the desired offset. (Error
analysis will be done later in the discussion of the experiment.)
From the graph, we can definitely see that the circuit we designed does linearly map the input
voltage range of 0.2V to 4.7V to the output voltage range of about 0V to 10V. This confirms that the
signal VPressure Display is now in the appropriate format to be read by the display. For a physical
understanding of this display, if a voltmeter was connected to measure VPressure Display, a reading of 0
would correspond to 0 kPa of pressure on the diver. If the voltmeter read about 10, this would
correspond to the diver’s pressure sensor reading about 500 kPa. For any reading between 0 and 10, the
pressure is linearly mapped to a value between 0 and 500kPa, and the value can be found using the
graph above.
Depth Display Measurements
Next, we built the signal conditioning circuitry for the depth display. As we built, we measured
the actual values for our resistors to be R2 = 13.5kΩ, R3 = 0.983MΩ, and RF2 = 38.7kΩ. With the circuit
built, we again used the DC power supply to simulate VSens. We varied Vsens from 0.2V to 4.7V in small
increments, each time measuring the output of the depth display circuitry VDepth Display. The measured
values for both the input and the corresponding output to the signal conditioning circuitry for the depth
display can be table below.
Figure 8: Depth Display Measurements
Vin, Vsens Vout, VDepth Display
0.2
-0.01
0.5
-0.92
0.79
-1.81
1.12
-2.81
1.45
-3.83
1.62
-4.34
1.97
-5.41
2.28
-6.37
2.59
-7.31
2.93
-8.34
3.24
-9.28
3.55
-10.22
3.79
-10.94
4.06
-11.78
4.32
-12.55
4.59
-13.38
4.7
-13.51
As shown by the measurements in this table, the circuit we designed is working as expected. For
an input range of 0.2V to 4.7V, we see a corresponding output range from about 0V to about -13V,
which is the desired result. Again we need to determine whether the circuit is performing a linear
mapping for the values between the minimum and maximum of the range. The easiest way to see this is
to plot the depth display voltage, VDepth Display versus the pressure sensor output, VSens, or in other words
the output versus the input for this specific part of the signal conditioning circuitry.
Figure 9: Depth Display Graph
Depth Display(Vo vs Vi)
0
0.5
1
1.5
2
2.5
3
3.5
4
4.5
0
-2
-4
-6
Vout (V) -8
-10
-12
y = -2.889x + 0.5778
y = -3.0329x + 0.5722
R² = 0.9999
-14
-16
Vin(V)
In Figure 9, the plot for the depth display voltages, we can again see the measured experimental
data (in blue) superimposed over the theoretical linear expression that we used to design this part of
the circuit. The slope of the experimental data, -3.0329, is negative, matching the slope of the
theoretical line. The slopes of the experimental data and the theoretical expression are close in
magnitude as well. Again, the experimental offset is very close to the desired offset. (Error analysis will
be done later – in the discussion of the experiment.)
From the plot above, it is clear that the circuit we designed linearly maps the input voltage range
of 0.2V to 4.7V to the output voltage range of about 0V to -13V. This confirms that the signal VDepth Display
is now also in the appropriate format to be read by the display. Using a second display, we could have
both a reading of pressure and depth at one time.
For a physical understanding of this display, if a voltmeter was connected to measure VDepth Display,
a reading of 0 would correspond to the depth at which there is 0 kPa of pressure on the diver. As
discussed earlier, the depth values less than a certain point at which the depth corresponds to
atmospheric pressure do not hold physical significance here. Taking “depth” to be feet below the
surface of the water, for the pressures less than atmospheric pressure (corresponding to the depths of
less than zero) the linear equation of the circuit does not hold the same physical interpretation. On the
other hand, if we are working in the range where the depth corresponds to a pressure greater than
atmospheric pressure, then for any reading until -13, the depth is linearly mapped to a pressure value
between 101.35 (atmospheric pressure) and 500kPa (which are then directly proportional to the diver’s
depth below the surface).
5
Depth Alarm Measurements
Lastly, we built the signal conditioning circuitry for the depth alarm. As we built, we measured
the actual values for our resistors. We found the actual value for our potentiometer to be a bit smaller
than expected. Using the equations that were still plugged into the calculator, we found that to keep the
equations true, we should then choose resistances slightly below the values we had calculated for R4
and R5. This taken into account, we measured our actual resistances to be Rpot = 19.0 kΩ R4 =60.8kΩ and
R5 = 29.4kΩ. Once this voltage ladder was constructed, we also measured the node voltages between
resistors. The node voltages were -10.77V and -8.09V, which was the desired result. Now, using this
voltage ladder we built the rest of the circuit (including RLED,actual = 0.943kΩ).
The test measurements that we needed to make on this circuit are different than that of the last
two. Here, the output signal that we are testing is whether or not the LED is lit. Therefore, we do not
need to measure with a DMM this time; rather we can adjust the input and simply watch the LED to see
when it turns on. From our analysis in the design of this part of the signal conditioning circuitry, we
found that a depth of 65 feet not only corresponded to VDepth Display = -8.10, but also to Vsens = 2.8613V.
Similarly, a depth of 95 feet corresponds to both VDepth Display = -10.55V and Vsens = 3.6686V.
We used these values to test whether or not the depth alarm was working properly. When the
adjustable max is set to 95 feet, when Vsens is less than about 3.7 V the LED should be off, and when Vsens
is greater than the 3.7V, the LED should turn on the warn the diver that they have exceeded the limit. At
the other extreme, when the adjustable maximum is set to 65 feet, when Vsens is less than about 2.9 V
the LED should be off, and when Vsens is greater than that 2.9V, the LED should turn on to warn the diver
that he or she has exceeded his or her limit. Throughout testing, our circuit behaved properly as
described here, so we have verified our design for the depth alarm (see signature on lab notebook
pages).
The following is a graphical representation of the depth alarm. Using the depth display voltages
as an input, when the depth is more than a certain adjustable maximum, the LED turns on to warn the
diver.
Figure 10: Graphical Representation of Depth Alarm
DISCUSSION
The result of taking all of these measurements is that we have examined and now know that the
design for each of the three components of the signal conditioning circuitry successfully provided for the
functionality that we desired. With one input signal from the diver’s pressure sensor, we were able to
design and build the signal conditioning circuitry needed for the pressure sensor input to be
manipulated into two signals appropriate for a pressure and a depth display. With this depth display
signal, we were also able to use a different op amp design, a comparator, to design and implement a
depth alarm for the SCUBA diver.
All of our designs were successful, but were not perfect. If we compare a few aspects of the
design to the specifications we were working with, we can see a few slight discrepancies. On the broad
scale, we met the specification for one op amp per function, the 15mA current through the LED, and
used only the allowed DC source voltages. Where we are slightly off was in both of our linear mappings
of the input voltage range to a new output voltage range.
First for the pressure display we wanted to take input voltages 0.2V to 4.7V and linearly map
them to a shifted and new spread of 0V to 10V. As we can see from our table of measurements, Figure
6, we got a very close output voltage range, but it was not exact. For an input, Vsens, of 0.21V, our
output, VPressure Display was 0.03V. This may have been exactly or extremely close to 0V output for exactly
0.20V input. On the other hand, at the high end of the range we were not as close. For an input, Vsens, of
4.7V, our output, VPressure Display, was 10.26V. It looks like our range may have been slightly larger than we
wanted. While this range was only very slightly off from the specifications, the range of voltages for the
depth display was farther off spec.
For the depth display we wanted to again take the same input voltages 0.2V to 4.7V but this
time linearly map them to a shifted and new spread of 0V to -13V. This time looking at Figure 8, our
table of measurements for the depth display circuitry, we again measured a close but not exact output
range. For an input, Vsens, of 0.20V, our output, VPressure Display, was -0.01V. As we can see this is not very
far off from the desired 0V, but it again is not exact. This means that our offset was ever so slightly too
large because we moved this value down a tiny bit too far. At the high end of the range, for an input,
Vsens, of 4.7V, our output, VPressure Display, was -13.51V. This means that for this design, our range also
ended up being larger than we desired. Again this experimental range is not terribly far off, but is still
not exactly as the specifications called for.
An easier way to compare the desired operation to the measured results is to compare the
theoretical linear expression that we calculated based on the specifications to the measured linear
expression from the plot of the measurement results. For the pressure display, the equations were
Theoretical: Vsens = 2.22Vin – 0.444
Measured: Vout = 2.2828Vsens -0.4471.
We can compare both the slopes and the y-intercepts of these two lines. We can see by
inspection that it does in fact look like the measured expression could definitely be an attempt to design
the theoretical with some errors in both the design and measurements.
For slopes: % 𝐸𝑟𝑟𝑜𝑟 =
% 𝐸𝑟𝑟𝑜𝑟 =
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙−𝑀𝑒𝑎𝑠𝑢𝑟𝑒𝑑|
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙|
|2.22−2.2828|
∗
|2.22|
100% =
∗ 100%
0.0628
∗ 100%
2.22
% 𝐸𝑟𝑟𝑜𝑟 = 0.0283 ∗ 100% = 2.83%
For y-intercepts: % 𝐸𝑟𝑟𝑜𝑟 =
% 𝐸𝑟𝑟𝑜𝑟 =
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙−𝑀𝑒𝑎𝑠𝑢𝑟𝑒𝑑|
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙|
|0.444−0.4471|
∗ 100%
|0.444|
=
0.0031
∗
0.444
∗ 100%
100%
% 𝐸𝑟𝑟𝑜𝑟 = 0.00137 ∗ 100% = 0.137%
Comparing both the slopes and intercepts of the theoretical expression to the measured
expression, the largest amount of error was in the gain of the circuit. We can use this concept to
compare the theoretical to the measured values for the depth display as well. For the depth display, the
equations were
Theoretical: Vsens = -2.889Vin + 0.5778
Measured: Vout = -3.0329Vsens + 0.5722.
Comparing both the slopes and the y-intercepts of these two lines, simply looking at the two
expressions, it looks like the measured expression could be an attempt to design the theoretical with
some errors.
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙−𝑀𝑒𝑎𝑠𝑢𝑟𝑒𝑑|
For slopes: % 𝐸𝑟𝑟𝑜𝑟 =
∗ 100%
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙|
% 𝐸𝑟𝑟𝑜𝑟 =
|−2.889−3.0329|
∗
|2.889|
100% =
0.1439
∗
2.889
100%
% 𝐸𝑟𝑟𝑜𝑟 = 0.0498 ∗ 100% = 4.98%
For y-intercepts: % 𝐸𝑟𝑟𝑜𝑟 =
% 𝐸𝑟𝑟𝑜𝑟 =
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙−𝑀𝑒𝑎𝑠𝑢𝑟𝑒𝑑|
|𝑇ℎ𝑒𝑜𝑟𝑒𝑡𝑖𝑐𝑎𝑙|
|0.5778−0.5722|
∗
|0.5778|
∗ 100%
0.0056
100% = 0.5778 ∗ 100%
% 𝐸𝑟𝑟𝑜𝑟 = 0.00969 ∗ 100% = 0.969%
Comparing both the slopes and intercepts of the theoretical expression to the measured
expression, we can see a similar pattern to that of the pressure display. Again our intercept is within 1%
error and the measured slope has a slightly greater error. Some of the possible sources of this error
could be coming from both the design and the measurements. For these measurements, we were using
the new DMMs, so there should not be as much error in our measurements from the equipment as
usual. This means that there must be some shortcoming of our design. If we think back to when we
started designing, we made an assumption that the op amp was ideal. All of our designs have resistor
values and all other aspects chosen based on the ideal model of the op amp. As we all know, the op amp
is not actually an ideal device. This was probably the largest source of error in our design, and what was
causing our theoretical and measured expressions to differ and our voltage ranges to be very slightly off
specification.
The only part of the circuitry we designed that we have not considered is the depth alarm.
Theoretically, we wanted to match the specification of having an adjustable maximum, and making the
LED turn on when the diver has exceeded this maximum. We successfully built a voltage ladder with the
values the comparator needs to compare the input signal to for both 65 and 95 feet maximum settings.
The error from the depth display will propagate itself through to the depth alarm also since we are using
the depth display output as the input to the alarm. We demonstrated in class that the LED does in fact
turn on at a value close to the input voltage that we expected, but it was hard to pin down an exact
value as our measurement technique included turning the very sensitive dial on the DC supply.
SUMMARY AND CONCLUSIONS
In summary, the signal conditioning circuitry takes the input signal from the diver’s pressure
sensor and manipulates the signal into a usable form for both a pressure display and a depth display.
Using the depth display circuitry output signal, we also designed a comparator with a potentiometer
voltage ladder on one terminal of the op amp to provide an adjustable maximum depth limit alarm
system that lights an LED when the diver has exceeded his or her maximum depth. Now, the diver that
only was equipped with a pressure sensor will be able to read digital indicators of both the pressure and
depth that he is diving to, and in case he swims too deep, he will also be equipped with an LED alarm
that will light to indicate he has gone too far.
The only thing that I would do differently if I did this experiment again is that it may have been
easier and created less error in the depth alarm to use the pressure sensor output rather than the depth
display output as the input to the depth alarm. The way we designed our circuitry with the depth display
output as the input to the depth alarm, the error from the depth display conditioning circuitry
propagates through to the depth alarm. If we had used the pressure sensor voltage output as the input
to our depth alarm, this extra error would not be in the depth alarm, which would be better for the
diver. (Having less error in the alarm that is keeping him or her safe from exceeding his or her maximum
depth will be safer for the diver.) In addition, if the op amp for the depth display had some sort of a
meltdown or anything else in the depth display circuitry malfunctioned, having the alarm still work
based on only the pressure sensor output would also be better for the diver’s health.
This experiment was my favorite by far, so far this semester. I liked it because rather than being
given specific step by step type instructions and following along, we were given a problem and asked to
solve it without much instruction. In this experiment, I learned how to use an op amp to offset the
voltage at the input. I had already known how to design ideal op amps for different gains, but I had not
used them for both a gain and a shift at the same time. Although I did not learn much new material in
this lab, I really enjoyed the experience at taking a problem like this and designing a solution from
scratch.