how to find vibration using accelerometer with arduino

Hi,

I’m using accelerometer ADXL335 for my project. I have connected it with arduino uno and I’m getting the readings in mV for x,y and z axes. I want to measure vibration form these readings. How do I do that? Please help.

Thank you.

idle.JPG

The best way would be to use an FFT, ( Fast Fourier Transform ).

http://www.arduinoos.com/2010/10/fast-fourier-transform-fft/

http://en.wikipedia.org/wiki/Jerk_%28physics%29

"Vibration" is the rate of change in acceleration. Basically you want to take the absolute value of the difference between consecutive readings of your accelerometer.

Also see http://playground.arduino.cc/Main/RunningAverage. What you probably want to do is take the running average of the change in acceleration for the last "X" readings.

Thank for the reply.

I tried to take FFT in arduino as instructed in the website. But I'm getting errors like; error: 'PlainFFT' has not been declared

What should I do? Please help.

Thank you

What should I do? Please help.

Post your code and links to any libraries you installed, which by the sound of it you haven’t.

Hi,

I’m able to Take FFT and it works. Thanks a lot…