# MEMS accelerometer unit

1. Apr 29, 2014

### likephysics

I am bit confused on the units when you convert acceleration to displacement.

The accelerometer data is in bits. I can convert this to gs or milli gs.
When integrating, this will get multiplied by millisecs.

What will the displacement unit be in?

2. Apr 29, 2014

### D H

Staff Emeritus
Different accelerometers have different outputs. What does the spec sheet for your particular accelerometer say?

3. Apr 29, 2014

### likephysics

Let's assume the accelerometer has digital output and a value of 256 decimal is equal to 1g.

4. Apr 29, 2014

### Baluncore

If you keep a continuous running total of the acceleration you will have velocity.
But there will be a zero velocity error and accumulating offset errors.

If you keep a continuous running total of the velocity total, you will have displacement.
But there will be a zero displacement error and accumulating errors.
Running totals are the equivalent of integration with unknown constants and so have square law errors.

If you want displacement you should measure it with a displacement transducer. You can then compute velocity and acceleration accurately from displacement. That involves differences and so will eliminate long term error accumulation. Differences are numerically stable.

5. Apr 29, 2014

### D H

Staff Emeritus
Divide by 256 to get acceleration in gs, or divide my 256*9.80665 to get acceleration in SI units.

This simple division implicitly assumes three things, none of which is true. Dividing by 256 assumes that
• A reported value of zero means zero acceleration.
All (almost all) sensors have a bias. Accelerometers are no different in this regard.
• The accelerometer output is linear.
Linear sensors would be nice. Accelerometers oftentimes have a non-linearity to them.
• That an output of 256 truly does mean 1g or (9.80665 m/s2).
It would be so very nice if the spec sheet matched reality. It doesn't.
In a simple application you can ignore all these nuances. In more complex applications, the Kalman filter oftentimes incorporate bias, non-linearity, and scale factor error as a part of the state to be estimated by the filter.

6. Apr 29, 2014

### likephysics

phew! I had completely missed multiplication by 9.8.

What about the unit of displacement?
While integrating, if the accn is multiplied by millisecs, velocity will be in m/millisec and displacement will be in mm. correct?

7. Apr 29, 2014

### D H

Staff Emeritus
Convert those counts to SI units rather than gs and your unit-based headaches will go away.