Datasheet
193
7734Q–AVR–02/12
AT90PWM81/161
correlation to temperature and the typical accuracy of the temperature measurement is ±10°C
after offset calibration.
The values described in Table 15-1 are typical values. However, due to the process variation the
temperature sensor output voltage varies from one chip to another. To be capable of achieving
more accurate results the temperature measurement can be calibrated in the application
software.
When using temperature sensor, the temperature (in Kelvin) is calculated as follows:
T = A × T
ptat
+ B, where
A - Gain correction multiplier (constant '1', or unsigned fixed point number)
B - Offset correction term (2. complement signed byte)
T
ptat
- ADC result when measuring temperature sensor voltage, V
REF
with 2.56V internal
reference
T - Temperature in Kelvin (°K = °C + 273)
Example:
If A = 0x80 (=1.00) and B = 8, and ADC result is 0x15E (=350), this gives a measured tempera-
ture of:
T = 1.00 × 350 + 8 = 358K (+85°C)
15.4.1 Manufacturing Calibration
One can also use the calibration values available in the signature row. See “Reading the Signa-
ture Row from Software” on page 243.
The calibration values are determined from values measured during test at room temperature
which is approximatively +25°C. Calibration measures are done at V
CC
= 3V and with ADC in
internal V
REF
(1.1V) mode.
The temperature in Celsius degrees can be calculated utilizing the formula:
T = ((([(ADCH << 8) | ADCL] -(273 + 25-TSOFFSET)) × TSGAIN)/128) + 25
Where:
a. ADCH & ADCL are the ADC data registers.
b. TSGAIN is the temperature sensor gain (unsigned fixed point 8-bit temperature sensor gain
factor in 1/128th units stored as previously in the signature row at address 0x0007). See
“Reading the Signature Row from Software” on page 243.
c. TSOFFSET is the temperature sensor offset correction term (signed twos complement 7-bit
temperature sensor offset reading stored as previously in the signature row at address
0x0005).
Table 15-1. Temperature vs. sensor output voltage (typical case).
Temperature -40°C 25°C 105°C 125°C
Voltage (mV) 600 762 1012
ADC 240 305 405