0
$\begingroup$

I am getting load cell reading from my adc ADS1231 every 100 ms or say at 10Hz i.e. 10 samples per seconds. I have obtained the readings as shown in the image. As you can see i am getting spike on sample number 8 which I would like to eliminate using digital filtering method. Any advice would be of great help.

I am continuously getting the adc values and the older data will be the first one to go out the accumulator. In below image i have shown accumulator values from 1 to 10. Latest value will be at position 10 and oldest will be as position 1.enter image description here

$\endgroup$
  • $\begingroup$ appropriate low pass filtering(or even simple averaging) should resolve this issue. $\endgroup$ – arpit jain Apr 11 '17 at 10:34
  • $\begingroup$ I have tried median, mean, moving average, etc... but no use...Now any idea how to design low pass filter ? $\endgroup$ – Nimit Vachhani Apr 11 '17 at 10:44
  • $\begingroup$ you can use matlab filter design tool to specify cutoff frequencies and you will get filter coefficients which can be used for filtering. $\endgroup$ – arpit jain Apr 11 '17 at 11:28
  • $\begingroup$ Moving average is a kind of low pass filtering. maybe you should try with different lengths for taking moving average. $\endgroup$ – arpit jain Apr 11 '17 at 11:29
  • $\begingroup$ Hmm. I am tryingy hand at MATLAB. $\endgroup$ – Nimit Vachhani Apr 11 '17 at 12:35
1
$\begingroup$

I would put this in a comment but I don't have enough rep points, as just started on this.

I would recommend reading this information before designing with sigma-delta ADCs http://www.numerix-dsp.com/appsnotes/APR8-sigma-delta.pdf

It may be that you need a basic analog filter before the ADC input to prevent interfrence noise aliasing back in to your signal (assuming the load on your cell is constant?).

$\endgroup$
  • 1
    $\begingroup$ It seems you are on the right track, so please add more information. I'll vote you. $\endgroup$ – MimSaad Apr 11 '17 at 17:29
  • 1
    $\begingroup$ When designing a system like this you need to start with an idea of the bandwidth (max. signal frequency), dynamic range (signal range) and resolution that you require. You can then design the anti-aliasing filter, set the appropriate analog gain and the correct output sample rate for the sigma-delta ADC. The application note I suggested is very helpful in this regard. $\endgroup$ – cyclotron Apr 11 '17 at 17:40
  • $\begingroup$ I would also investigate why the spike ("outlyer") is there before resorting to post filtering. $\endgroup$ – cyclotron Apr 11 '17 at 17:52
  • $\begingroup$ @MimSaad I have given a decent answer. Have you lost interest? $\endgroup$ – cyclotron Apr 24 '17 at 16:48
  • $\begingroup$ OK good, please, add the information in the your comment above to your answer. $\endgroup$ – MimSaad Apr 24 '17 at 18:10
1
$\begingroup$

it looks to me that something like median filtering is what you're looking for. if you're trying to keep out the outlyers.

$\endgroup$
  • $\begingroup$ Hi, I have designed moving average filter from here[link]micromodeler.com/dsp/[link] . Sorry dont know much on how to post the links. I did download the code but am confused on how to use the filter code.. $\endgroup$ – Nimit Vachhani Apr 12 '17 at 6:30

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.