Maker Pro
Maker Pro

linearising a sensor

M

muthuraman.s

Hi all,
I have a pressure sensor that does not produce a linear output. When
I increase the pressure to the sensor, the electrical output does not
increase propotionally. If I replace the sensor with another one , the
new one gives more output than expected. How to linearise the sensor
characteristics? Googling gives some complex IEEE transactions which
basically are too complex to me to understand.

Thanks in advance.
Muthuraman.
 
D

D from BC

Hi all,
I have a pressure sensor that does not produce a linear output. When
I increase the pressure to the sensor, the electrical output does not
increase propotionally. If I replace the sensor with another one , the
new one gives more output than expected. How to linearise the sensor
characteristics? Googling gives some complex IEEE transactions which
basically are too complex to me to understand.

Thanks in advance.
Muthuraman.

I linearize stuff with a PIC with a compensation table in memory.


D from BC
 
T

Tim Williams

1. Put it in a loop. If the sensor has some manner of feedback (such as
adding another transducer to feed back to the sensor, etc.), sufficient
negative feedback will linearize it. Baxandall(?) covered this almost a
century ago (and likely, mechanical engineers even earlier).

2. Construct an inverse function, perhaps out of piecewise functional
blocks (op-amps with lots of diodes and resistors), or components with
specific properties (e.g., FET for squared terms, silicon junction for
exponential terms) to effectively neutralize the sensor's own nonlinearity.

3. Combine 1. and 2., by using a (known to be linear) transducer to excite
an identical isolated sensor, enclosing this in a feedback loop. The error
signal from this sensor feedback loop is the exact inverse function of the
sensor's nonlinearity (within reason). Add the sensor's signal to this
function block and you will get a linear output.

#1 and 3 have relatively slow response time, but can be arbitrarily
accurate (the limiting factor is how much feedback you apply and the delay
time you can allow for it to settle to that accuracy). #1 may not be
practical, especially if your pressure sensor must connect to other things;
connecting pressures "in series" may not be very practical. #2 is the
fastest (effectively instantaneous), but must be tediously adjusted to
accuracy.

If you're digitizing the signal anyway, you might as well calibrate your
own correction table for the sensor, forgoing the analog solution. Sensor
voltage maps to address in memory, which then maps to the corrected value.
What's more, if you have a linear sensor, you could generate the conversion
easily enough automatically. (This of course begs the question, why don't
you have a linear sensor to begin with? I'd assume you have some sort of
standard somewhere.)

Tim
 
B

Ben Jackson

I have a pressure sensor that does not produce a linear output. When
I increase the pressure to the sensor, the electrical output does not
increase propotionally.

If you mean that the output is a function, just not a linear function,
you can calibrate with a few points (depending on what the function is).
This is how you work with an NTC thermistor, for example. If you mean
the output isn't even monotonic, then you've got a much more complex
problem. If it's monotonic but "unpredictable" you could build a jig
to calibrate it over all possible conditions.
 
M

Martin Brown

Hi all,
I have a pressure sensor that does not produce a linear output. When
I increase the pressure to the sensor, the electrical output does not
increase propotionally. If I replace the sensor with another one , the
new one gives more output than expected. How to linearise the sensor
characteristics? Googling gives some complex IEEE transactions which
basically are too complex to me to understand.

As posed your question is unanswerable. You don't say what the sensor
transfer function is or over what dynamic range you are hoping to
compensate the thing over. Knowing the sensor type and application
would help. Vacuum gauges have very different calibration problems to
diamond anvil controllers (picking the 2 extremes).

Do you mean it is linear with small non-linear deviations, or gives a
reciprocal, square law or logarithmic response ?

Basically if it has to work with a range of sensors then you need to
be able to calibrate the system against a suitable number of fixed
points when the new sensor is installed. If you already know the
functional form of the transfer function then you need slightly fewer
calibration points to get a decent result. And watch out for numerical
instabilities when inverting anything beyond a cubic polynomial.

Regards,
Martin Brown
 
N

Nemo

This is why some instruments are so expensive - they are individually
calibrated and sometimes even individually temperature compensated by
running them at different temperatures in an environmental chamber. By a
person. This process can be semi-automated if the production run is
large enough. Like many things in life, it sounds simple when your boss
tells you to do it, but when you begin looking into exactly how to do
it...

I would think, though, that if you have the sensor datasheet, the
manufacturer will show a graph or something to show you the shape of the
response, and hopefully some suggestions about how to use the sensor.

As a rule of thumb, cheap sensors have lots of individual variation, and
can often only be used as a threshold detector. To get a sensor good
enough to measure quantitatively with, you need to spend more.
 
D

David L. Jones

Hi all,
I have a pressure sensor that does not produce a linear output. When
I increase the pressure to the sensor, the electrical output does not
increase propotionally. If I replace the sensor with another one , the
new one gives more output than expected. How to linearise the sensor
characteristics? Googling gives some complex IEEE transactions which
basically are too complex to me to understand.

Thanks in advance.
Muthuraman.

With pressure sensors, watch out for temperature compensation. If you
don't have a temperature compensated sensor, then you may have to add
your own compensation circuitry. That is not easy to do, and there are
often multiple adjustment factors that can be interactive i.e, adjust
one and it upsets the other.

With regards to linearity, use the linear sensor and then scale the
output voltage. That is much simpler than trying to linearise a non-
linear sensor.

Dave.
 
Top