8 8-bit timer/counter 5 (tc5), 1 configuration, 2 control – Toshiba TMP87CP24AF User Manual
Page 79: Toshiba
Attention! The text in this document has been recognized automatically. To view the original document, you can use the "Original mode".

TOSHIBA
TMP87CM24A/P24A
2.8
8-Bit Timer/Counter 5 (TC5)
2.8.1 Configuration
Figure 2-29. Timer/Counter 5 (TC5)
2.8.2 Control
The TC5 is controlled by a timer/counter 5 control register (TC5CR) and an
8
-bit timer register 5 (TREG5).
7 6
5
4 3 2
1 0
Write only
7 6
5
4 3 2
1 0
TC5S
TC5CK
_____ 1____ 1____
TC5M
_____ 1____
(Initial **00 0000)
TREG5
(001DH)
TC5CR
(001 EH)
00
Timer mode
TC5M
TC5 Operating mode select
01
Reserved
10
Progrmmable divider output (PDO) mode
11
Pulse width modulation (PWM) output mode
000
Reserved
Write
001
Internal clock fc/2ii or fs/23 [Hz]
TC5CK
TC5 Source clock select
010
o i l
Internal clock fc/27
Internal clock fc/23
only
100
Internal clock fc/22
101
Internal clock fc/2
110
Internal clock fc
111
Reserved
TC5S
TC5 Start control
0
Stop and clear
1
Start
Note 1: fc: High-frequency clock [Hz], fs: Low-frequency clock [Hz], *: Don't care
Note 2: The set value of timer register must satisfy the following conditions.
(a)
When in PWM output mode, 5
(b) When in any other mode than PWM output mode, 0< TREG5
Note 3: Source clock fcl22, fcl2, and fc cannot be used except in PWM output mode.
Note 4: Set the operating mode and the source clock selection when timer/counter stops (TC5S = 0).
Figure 2-30. Timer/Counter 5 Timer register. Control register
3
-
24-79
2002
-
10-03