pic24hj16gp304 Microchip Technology Inc., pic24hj16gp304 Datasheet - Page 161

no-image

pic24hj16gp304

Manufacturer Part Number
pic24hj16gp304
Description
High-performance, 16-bit Microcontrollers
Manufacturer
Microchip Technology Inc.
Datasheet

Available stocks

Company
Part Number
Manufacturer
Quantity
Price
Part Number:
pic24hj16gp304-E/ML
Manufacturer:
MICROCHIP
Quantity:
12 000
Part Number:
pic24hj16gp304-E/PT
Manufacturer:
MICROCHIP
Quantity:
12 000
Part Number:
pic24hj16gp304-E/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
pic24hj16gp304-H/ML
Manufacturer:
MICROCHIP
Quantity:
12 000
Part Number:
pic24hj16gp304-H/PT
Manufacturer:
MICROCHIP
Quantity:
12 000
Part Number:
pic24hj16gp304-I/ML
Manufacturer:
MICROCHIP
Quantity:
12 000
Part Number:
pic24hj16gp304-I/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
Part Number:
pic24hj16gp304T-I/PT
Manufacturer:
Microchip Technology
Quantity:
10 000
17.0
The PIC24HJ32GP202/204 and PIC24HJ16GP304
devices have up to 13 Analog-to-Digital Conversion
(ADC) module input channels.
The AD12B bit (AD1CON1<10>) allows each of the
ADC modules to be configured as either a 10-bit, 4-
sample-and-hold ADC (default configuration), or a
12-bit, 1-sample-and-hold ADC.
17.1
The 10-bit ADC configuration has the following key
features:
• Successive Approximation (SAR) conversion
• Conversion speeds of up to 1.1 Msps
• Up to 13 analog input pins
• External voltage reference input pins
• Simultaneous sampling of up to four analog input
• Automatic Channel Scan mode
• Selectable conversion trigger source
• Selectable Buffer Fill modes
• Operation during CPU Sleep and Idle modes
• 16-word conversion result buffer
The 12-bit ADC configuration supports all the above
features, except:
• In the 12-bit configuration, conversion speeds of
• There is only 1 sample-and-hold amplifier in the
© 2007 Microchip Technology Inc.
Note:
Note:
pins
up to 500 ksps are supported
12-bit configuration, so simultaneous sampling of
multiple channels is not supported.
10-BIT/12-BIT ANALOG-TO-
DIGITAL CONVERTER (ADC)
Key Features
This data sheet summarizes the features
of
PIC24HJ16GP304 devices. It is not
intended to be a comprehensive reference
source. To complement the information in
this data sheet, refer to the “PIC24H
Family Reference Manual”.
The ADC module must be disabled before
the AD12B bit can be modified.
PIC24HJ32GP202/204 and PIC24HJ16GP304
the
PIC24HJ32GP202/204
and
Preliminary
Depending on the particular device pinout, the ADC
can have up to 13 analog input pins, designated AN0
through AN12. In addition, there are two analog input
pins for external voltage reference connections. These
voltage reference inputs can be shared with other ana-
log input pins.
The actual number of analog input pins and external
voltage reference input configuration will depend on the
specific device. Refer to the device data sheet for fur-
ther details.
A block diagram of ADC for PIC24HJ16GP304 and
PIC24HJ32GP204 devices is shown in Figure 17-1. A
block diagram of the ADC for the PIC24HJ32GP202
device is shown in Figure 17-2.
17.2
To configure the ADC module:
1.
2.
3.
4.
5.
6.
7.
8.
Select
(AD1PCFGH<15:0> or AD1PCFGL<15:0>).
Select voltage reference source to match
expected
(AD1CON2<15:13>).
Select the analog conversion clock to match
desired
(AD1CON3<7:0>).
Determine how many sample-and-hold chan-
nels will be used (AD1CON2<9:8> and
AD1PCFGH<15:0> or AD1PCFGL<15:0>).
Select
sequence
AD1CON3<12:8>).
Select the way conversion results are presented
in the buffer (AD1CON1<9:8>).
Turn on the ADC module (AD1CON1<15>).
Configure ADC interrupt (if required):
a)
b)
ADC Initialization
Clear the AD1IF bit.
Select ADC interrupt priority.
the
port
data
range
appropriate
rate
pins
(AD1CON1<7:5>
with
on
as
sample/conversion
processor
analog
DS70289A-page 159
analog
inputs
inputs
clock
and

Related parts for pic24hj16gp304