TOSHIBA
TMPR3904F Rev. 2.0
210
13.4
Operations
This section describes the case of Timer 2 because the operations are the same for Timers 2, 1
and 0. If there are differences on different channels, they shall be explained individually.
13.4.1
Interval timer mode
It is set up to the interval timer mode by the timer mode (TMODE)=00 of the timer control
register (TCRn; n=0,1,2). The counter clock select (CCS) of the TCRn designates to use either
the internal system clock or the external input clock. (Timer 0 can use only the internal system
clock.)
When having selected the internal system clock, the clock that results from dividing the internal
system clock can be regarded as the input of the 24-bit counter. The set up of the divider is
conducted by the counter clock divide (CCD) of the divider register when the counter clock
divide enable (CCDE) of the TCRn is 1. From 2
1
to 2
8
dividing of the internal system clock can
be set up. When having selected the external input clock, the clock edge that operates to count
can be selected in the external clock edge select (ECES) of the TCRn.
When the timer count enable (TCE) of the TCRn is set to 1, the 24-bit counter starts counting.
When the count value matches the value of the compare register A (CPRA), a flag (“1”) is
hoisted to the timer interval interrupt status (TIIS) of the status register (TISRn; n=2,1,0). The
interrupt control logic asserts the timer interrupt request signal TMINTREQ* when 1 is set to
the timer interval interrupt enable (TIIE) of the interval timer mode register (ITMRn; n=2,1,0).
When 0 is set to the TIIE, the TMINTREQ* shall not be asserted. When “0” is written into the
TIIS of the timer interrupt status register, the TIIS shall be cleared and the TMINTREQ* shall
be deasserted. The writing-in of “1” to the TIIS is ignored.
When the timer zero clear enable (TZCE) of the ITMRn is set to 1, the 24-bit counter is cleared
to 0 when the count value matches the value of the CPRA. When the TZCE is 0, the count
operation is halted when the count value matches the value of the CPRA. The interrupt request
occurrences are summarized in the Table 0-4 below.
Table 13-4 Interrupt Control by TIIE and TZCE
TIIE
TZCE
Interrupt operation when the counter has reached the set-up value.
0
*
Interrupt does not occur.
1
0
An interrupt occurs. If TZCE=0 when having recovered (write “0”
to the TIIS) from the interrupt, another interrupt shall not occur.
When the interrupt is recovered after TZCE=1 is set, it is the same
as the cases of TIIE=1 and TZCE=1.
1
1
An interrupt occurs.
The reading of the count value can be done by reading the timer read register (TRRn; n=2,1,0).
The value that was read from the TRRn is a copy of the count value of the 24-bit counter.
Fig. 9-14 shows the outline of the count operation and interrupt occurrences in the interval timer
mode.
Fig. 9-15 shows the operation using the external input clock.
Содержание TMPR3904F
Страница 1: ...Users Manual 32bit RISC Microprocessor TX39 family TMPR3904F Rev 2 0 Jan 12 1998 ...
Страница 2: ......
Страница 9: ...Users Manual 01 1 INTRODUCTION 1 1 Overview ...
Страница 10: ...Users Manual 02 1 2 Notation used in this manual Mathematical notation Data notation Signal notation ...
Страница 11: ...Users Manual 03 1 3 Kind of accessing by the TX3904 ...
Страница 12: ...Users Manual 04 1 4 Precautions in the TMPR3904F specification Don t set Don t use ...
Страница 13: ...Users Manual 05 Do not use ...
Страница 14: ...Users Manual 06 ...
Страница 15: ...Users Manual 7 2 FEATURES n n n n n n n n n n n n n ...
Страница 16: ...Users Manual 8 ...
Страница 18: ...Users Manual 10 ...
Страница 19: ...Users Manual 11 4 PINS 4 1 Positions of Pins ...
Страница 20: ...Users Manual 12 ...
Страница 21: ...Users Manual 13 4 2 Functions of Pins ...
Страница 22: ...Users Manual 14 ...
Страница 23: ...Users Manual 15 ...
Страница 24: ...Users Manual 16 ...
Страница 26: ...Users Manual 18 5 2 Register Map ...
Страница 27: ...Users Manual 19 ...
Страница 28: ...Users Manual 20 ...
Страница 30: ...Users Manual 22 5 3 2 PIO2 and PIO1 ...
Страница 32: ...Users Manual 24 5 3 4 Connection of external bus master 5 3 5 INT 7 0 active status clear ...
Страница 33: ...Users Manual 25 5 3 6 INT 7 0 active status set up ...
Страница 34: ...Users Manual 26 ...
Страница 123: ...TOSHIBA TMPR3904F Rev 2 0 115 26 ...
Страница 169: ...TOSHIBA TMPR3904F Rev 2 0 161 26 ...
Страница 203: ...TOSHIBA TMPR3904F Rev 2 0 195 ...
Страница 230: ......