DR
AFT
DR
AFT
DRAFT
DR
D
RAFT
DRAFT
DRA
FT DRAF
D
RAFT DRAFT DRAFT DRAFT DRAFT D
DRAFT
D
RAFT DRA
FT DRAFT DRAFT DRAFT DRA
UM10316_0
© NXP B.V. 2008. All rights reserved.
User manual
Rev. 00.06 — 17 December 2008
453 of 571
NXP Semiconductors
UM10316
Chapter 26: LPC29xx Analog-to-Digital Converter (ADC)
3.2 ADC channel-compare register
The LPC29xx contains a compare register for each of the ADC channel inputs. These
registers contain the value with which the ADC_R_x data is to be compared. The
comparison can be done for values ‘less than’ or ‘greater than or equal to’ the compare
value as defined in the match part of the register. The COMP registers can be updated ‘on
the fly’. The comparison check is done at the end of a scan when new ADC_R_x data is
available.
shows the bit assignment of the COMP0 to COMP15 registers.
Table 373. ACCn register bit description (ACC0 to 15, addresses 0xE00C 2000 to
0xE00C203C (ADC0), 0xE00C 3000 to 0xE00C303C (ADC1), 0xE00C 4000 to
0xE00C403C (ADC2))
* = reset value
Bit
Symbol
Access
Value
Description
31 to 4
reserved
R
-
Reserved; do not modify. Read as logic 0
3 to 0
ACC[3:0]
R/W
Set the resolution for a channel
0000*
Channel not selected
0001
Reserved
0010
2-bit resolution
0011
3-bit resolution
0100
4-bit resolution
0101
5-bit resolution
0110
6-bit resolution
0111
7-bit resolution
1000
8-bit resolution
1001
9-bit resolution
1010
10-bit resolution
1011
Reserved
:
:
1111
Reserved
Table 374. COMPn register bit description (COMP0 to 15, addresses 0xE00C 2100 to
0xE00C213C (ADC0), 0xE00C 3100 to 0xE00C313C (ADC1), 0xE00C 4100 to
0xE00C413C (ADC2))
* = reset value
Bit
Symbol
Access
Value
Description
31 to 18
reserved
R
-
Reserved; do not modify. Read as logic 0
17 and16 MATCH[1:0]
R/W
Compare for values ‘less than’ or ‘greater than
or equal to’ the compare value
00*
No comparison is done
01
Unused
10
Interrupt is generated when ADC data is less
than compare data
11
Interrupt is generated when ADC data is
greater than or equal to compare data