One-Shot 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.1 One-shot mode

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

Advertisement

Table of Contents
loading

Table of Contents