Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Accelerometer: different values on different devices?

I am needing to implement a shake recognizer, and I am using the accelerometer on the device to that. However, when I check the values I get from the sensor, it appears that they vary wildly from device to device. For instance, I get a value range of 0-8 as force (after some calculations) on one device, and on the other 0 - 4.

So it looks like they have very different ranges.

Is there anything I can do to make these ranges equal. Or are there some variables that I can use to somehow calculate what a fairly hard shake would be?

like image 886
Peterdk Avatar asked Mar 14 '26 05:03

Peterdk


1 Answers

According to specification accelerometer should return Measures the acceleration force in m/s2. So it should be calibrated. One thing you could check however is the Sensor class's getMaximumRange() and getResolution()

like image 100
Vajk Hermecz Avatar answered Mar 16 '26 20:03

Vajk Hermecz



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!