Jäger ADwin-Gold-USB Manual page 34

Hide thumbs Also See for ADwin-Gold-USB:
Table of Contents

Advertisement

CO1 Counter Add-On
Programming example
30
8.4.2 Impulse Width and Pause Duration Measurements
All 4 counters measure impulse width and pause duration.
LATCH
4k7
ref.-CLK
G
20 MHz
to f
ref
other counters
Fig. 24 – Block diagram of the CO1 add-on mode
"impulse width/pause duration"
The counters 1 and 2 have two latches for positive (Latch A) and negative
edges (Latch B). Thus, pulse and pause duration can be evaluated separately
by calculating the differences of the latches.
INIT:
. . .
CNT_ENABLE(0)
CNT_CLEAR(1)
CNT_MODE(1)
CNT_SET(0)
CNT_SET(1)
CNT_INPUTMODE(1)
CNT_SE_DIFF(0)
CNT_ENABLE(1)
EVENT:
CNT_READLATCH(1)
CNT_READFLATCH(1)
. . .
32 bit Latch A
f
ref
switch
Divider
CLK
÷ 4
Up
DIR
32 bit Counter
CLR
EN
switches of
32 bit Latch B
Control Registers
initialization ...
disable counters
clear counter(s)
mode "internal reference clock" with ...
... 20 MHz or
... 5 MHz reference frequency
input CLR/LATCH as LATCH input
select single-ended inputs
enable counter(s)
event loop ...
read out latch A
read out latch B
evaluate counter value in process
ADwin-Gold USB / ENET, manual version 3.8, October 2005
ADwin
Data
Data
Data

Advertisement

Table of Contents
loading

This manual is also suitable for:

Adwin-gold-enet

Table of Contents