Chapter 3
Connecting Signals
©
National Instruments Corporation
3-17
Figure 3-8.
Event-Counting Application with External Switch Gating
Use level gating to measure pulse width. Apply the pulse to be measured
to the counter GATE input. Load the counter with the known count and
program the counter to count down while the signal at the GATE input is
high. The pulse width equals the counter difference (loaded value minus
read value) multiplied by the CLK period.
To measure time lapse, program a counter to be edge gated. Apply an edge
to the counter GATE input to start the counter. Program the counter to start
counting after receiving a low-to-high edge. The time lapse since receiving
the edge equals the counter value difference (loaded value minus the read
value) multiplied by the CLK period.
+5 V
Signal
Source
Switch
I/O Connector
19
DGND
CLK
GATE
OUT
Counter
DAQCard-700