
XC161 Derivatives
Peripheral Units (Vol. 2 of 2)
The General Purpose Timer Units
User’s Manual
14-42
V2.2, 2004-01
GPT_X1, V2.0
Timer T5 in Gated Timer Mode
Gated timer mode for the auxiliary timer T5 is selected by setting bitfield T5M in register
T5CON to 010
B
or 011
B
. Bit T5M.0 (T5CON.3) selects the active level of the gate input.
Note: A transition of the gate signal at line T5IN does not cause an interrupt request.
Figure 14-26 Block Diagram of Auxiliary Timer T5 in Gated Timer Mode
Note: There is no output toggle latch for T5.
Start/stop of the auxiliary timer can be controlled locally or remotely.
Timer T5 in Counter Mode
Counter mode for auxiliary timer T5 is selected by setting bitfield T5M in register T5CON
to 001
B
. In counter mode, the auxiliary timer can be clocked either by a transition at its
external input line T5IN, or by a transition of timer T6’s toggle latch T6OTL. The event
causing an increment or decrement of a timer can be a positive, a negative, or both a
positive and a negative transition at either the respective input pin or at the toggle latch.
Bitfield T5I in control register T5CON selects the triggering transition (see
Prescaler
Gate
Ctrl.
Auxiliary
Timer T5
BPS2
T5I
T5IN
f
GPT
f
T5
Count
T5IRQ
MCB05407
T5UD
MUX
T5RC
T5R
T6R
Clear
Up/Down
0
1