lis3mdl: Fix check_calibration() output

The previous implementation returned OK when the sensor was not calibrated and vice
versa. This fixes a preflight fail due to selftest failed.
This commit is contained in:
Michael Schaeuble 2017-02-27 18:21:25 +01:00 committed by Lorenz Meier
parent cff430e137
commit 497a210742
1 changed files with 1 additions and 6 deletions

View File

@ -1228,12 +1228,7 @@ int LIS3MDL::check_calibration()
}
/* return 0 if calibrated, 1 else */
if (!_calibrated) {
return 0;
} else {
return 1;
}
return !_calibrated;
}
int LIS3MDL::set_excitement(unsigned enable)