I'm working with an Adafruit LSM303DLHC Accelerometer Sensor hooked up to an Arduino. I've downloaded the appropriate libraries to make it work and uploaded the example sketch "accelsensor.pde". I then placed my sensor at rest on a flat surface and obtained the following acceleration vector values on average, in units of meters per second:
X: -0.24 Y: -0.71 Z: 10.47
At rest, each of these three values fluctuate approximately +-0.04 on average.
As I see it, the values are off a bit. At rest, the X and Y components should hover closer to 0m/s^2 while the Z component should be closer to 9.8m/s^2.
What is the best way to compensate for this biased measurement? Should I simply add back the average observed bias? Or is there a more robust method to calibrate the sensor values?