
11
11-29
A-D Converters
32180 Group User's Manual (Rev.1.0)
11.2 A-D Converter Related Registers
11.2.8 A-D Successive Approximation Registers
A-D0 Successive Approximation Register(AD0SAR)
<Address: H’0080 0088>
A-D1 Successive Approximation Register(AD1SAR)
<Address: H’0080 0A88>
b0
123456789
10
11
12
13
14
b15
ADSAR
0
??????????
<After reset: Undefined>
b
Bit Name
Function
R
W
0–5
No function assigned. Fix to "0".
00
6–15
ADSAR
0: A-D successive approximation value (A-D conversion mode)
RW
A-D successive approximation value/comparison value 1: Comparison value (comparator mode)
Note: This register must always be accessed in halfwords.
The A-D Successive Approximation Registers (ADSAR) are used to read the conversion result of the A-D
Converters when operating in A-D conversion mode or write a comparison value when operating in comparator
mode.
In A-D conversion mode, the successive approximation method is used to perform A-D conversion. With this
method, the reference voltage VREF and analog input voltages are sequentially compared bitwise beginning
with the high-order bit, and the comparison result is set in the A-D Successive Approximation Register (ADSAR)
bits 6–15. When the A-D conversion has finished, the value of this register is transferred to the 10-bit A-D Data
Register (ADDTn) corresponding to each converted channel. When this register is accessed for read in the
middle of A-D conversion, the value read from the register indicates the intermediate result of conversion.
In comparator mode, this register is used to write a comparison value (the voltage with which to “comparate”).
Simultaneously with a write to this register, the A-D Converter starts comparing the voltage on the analog input
pin selected with A-D Single Mode Register 1 and the value written in this register. After comparate operation,
the result is stored in the A-D Comparate Data Register (ADCMP).
Use the calculation formula shown below to find the comparison value to be written to the A-D Successive
Approximation Register (ADSAR) during comparator mode.
Comparison value = H’3FF x
Comparate comparison voltage [V]
VREF input voltage [V]