English
Language : 

GMS81504 Datasheet, PDF (33/54 Pages) List of Unclassifed Manufacturers – CMOS SINGLE-CHIP 8-BIT MICROCONTROLLER
HYUNDAI MicroElectronics
GMS81504
ANALOG TO DIGITAL CONVERTER
The analog-to-digital converter (A/D) allows conver-
sion of an analog input signal to a corresponding 8-bit
digital value. The A/D module has eight analog inputs,
which are multiplexed into one sample and hold. The
output of the sample and hold is the input into the
converter, which generates the result via successive
approximation. The analog supply voltage is con-
nected to AVDD of ladder resistance of A/D module.
The A/D module has two registers which are the con-
trol register ADCM and A/D result register ADR. The
register ADCM, shown in Figure 22, controls the
operation of the A/D converter module. The port pins
can be configured as analog inputs or digital I/O. To
use analog inputs, I/O is selected input mode by R6DD
direction register.
How to Use A/D Converter
The processing of conversion is start when the start bit
ADST is set to "1". After one cycle, it is cleared by
hardware. The register ADR contains the results of the
A/D conversion. When the conversion is completed,
the result is loaded into the ADR, the A/D conversion
status bit ADSF is set to "1", and the A/D interrupt flag
AIF is set. The block diagram of the A/D module is
shown in Figure 21. The A/D status bit ADSF is set
automatically when A/D conversion is completed,
cleared when A/D conversion is in process. The con-
version time takes maximum 40 uS (at fXIN=4 MHz).
AVDD PIN
R64/AN4
R65/AN5
R66/AN6
R67/AN7
ADEN
"0"
"1"
LADDER
RESISTOR
DECODER
3
100
101
110
111
ADS[2:0]
000~011: RESERVED
VIN S/H
SAMPLE & HOLD
INPUT CHANNEL SELECTION
SUCCESSIVE
APPROXIMATION
AIF
CIRCUIT
A/D
INTERRUPT
ADR
ADDRESS: E9H
RESET VALUE: Undefined
A/D RESULT REGISTER
Figure 21. A/D Block Diagram
33