© National Instruments | 3-13
NI 6612 User Manual
Figure 3-15. Frequency Measurement: Sample Clock with Averaging
At each sample clock, the device stores T1 and T2 in a buffer. DAQmx reads these values, and
uses the known frequency of the timebase (f
k
), to calculate the frequency of the input signal (f
x
)
as:
The maximum error and maximum frequency error for this method, are given by:
To use the Sample Clock (with Averaging) method, configure the following:
• DAQmx Create channel (CI-Frequency)—Use this VI or function to create the channel.
• DAQmx Timing (Sample Clock)—Use this VI or function to set the number of samples,
sample clock source, and other properties.
• CI.Freq.EnableAveraging—Set this property to True.
By default, the counter measures the frequency on a default PFI terminal (refer to Chapter 5,
Counter Signal Routing and Clock Generation, for more information) and use an onboard
100 MHz clock as the timebase. To change the signals used for this measurement, configure the
following:
• CI.Freq.Term—The signal-to-measure comes from an input terminal. To change the
signal-to-measure, set this property to a different terminal.
Signal to
Measure (f )
Counter
Timebase (f )
Sample
Clock (f )
DAQmx
Start Task
T1 T2
1
7
T1
T2
1
7
2
10
T1 T2
1
7
2
10
1
6
Buffer
121
7106
Sample 2
Sample 3Sample 1
x
k
s
Maximum Error (%)
f
x
f
k
f
x
f
s
--- 1–×
----------------------------= 100%×
Maximum Frequency Error (Hz) f
x
f
x
f
k
f
x
f
s
--- 1–×
----------------------------×=