diff --git a/EKF/gps_checks.cpp b/EKF/gps_checks.cpp index b03f72d0f7..6f7b8afaf7 100644 --- a/EKF/gps_checks.cpp +++ b/EKF/gps_checks.cpp @@ -68,7 +68,7 @@ bool Ekf::collect_gps(uint64_t time_usec, struct gps_message *gps) map_projection_init_timestamped(&_pos_ref, lat, lon, _time_last_imu); // if we are already doing aiding, corect for the change in posiiton since the EKF started navigating - if (_control_status.flags.opt_flow || _control_status.flags.gps) { + if (_control_status.flags.opt_flow || _control_status.flags.gps || _control_status.flags.ev_pos) { double est_lat, est_lon; map_projection_reproject(&_pos_ref, -_state.pos(0), -_state.pos(1), &est_lat, &est_lon); map_projection_init_timestamped(&_pos_ref, est_lat, est_lon, _time_last_imu);