Input Voltage And Conversion Results - NEC 78K0/KD1 Series User Manual

8-bit single-chip microcontrollers
Table of Contents

Advertisement

12.4.2 Input voltage and conversion results

The relationship between the analog input voltage input to the analog input pins (ANI0 to ANI7) and the A/D
conversion result (stored in the A/D conversion result register (ADCR)) is shown by the following expression.
V
IN
ADCR = INT (
AV
REF
or
AV
REF
(ADCR − 0.5) ×
1024
where, INT( ):
Function which returns integer part of value in parentheses
V
:
Analog input voltage
IN
AV
:
AV
pin voltage
REF
REF
ADCR: A/D conversion result register (ADCR) value
Figure 12-10 shows the relationship between the analog input voltage and the A/D conversion result.
Figure 12-10. Relationship Between Analog Input Voltage and A/D Conversion Result
A/D conversion result
(ADCR)
234
CHAPTER 12 A/D CONVERTER
× 1024 + 0.5)
AV
− V
< (ADCR + 0.5) ×
IN
1024
1023
1022
1021
3
2
1
0
1
1
3
2048
1024
2048
Preliminary User's Manual U16315EJ1V0UD
REF
2
5
3
2043
1022
1024
2048
1024
2048
1024
Input voltage/AV
REF
2045
1023
2047
1
2048
1024
2048

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents