Fixed accelerometer code after integration