Counter Applications - Advantech PCM-3718 Series User Manual

Pc/104 12-bit das module with programmable gain
Table of Contents

Advertisement

and CNT to 0. The latter method has the advantage of operating several
counters at the same time. A subsequent read operation on the selected
counter will retrieve the latched value.

7.5 Counter Applications

The 8254 programmable Interval timer/counter on your PCM-3718 inter-
face module is a very useful device. You can program counters 1 and 2 as
pacers to generate A/D conversion trigger pulses.
Setting the Pacer Rate
The following equation gives the pacer rate:
Pacer rate = FCLK / (C1 *C2)
FCLK is either 1 MHz or 10 MHz, as set by jumper JP1. The following
steps tell you how to set the counter modes and constants:
1.
Set Counter 1 to Mode 3 by writing '76h' to address BASE+15.
2.
Set Counter 1's divisor constant C1 by writing to BASE+13. Con-
stant C1 can be any 16-bit value from 2 to 65535. Because the 8254
has 8-bit registers, you should first write the low byte of C1 to
BASE+13, then write the high byte of C1 to BASE+13.
3.
Set Counter 2 to Mode 3 by writing 'B6h' to address BASE+15.
4.
Set Counter 2's divisor constant C2 by writing to BASE+14. Con-
stant C2 can be any 16-bit value from 2 to 65535. Because the 8254
has 8-bit registers, you should first write the low byte of C2 to
BASE+14, then write the high byte of C2 to BASE+14.
Artisan Technology Group - Quality Instrumentation ... Guaranteed | (888) 88-SOURCE | www.artisantg.com
59
Chapter 7

Advertisement

Table of Contents
loading

This manual is also suitable for:

Pcm-3718hPcm-3718hgPcm-3718ho

Table of Contents