My final test programs aquire waveforms that are basically square waves. We use scope cards for this because we also need to characterize the voltage levels as well as symmetry, etc.
Since the earliest days of when I inherited this process, we have fetched a 1D array of DBL for the waveform. That is, the element number is the sample number, and the element value is the voltage. If I take 100,000 samples, thats how big my array is.
I've been struggling with extracting the frequency information. I have a working solution but I don't like it. I put an extra Fetch down in the aquisition routine, but configured for WDT instead of 1D DBL. Then I can pop this into the Tone Measurement VI to get the frequency. The problem is, I have a lot of aquisitions, and the Tone Measuremnt VI adds some time. Also, I just don't like doing another fetch.
I thought I had a solution, see attached. However, the frequency result varies in strange ways as I change the sample rate. At 100mS/s and 20 mS/s, the results are very similar, but at 40 MS/s, its way off. I saved a data set at 100 MS/s and one at 40 MS/s.
I can't figure out why the Frequency VI won't cooperate. Any help?
~~~~~~~~~~~~~~~~~~~~
Paul Johnson
Renco Encoders, Inc
Goleta, CA
~~~~~~~~~~~~~~~~~~~~