diff --git a/xarm_controller/src/hardware/uf_robot_system_hardware.cpp b/xarm_controller/src/hardware/uf_robot_system_hardware.cpp index 0a882eea..cf97bd32 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()); @@ -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_); 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; }