1
0
Fork 0
mirror of https://github.com/betaflight/betaflight.git synced 2025-07-19 06:15:16 +03:00

Merge pull request #714 from martinbudden/bf_msp_acc

Fixed accelerometer scaling in MSP
This commit is contained in:
borisbstyle 2016-07-10 09:13:46 +02:00 committed by GitHub
commit 0fb2461933

View file

@ -766,7 +766,7 @@ static bool processOutCommand(uint8_t cmdMSP)
headSerialReply(18);
// Hack scale due to choice of units for sensor data in multiwii
uint8_t scale = (acc.acc_1G > 1024) ? 8 : 1;
const uint8_t scale = (acc.acc_1G > 512) ? 4 : 1;
for (i = 0; i < 3; i++)
serialize16(accSmooth[i] / scale);