English
Language : 

MC9S08GB60A Datasheet, PDF (229/302 Pages) Freescale Semiconductor, Inc – HCS08 Microcontrollers
Analog-to-Digital Converter (S08ATDV3)
• ATD input capacitance (CAIN – maximum value 50 pF) — This is the internal capacitance of the
ATD sample and hold circuit. This capacitance varies with temperature, voltage, and process
variation but a worst case number is necessary to compute worst case sample error.
• ATD conversion clock frequency (fATDCLK – maximum value 2 MHz) — This is the frequency of
the clock input to the ATD and is dependent on the bus clock frequency and the ATD prescaler.
This frequency determines the width of the sample window, which is 14 ATDCLK cycles.
• Input sample frequency (fSAMP – see Appendix A, “Electrical Characteristics”) — This is the
frequency that a given input is sampled.
• Delta-input sample voltage (ΔVSAMP) — This is the difference between the current input voltage
(intended for conversion) and the previously sampled voltage (which may be from a different
channel). In non-continuous convert mode, this is assumed to be the greater of (VREFH – VAIN) and
(VAIN – VREFL). In continuous convert mode, 5 LSB should be added to the known difference to
account for leakage and other losses.
• Delta-analog input voltage (ΔVAIN) — This is the difference between the current input voltage and
the input voltage during the last conversion on a given channel. This is based on the slew rate of
the input.
In cases where there is no external filtering capacitance, the sampling error is determined by the number
of time constants of charging and the change in input voltage relative to the resolution of the ATD:
# of time constants (τ) = (14 / fATDCLK) / ((RAS + RAIN) * CAIN)
sampling error in LSB (ES) = 2N * (ΔVSAMP / (VREFH - VREFL)) * e−τ
The maximum sampling error (assuming maximum change on the input voltage) will be:
Eqn. 14-1
ES = (3.6/3.6) * e–(14/((7 k + 10 k) * 50 p * 2 M)) * 1024 = 0.271 LSB
Eqn. 14-2
In the case where an external filtering capacitance is applied, the sampling error can be reduced based on
the size of the source capacitor (CAS) relative to the analog input capacitance (CAIN). Ignoring the analog
source impedance (RAS), CAS will charge CAIN to a value of:
ES = 2N * (ΔVSAMP / (VREFH – VREFL)) * (CAIN / (CAIN + CAS))
Eqn. 14-3
In the case of a 0.1 μF CAS, a worst case sampling error of 0.5 LSB is achieved regardless of RAS.
However, in the case of repeated conversions at a rate of fSAMP, RAS must re-charge CAS. This recharge is
continuous and controlled only by RAS (not RAIN), and reduces the overall sampling error to:
+
(ΔVSAMP
/
(VREFH
ES = 2N * {(ΔVAIN / (VREFH – VREFL))
- VREFL)) * Min[(CAIN / (CAIN + CAS)),
* e−(1 / (fSAMP * RAS *
e−(1 / (fATDCLK * (RAS
CAS )
+ RAIN)
*
CAIN
)]}
Eqn. 14-4
This is a worst case sampling error which does not account for RAS recharging the combination of CAS
and CAIN during the sample window. It does illustrate that high values of RAS (>10 kΩ) are possible if a
large CAS is used and sufficient time to recharge CAS is provided between samples. In order to achieve
accuracy specified under the worst case conditions of maximum ΔVSAMP and minimum CAS, RAS must
be less than the maximum value of 10 kΩ. The maximum value of 10 kΩ for RAS is to ensure low sampling
error in the worst case condition of maximum ΔVSAMP and minimum CAS.
MC9S08GB60A Data Sheet, Rev. 2
Freescale Semiconductor
229