3.2 Theory of Operation
To measure the RTD, the Digital-to-Analog Converter (DAC) is enabled to produce an output of approximately 1.8V. The DAC on AVR EA is buffered so it can drive low-impedance loads. Since the DAC voltage is applied to a 1.8 kΩ fixed resistor in series with the RTD, the current flowing through the RTD will be under 1 mA. RTD datasheets usually provide guidance for maximum current, but generally, a current of less than 1 mA is recommended because it prevents the RTD from any significant self-heating. The ADC is used to measure the voltage across the RTD, which can be converted into the sensor resistance and thus, its temperature.
The resistance of the RTD varies in a known way as a function of temperature (T), by the following equations, where R0 is the resistance of the RTD at a temperature of 0°C and A, B and C are constants provided by the RTD manufacturer:
For T of 0°C or higher,
For T of -200°C to 0°C,
If the resistance of the RTD is known, then the formulas above can be used to determine the temperature.
Here are the relevant formulas for determining the resistance of the RTD:
First, the voltage across the RTD is determined by the voltage divider equation, where RF is the resistance of the fixed resistor and RTD is the resistance of the RTD:
The ADC digital result x, when the ADC is used in differential mode, is determined by the following equation (from the device datasheet), where GPGA is the gain of the PGA:
The voltage divider equation from above can be substituted in for VRTD, causing VREF to cancel out:
This equation can be solved for RTD, the resistance of the RTD:
Note that VREF does not appear in the equation, so errors in the reference voltage value will not affect the result. The only parameters needed to compute the RTD resistance are the resistance value of the fixed resistor, the ADC result, and the PGA gain value.