Specifications
Counter/Timers
Modes of Operation
There are six possible count modes for the counter/timers. There are
restrictions for counter/timers 0 and 1 because the control inputs are
not available externally.
Mode 0 - Interrupt on Count Termination
In Mode 0 operation, the counter/timers count down the programmed
number of counts and transition the output signal. This mode is
commonly used to count external events. Counter/timer 2 fully
supports this mode with the TCTL input available through connector
J3 of the ZT 8832. Timer/counters 0 and 1 support Mode 0 with the
exception of the TCTL input signal.
Examples of Mode 0 operation are shown in Figure 7-7. TOUT
remains low until the Down Counter reaches zero, at which point
TOUT returns high. TOUT stays high until the Count or Mode
registers are reprogrammed.
CLK
TOUT2
Count value
??
0003H 0002H 0001H 0000H FFFFH FFFEH FFFDH FFFCH FFFBH
TOUT2
Count value
??
0003H 0002H 0004H 0003H 0002H 0001H 0000H FFFFH FFFEH
TOUT2
Count value
??
0003H 0002H 0002H 0001H 0000H FFFFH FFFEH FFFDH FFFCH
TCTL2
COUNT = 0003H
(Internal)
IOWR
COUNT = 0003H COUNT = 0004H
(Internal)
IOWR
COUNT = 0003H
(Internal)
IOWR
Figure 7–7. Mode 0 Operation.
7-16