English
Language : 

MC80F0204 Datasheet, PDF (56/126 Pages) List of Unclassifed Manufacturers – 8-BIT SINGLE-CHIP MICROCONTROLLERS
MC80F0104/0204
Preliminary
13.2 16-bit Timer / Counter Mode
The Timer register is being run with all 16 bits. A 16-bit
timer/counter register T0, T1 are incremented from 0000H
until it matches TDR0, TDR1 and then resets to 0000H.
The match output generates Timer 0 interrupt.
The clock source of the Timer 0 is selected either internal
or external clock by bit T0CK[2:0]. In 16-bit mode, the bits
T1CK[1:0] and 16BIT of TM1 should be set to "1" respec-
tively as shown in Figure 13-9 .
Likewise, A 16-bit timer/counter register T2, T3 are incre-
mented from 0000H until it matches TDR2, TDR3 and then
resets to 0000H. The match output generates Timer 2 inter-
rupt.
The clock source of the Timer 2 is selected either internal
or external clock by bit T2CK[2:0]. In 16-bit mode, the bits
T3CK[1:0] and 16BIT of TM3 should be set to "1" respec-
tively as shown in Figure 13-10 .
Even if the Timer 0 (including Timer 1) is used as a 16-bit
timer, the Timer 2 and Timer 3 can still be used as either
two 8-bit timer or one 16-bit timer by setting the TM3. Re-
versely, even if the Timer 2 (including Timer 3) is used as
a 16-bit timer, the Timer 0 and Timer 1 can still be used as
8-bit timer independently.
TM0
7
6
5
4
3
2
1
0
-
- CAP0 T0CK2 TB0TCCKL1 T0CK0 T0CN T0ST
-
-
0
X
X
XX
X
ADDRESS: 0D0H
INITIAL VALUE: --00 0000B
X means don’t care
TM1
7
6
5
4
3
2
1
0
POL 16BIT PWM1E CAP1 TB1TCCKL1 T1CK0 T1CN T1ST
X1
0
0
1
1
X
X
ADDRESS: 0D2H
INITIAL VALUE: 00H
X means don’t care
EC0 PIN
XIN PIN
EDGE
DETECTOR
T0CK[2:0]
111
÷2
000
÷4
001
÷8
010
÷ 32
011
÷ 128
100
÷ 512
101
÷ 2048 110
MUX
T0CN
TIMER 0 + TIMER 1 → TIMER 0 (16-bit)
T0ST
0: Stop
1: Clear and start
T1 + T0
(16-bit)
clear
Comparator
TDR1 + TDR0
(16-bit)
Higher byte Lower byte
COMPARE DATA
T0IF
TIMER 0
INTERRUPT
(Not Timer 1 interrupt)
Figure 13-9 16-bit Timer/Counter for Timer 0, 1
52
Mar. 2005 Ver 0.2