From e9baf3d15a91348cab2a878c5532b6b3a993046e Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Sat, 11 Feb 2023 10:33:06 +1100 Subject: [PATCH] AP_DAL: add and use pr/EK3_FEATURE_OPTFLOW_FUSION --- libraries/AP_DAL/AP_DAL.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libraries/AP_DAL/AP_DAL.cpp b/libraries/AP_DAL/AP_DAL.cpp index 779bb88b1f..06be6c7c7e 100644 --- a/libraries/AP_DAL/AP_DAL.cpp +++ b/libraries/AP_DAL/AP_DAL.cpp @@ -7,6 +7,7 @@ #include #include #include +#include #if APM_BUILD_TYPE(APM_BUILD_Replay) #include @@ -467,7 +468,9 @@ void AP_DAL::handle_message(const log_ROFH &msg, NavEKF2 &ekf2, NavEKF3 &ekf3) { _ROFH = msg; ekf2.writeOptFlowMeas(msg.rawFlowQuality, msg.rawFlowRates, msg.rawGyroRates, msg.msecFlowMeas, msg.posOffset, msg.heightOverride); +#if EK3_FEATURE_OPTFLOW_FUSION ekf3.writeOptFlowMeas(msg.rawFlowQuality, msg.rawFlowRates, msg.rawGyroRates, msg.msecFlowMeas, msg.posOffset, msg.heightOverride); +#endif } /*