PCVisionplus
Hardware Reference
Registers
3–57
Rev 02; February 8, 2002
3.4.14 Timer Counter (TIMER) R/W
0
7
BADR2 + 0x3C
CNT7
CNT6
CNT5
CNT4
CNT3
CNT2
CNT1
CNT0
8
15
CNT15
CNT14
CNT13
CNT12
CNT11
CNT10
CNT9
CNT8
PCP_TIMER_32
16
23
CNT23
CNT22
CNT21
CNT20
CNT19
CNT18
CNT17
CNT16
24
31
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
Reserved
This register controls a general purpose 24-bit down-counter. The counter is clocked by the PCI-bus clock, divided
by 4 (33 MHz/4 = 8.25 MHz). If the PCI-bus clock is 33 MHz, the counter range is approximately 2 seconds. Reading
this register gives the current count value.
Bit
Mnemonic
Function
0–23
TIMERCNT
Timer Count
24–31
Reserved
“Don’t care”
3.4.14.1 Timer Count (TIMERCNT) R/W
The TIMERCNT bits define a starting value for the down counter. Writing to this register immediately loads a new
value into the counter, and the count continues from that value. The down counter is clocked by the PCI-bus clock
divided by four (33 MHz/4 = 8.25 MHz). The resolution is 121 nanoseconds (ns). The maximum count is approxi-
mately two seconds. The counter wraps from 0x000000 to 0xFFFFFF. The counter wraps from zero to 0xFFFFFF.
An interrupt is generated when the counter reaches zero, if the interrupt is enabled by the TCNTINTEN bit (AMIN-
TEN register). Reading this register gives the current count value. Software can subtract the read value from the
written value to time events.
TIMERCNT
Down-count interval
0
121 ns
1
242 ns
2
363 ns
. . .
. . .
0xFFFFFF
2 seconds
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com