Vault 7: Projects

This publication series is about specific projects related to the Vault 7 main publication.

© 2010 Microchip Technology Inc. Preliminary DS39737A-page 49-33
Section 49. 10-Bit ADC with 4 Simultaneous Conversions
10-Bit ADC with
4 Simultaneous
Conversions
49
49.7 ADC CONFIGURATION EXAMPLE
The following steps should be used for performing an A/D conversion:
1. Select the analog conversion clock to match the desired data rate with the processor clock
(ADxCON3<7:0>).
2. Select the port pins as analog inputs (ADxPCFGL<5:0>).
3. Determine how inputs will be allocated to Sample and Hold channels (ADxCHS0<15:0>
and ADxCHS123<15:0>).
4. Determine how many Sample and Hold channels will be used (ADxCON2<9:8> and
ADxPCFGL<5:0>).
5. Determine how sampling will occur (ADxCON1<3> and ADxCSSL<5:0>).
6. Select manual or auto-sampling.
7. Select the conversion trigger and sampling time.
8. Select how the conversion results are stored in the buffer (ADxCON1<9:8>).
9. Select the data format.
10. Configure the ADC interrupt (if required):
Clear the ADxIF bit
Select interrupt priority (ADxIP<2:0>)
Set the ADxIE bit
11. Turn on the ADC module (ADxCON1<15>).
The options for these configuration steps are described in subsequent sections.

e-Highlighter

Click to send permalink to address bar, or right-click to copy permalink.

Un-highlight all Un-highlight selectionu Highlight selectionh