IMU calculating velocity

Could you clarify this condition. Is your sensor stationary?
Can you print out the raw Accelerometer values?
Is stationary an acceleration of 1? (i.e. gravity).

My experience with this type of problem is it is best to remove all calculation and unneeded code and work with the raw numbers and little other code.