diff --git a/aerial_robot_control/src/flight_navigation.cpp b/aerial_robot_control/src/flight_navigation.cpp index 8443551cb..7561ea2bc 100644 --- a/aerial_robot_control/src/flight_navigation.cpp +++ b/aerial_robot_control/src/flight_navigation.cpp @@ -408,6 +408,7 @@ void BaseNavigator::joyStickControl(const sensor_msgs::JoyConstPtr & joy_msg) setNaviState(LAND_STATE); //update + setXyControlMode(POS_CONTROL_MODE) setTargetXyFromCurrentState(); setTargetYawFromCurrentState(); setTargetPosZ(estimator_->getLandingHeight()); @@ -638,6 +639,7 @@ void BaseNavigator::update() if(normal_land && !force_att_control_flag_) { setNaviState(LAND_STATE); + setXyControlMode(POS_CONTROL_MODE); setTargetXyFromCurrentState(); setTargetYawFromCurrentState(); setTargetPosZ(estimator_->getLandingHeight());