LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

read waveform file from .mat file and perform filtering

I have a sample waveform stored in matlab (.mat) and would like to perform various filtering after reading it. I am able to read and view the the waveform on a Waveform graph, but unable to do any filtering.

Can somebody help suggest a way to read the .mat file, perform low pass filtering and display it on a graph ?

0 Kudos
Message 1 of 5
(3,619 Views)

If you are able to read the data and display it on a graph, then you have the information in a usable format within LV.

 

Just connect the wire going to the graph to the filter input. What you may not have is the timing information.

 

Is your data an array, a waveform, or some other datatype? Is the sampling rate or the timie increment between samples saved in the MATLAB file?

 

LYNN

0 Kudos
Message 2 of 5
(3,606 Views)

Thanks Lynn, the Matlab file is an array of 8 channel waveforms. However, the sampling rate information is not available. When I connect the wire going to the waveform graph to the filter input, I get an error for the filter when executing, it mentions that the the dt <= 0. Any ideas ?

0 Kudos
Message 3 of 5
(3,591 Views)

The filter VIs assume a default value of dt if none is present in the input data.

 

There are several ways this could be resolved. Please post your VI along with some typical data so we can see what you hve tried.

 

Lynn

0 Kudos
Message 4 of 5
(3,584 Views)

Hi Lynn,

 

Attached is the vi and the sample data .mat file.

 

regards,

Prakash

Download All
0 Kudos
Message 5 of 5
(3,566 Views)