
BAT32G1x9 user manual | Chapter 8 Timer B
273 / 1149
Rev.1.02
8.4
Operation of timer B
8.4.1 Common things about multiple patterns and features
(1) Count the sources
The selection of the counting source and the block diagram are shown in Table 8-5 and Figure 8-12,
respectively.
When selecting the phase count mode, the settings of TBTCK0~TBTCK2 bits, TBCKEG0 bits, and TBCKEG 1
bits of tbCR registers are invalid.
Table 8-5
Counting Source Selection
Count the sources
Select a method
f
CLK
, f
CLK
/2, f
CLK
/4, f
CLK
/8, f
CLK
/32
Select the counting source by the TBTCK0~TBTCK2 bit of the TBCR register.
TBCLK0 pin and
TBCLK1
External input signal for pins
The TBCR register has bits "101B" (TBCLK0 input) or "111B" in the TBCR
register
(TBCLK1 input).
Valid edges are selected by the TBCKEG0 bits and TBCKEG1
bits of the TBBCR registers. The corresponding bit of the port
mode register is "1" (input mode).
Figure 8-12
Block diagram of the counting source
TB register
TBCLK1
TBCLK0
TBTCK2~TBTCK0
Remark: TBTCLK2~TBTCLK0: TBCR register bits
counting source
f
CLK
f
CLK
/2
f
CLK
/4
f
CLK
/8
f
CLK
/32
=000B
=001B
=010B
=011B
=100B
=101B
=111B
The pulse width of the external clock input to the TBCLKj pin (j=0, 1) must be at least 3 timer B operating clock
(f
CLK
) cycles.