Skip to content

Voltage Reference Sensor Calibration

Miguel Tomas Silva edited this page Nov 15, 2023 · 50 revisions

Change Language
Last update: 15-11-2023

Reference Voltage Sensor

The reference voltage sensor is a sensor that is able to monitor the output voltage on the ADC connector and also on the External Connector for compatible I2C sensors. The 12bit Smart DAQ utilizes the MCP1525 IC from Microchip, a 2.5V precision voltage reference that uses a combination of an advanced CMOS circuit design and EPROM trimming to provide an initial tolerance of ±1% (max.) and temperature stability of ±50 ppm/°C (max.). In addition to a low quiescent current of 100 µA (max.) at 25°C, this IC offers a clear advantage over the traditional Zener techniques in terms of stability across time and temperature. The output voltage is 2.5V and is specified over the industrial temperature range of -40°C to +85°C.


How to Calculate the Temperature Coefficient

The output temperature coefficient or voltage drift is a measure of how much the output voltage (Vo) will vary from its initial value with changes in ambient temperature. The value specified in the electrical specifications is measured and equal to:

TC|Vo = (ΔVo/Vn) / (ΔT) ppm/°C

, where TC|Vo is the temperature coefficient, ΔVo is the voltage variation for the temperature interval, ΔT, considered. Vn is the nominal voltage and is equal to 2.5V. As an example, the 12-bit Smart DAQ has a 12-bit ADC resolution. Assuming one needs the temperature-induced error to be less than half the Least significant bit (LSB). For a nominal output of the voltage reference, Vref, the LSB of the 12-bit ADC will be

Vref/ 2^12

. Hence, the total variation of the voltage reference output should be less than

Vref/ 2^13

for the temperature range of -40°C to 85°C, we obtain:

TCVo = [(2.50046-2.49544)/2.50] / (85-(-40)) ppm,/°C
= 0.002008 / 125 = 0.000016064 = 1.6064E-5 ppm/°C

in summary, for the example above and for the 12-bit Smart DAQ ADC, is needed a voltage reference with less than 16.05 ppm/°C.


Calibration for the Voltage Reference Sensor

The output temperature coefficient, or voltage drift, is a measure of how much the reference voltage (Vref) will vary from its initial value with changes in ambient temperature. The 12-Bit Smart DAQ uses a voltage reference from Microchip, the MCP1525 IC, and is able to sense voltage variations of 2.44mV and do temperature compensation according to the voltage-temperature drift curve below.




The OEM firmware code available on this repository has the curve above coded into it. To do temperature compensation uses values from the onboard temperature sensor, located on the LSM3DS6 IC, as input to calculate the compensated reference voltage value. It computes a linear interpolation (see below) between the values above and below the temperature sensed. A table with Voltage-Temperature drift values can be found in this excel workbook extracted from the datasheet provided by the manufacturer.


Computing a linear interpolation between 2 adjacent pairs of values

In scientific programming and embedded sensor systems applications, linear interpolation is often used to estimate a value from a series of discrete data points. The problem is stated and the solution is given as follows:

source Bulldozer00's Blog

The solution assumes that any two points in a set of given data points represent a straight line. Hence, it takes the form of the classic textbook equation for a line, y = b + mx, where b is the y-intercept and m is the slope of the line.

If the set of data points does not represent a linear underlying phenomenon, more sophisticated polynomial interpolation techniques that use additional data points around the point of interest can be utilized to get a more accurate estimate.

The code snippets below give the definition and implementation of a C++ functor class that performs linear interpolation. I chose to use a vector of pairs to represent the set of data points.

 /* Calculation */
 y = y2 + (x - x2) * ((y3-y2)/(x3-x2));
 printf("Interpolated value at %0.3f is %0.3f", xp, yp);


Clone this wiki locally