Datasheet

1999-2013 Microchip Technology Inc. Preliminary DS41124D-page 91
PIC16C745/765
12.0 ANALOG-TO-DIGITAL
CONVERTER (A/D) MODULE
The 8-bit Analog-To-Digital (A/D) converter module has
five inputs for the PIC16C745 and eight for the
PIC16C765.
The A/D allows conversion of an analog input signal to
a corresponding 8-bit digital value. The output of the
sample and hold is the input into the converter, which
generates the result via successive approximation. The
analog reference voltage is software selectable to
either the devices positive supply voltage (V
DD) or the
voltage level on the RA3/AN3/V
REF pin.
The A/D converter has a unique feature of being able
to operate while the device is in SLEEP mode. To oper-
ate in sleep, the A/D conversion clock must be derived
from the A/D’s dedicated internal RC oscillator.
The A/D module has three registers. These registers
are:
A/D Result Register (ADRES)
A/D Control Register 0 (ADCON0)
A/D Control Register 1 (ADCON1)
The ADCON0 register, shown in Register 12-1, con-
trols the operation of the A/D module. The ADCON1
register, shown in Register 12-2, configures the func-
tions of the port pins. The port pins can be configured
as analog inputs (RA3 can also be a voltage reference)
or as digital I/O.
Additional information on using the A/D module can be
found in the PIC Mid-Range MCU Family Reference
Manual (DS33023) and in Application Note, AN546.
Note: In order to maintain 8-bit A/D accuracy,
ADCS<1:0> must be set to either F
INT/32 or
F
RC. Choosing FINT/8 or FINT/2 will cause
loss of accuracy, due to the USB module’s
requirement of running at 24 MHz.