change the range of accel

This commit is contained in:
KalmanSLightech
2018-07-23 11:23:44 +08:00
parent 08fb1a425f
commit c5a4161b9c
3 changed files with 5 additions and 5 deletions

View File

@@ -52,9 +52,9 @@ void Motions::SetMotionCallback(motion_callback_t callback) {
imu->temperature = seg.temperature / 326.8f + 25;
if(imu->flag == 1) {
imu->accel[0] = seg.aceel_or_gyro[0] * 8.f / 0x10000;
imu->accel[1] = seg.aceel_or_gyro[1] * 8.f / 0x10000;
imu->accel[2] = seg.aceel_or_gyro[2] * 8.f / 0x10000;
imu->accel[0] = seg.aceel_or_gyro[0] * 12.f / 0x10000;
imu->accel[1] = seg.aceel_or_gyro[1] * 12.f / 0x10000;
imu->accel[2] = seg.aceel_or_gyro[2] * 12.f / 0x10000;
imu->gyro[0] = 0;
imu->gyro[1] = 0;
imu->gyro[2] = 0;