Multifunction DAQ

cancel
Showing results for 
Search instead for 
Did you mean: 

Urgent, resample input signal

Need help, urgent

 

How to resample the input signal? Not just the sampling rate (samples per second), but also it’s number of samples (samples/cycle)

this is the example:  I read 2 channel (ai0 and ai1) in sampling rate of 50khz and 5000 sample/cycle.  How to resample the ai1 from 50khz and 5000 samples/cycle to be 50khz and 25000 sample/cycle ?

 

Thanks a lot,



0 Kudos
Message 1 of 3
(3,113 Views)
Hello B.,

I built for you a VI that performs the resampling. It takes a waveform and a target number of samples (at least twice larger than the original number of samples) and performs linear interpolation to resample it. Both the original waveform (indexed 0) and the resampled one (indexed 1) are output in an array of waveforms.
Extract the VIs below in the same directory and run the example one to see how the resample sub VI works.
Hope it helps

0 Kudos
Message 2 of 3
(3,098 Views)
I use this to get an ideal interpolation.  It works as long as your data file isn't extrememly large (since it requires the use of a FFT).  Essentially you just pad the FFT with zeros and this creates an interpolated signal after the Inv FFT.
Randall Pursley
0 Kudos
Message 3 of 3
(3,092 Views)