CHAPTER 11 A/D CONVERTER
520
User’s Manual U15195EJ5V0UD
(3) A/D voltage detection mode registers 0 and 1 (ADETM0, ADETM1)
The ADETMn registers are 16-bit registers that set the voltage detection mode. In the voltage detection
mode, the analog input pin for which voltage detection is being performed and a reference voltage value are
compared and an interrupt is set in response to the comparison result.
These registers can be read or written in 16-bit units.
When the higher 8 bits of the ADETMn register are used as the ADETMnH register, and the lower 8 bits are
used as the ADETMnL register, they can be read/written in 8-bit or 1-bit units.
Caution Do not write to an ADETMn register during an A/D conversion operation. If a write is
performed, conversion is suspended and it subsequently terminates.
Address
FFFFF204H
After reset
0000H
<14>
ADET
LH0
13
DET
ANI3
12
DET
ANI2
2
DET
CMP2
3
DET
CMP3
4
DET
CMP4
5
DET
CMP5
6
DET
CMP6
7
DET
CMP7
8
DET
CMP8
9
DET
CMP9
10
DET
ANI0
11
DET
ANI1
<15>
ADET
EN0
1
DET
CMP1
0
DET
CMP0
ADETM0
Address
FFFFF244H
After reset
0000H
<14>
ADET
LH1
13
DET
ANI3
12
DET
ANI2
2
DET
CMP2
3
DET
CMP3
4
DET
CMP4
5
DET
CMP5
6
DET
CMP6
7
DET
CMP7
8
DET
CMP8
9
DET
CMP9
10
DET
ANI0
11
DET
ANI1
<15>
ADET
EN1
1
DET
CMP1
0
DET
CMP0
ADETM1
Bit position
Bit name
Function
15
ADETENn
Specifies voltage detection mode.
0: Operates in normal mode
1: Operates in voltage detection mode
14
ADETLHn
Sets voltage comparison detection.
0: Generates INTDETn interrupt if reference voltage value > analog input pin voltage.
1: Generates INTDETn interrupt if reference voltage value < analog input pin voltage.
Selects analog input pin to compare to reference voltage value set by DETCMP9 to
DETCMP0 when in voltage detection mode.
DETANI3 DETANI2 DETANI1 DETANI0
Voltage detection analog input pin
0 0 0 0
ANIn0
0 0 0 1
ANIn1
0 0 1 0
ANIn2
0 0 1 1
ANIn3
0 1 0 0
ANIn4
0 1 0 1
ANIn5
0 1 1 0
ANI16
0 1 1 1
ANI17
1
×
×
×
Setting prohibited
13 to 10
DETANI3
to
DETANI0
Remark
×
: Don’t care
9 to 0
DETCMP9
to
DETCMP0
Sets reference voltage value to compare with analog input pin selected by DETANI3 to
DETANI0.
Remark
n = 0, 1
Содержание PD703114
Страница 2: ...2 User s Manual U15195EJ5V0UD MEMO ...