Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Tutorial inconsistent movegroup naming #964

Open
alejandrojginerd opened this issue Sep 13, 2024 · 1 comment
Open

Tutorial inconsistent movegroup naming #964

alejandrojginerd opened this issue Sep 13, 2024 · 1 comment

Comments

@alejandrojginerd
Copy link

Description

Overview of your issue here.

Your environment

  • ROS Distro: [Humble] (Docker)
  • OS Version: e.g. Ubuntu 22.04
  • Source build

Steps to reproduce

Following "Your First C++ MoveIt Project" tutorial.

// Create the MoveIt MoveGroup Interface
using moveit::planning_interface::MoveGroupInterface;
auto move_group_interface = MoveGroupInterface(node, "manipulator"); //<--- this is the error 

// Set a target Pose
auto const target_pose = []{
  geometry_msgs::msg::Pose msg;
  msg.orientation.w = 1.0;
  msg.position.x = 0.28;
  msg.position.y = -0.2;
  msg.position.z = 0.5;
  return msg;
}();
move_group_interface.setPoseTarget(target_pose);

// Create a plan to that target pose
auto const [success, plan] = [&move_group_interface]{
  moveit::planning_interface::MoveGroupInterface::Plan msg;
  auto const ok = static_cast<bool>(move_group_interface.plan(msg));
  return std::make_pair(ok, msg);
}();

// Execute the plan
if(success) {
  move_group_interface.execute(plan);
} else {
  RCLCPP_ERROR(logger, "Planning failed!");
}

Expected behaviour

Console ouput when runnning ros2 launch moveit2_tutorials demo.launch.py

[INFO] [1726223793.098367005] [moveit_rdf_loader.rdf_loader]: Loaded robot model in 1.01257 seconds
[INFO] [1726223793.098575034] [moveit_robot_model.robot_model]: Loading robot model 'panda'...
[WARN] [1726223793.125028796] [moveit_ros.robot_model_loader]: No kinematics plugins defined. Fill and load kinematics.yaml!
[FATAL] [1726223793.125237385] [move_group_interface]: Group 'manipulator' was not found.
terminate called after throwing an instance of 'std::runtime_error'
  what():  Group 'manipulator' was not found.
[ros2run]: Aborted

Possible Solution

Looking at src/moveit_resources/panda_moveit_config/config/panda.srdf we noticed that the robot used calls the movegroup "panda_arm". Changing the MoveGroupInterface name from "manipulator" to "panda_arm" solves the issue

@sea-bass
Copy link
Contributor

The main branch of this repo uses a Kinova arm model that does have a manipulator group -- you may want to clone the humble branch of this repo and follow along with the Franka example there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants