
Enhanced Queued Analog-to-Digital Converter (EQADC)
MPC5644A Microcontroller Reference Manual, Rev. 6
1164
Freescale Semiconductor
25.7.6
ADC Result Calibration
The ADC result calibration process consists of two steps: determining the gain and offset calibration
constants, and calibrating the raw results generated by the on-chip ADCs by solving the following equation
discussed in
Section 25.6.6.7, ADC Calibration Feature
CAL_RES = GCC * R OCC+2;
Eqn. 25-1
The calibration constants GCC and OCC can be calculated from equation
provided that two
pairs of expected (CAL_RES) and measured (RAW_RES) result values are available for two different
input voltages. Most likely calibration points to be used are 25% VREF
1
and 75% VREF since they are far
apart but not too close to the end points of the full input voltage range. This allows for calculations of more
representative calibration constants. The EQADC provides these voltages via channel numbers 43 and 44.
The raw, uncalibrated results for these input voltages are obtained by converting these channels with
conversion commands that have the CAL bit negated.
The transfer equations for when sampling these reference voltages are:
CAL_RES
75%VREF
= GCC * RAW_RES
75%VREF
+ OCC+2;
CAL_RES
25%VREF
= GCC * RAW_RES
25%VREF
+ OCC+2;
Thus;
GCC = (CAL_RES
75%VREF
– CAL_RES
25%VREF
) / (RAW_RES
75%VREF
– RAW_RES
25%VREF
);
Eqn. 25-2
OCC = CAL_RES
75%VREF
– GCC*RAW_RES
75%VREF
– 2;
Eqn. 25-3
or
OCC = CAL_RES
25%VREF
– GCC*RAW_RES
25%VREF
– 2;
Eqn. 25-4
After being calculated, the GCC and OCC values must be written to ADC registers:
ADC0/1 Gain Calibration Constant Registers (ADC0_GCCR and ADC1_GCCR)
, and
ADC0/1 Offset Calibration Constant Registers (ADC0_OCCR and ADC1_OCCR)
configuration commands.
The EQADC will automatically calibrate the results, according to equation
conversion command that has its CAL bit asserted using the GCC and OCC values stored in the ADC
calibration registers.
NOTE
For accurate calibration, the 25% VREF channel must be converted using
the Long Sample Time (LST) setting for either 64 or 128 ADC sample
cycles in the ADC Conversion Command Message (LST = 0b10 or 0b11).
1.
VREF=VRH-VRL
Summary of Contents for MPC5644A
Page 2: ...MPC5644A Microcontroller Reference Manual Rev 6 2 Freescale Semiconductor...
Page 24: ...MPC5644A Microcontroller Reference Manual Rev 6 24 Freescale Semiconductor...
Page 26: ...MPC5644A Microcontroller Reference Manual Rev 6 26 Freescale Semiconductor...
Page 52: ...Introduction MPC5644A Microcontroller Reference Manual Rev 6 52 Freescale Semiconductor...
Page 56: ...Memory Map MPC5644A Microcontroller Reference Manual Rev 6 56 Freescale Semiconductor...
Page 1228: ...Decimation Filter MPC5644A Microcontroller Reference Manual Rev 6 1228 Freescale Semiconductor...
Page 1440: ...FlexCAN Module MPC5644A Microcontroller Reference Manual Rev 6 1440 Freescale Semiconductor...