Angular Errors with Accelerometers

Hi fam,

I am currently working on a project where I want to determine position using an accelerometer.
The movement of my object is strictly linear, hence I thought gyros might not be necessary to calculate the position. But then I read about the errors that can occur if the measuring direction of the accelerometer is not perfectly aligned with the direction of the object’s movement.

This leads to the question if the gyros could help correcting these angle errors and thus, I cannot only use an accelerometer?

Thx a lot for the answer :*

No. Because tiny errors like 0.01 degrees accumulate horribly in the double-integration process when you go from acceleration to speed to position. Like several kilometers error in a couple of minutes, and that's with the device sitting stationary on your desk.

Think about trying to measure acceleration while riding on a dragster car doing a 7-second pass down the quarter-mile. That's the acceleration of one gravity.

Pick a different method of measuring position. The Sharp optical distance sensors sold at Sparkfun (and lots of other places) are really great for one-dimensional positioning.

You cannot use ACC to get POSITION. Reason:

v = Integral(adt) --> v(t) = at + C0
s = Integral(vdt) --> s(t) = vt + C1 --> s(t) = at² + C0t + C1

You measure a(t), C0 and C1 are unknown.

... oh, just as MorganS posted :slight_smile:

C0 and C1 can be easily known. Set a zero point somewhere on the track and start with zero velocity.

Acceleration (a) is fantastically difficult to measure to an appropriate level of precision.

Sorry to object, but C0 and C1 are unknown per definition.

Thanks for the replay, but accelerometers and gyros (sometimes in combination with magnetometers) are used all the time to measure position. Often compensatory or Kalman filtes are used to get more accurate results.

But now I am concerned.

Plus an optical sensor cannot be inside a casing... or can it?

You need to look in the theory of "dead reckoning" for details. Sensor drift is the poision that everybody wants to cure. Usually with sensor fusion, more sensors, more expensive sensors ... well, you get it. Just imagine you sit blindfolded in a small boat on a droad river - how do you know where you are after an hour?

I was aware of that problem, I might posed my question in a wrong way. When I only deal with linear movement, do gyros add any additional information or not, since there is no rotation involved?

no roataion --> gyro useless.

timkeweb:
Thanks for the replay, but accelerometers and gyros (sometimes in combination with magnetometers) are used all the time to measure position. Often compensatory or Kalman filtes are used to get more accurate results.

But now I am concerned.

Plus an optical sensor cannot be inside a casing... or can it?

If by "all the time" you mean "On military aircraft and ICBM's and only with some careful setup and constant checking during the flight and only accurate to a few miles" then yes. If you don't have the budget for military-grade sensors then it's simply impossible to integrate acceleration and get position. Not for more than a few seconds or for accuracies better than kilometers.

Well, what is it you're trying to measure? If it's on a linear track then the sensor can look out one end of the object and see the end of the track. Or it's on the end of the track, watching the object.

Thanks a lot for the quick response :).

timkeweb:
Thanks for the replay, but accelerometers and gyros (sometimes in combination with magnetometers) are used all the time to measure position.

No, MEMS accelerometers and rate-gyros are used all the time to determine orientation, and usually need drift correction to do so if accurate yaw is needed.

Often compensatory or Kalman filtes are used to get more accurate results.

But now I am concerned.

Plus an optical sensor cannot be inside a casing… or can it?

Measuring position on a timescale of a few seconds or less, yes you can use MEMS accelerometers to measure position (not highly accurately), but long term drift means you cannot measure position on long timescales without correcting for drift using GPS/barometer or some such.

One application I’ve seen using accelerometer is a pedometer. The drift is corrected during the period the foot is planted on the ground, allowing the size of each step to be measured with reasonable accuracy.

Decently engineered precision accelerometers (not MEMS ones) can fare much much better, as they can be highly accurate by comparison, increasing the drift time scales significantly. This is how real inertial guidance systems work - and laser gyroscopes are used.

What are you actually trying to do?

I want to calculate the position of a sledge on a linear guiding of about 6 meters.

I would use a wheel and shaft encoder to measure position along a guide rail.