Rev. 1.0, 09/02, page 434 of 568
17.4 Operation
The A/D converter operates by successive approximation with 10-bit resolution. It has two
operating modes; single mode and scan mode. When changing the operating mode or analog input
channel, clear the ADST bit in ADCSR to 0 first in order to prevent incorrect operation. The
ADST bit can be set at the same time as the operating mode or analog input channel is changed.
17.4.1 Single
Mode
In single mode, A/D conversion is performed only once on the specified single channel as follows:
1. A/D conversion is started when the ADST bit is set to 1 by software or external trigger input.
2. When A/D conversion is completed, the result is transferred to the A/D data register
corresponding to the channel.
3. On completion of conversion, the ADF bit in ADCSR is set to 1. If the ADIE bit is set to 1 at
this time, an ADI interrupt request is generated.
4. The ADST bit retains 1 during A/D conversion. When A/D conversion ends, the ADST bit is
automatically cleared to 0 and the A/D converter enters the wait state. If the ADST bit is
cleared to 0 during A/D conversion, the conversion is stopped and the A/D converter enters the
wait state.
17.4.2 Scan
Mode
In scan mode, A/D conversion is to be performed sequentially on the specified channels up to four
channels as follows.
1. When the ADST bit is set to 1 by software, TPU or external trigger input, A/D conversion
starts on the first channel in the group (for example, AN0 when CH3 and CH2 = 00, AN4
when CH3 and CH2 = 01, AN8 when CH3 and CH2 = 10, or AN12 when CH3 and CH2 = 11).
2. When the A/D conversion is completed on one channel, the result is sequentially transferred to
the A/D data register corresponding to the channel.
3. When the conversion is completed on all the selected channels, the ADF bit in ADCSR is set
to 1. If the ADIE bit is set to 1 at this time, an ADI interrupt is requested after A/D conversion
ends. Then, the A/D converter restarts the conversion from the first channel in the group.
4. Steps 2 to 3 are repeated as long as the ADST bit is set to 1. When the ADST bit is cleared to
0, the A/D conversion stops and the A/D converter enters the wait state.
Summary of Contents for H8S/2627
Page 22: ...Rev 1 0 09 02 page xx of xxxvi Index 565 ...
Page 30: ...Rev 1 0 09 02 page xxviii of xxxiv ...
Page 36: ...Rev 1 0 09 02 page xxxiv of xxxiv Table 23 9 Flash Memory Characteristics 561 ...
Page 82: ...Rev 1 0 09 02 page 46 of 568 ...
Page 88: ...Rev 1 0 09 02 page 52 of 568 ...
Page 98: ...Rev 1 0 09 02 page 62 of 568 ...
Page 156: ...Rev 1 0 09 02 page 120 of 568 ...
Page 390: ...Rev 1 0 09 02 page 354 of 568 ...
Page 480: ...Rev 1 0 09 02 page 444 of 568 ...
Page 512: ...Rev 1 0 09 02 page 476 of 568 ...
Page 528: ...Rev 1 0 09 02 page 492 of 568 ...
Page 580: ...Rev 1 0 09 02 page 544 of 568 ...