NuMicro® NUC029LEE/NUC029SEE
32-bit Arm
®
Cortex
®
-M0 Microcontroller
Aug, 2018
Page
490
of
497
Rev 1.00
N
U
MICRO
®
N
UC02
9L
E
E
/N
UC029
S
E
E
T
E
CHN
ICA
L R
E
F
E
R
E
NC
E
M
A
NU
A
L
[6:3]
CMPCH
Compare Channel Selection
0000 = Channel 0 conversion result is selected to be compared.
0001 = Channel 1 conversion result is selected to be compared.
0010 = Channel 2 conversion result is selected to be compared.
0011 = Channel 3 conversion result is selected to be compared.
0100 = Channel 4 conversion result is selected to be compared.
0101 = Channel 5 conversion result is selected to be compared.
0110 = Channel 6 conversion result is selected to be compared.
0111 = Channel 7 conversion result is selected to be compared.
1000 = Channel 8 conversion result is selected to be compared.
1001 = Channel 9 conversion result is selected to be compared.
1010 = Channel 10 conversion result is selected to be compared.
1011 = Channel 11 conversion result is selected to be compared.
[2]
CMPCOND
Compare Condition
0 = Set the compare condition as that when a 12-bit A/D conversion result is less than the
12-bit CMPD (ADCMPR0/1[27:16]), the internal match counter will increase one.
1 = Set the compare condition as that when a 12-bit A/D conversion result is greater or
equal to the 12-bit CMPD (ADCMPR0/1[27:16]), the internal match counter will increase
one.
Note:
When the internal counter reaches the value to (CMPMATCNT
(ADCMPR0/1[11:8])+1), the CMPF0/1 bit (ADSR[1]/[2]) will be set.
[1]
CMPIE
Compare Interrupt Enable Bit
0 = Compare function interrupt Disabled.
1 = Compare function interrupt Enabled.
If the compare function is enabled and the compare condition matches the setting of
CMPCOND (ADCMPR0/1[2]) and CMPMATCNT (ADCMPR0/1[11:8]), CMPF0/1 bit
(ADSR[1]/[2]) will be asserted, in the meanwhile, if CMPIE (ADCMPR0/1[1]) is set to 1, a
compare interrupt request is generated.
[0]
CMPEN
Compare Enable Bit
0 = Compare function Disabled.
1 = Compare function Enabled.
Set this bit to 1 to enable ADC controller to compare CMPD (ADCMPR0/1[27:16]) with
specified channel conversion result when converted data is loaded into ADDR register.