From 665066366501e5d92fb5270ab5f60d5e8ab68788 Mon Sep 17 00:00:00 2001 From: peterdavidfagan Date: Fri, 10 Feb 2023 14:19:41 +0000 Subject: [PATCH 1/3] fix substr index this change is required to ensure compatibility with MoveItConfigsBuilder --- xarm_controller/src/hardware/uf_robot_system_hardware.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/xarm_controller/src/hardware/uf_robot_system_hardware.cpp b/xarm_controller/src/hardware/uf_robot_system_hardware.cpp index 0a882eea..c1e38a9c 100644 --- a/xarm_controller/src/hardware/uf_robot_system_hardware.cpp +++ b/xarm_controller/src/hardware/uf_robot_system_hardware.cpp @@ -62,7 +62,7 @@ namespace uf_robot_hardware robot_ip_ = ""; auto it = info_.hardware_parameters.find("robot_ip"); if (it != info_.hardware_parameters.end()) { - robot_ip_ = it->second.substr(1); + robot_ip_ = it->second.substr(0); } if (robot_ip_ == "") { RCLCPP_ERROR(LOGGER, "[%s] No param named 'robot_ip'", robot_ip_.c_str()); @@ -144,7 +144,7 @@ namespace uf_robot_hardware robot_ip_ = ""; it = info_.hardware_parameters.find("robot_ip"); if (it != info_.hardware_parameters.end()) { - robot_ip_ = it->second.substr(1); + robot_ip_ = it->second.substr(0); } if (robot_ip_ == "") { RCLCPP_ERROR(LOGGER, "[%s] No param named 'robot_ip'", robot_ip_.c_str()); From 5d6123b37eeec404f45fd58e138c8733c21f6b19 Mon Sep 17 00:00:00 2001 From: peterdavidfagan Date: Wed, 15 Feb 2023 13:40:25 +0000 Subject: [PATCH 2/3] remove underscore from public members in MotionPlanResponse --- xarm_planner/src/xarm_planner.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/xarm_planner/src/xarm_planner.cpp b/xarm_planner/src/xarm_planner.cpp index 799fc4f3..d8b48c35 100644 --- a/xarm_planner/src/xarm_planner.cpp +++ b/xarm_planner/src/xarm_planner.cpp @@ -78,7 +78,7 @@ bool XArmPlanner::planCartesianPath(const std::vector& RCLCPP_ERROR(node_->get_logger(), "planCartesianPath: plan failed, fraction=%lf", fraction); return false; } - xarm_plan_.trajectory_ = trajectory; + xarm_plan_.trajectory = trajectory; return true; } From 5dce8da294861a6302082948f8e7072443beb963 Mon Sep 17 00:00:00 2001 From: peterdavidfagan Date: Sun, 7 May 2023 12:42:39 +0100 Subject: [PATCH 3/3] rename start/stop nomenclature to align with ros2_control updates --- xarm_controller/src/hardware/uf_robot_system_hardware.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/xarm_controller/src/hardware/uf_robot_system_hardware.cpp b/xarm_controller/src/hardware/uf_robot_system_hardware.cpp index c1e38a9c..cf97bd32 100644 --- a/xarm_controller/src/hardware/uf_robot_system_hardware.cpp +++ b/xarm_controller/src/hardware/uf_robot_system_hardware.cpp @@ -407,11 +407,11 @@ namespace uf_robot_hardware void UFRobotSystemHardware::_reload_controller(void) { int ret = _call_request(client_list_controller_, req_list_controller_, res_list_controller_); if (ret == 0 && res_list_controller_->controller.size() > 0) { - req_switch_controller_->start_controllers.resize(res_list_controller_->controller.size()); - req_switch_controller_->stop_controllers.resize(res_list_controller_->controller.size()); + req_switch_controller_->activate_controllers.resize(res_list_controller_->controller.size()); + req_switch_controller_->deactivate_controllers.resize(res_list_controller_->controller.size()); for (uint i = 0; i < res_list_controller_->controller.size(); i++) { - req_switch_controller_->start_controllers[i] = res_list_controller_->controller[i].name; - req_switch_controller_->stop_controllers[i] = res_list_controller_->controller[i].name; + req_switch_controller_->activate_controllers[i] = res_list_controller_->controller[i].name; + req_switch_controller_->deactivate_controllers[i] = res_list_controller_->controller[i].name; } req_switch_controller_->strictness = controller_manager_msgs::srv::SwitchController::Request::BEST_EFFORT; _call_request(client_switch_controller_, req_switch_controller_, res_switch_controller_);