11-28-2012 05:55 AM
Hi everyone,
I am acquiring a load cell/strain guage signal that needs some real-time smoothing prior to displaying, processing, and/or writing to the data disk... In the pass I have simply used a 2nd order LP butterworth filter at 50Hz to do this... However, I believe this is probably not the best way to do it... The more I learn about labview and signal acquisition/processing n the gernal the more pickier I am getting in my vi design... Could some please provide comment on my thoughts below..?
1. Given that the data are to be filtered in real-time a 4th order elliptic filter is probably best (due to the sharper roll-offs)...
2. The filter should be an "I.C." filter as the "DAQmx Read (Analog 1D wmf).vi" is stopped and started (using "idle" and "run" states in the vi) so that the operator can stop sending data to the chart so the graph pallete tools can be used to examine the data when need as it comes in.. My understanding is that te IC filters store the last transition state and use that to start the next filter function on subsequent data?
3. The "PybyPt" filter should be used as data are filtered in real-time as it i acquired.
4. 50 Hz lowpass seems to be ok based on eyeballing the data and reading what others have used in previous research publications...
If an elliptic filter is the best filter type to use, how do I select the most appropriate passband ripple and stopband attenuation parameters for the load cell/strain guage signal?
Regards,
Jack
11-29-2012 02:56 PM
Hello jcannon,
Designing filters is heavily signal-dependent. There is no overall best filter, most appropriate passband ripple, or stopband attenuation. For some guidelines, please see the following links:
Filter choice:
http://digital.ni.com/public.nsf/allkb/B5C159262A4976DD86256C2F005EAB94?OpenDocument
LabVIEW Elliptic Filter PtByPt VI:
http://zone.ni.com/reference/en-XX/help/371361G-01/ptbypt/elliptic_filter_ptbypt/
Filter Specifications:
https://ccrma.stanford.edu/~jos/sasp/Lowpass_Filter_Design_Specifications.html
I would suggest simply adjusting these values until your filter behaves the way you need according to your application.
11-29-2012 08:09 PM
Hi Patrick,
Thanks for the reply... I have had a read through the links you provided... Although much of what they talk about is above my head, I suspect the butterworth filter may in fact be the best as it is maximally flat (no ripples in bandpass or stopband)...
However, when should the filter be intialized? My understanding is that it should be initialized during the first iteration of the DAQ loop, and not initialized during subsequent iterations... Cold you please confirm?
Many thanks,
Jack
11-30-2012 12:23 PM
Generally, that is the way it works. The exact programming depends if you are using the express or normal filter VIs. What VIs are you using?