Repeat Mode - Renesas M16C Series User Manual

16-bit single-chip microcomputer
Hide thumbs Also See for M16C Series:
Table of Contents

Advertisement

M30240 Group

1.2.24.2 Repeat mode

In repeat mode, the pin selected using the analog input pin select bit is used for repeated A-D conver-
sion.Table 1.32 shows the specifications of repeat mode. Figure 1.100 shows the A-D control register
in repeat mode.
Table 1.32:
Repeat mode specification
Item
Function
Star condition
Stop condition
Interrupt request generation timing
Input pin
Reading of result of A-D converter
A-D control register 0 (Note 1)
A-D control register 0 (Note 1)
b7
b7
b6
b6
b5
b5
b4
b4
0 1
0 1
A-D control register 1 (Note)
A-D control register 1 (Note)
b7
b7
b6
b6
b5
b5
b4
b4
0 0
0 0
1
1
Figure 1.100: A-D conversion register in repeat mode
Rev.1.00 Sep 24, 2003 Page 104 of 360
The pin selected by the analog input pin select bit is used for repeated A-D
Writing "1" to A-D conversion start flag
Writing "0" to A-D conversion start flag
None generated
One of AN0 to AN7, as selected
Read A-D register corresponding to selected pin
b3
b3
b2
b2
b1
b1
b0
b0
Symbol
Symbol
Address
Address
ADCON0
ADCON0
03D6
03D6
Bit symbol
Bit symbol
Bit name
Bit name
CH0
CH0
Analog input pin
Analog input pin
CH1
CH1
select bit
select bit
CH2
CH2
MD0
MD0
A-D operation mode
A-D operation mode
select bit 0
select bit 0
MD1
MD1
TRG
TRG
Trigger select bit
Trigger select bit
A-D conversion start flag
A-D conversion start flag
ADST
ADST
CKS0
CKS0
Frequency select bit 0
Frequency select bit 0
Note 1: If the A-D control register is rewritten during A-D conversion, the conversion
Note 1: If the A-D control register is rewritten during A-D conversion, the conversion
result is indeterminate.
result is indeterminate.
Note 2: When changing A-D operation mode, set analog input pin again.
Note 2: When changing A-D operation mode, set analog input pin again.
b3
b3
b2
b2
b1
b1
b0
b0
Symbol
Symbol
Address
Address
0
0
ADCON1
ADCON1
03D7
03D7
Bit symbol
Bit symbol
Bit name
Bit name
SCAN0
SCAN0
A-D sweep pin
A-D sweep pin
select bit
select bit
SCAN1
SCAN1
A-D operation mode
A-D operation mode
MD2
MD2
select bit 1
select bit 1
8/10-bit mode select bit
8/10-bit mode select bit
BITS
BITS
CKS1
CKS1
Frequency select bit 1
Frequency select bit 1
VCUT
VCUT
Vref connect bit
Vref connect bit
Reserved bit
Reserved bit
Note: If the A-D control register is rewritten during A-D conversion, the conversion
Note: If the A-D control register is rewritten during A-D conversion, the conversion
result is indeterminate.
result is indeterminate.
Specification
When reset
When reset
00000XXX
00000XXX
16
16
2
2
Function
Function
b2 b1 b0
b2 b1 b0
0 0 0 : AN
0 0 0 : AN
is selected
is selected
0
0
0 0 1 : AN
0 0 1 : AN
is selected
is selected
1
1
0 1 0 : AN
0 1 0 : AN
is selected
is selected
2
2
0 1 1 : AN
0 1 1 : AN
is selected
is selected
3
3
1 0 0 : AN
1 0 0 : AN
is selected
is selected
4
4
1 0 1 : AN
1 0 1 : AN
is selected
is selected
5
5
1 1 0 : AN
1 1 0 : AN
is selected
is selected
6
6
1 1 1 : AN
1 1 1 : AN
is selected
is selected
7
7
b4 b3
b4 b3
0 1 : Repeat mode
0 1 : Repeat mode
0 : Software trigger
0 : Software trigger
1 : AD
1 : AD
trigger
trigger
TRG
TRG
0 : A-D conversion disabled
0 : A-D conversion disabled
1 : A-D conversion started
1 : A-D conversion started
0 : f
0 : f
/4 is selected
/4 is selected
AD
AD
1 : f
1 : f
/2 is selected
/2 is selected
AD
AD
When reset
When reset
00
00
16
16
16
16
Function
Function
Invalid in repeat mode
Invalid in repeat mode
0 : Any mode other than repeat sweep mode 1
0 : Any mode other than repeat sweep mode 1
0 : 8-bit mode
0 : 8-bit mode
1 : 10-bit mode
1 : 10-bit mode
0 : f
0 : f
/2 or f
/2 or f
/4 is selected
/4 is selected
AD
AD
AD
AD
1 : f
1 : f
is selected
is selected
AD
AD
1 : Vref connected
1 : Vref connected
Always set to "0"
Always set to "0"
A-D Converter
R
R
W
W
(Note 2)
(Note 2)
(Note 2)
(Note 2)
R
R
W
W

Advertisement

Table of Contents
loading

Table of Contents