Posts: 1
Joined: Sun May 01, 2016 7:35 pm

[RP3] measuring speed

Sun May 01, 2016 8:43 pm

Hello guys,
yesterday I ordered my first Pi and now I am seeking for use cases. Is it possible to measure the speed of whatever the Pi is attached to by using acceleration sensors or are these measurement too inaccurate? I am thinking about tracking myself while skiing. Normally I use a smartphone for this, but the measurements using GPS are quite inaccurate.


Posts: 4101
Joined: Fri Jun 08, 2012 6:03 pm

Re: [RP3] measuring speed

Tue May 03, 2016 10:16 am

Sensor Fusion.

GPS is accurate in the long term but noisy in the short term.
Accelerometers are only accurate in the short term (to get speed from acceleration you integrate, any error is also integrated making the speed in-accurate)

To get a better solution from the two, you need to fuse the raw data from both together, Kalman filtering is a commonly used way to do this.
Electronic and Computer Engineer
Pi Interests: Home Automation, IOT, Python and Tkinter

User avatar
Posts: 204
Joined: Mon Nov 10, 2014 7:39 pm
Location: Coquille OR
Contact: Website

Re: [RP3] measuring speed

Tue May 03, 2016 1:27 pm

I'll expand a little on what scotty101 said. The accelerometer cannot measure speed. What it measures is change of speed, that is, acceleration. You have to integrate that over time in order to get the present speed relative to the speed you had when you started integrating. That will accumulate errors as well as legitimate acceleration, that is, if the accelerometer is not accurately calibrated and gives you a small non-zero reading when there is no change of speed, that offset will be integrated along with legitimate signal and the speed error that it makes will accumulate.

Return to “Automation, sensing and robotics”