
A-D Converter
M30240 Group
Rev.1.00 Sep 24, 2003 Page 243 of 360
2.6.2.6 Repeat-sweep mode 1
In repeat-sweep mode 1 select functions from those listed in
Table 2.32 . An example using the indicated
procedure.
Table 2.32:
Operation of A-D converter in repeat-sweep mode 1 functions
Operation
(1) Setting the A-D conversion start flag to “1” causes the A-D converter to start the conversion on the
voltage input to the AN0 pin.
(2) After the A-D conversion on the voltage input to the AN0 pin is completed, the content of the suc-
cessive comparison register (conversion result) is transmitted to A-D register 0.
(3) Every time the A-D converter carries out A-D conversion on a selected analog input pin, the A-D
converter carries out A-D conversion on only one unsettled pin, and then the A-D converter carries out
A-D conversion from the AN0 pin again. Figure 2.89 shows ANi pin's sweep sequence. The conversion result is transmitted to A-D register i every time conversion on a pin is completed. The A-D conversion
interrupt request bit does not go to “1”.
(4) The A-D converter continues operating until software goes the A-D conversion start flag to “0”.
Figure 2.89: ANi pin sweep sequence in repeat-sweep mode
Figure 2.90: Operation timing of repeat-sweep mode 1
Item
Set-up
Item
Set-up
Operation clock
ΦA(chǔ)D
O
Divided-by-4 fAD/ divided-by-2
fAD/fAD
Trigger for starting A-D
conversion
O
Software trigger
Resolution
O
8-bit /10-bit
Trigger by ADTRG
Analog input pin
O
AN0 (1 pin) / AN0 and AN1 (2
pin) / AN0 to AN2 (3 pin) / AN0 to
AN3 (4 pin)
Sample & Hold
Not activated
O
Activated
When AN0 is selected
Con
v
e
rt
ed
analog
input
pin
Time
000
0000000
1
2
3
4
5
6
7
1
2
.
When AN0, AN1 are selected
Con
v
e
rt
ed
analog
input
pin
Time
0000000
111
1111
2
3
4
5
6
7
.
0
2
Con
v
e
rt
ed
analog
input
pin
Time
000
0000
222
3
4
5
6
7
.
3
111111
When AN0 to AN2 are selected
Con
v
e
rt
ed
analog
input
pin
Time
000
33
2
4
5
6
7
.
11111
22
3
4
When AN0 to AN3 are selected
A-D
conversion
start flag
“1”
“0”
A-D register 0
A-D register 1
φAD
A-D register 2
Result
Set to “1” by software
Result
Cleared to “0” by software
(2)
(3) Consecutive conversion
8-bit resolution :
28 φAD cycles
10-bit resolution :
33 φAD cycles
A-D
conversion
is complete
(4)
Conversion result is
transfered to A-D
conversion register
8-bit resolution :
28 φAD cycles
10-bit resolution :
33 φAD cycles
8-bit resolution :
28 φAD cycles
10-bit resolution :
33 φAD cycles
8-bit resolution :
28 AD cycles
10-bit resolution :
33 AD cycles
(1) Start AN0 pin conversion