3-6
|
ni.com
Chapter 3
Counter Input
Other Settings
You can filter noise on any PFI signal that is an input to the counter by enabling a filter. Refer
to the
section in Chapter 6,
, for more information.
If you route the same PFI signal to multiple destinations, you should enable the Synchronization
feature. Refer to Chapter 6,
, for more information.
Exporting a Terminal Count Signal
Each counter,
n
, asserts an internal terminal count signal, Ctr
n
InternalOutput, when the count
reaches 2^32-1 when counting up, or when the count reaches 0 when counting down.
To route the terminal count signal to an output terminal, use the CtrOutEvent.OutputTerm
DAQmx Export Signal property. You can change the polarity and other behavior of the output
signal by setting CtrOutEvent.OutputBehavior, CtrOutEvent.Pulse.Polarity, and
CtrOutEvent.Toggle.IdleState.
Cascading Counters
You can cascade two counters to make a single 64-bit counter. For example, assuming that you
want to use counter 5 and counter 6 to make a 64-bit counter, configure the following:
1.
Set counter 5 to count edges.
2.
Route the signal-to-measure to counter 5.
3.
Configure counter 6 to count edges.
4.
Route the terminal count signal of counter 5 to the input of counter 6. That is, on counter 6,
set the CI.CountEdges.Term DAQmx Channel property to Ctr5InternalOutput.
Pulse Measurement
Note
This section describes Pulse measurements. For Pulse-Width measurements,
refer to the
In a Pulse measurement task, the counter measures the high and low duration of a pulse on a
signal. You can configure DAQmx to return the high and low times of the pulse, or return the
frequency and duty cycle of the pulse. Figure 3-8 shows an example of a Pulse measurement.