diff --git a/libraries/AP_NavEKF3/AP_NavEKF3_Control.cpp b/libraries/AP_NavEKF3/AP_NavEKF3_Control.cpp index e3720c8018..11f4093768 100644 --- a/libraries/AP_NavEKF3/AP_NavEKF3_Control.cpp +++ b/libraries/AP_NavEKF3/AP_NavEKF3_Control.cpp @@ -45,7 +45,7 @@ NavEKF3_core::MagCal NavEKF3_core::effective_magCal(void) const MagCal magcal = MagCal(frontend->_magCal.get()); // force use of simple magnetic heading fusion for specified cores - if (magcal != MagCal::EXTERNAL_YAW && magcal != MagCal::EXTERNAL_YAW_FALLBACK && magcal != MagCal::GSF_YAW && (frontend->_magMask & core_index)) { + if ((magcal != MagCal::EXTERNAL_YAW) && (magcal != MagCal::EXTERNAL_YAW_FALLBACK) && (magcal != MagCal::GSF_YAW) && (frontend->_magMask & core_index)) { return MagCal::NEVER; } diff --git a/libraries/AP_NavEKF3/AP_NavEKF3_MagFusion.cpp b/libraries/AP_NavEKF3/AP_NavEKF3_MagFusion.cpp index c3ae51049a..a3dfd56ed4 100644 --- a/libraries/AP_NavEKF3/AP_NavEKF3_MagFusion.cpp +++ b/libraries/AP_NavEKF3/AP_NavEKF3_MagFusion.cpp @@ -404,7 +404,7 @@ void NavEKF3_core::SelectMagFusion() // above readMagData(); } - + // If we are using the compass and the magnetometer has been unhealthy for too long we declare a timeout if (magHealth) { magTimeout = false; diff --git a/libraries/AP_NavEKF3/AP_NavEKF3_core.h b/libraries/AP_NavEKF3/AP_NavEKF3_core.h index 4c65b54a5c..37157041ab 100644 --- a/libraries/AP_NavEKF3/AP_NavEKF3_core.h +++ b/libraries/AP_NavEKF3/AP_NavEKF3_core.h @@ -1398,8 +1398,8 @@ private: void updateMovementCheck(void); // The following declarations are used to control when the main navigation filter resets it's yaw to the estimate provided by the GSF - uint32_t EKFGSF_yaw_reset_ms; // timestamp of last emergency yaw reset (uSec) - uint32_t EKFGSF_yaw_reset_request_ms; // timestamp of last emergency yaw reset request (uSec) + uint32_t EKFGSF_yaw_reset_ms; // timestamp of last emergency yaw reset (uSec) + uint32_t EKFGSF_yaw_reset_request_ms; // timestamp of last emergency yaw reset request (uSec) uint8_t EKFGSF_yaw_reset_count; // number of emergency yaw resets performed bool EKFGSF_run_filterbank; // true when the filter bank is active };