
R01UH0092EJ0110 Rev.1.10
Page 641 of 807
Jul 31, 2012
M16C/64C Group
27. A/D Converter
Figure 27.14 Operation Example in Repeat Sweep Mode 1
Table 27.17
Registers and Settings in Repeat Sweep Mode 1
Register
Bit
Setting
PCLKSTP1
PCKSTP1A
Set to 0 when using f1.
PCR
PCR5
Set to 1 (
INT6
input disabled) when using the AN2_4 pin for
analog input.
PCR6
Set to 1 (
INT7
input disabled) when using the AN2_5 pin for
analog input.
PCR7
Set to 1 (key input disabled) when using pins AN4 to AN7 for
analog input.
AINRST
AINRST1,
AINRST0
Select whether open-circuit detection assist function is used or
not.
AD0 to AD7
b9 to b0
A/D conversion result can be read.
ADCON2
ADGSEL1,
ADGSEL0
Select analog input pin group.
CKS2
Select
φ
AD frequency.
ADCON0
CH2 to CH0
Disabled
MD1 to MD0
Set to 11b.
TRG
Select a trigger.
ADST
Set to 1 to start A/D conversion and set to 0 to stop it.
CKS0
Select
φ
AD frequency.
ADCON1
SCAN1, SCAN0
Select a pin to be given
priority when A/D converted
MD2
Set to 1.
CKS1
Select
φ
AD frequency.
ADSTBY
Set to 1 when performing A/D conversion.
ADEX1, ADEX0
Set to 00b.
Note:
1.
This table does not describe a procedure.
A/D conversion start
AN0
Single A/D conversion
The above diagram applies under the following conditions.
y
Bits SCAN1 to SCAN0 in the ADCON1 register are 00b (AN0 (1 pin)).
y
Bits ADGSEL1 to ADGSEL0 in the ADCON2 register are 00b (A0 to AN7).
AN2
AN1
AN3
AN4
AN5
AN6
AN7
Time
Содержание M16C Series
Страница 846: ...M16C 64C Group R01UH0092EJ0110...