© Koninklijke Philips Electronics N.V. 2005. All rights reserved.
User manual
Rev. 03 — 7 June 2005
24 of 139
Philips Semiconductors
UM10119
P89LPC938 User manual
3.2.1.2
Fixed channel, continuous conversion mode
A single input channel can be selected for continuous conversion. The results of the
conversions will be sequentially placed in the eight result register pairs (see
). The
user may select whether an interrupt can be generated after every four or every eight
conversions. Additional conversion results will again cycle through the result register
pairs, overwriting the previous results. Continuous conversions continue until terminated
by the user. This mode is selected by setting the SCC0 bit in the ADMODA register.
3.2.1.3
Auto scan, single conversion mode
Any combination of the eight input channels can be selected for conversion by setting a
channel’s respective bit in the ADINS register. A single conversion of each selected input
will be performed and the result placed in the result register pair which corresponds to the
selected input channel (see
). The user may select whether an interrupt, if enabled,
will be generated after either the first four conversions have occurred or all selected
channels have been converted. If the user selects to generate an interrupt after the first
four input channels have been converted, a second interrupt will be generated after the
remaining input channels have been converted. If only a single channel is selected this is
equivalent to single channel, single conversion mode. The channels are converted from
LSB to MSB order (in ADINS). This mode is selected by setting the SCAN0 bit in the
ADMODA register.
3.2.1.4
Auto scan, continuous conversion mode
Any combination of the eight input channels can be selected for conversion by setting a
channel’s respective bit in the ADINS register. A conversion of each selected input will be
performed and the result placed in the result register pair which corresponds to the
selected input channel (See
). The user may select whether an interrupt, if
enabled, will be generated after either the first four conversions have occurred or all
selected channels have been converted. If the user selects to generate an interrupt after
the four input channels have been converted, a second interrupt will be generated after
the remaining input channels have been converted. After all selected channels have been
AD0DAT1R/L
AD01
AD0DAT5R/L
AD05
AD0DAT2R/L
AD02
AD0DAT6R/L
AD06
AD0DAT3R/L
AD03
AD0DAT7R/L
AD07
Table 7:
Input channels and result registers for fixed channel single, auto scan single, and
auto scan continuous conversion modes
…continued
Result register
Input channel
Result register
Input channel
Table 8:
Result registers and conversion results for fixed channel, continuous conversion
mode
Result register
Contains
AD0DAT0R/L
Selected channel, first conversion result
AD0DAT1R/L
Selected channel, second conversion result
AD0DAT2R/L
Selected channel, third conversion result
AD0DAT3R/L
Selected channel, fourth conversion result
AD0DAT4R/L
Selected channel, fifth conversion result
AD0DAT5R/L
Selected channel, sixth conversion result
AD0DAT6R/L
Selected channel, seventh conversion result
AD0DAT7R/L
Selected channel, eighth conversion result