Electrolytic tilt sensors are fluid based devices making their output susceptible to variations in temperature. The purpose of this document is to explain how temperature compensation of electrolytic tilt sensor output can be achieved to produce the highest accuracy angular measurement.
There are two components to the temperature compensation of an electrolytic tilt sensor:
- Null temperature compensation
- Scale (or sensitivity) temperature compensation
Null temperature compensation is accomplished with a null temperature coefficient. This is a factor which varies from sensor to sensor and therefore must be calibrated individually for each sensor. The units of this factor will vary depending on the type of output. For example, some sensors have an analog output of 0 to 5 V while others will have an ASCII decimal output of the current tilt angle.
Scale temperature compensation is accomplished with a scale temperature coefficient. This is a factor which is uniform among all sensors of the same type. It has units of percent of output per degree C or %/°C.
The only other requirement for temperature compensation is the ability to read the current temperature. This feature is available on all TFC signal conditioner circuits through the use of the MCP9700 from Microchip (http://www.microchip.com/wwwproducts/Devices.aspx?dDocName=en022289).
Null Temperature Compensation
In order to accomplish null temperature compensation, a null temperature coefficient must first be calculated (because the coefficient varies for each individual sensor, TFC cannot provide it). This is accomplished by temperature cycling the sensor over the desired range and recording the output while the sensor remains stationary at null (0° tilt). At TFC we typically do a 3 point calibration at -20° C, +20° C, and +50° C.
Let’s suppose we have a 0717-4318-99 TFC wide range dual axis tilt sensor sitting at null at +20° C being driven by a TFC digital signal conditioner with a 16 bit (0 to 65535) output. We take a reading and record the following output:
Output at +20° C = 32768
We then reduce the temperature to -20° C and allow the sensor to reach ambient temperature. We take another reading and record the following output:
Output at -20° C = 32738
We then increase the temperature to +50° C and again allow the sensor to reach ambient temperature. We take another reading and record the following output:
Output at +50° C = 32798
We can now calculate a temperature coefficient for temperatures between -20° C and +20° C and another for temperatures between +20° C and +50° C using the following formula:
Temperature coefficient = (output at 20° C – output at current temperature)/(20 – current temperature)
Completing the calculations for the above example, we find the following two temperature coefficients:
Temperature coefficient between -20° C and +20° C = (32768 – 32738)/ (20° C – (-20° C)) = 30/40 = 0.75 counts/°C
Temperature coefficient between +20° C and +50° C = (32768 – 32798)/(20° C – 50° C) = (-30)/(-30) = 1 count/°C
Once the null temperature coefficients are calculated, null temperature compensation can be achieved by using the coefficients along with the following formula:
Null compensated output = (20 – current temperature)*(null temperature coefficient) + current output
Let’s suppose that we have the same sensor above at an unknown position where its output reads 35000 at a temperature of +40°C. We can use the formula for the compensated output to complete the following calculations:
Compensated output = (20° C – 40° C)*(1 count/°C) + 35000 = -20 + 35000 = 34980
It is important to note that the null offset due to temperature will produce an offset, and therefore an error, across the full range of the sensor if it is not compensated.
Scale Temperature Compensation
Scale temperature compensation can be achieved by using the scale temperature coefficient provided by TFC along with the following formula:
Scale compensated output =
(current output)*(20 – current temperature)*(-scale temperature coefficient) + current output
Let’s suppose we have a 0703-1602-99 TFC mid-range single axis electrolytic tilt sensor. This sensor has a scale temperature coefficient of 0.075%/°C. Now let’s suppose that the current sensor output is 5° tilt at a temperature of -20° C. We can then use the formula above to complete the following calculations:
(5° tilt)*(20° C – (-20° C))*(-0.00075) = (5° tilt)*(40° C)*(-0.00075) = -0.15° tilt
5° tilt + (-0.15° tilt) = 4.85° tilt
4.85° is therefore your temperature compensated angular position measurement.
Here’s another example. This time let’s suppose that the current sensor output is -5° tilt at a temperature of 40° C:
(-5° tilt)*(20° C – 40° C)*(-0.00075) = (-5° tilt)*(-20° C)*(-0.00075) = -0.075° tilt
-5° tilt + (-0.075° tilt) = -5.075° tilt
-5.075° is therefore your temperature compensated angular position measurement.
It’s important to keep in mind the sign of the current output when doing calculations for scale temperature compensation. If you are using a TFC signal conditioning board that has a 16 bit output of 0 to 65535, this output will first need to be shifted so that 0 is the midpoint (this is easily accomplished by subtracting 32767).