PIC24F Family Reference Manual 66.1 INTRODUCTION The PIC24F 16-bit Sigma-Delta Analog-to-Digital (SD A/D) Converter has the following key features: • Sigma-Delta Conversion • Programmable Data Rate up to 62.5 ksps • Differential inputs with Gain Settings • Dithering Option and Adjustable Oversampling Ratios •...
PIC24F Family Reference Manual 66.2 REGISTERS The 16-bit SD A/D Converter uses five registers for its operation: • SDxCON1: SD A/Dx Control Register 1 • SDxCON2: SD A/Dx Control Register 2 • SDxCON3: SD A/Dx Control Register 3 • SDxRESH: SD A/Dx Result Register High Word •...
PIC24F Family Reference Manual 66.3 SD A/D MODULE CONFIGURATION All of the registers described in the previous section must be configured for the module operation. The various configuration and control functions of the module are distributed throughout the module’s three control registers. Control functions can be sorted into four groups: input, timing, conversion and output.
Page 10
PIC24F Family Reference Manual 66.3.2 Gain Control The Programmable Gain Amplifier (PGA) block can be used to amplify very low signals, but the differential input range of the SD A/D module should not be exceeded to avoid a saturated output result code.
Page 12
PIC24F Family Reference Manual 66.3.4 Selection of Dither Dithering helps in suppressing the Idle tones present in the SD A/D module. Dithering is the pro- cess of intentionally adding a small error to the SD A/D feedback loop in order to “decorrelate”...
PIC24F Family Reference Manual 66.4 INTERRUPT MODES There are four Interrupt modes: • Interrupt on Every Data Ready mode • Interrupt on every Fifth Data Ready mode • Interrupt on Threshold Current Value Lesser than the Previous Value mode • Interrupt on Threshold Current Value Greater than the Previous Value mode The four modes are controlled by the SDINT<1:0>...
Page 16
PIC24F Family Reference Manual Example 66-2: Channel Conversion with Offset and Gain Correction unsigned char count; signed short int offset; signed long int maxValue; const double expectedMaxValue = 32767; // 0x7FFF double gain; signed long int channelValue; double calibratedResult; // ADC initialization.
Page 18
PIC24F Family Reference Manual 66.6.2 Gain Error Correction Using Integer Math Floating-point math is easy and convenient to use, but is often undesirable during actual execution because it generally consumes a large amount of CPU execution time and code space to perform.
Page 20
PIC24F Family Reference Manual Example 66-3: Channel Conversion with Offset and Gain Correction Using Integer Math (Continued) // Adjust loop end value for desired settling time (value must be >= 5). for(count=0; count<8; count++) // Clear interrupt flag. IFS6bits.SDA1IF = 0;...
66.9 REGISTER MAP Table 66-4: SD A/D Converter Register Map File Name Bit 15 Bit 14 Bit 13 Bit 12 Bit 11 Bit 10 Bit 9 Bit 8 Bit 7 Bit 6 Bit 5 Bit 4 Bit 3 Bit 2 Bit 1 Bit 0 Resets...
This section lists application notes that are related to this section of the manual. These application notes may not be written specifically for the PIC24F device family, but the concepts are pertinent and could be used with modification and possible limitations. The current...
Page 27
Total Endurance, TSHARC, UniWinDriver, WiperLock, ZENA and Z-Scale are trademarks of Microchip Technology Incorporated in the U.S.A. and other countries. SQTP is a service mark of Microchip Technology Incorporated in the U.S.A. GestIC and ULPP are registered trademarks of Microchip Technology Germany II GmbH &...
Need help?
Do you have a question about the PIC24F and is the answer not in the manual?
Questions and answers