5
0
mirror of https://github.com/ArduPilot/ardupilot synced 2025-01-03 14:38:30 -04:00

Rover: use AP::compass().available in place of enabled()

This commit is contained in:
Peter Barker 2021-07-28 10:27:40 +10:00 committed by Peter Barker
parent 3e13790039
commit ffd577f30b

View File

@ -10,7 +10,7 @@ void Rover::update_compass(void)
// Save compass offsets
void Rover::compass_save() {
if (AP::compass().enabled() &&
if (AP::compass().available() &&
compass.get_learn_type() >= Compass::LEARN_INTERNAL &&
!arming.is_armed()) {
compass.save_offsets();