Plane: Don't disable compass checks for HIL mode unless actually in hil mode

This commit is contained in:
Michael du Breuil 2015-12-08 05:07:46 -07:00
parent 7236b48518
commit 4b40a884e9
1 changed files with 2 additions and 0 deletions

View File

@ -168,7 +168,9 @@ void Plane::init_ardupilot()
if (g.compass_enabled==true) {
bool compass_ok = compass.init() && compass.read();
#if HIL_SUPPORT
if (!is_zero(g.hil_mode)) {
compass_ok = true;
}
#endif
if (!compass_ok) {
cliSerial->println("Compass initialisation failed!");