3-16
|
ni.com
Chapter 3
Counters
Large Range with 2 Counters
This measurement method requires two counters: Counter N and Counter M.
For this measurement method, Counter N creates a pulse equal to
T1
periods of the
signal-to-measure. The device routes this pulse to Counter M. Counter M measures the duration
of this pulse by counting the number of cycles (
T2
) of the timebase.
The device returns
T2
and
T1
to DAQmx. DAQmx reads these value, and uses the known
frequency of the timebase (
f
k
)
to calculate the frequency (
f
x
) of the signal-to-measure as:
Figure 3-18.
Frequency Measurement: Large Range of Frequencies with Two Counters
With
N
as the integer that divides down the input signal (
f
x
), which can be configured in
CI.Freq.Div, the maximum error and maximum frequency error for this method are given by:
f
x
f
k
T
1
T
2
------
×
=
S
o
u
rce
O
u
t
Co
u
nter N
S
o
u
rce
G
a
te
Co
u
nter M
Co
u
nter N O
u
t
Interv
a
l
to Me
asu
re
0
1
2
3
…
T1
0
1 2
…
T2
S
ign
a
l to
Me
asu
re (f )
Co
u
nter
Time
bas
e (f )
x
k
S
ign
a
l to Me
asu
re (f )
Co
u
nter Time
bas
e (f )
x
k
Maximum Error (%)
f
x
N f
k
f
x
–
×
------------------------
=
100%
×
Maximum Frequency Error (Hz)
f
x
f
x
N f
k
f
x
–
×
------------------------
×
=