\
Sensors and Transducers
Sensors are transducers used to obtain information about the outside world
Terminology that might appear in specs of a sensor:
range = limits between which input can vary
span = max val - min val
error = measured val - true val
accuracy = a range for the error, often expressed as a % of full scale.
sensitivity = ratio of delta out / delta in (e.g., 0.5 ohm/degree C)
hysteresis error = error due to hysteresis
What is Hysteresis?
non-linearity error
repeatability/reproducibility - same input may give different outputs
at different times.
repeatability = ((maxval - minval)/fullrange) x 100
stability = steadyness of output when input is held constant
drift = change in output over time (constant input)
zero drift = change in output when input = zero
dead band = range of input vals that produce no output
dead time = time lag between change in input and response in output
resolution = smallest change in input that produces an observable change
in output
output impedance
Example: specs for a strain gauge pressure transducer
ranges: 70 to 1000 kPa, 2000 to 70000 kPa (kiloPascals, about 1/101th atm)
supply voltage: 10 V d.c. or a.c. r.m.s.
full range output: 40 mV
non-linearity and hysteresis: +- 0.5% full range output
temperature range -54 degree C to +120 degree C when operating
thermal zero shift: 0.030% full range output/ degree C
(when temp changes by 1 degree C, output for zero input changes
by this amount)
static characteristics = values for steady-state conditions
dynamic characteristics = values characterizing behavior when conditions
change
response time = time needed for transducer to respond to step input;
time from step to when output reaches n % of steady-state output
(n often = 95)
time constant = 63.2% response time
rise time = time taken for output to rise some specified %age of
steady-state output. Often, time for rise from 10% to 90 or 95% of
steady-state value.
settling time = time taken for output to settle to within some %age
of steady-state value. E.g., with 2% of s.-s. value
Sensor types
Displacement, position, proximity sensors
Potentiometer - rotary and linear
Secret Life of Pots
The Humble Potentiometer
Linear potentiometers
Let Rp = resistance of pot
RL = resistance of load
x = fractional position of slider
Vs = source voltage
VL = output voltage
VL / Vs = x / ((Rp / RL) x (1 - x) + 1)
If RL = infinity, VL = x Vs. Output is linear.
Error = x Vs - VL = Vs (Rp / RL) (x^2 - x^3) (non-linearity error)
Strain gauge - can be made of thin wire, metal foil, semiconductor,
conductive plastic foam
How they work
the strain gage
Delta R / R = G e
where G = gauge factor, e(epsilon) = strain
Typically, G = 2 for wire and foil, +/- 100 for semiconductors
Capacitive element - plates can move away from each other, by each other,
or dielectric can slide from between them
Let A = area of plate overlap
d = distance between plates
C = capacitance
C = er e0 A / d
where er(epsilon r) = relative permittivity of
dielectric, e0(epsilon 0) = permittivity of free space
If plates move away from each other, C is a non-linear function
of displacement:
C = er e0 A / (d + x)
If three plates are used to form two capacitors (two outer plates
fixed, the middle plate gets displaced) we have a
push-pull displacement sensor.
How they work
The two capacitors can be put in different arms of an a.c. bridge.
the out-of-balance voltage is proportional to displacement x.
linear variable differential transformer - a transformer with a sliding
ferrous rod core (primary coil between two secondary coils)
Construction
Backup
Constant a.c. fed to primary coil, varying a.c. comes out of difference
of secondary coils, depending on position of rod. Fairly linear
There is also a rotary variable differential transformer that uses a heart-
shaped core. Detects rotations of core of +/- 40 degrees.
Another design
Backup
Eddy current proximity sensor - two coils, no core. Constant a.c. to reference
coil. Sensor coil picks up induced a.c. Amount varies when a conducting object
comes near because eddy currents are produced in the object.
Overview
backup
Inductive proximity switch - single coil around a core. When metal object
is near the coil, its inductance changes. Coil is part of a resonant circuit;
frequency of circuit changes.
examples
Optical encoders - Position of disc determined by effect of holes on light
beam.
digital encoders
Incremental encoder - Uses two rings of holes, offset from each other by
1/2 width of hole; allows direction of motion to be deduced. A single
hole in a third ring indicates a "home" position.
Absolute encoder - one track is used for each bit of the binary number
representing a position; the binary number for the disc position is read
directly off the light sensors. Glitches can occur when more than one bit
changes at the same time or nearly the same time (due to misalignment,
for example).
absolute encoders
Gray code is often used instead of the usual sequence of binary numbers
so that only one bit changes at a time-less chance for errors if sensor
is out of alignment.
Normal binary Gray code
------------- ---------
0000 0000
0001 0001
0010 0011
0011 0010
0100 0110
0101 0111
0110 0101
0111 0100
1000 1100
1001 1101
1010 1111
Pneumatic sensor - low pressure air escapes from end of sensor. If object
nearby, pressure detector in sensor detects increase in air pressure.
non-contact pneumatic sensors
Proximity switch -
microswitch - electrical switch requiring little force to operate it.
(This is also called a snap action switch.)
photo
catalog page-we'll use
SW143-ND switch
reed switch - electrical switch closed by bringing a magnet near it.
magnetic reed switch
photosensitive device - light or infra-red; object breaks beam or
reflects light back to sensor (as in my robots)
introduction
range-finding sensors
Hall effect sensor - When a current flows through a conductor, a voltage
forms sideways across the conductor if it is in a magnetic field (the
electrons are deflected to the side, just as they would in a vacuum).
Hall effect sensors come as ICs that are either linear in output, or
behave as threshold detectors. Can operate very fast (100kHz).
the Hall effect
Motion detectors
Incremental encoder - holes in disc break light beam; # of pulses per second
gives speed
encoder module
Tachogenerator - ferromagnetic tooth wheel spins next to a pick-up coil with
permanent magnet core.
Magnitude of induced current is proportional to speed. Also, individual
pulses can be counted.
DC tachogenerator
An alternative form is just an a.c. generator. shaft turns coil in a
magnetic field. Amplitude and frequency of generated current are proportional
to speed of shaft.
Pyroelectric sensor - polarized lithium tantalate generates a charge that
is proportional to the temperature that it detects. Motion of heat source
(person) is detected when it moves by two of these sensors, causing a
difference in their outputs. A parabolic mirror or Fresnel lens is often
used to focus infrared radiation onto the sensor.
the basic detector
kit version with Fresnel lens
Force detectors
Strain gauge load cell --- a cylindrical tube with strain gauges attached.
Strain gauges are temperature sensitive too, so this has to be accounted
for in signal conditioning. Errors are typically about +/- 0.03% of full
range for non-linearity error, and +/- 0.02% of full range for hysteresis
and repeatability errors.
wide variety
Fluid pressure sensors
Position of a diaphragm or bellows can be detected with strain gauges or
linear variable differential transformers. Mechanical part could be a
Bourdon tube (C-shaped or coiled tube that straightens out as pressure
increases)
pressure measurement
Diaphragm
Backup
a Bourdon tube
Backup
Piezoelectric sensors - voltage is proportional to applied pressure.
Piezoelectric sensors
more technical detail
big catalog
Tactile sensors - two layers of piezoelectric polyvinylidene fluoride
(PVDF) film separated by a soft film. A.c. to one layer causes it
to vibrate. Vibrations transmit to other layer, causing it to generate
a current. Vibration is stronger when layers are pushed together.
many approaches to tactile sensing
Liquid flow
Orifice plate - constriction in pipe, with pressure sensors in front
and behind. Flow is proportional to sqrt of pressure difference.
Orifice plate is often a disc with a hole in the middle. Pressure
sensors are one pipe diameter upstream, 1/2 pipe diameter downstream.
Other tap locations are common.
differential pressure flowmeters
backup
medical applications
Turbine meter - multibladed rotor inside the pipe. Rotation of turbine
may be detected by magnetic pick-up coil. More accurate, but more
expensive.
turbine flowmeters
backup
Liquid level
Float - position of float detected by potentiometer, linear variable
differential transformer, or strain-gauge.
Differential pressure - pressure between liquid at bottom of vessel
and the atmosphere or the gas at the top of the tank is measured.
(Every pressure sensor measures the difference between two pressures;
sometimes one side of the sensor is vented to the atmosphere, sometimes
it is vented to another point in the system being monitored, e.g., the
top of a tank or other side of an orifice.)
Temperature
survey presentation
Bimetallic strip - two metals attached to each other. Bends when
temperature changes. This can close switch. magnet in switch
can attract piece of soft iron on strip to cause hysteresis.
thermometer
Resistance temperature detector - resistance is often variable
with temperature. Platinum is linear over common temperature ranges,
copper is somewhat nonlinear (exponential) and Nickel is linear
above 400 degrees C.
Thermistor - special resistor made of mixtures of metal oxides
(semiconductors). Look like beads, discs or rods. Typically,
B/t
R(t) = K e
thermistors
Some thermistors have positive temperature coefficients (like
the wire resistors do). (The temperature coefficient is the
derivative of the resistance with respect to the temperature.
Hence, the sign of the temperature coefficient is the opposite
of the sign of the B constant in the formula.)
Thermodiodes and transistors - semiconductor devices. In a diode, the
current I is
eV/kT
I = Io (e - 1)
T is degrees Kelvin, e (in exponent) is the charge on an electron,
k and Io are constants. Solving for V,
V = (kT/e)ln(I/Io + 1)
If I is held constant, V is proportional to T in degrees Kelvin.
A common chip based on this is LM3911, which has a sensativity of
10 mV/ degrees C.
Transistors behave similarly. A chip based on temperature
sensitive transistors is the LM35. also 10 mV/ degree C.
(The difference between base-emitter voltages of two transistors
with different collector currents is proportional to temperature
on the Kelvin scale.)
LM35 sensor
Thermocouples - The junction of two different metals has a voltage
that is a function of temperature. Two thermocouples are used; one
is kept at a reference temperature, the other is the sensor. The
voltage difference between the two junctions is a quadratic function
of temperature.
thermocouples
Light sensors -
Photodiodes
photodiodes
phototransistors -
IR phototransistors
Photo Darlington - emitter of phototrans. connected to base of
power trans., both have common power to collectors.
phototransistors and photodarlingtons
photoresistors - cadmium sulphide or cadmium selinide
picture
connecting photoresistors
Switches -
Switches
Single Pole Single Throw (SPST) _/ _
_
Single Pole Double Throw (SPDT) _/ _
Double Pole Double Throw (DPDT) _ |/ _
o
_ / _
o
|
Problem: switch bounce.
Software solution: when closed switch is detected, wait a while
(20 msec, for example), if switch is still closed, accept that it
is closed.
solutions
Hardware solution: SR flip-flop can be used to debounce SPDT switch.
+5 V--R---+ (R = a resistor)
| +-----+
--+--|S Q|--
/ | |
+-----o | |
| --+--|R |
----- | +-----+
--- +5 V-R+
-
Flip-flop will change state when switch reaches other pole, but
is not affected by bounce at that pole, since a pulse is needed
at the other input to SR flip-flop to cause change.
D flip-flop can be used to debounce a SPST switch.
/ +------+
---o o---|D Q|-----
| |
---|clk |
+------+
D flip-flop only changes when clock signal changes.
Keypads -
contact key, membrane pad
These notes are based in part on W. Bolton, Mechatronics: Electronic
Control Systems in Mechanical and Electrical Engineering, Second
edition, Addison Wesley Longman, 1999.