TMP92CF30
2009-06-12
92CF30-276
3.13.4 Operation in Each Mode
(1) 16 bit timer mode
Generating interrupts at fixed intervals
In this example, the interrupt INTTB01 is set to be generated at fixed intervals. The
interval time is set in the timer register TB0RG1H/L.
7
6
5
4
3
2
1
0
TB0RUN
←
– 0 X X –
–
X
0
Stop
TMRB0
INTETB0
←
X
1
0
0
X
0
0
0
Enable INTTB01and set interrupt level 4.
Disable
INTTB00
TB0FFCR
←
1
1
0
0
0
0
1
1
Disable the trigger
TB0MOD
←
0
0
1
0
0
1
*
*
Select internal clock for input and
(**
=
01, 10, 11)
disable the capture function.
TB0RG1H/L
←
*
*
*
*
*
*
*
*
Set the interval time
*
*
*
*
*
*
*
*
(16 bits).
TB0RUN
←
– 0 X X –
1
X
1
Start
TMRB0.
X: Don't care,
−
: No change
(2) 16 bit event counter mode
In 16 bit timer mode as described in above, the timer can be used as an event counter
by selecting the external clock (TB0IN0 pin input) as the input clock. Up counter
(UC10) counts up at the rising edge of TB0IN0 input. To read the value of the counter,
first perform “software capture” once and read the captured value.
7
6
5
4
3
2
1
0
TB0RUN
←
– 0 X X –
–
X
0
Stop
TMRB0
PPCR
←
X
X
–
1
–
–
–
X
Set PP4 to input mode for TB0IN0
PPFC
←
– – – 1 –
–
–
X
INTETB0
←
X
1
0
0
X
0
0
0
Enable INTTB01 and sets interrupt level 4
Disable
INTTB00
TB0FFCR
←
1
1
0
0
0
0
1
1
Disable trigger
TB0MOD
←
0
0
1
0
0
1
0
0
Select TB0IN0 as the input clock
TB0RG1H/L
←
*
*
*
*
*
*
*
*
Set the number of counts
*
*
*
*
*
*
*
*
(16 bit)
TB0RUN
←
– 0 X X –
1
X
1
Start
TMRB0
X: Don't care,
−
: No change
When used as an event counter, set the prescaler in RUN mode.
(TB0RUN <TB0PRUN>
=
“1”)
Содержание TLCS-900/H1 Series
Страница 1: ...TOSHIBA Original CMOS 32 Bit Microcontroller TLCS 900 H1 Series TMP92CF30FG Semiconductor Company ...
Страница 650: ...TMP92CF30 2009 06 12 92CF30 648 7 Package Dimensions LQFP176 P 2020 0 40F TOP VIEW BOTTOM VIEW Detail view of A 25 1 A ...
Страница 652: ...TMP92CF30 2009 06 12 92CF30 650 ...