how to find vibration using accelerometer with arduino


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.


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

"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 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.


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