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

This commit is contained in:
Peter Barker 2021-07-28 10:27:39 +10:00 committed by Peter Barker
parent c348f602d9
commit 3e13790039
1 changed files with 1 additions and 1 deletions

View File

@ -164,7 +164,7 @@ void Sub::update_batt_compass()
// read battery before compass because it may be used for motor interference compensation
battery.read();
if (AP::compass().enabled()) {
if (AP::compass().available()) {
// update compass with throttle value - used for compassmot
compass.set_throttle(motors.get_throttle());
compass.read();