3-8
Theory of Operation
KPCMCIA-12AIAOH User’s Manual
There are four timer/counter modes: 0, 1, 2, and 3. In mode 0, the counter stops and reloads with
the initial value by the rising edge of the selected clock source. In mode 1, the counter pauses
counting but does not reload (as it does in mode 0). Mode 2 is the counting mode in which the
counter counts up the rising edge of the selected clock source. In mode 3, the counter is controlled
by the external gate (shared with D/A) signal. The counting proceeds when the signal is high and
pauses when the signal is low.
Three I/O pins are associated with the timer: the external clock source input (shared with the
pacer clock), external gate control (shared with D/A), and the timer overflow pulse output (TTL),
which goes high when the timer reaches its final count (hexadecimal FFFF).
The reload register can be set up for both counting and timing operations. The value written into
the reload register, denoted as X for the sake of the discussion, determines the divisor or modulus
for timing and counting. Since the final count before reloading is always 65535 (hexadecimal
FFFF) for the up-counter, the reload (initial) value determines from where the counting will start.
Therefore, 65536 - X will be the divisor for timing operations or the modulus for counting oper-
ations. For example, a divided-by-2 timer (or modulus 2 counter) can be configured by setting X
equal to 65534, while X = 0 implies the divisor is 65536 (or the modulus is 65536).
Avoid X = 65535 (hexadecimal FFFF) because the timer will be stuck at the final count and the
hardware will not reject or indicate such a setting.
Changing the reload register “on the fly” is allowed, but the setting will not take effect until the
up-counter reaches its final count (65535 or hexadecimal FFFF). The next clock rising edge will
load the counter with the new setting.
The timer interrupt is enabled and disabled by software. When enabled, an interrupt is sent each
time the up-counter overflows (passes through its final count).
Summary of Contents for KPCMCIA-12AIAOH
Page 11: ...1 Introduction...
Page 15: ...2 Installation...
Page 17: ...3 Theory of Operation...
Page 25: ...4 I O Connections...
Page 28: ...5 Optional Accessories...
Page 30: ...A Specifications...
Page 33: ...B PCMCIA Interface...
Page 36: ...C I O Registers...