English
Language : 

ATMEGA8_08 Datasheet, PDF (205/308 Pages) ATMEL Corporation – 8-bit with 8K Bytes In-System Programmable Flash
Figure 100. Differential Non-linearity (DNL)
Output Code
0x3FF
ATmega8(L)
ADC Conversion
Result
ADC Multiplexer
Selection Register –
ADMUX
1 LSB
DNL
0x000
0
VREF Input Voltage
• Quantization Error: Due to the quantization of the input voltage into a finite number of codes,
a range of input voltages (1 LSB wide) will code to the same value. Always ±0.5 LSB.
• Absolute accuracy: The maximum deviation of an actual (unadjusted) transition compared to
an ideal transition for any code. This is the compound effect of offset, gain error, differential
error, non-linearity, and quantization error. Ideal value: ±0.5 LSB.
After the conversion is complete (ADIF is high), the conversion result can be found in the ADC
Result Registers (ADCL, ADCH).
For single ended conversion, the result is
ADC = -V---I--N-----⋅---1---0----2---4--
VREF
where VIN is the voltage on the selected input pin and VREF the selected voltage reference (see
Table 74 on page 205 and Table 75 on page 206). 0x000 represents ground, and 0x3FF repre-
sents the selected reference voltage minus one LSB.
Bit
7
6
5
4
REFS1 REFS0 ADLAR
–
Read/Write
R/W
R/W
R/W
R
Initial Value
0
0
0
0
3
MUX3
R/W
0
2
MUX2
R/W
0
1
MUX1
R/W
0
0
MUX0
R/W
0
ADMUX
• Bit 7:6 – REFS1:0: Reference Selection Bits
These bits select the voltage reference for the ADC, as shown in Table 74. If these bits are
changed during a conversion, the change will not go in effect until this conversion is complete
(ADIF in ADCSRA is set). The internal voltage reference options may not be used if an external
reference voltage is being applied to the AREF pin.
Table 74. Voltage Reference Selections for ADC
REFS1 REFS0 Voltage Reference Selection
0
0
AREF, Internal Vref turned off
2486T–AVR–05/08
205