I am using the accelerometer MMA7455L which is connected to the micro controller (9s08Aw32) via the I2C bus. I am able to communicate to the accelerometer and read the X, Y and Z axis values from the accelerometer. But, even when the board is idle, the X, Y and Z axis values are changing everytime I read.
For Example: When the accelerometer is not moving, the X and Y axis values should be 0 and Z axis value should be 1. Even there are any deviations in these values, it can be calibrated to show the proper values. But I am not getting any constant values everytime I read the accelerometer. The values are varying in a range of 30 to 40 points which is not acceptable.
Does anybody has any idea as to why this might be happening?