English
Language : 

XC164-16 Datasheet, PDF (48/417 Pages) Infineon Technologies AG – 16-Bit Single-Chip Microcontroller with C166SV2 Core Volume 2 (of 2): Peripheral Units
XC164-16 Derivatives
Peripheral Units (Vol. 2 of 2)
The General Purpose Timer Units
Timer T6 Run Control
The core timer T6 can be started or stopped by software through bit T6R (timer T6 run
bit). This bit is relevant in all operating modes of T6. Setting bit T6R will start the timer,
clearing bit T6R stops the timer.
In gated timer mode, the timer will only run if T6R = 1 and the gate is active (high or low,
as programmed).
Note: When bit T5RC in timer control register T5CON is set, bit T6R will also control
(start and stop) the Auxiliary Timer T5.
Count Direction Control
The count direction of the GPT2 timers (core timer and auxiliary timer) can be controlled
either by software or by the external input pin TxEUD (Timer Tx External Up/Down
Control Input). These options are selected by bits TxUD and TxUDE in the respective
control register TxCON. When the up/down control is provided by software (bit
TxUDE = 0), the count direction can be altered by setting or clearing bit TxUD. When bit
TxUDE = 1, pin TxEUD is selected to be the controlling source of the count direction.
However, bit TxUD can still be used to reverse the actual count direction, as shown in
Table 14-11. The count direction can be changed regardless of whether or not the timer
is running.
Table 14-11 GPT2 Timer Count Direction Control
Pin TxEUD Bit TxUDE Bit TxUD
Count Direction
X
0
0
Count Up
X
0
1
Count Down
0
1
0
Count Up
1
1
0
Count Down
0
1
1
Count Down
1
1
1
Count Up
User’s Manual
GPT_X41, V2.0
14-35
V2.1, 2004-03