Enhanced Queued Analog-to-Digital Converter (eQADC)
MPC5566 Microcontroller Reference Manual, Rev. 2
Freescale Semiconductor 19-117
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 x RAW_RES
75%VREF
 + OCC + 2;  Eqn. 19-2
CAL_RES
25%VREF
 = GCC x RAW_RES
25%VREF
 + OCC + 2;  Eqn. 19-3
Thus;
GCC = (CAL_RES
75%VREF
 - CAL_RES
25%VREF
) / (RAW_RES
75%VREF
 - RAW_RES
25%VREF
);  Eqn. 19-4
OCC = CAL_RES
75%VREF
 - GCC x RAW_RES
75%VREF
 – 2;  Eqn. 19-5
or
OCC = CAL_RES
25%VREF
 - GCC x RAW_RES
25%VREF
 – 2;  Eqn. 19-6
After being calculated, the GCC and OCC values must be written to ADC0_GCCR and ADC1_GCCR 
registers (see Section 19.3.3.4, “ADCn Gain Calibration Constant Registers (ADC0_GCCR and 
ADC1_GCCR)”) and the ADC0_OCCR and ADC1_OCCR registers (see Section 19.3.3.5, “ADCn Offset 
Calibration Constant Registers (ADC0_OCCR and ADC1_OCCR)”) using write configuration 
commands.
The eQADC automatically calibrates the results, according to Equation 19-1, of every conversion 
command that has its CAL bit asserted using the GCC and OCC values stored in the ADC calibration 
registers.
19.5.6.1 MAC Configuration Procedure
The following steps illustrate how to configure the calibration hardware, that is, determining the values of 
the gain and offset calibration constants, and the writing these constants to the calibration registers. This 
procedure should be performed for both ADC0 and ADC1.
1. Convert channel 44 with a command that has its CAL bit negated and obtain the raw, uncalibrated 
result for 25% V
REF
 (RAW_RES
25%VREF
).
2. Convert channel 43 with a command that has its CAL bit negated and obtain the raw, uncalibrated 
result for 75% V
REF
 (RAW_RES
75%VREF
).
3. Because the expected values for the conversion of these voltages are known (CAL_RES
25%VREF
 
and CAL_RES
75%VREF
), GCC and OCC values can be calculated from Equation 19-4 and 
Equation 19-5 using these values, and the results determined in steps 1 and 2.
4. Reformat GCC and OCC to the proper data formats as specified in Section 19.4.5.4.2, “MAC Unit 
and Operand Data Format.” GCC is an unsigned 15-bit fixed point value and OCC is a signed 
14-bit value.