diff --git a/libraries/APM_Control/AR_PosControl.cpp b/libraries/APM_Control/AR_PosControl.cpp index e3367a468cd..d55a1578238 100644 --- a/libraries/APM_Control/AR_PosControl.cpp +++ b/libraries/APM_Control/AR_PosControl.cpp @@ -406,16 +406,14 @@ void AR_PosControl::write_log() /// initialise ekf xy position reset check void AR_PosControl::init_ekf_xy_reset() { - Vector2f pos_shift; - _ekf_xy_reset_count = AP::ahrs().get_position_NE_reset_count(pos_shift); + _ekf_xy_reset_count = AP::ahrs().get_position_NE_reset_count(); } /// handle_ekf_xy_reset - check for ekf position reset and adjust loiter or brake target position void AR_PosControl::handle_ekf_xy_reset() { - // check for position shift - Vector2f pos_shift; - const uint16_t reset_count = AP::ahrs().get_position_NE_reset_count(pos_shift); + // check for position reset + const uint16_t reset_count = AP::ahrs().get_position_NE_reset_count(); if (reset_count != _ekf_xy_reset_count) { Vector2p pos_ne_m; if (!AP::ahrs().get_relative_position_NE_origin(pos_ne_m)) {