Ask Your Question

Reading from an IMU (single axis)

asked 2013-03-25 05:26:46 -0600

McMurdo gravatar image

How do I use the single axis accelerometer (one in the single axis IMU) to measure linear velocity (and hence linear distance covered)?

edit retag flag offensive close merge delete

1 Answer

Sort by » oldest newest most voted

answered 2013-03-25 07:11:06 -0600

Claudio gravatar image

updated 2013-04-30 04:29:07 -0600

Basic answer: you don't.

The relation from acceleration to space is a double integral, this means the second integral is integrating the error in the first which you can't eliminate.

Accelerometers are never used alone to measure space. You could obtain a decent estimate for around 100m, no farther than that.

All of this is valid for MEMS, other technologies (like ICP) respond differently, but the double integration error is inherent in the math behind it all.

If you simulate it in matlab by moving a point by its speed, deriving acceleration and then integrating acceleration two times to obtain space, you'd see the estimate will drift hugely over time.

It would drift even if you'd use the acceleration instead of the speed, only the simulation would appear much more reliable than the real thing because you would not have all the noise that affect the various processes in a real system. Unless you simulate it that is...

Detailed explanation as to why this is the truth about MEMS sensors.

Every sensor has its pros and cons. MEMS accelerometers are misleadingly named: they don't really measure accelerations, rather they measure the direction of the gravity vector. This measure is often used to correct the bias of MEMS gyros which tend to accumulate during integration.

A proper IMU, as those found in military systems or civilian passenger jets, is a bulky, powerthirsty thing using huge sensors like mechanical gyroscopes (real rotating mass) or laser ones and real accelerometers made with displaced masses (check wikipedia).

MEMS accelerometers on the contrary are way too small and subject to noise, just like MEMS gyros: if you blindly integrate a gyro's signal, you'll end up with a big accumulated error very fast. Should you do the same with a MEMS accelerometer, integrating to get the speed, you'd also get to an unrecoverable error very fast.

This is due to the inherent nature of the mechanics involved: these kind of sensors are accurate in the transients, but have very noisy steady state ouputs. Such sensors are, by design, suitable for instantaneous measurement rather than accumulated data.

So in 6dof system the Kalman filter family greatly benefits from the fusion of accelerometers and gyroscopes because this fusion yields a very accurate 6dof estimation but don't let the names mislead you: 6dof system means it has 6 degrees of freedom, it doesn't mean it gives you accurate measurements on 6 degrees of movements. Actually what you end up with is a pretty noisy and rough estimate on 4 (the 3 translations and the z rotation) and a very accurate one on 2 (the x and y rotation).

This is much akin to human capability: if I put you in a desert and tell you where you are, than wait some time while you walk and then ask you for your estimation of your position, the degree to which you diverge from the actual position depends utterly on the ... (more)

edit flag offensive delete link more


Then what use is the IMU in measuring distance? Does it only measure angular twist (using the gyro) and nothing else? Then, of what use is the accelerometer present in the IMU. Please explain.

How does an EKF improve drastically when you include an IMU?

McMurdo gravatar image McMurdo  ( 2013-04-21 06:07:02 -0600 )edit

I've extended the answer, hope it helps you understand the problem.

Claudio gravatar image Claudio  ( 2013-04-30 00:48:46 -0600 )edit

Wow, great answer, Claudio! Maybe to add one more thing: Since MEMS IMUs alone are very bad at estimating traveled distance, you need to add other sources of information to your EKF, such as wheel odometry (which is typically rather good at estimating distance, and rather bad at estimating rotation)

Martin Günther gravatar image Martin Günther  ( 2013-04-30 01:14:36 -0600 )edit

Great idea Martin, although I didn't envision an answer as a comprehensive tutorial on position estimation ;)

Well maybe if i find the time...

Claudio gravatar image Claudio  ( 2013-04-30 04:28:25 -0600 )edit

Great Answer! Thanks!

McMurdo gravatar image McMurdo  ( 2013-06-02 20:57:22 -0600 )edit

Why is the z rotational (yaw) error noisy?

TwoBid gravatar image TwoBid  ( 2017-05-09 04:32:31 -0600 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2013-03-25 05:26:46 -0600

Seen: 2,008 times

Last updated: Apr 30 '13