R01UH0092EJ0110 Rev.1.10
Page 598 of 807
Jul 31, 2012
M16C/64C Group
26. Consumer Electronics Control (CEC) Function
26.3
Operations
26.3.1
Standard Value and I/O Timing
CEC transmission/reception is based on the count source cycle.
When outputting, an output waveform is based on the count source cycle which is closest to the CEC
standard value. When inputting, an input waveform is sampled in the count source cycle.
Also, the input/output is practically performed based on the count source cycle closest to the
acceptable range or output timing.
26.3.2
Count Source
Select fC or timer A0 underflow by bits CCLK1 to CCLK0 in the CECC1 register. In either case, the
clock frequency should be 32.768 kHz and oscillation allowable error should be within ±1%. Set the
CECEN bit in the CECC1 register to 1 (CEC enabled), after the count source is selected by bits
CCLK1 and CCLK0 and when the count source is stable.
To use fC, set the PM25 bit in the PM2 register to 1 (peripheral clock fC provided). Refer to
Generator” for details.
When the timer A0 underflow is used as the count source, each time timer A0 underflows the internal
signal of the timer A0 is inverted. Since this internal signal is the count source, two cycles of timer A0
underflows are one cycle of the count source. Figure 26.3 shows the Count Source When Timer A0
Underflow Selected. Use timer A0 without timer mode and gate function. Refer to 17. “Timer A” for
details.
Figure 26.3
Count Source When Timer A0 Underflow Selected
26.3.3
CEC Input/Output
The CEC input and output share pins with the I/O port and
NMI
input. To use CEC input and output, set
bits as follows:
•
Set the PM24 bit in the PM2 register to 0 (
NMI
interrupt disabled)
•
Set the PCR4 bit in the PCR register to 1 (CEC output enabled)
•
Set the PD8_5 bit in the PD8 register to 0 (input mode)
Also, the CEC input has a digital filter. (refer to
.
1
32.768 kHz
Timer A0
underflow cycle
Timer A0
underflow cycle
Inverted by underflow
Count source
(Timer A0 internal signal)
Содержание M16C Series
Страница 846: ...M16C 64C Group R01UH0092EJ0110...