Input Voltage And Conversion Results - NEC mPD780344 Series User Manual

8-bit single-chip microcontrollers
Table of Contents

Advertisement

CHAPTER 12 8-BIT A/D CONVERTER ( µ PD780344, 780344Y SUBSERIES)

12.4.2 Input voltage and conversion results

The relationship between the analog voltage input to the analog input pins (ANI0 to ANI7) and the logical A/D
conversion result (stored in A/D conversion result register 1 (ADCR1)) is shown by the following expression.
V
IN
ADCR1 = INT (
AV
DD
or
AV
(ADCR1 – 0.5) ×
256
where, INT( ):
Function which returns integer part of value in parentheses
V
:
Analog input voltage
AIN
AV
:
AV
DD
DD
ADCR1: A/D conversion result register 1 (ADCR1) value
Figure 12-6 shows the relationship between the analog input voltage and the A/D conversion result.
Figure 12-6. Relationship Between Analog Input Voltage and A/D Conversion Result
A/D conversion result
(ADCR1)
232
× 256 + 0.5)
DD
≤ V
< (ADCR1 + 0.5) ×
AIN
pin voltage
255
254
253
3
2
1
0
1
1
3
512
256
512
User's Manual U15798EJ2V0UD
AV
DD
256
2
5
3
507
254
256
512
256
512
256
Input voltage/AV
DD
509
255
511
1
512
256
512

Advertisement

Table of Contents
loading

Table of Contents