LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

HELP: Downsample Data Acquired From Multiple Channels

Solved!
Go to solution

Currently stuck on a project that measures voltages on 12 channels using cDAQ-9188 and modules 9239. The Daq ni-9239 will coerce my data rate to only allow 1.6khz because that is all it supports, The measurements I need have to be at 100hz. I found the example below but Its configured to down sample 1khz to 250hz. I tried changing my numbers and to only sample 200 times making my sample rate 200hz from 2khz. The issue I'm seeing is when I go to graph my acquired data there are gaps. What can I do to fix the gaps or is there a better solution on how to Down Sample an Array of Waveforms. I am using the template from the Example Projects (Continuous Measurement and Logging). Can I please get some help with this issue of having to down sample and graphing my data. The data is being put into a queue and continuously being graphed in a separate while loop. Thanks!

 

http://forums.ni.com/t5/Example-Program-Drafts/Downsample-Data-Acquired-From-Multiple-Channels-Using...

0 Kudos
Message 1 of 6
(3,792 Views)

I don't have LabVIEW here to confirm, but I believe there is a resample waveform function in the Signal Processing pallet.


GCentral
There are only two ways to tell somebody thanks: Kudos and Marked Solutions
Unofficial Forum Rules and Guidelines
"Not that we are sufficient in ourselves to claim anything as coming from us, but our sufficiency is from God" - 2 Corinthians 3:5
Message 2 of 6
(3,766 Views)

I do not have LabVIEW here either to look over your VI, but the example you linked to would NOT be the correct way to down sample the data.

 

First you need to low pass filter your data, for your case put the pass band at 160Hz and then you down sample the data from 1.6kSa/s to 320Hz. 

 

If you skip the low pass filtering then you run the risk of aliasing your signal and getting an incorrect result.

 

I suggest you check out the VI crossrulz suggested, it will correctly apply the filtering according to the help.

 

Cheers,

mcduff

 

 

0 Kudos
Message 3 of 6
(3,754 Views)

Does this look correct? I found a similar example and thought this looks correct? My sample rate and samples per ch would be running at 2k

Download All
0 Kudos
Message 4 of 6
(3,741 Views)
Solution
Accepted by topic author Nailer

I will be away from my desk for awhile doing some work that pays the bills. Smiley LOL

 

At first glance it looks okay, however, I would change the interpolation mode to FIR filter instead of Coerce in the resample VI. It looks like the defaults are good for the FIR filter.

 

Cheers,

mcduff

Message 5 of 6
(3,714 Views)

Thanks mcduff and crossrulz, This seems to be working. I really appreciate your help. 

0 Kudos
Message 6 of 6
(3,702 Views)