Plane: change to Compass::learn_offsets

This commit is contained in:
Andrew Tridgell 2014-02-16 13:22:06 +11:00
parent f493b1c07a
commit 99f2c8387c
2 changed files with 2 additions and 2 deletions

View File

@ -859,7 +859,7 @@ static void update_compass(void)
{
if (g.compass_enabled && compass.read()) {
ahrs.set_compass(&compass);
compass.null_offsets();
compass.learn_offsets();
if (should_log(MASK_LOG_COMPASS)) {
Log_Write_Compass();
}

View File

@ -516,7 +516,7 @@ test_mag(uint8_t argc, const Menu::arg *argv)
// Calculate heading
const Matrix3f &m = ahrs.get_dcm_matrix();
heading = compass.calculate_heading(m);
compass.null_offsets();
compass.learn_offsets();
}
}