From 2f0b1b3d9c4838bb066b7342de1d11b96945ac48 Mon Sep 17 00:00:00 2001 From: priseborough Date: Sat, 3 Jan 2015 21:30:23 +1100 Subject: [PATCH] AP_NavEKF: Fix bug preventing use of optical flow without GPS --- libraries/AP_NavEKF/AP_NavEKF.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libraries/AP_NavEKF/AP_NavEKF.cpp b/libraries/AP_NavEKF/AP_NavEKF.cpp index 866be00435..04eeecdc36 100644 --- a/libraries/AP_NavEKF/AP_NavEKF.cpp +++ b/libraries/AP_NavEKF/AP_NavEKF.cpp @@ -720,7 +720,7 @@ void NavEKF::UpdateFilter() void NavEKF::SelectVelPosFusion() { // check for new data, specify which measurements should be used and check data for freshness - if (!constPosMode && !constVelMode) { + if (PV_AidingMode == AID_ABSOLUTE) { // check for and read new GPS data readGpsData();