-
Notifications
You must be signed in to change notification settings - Fork 581
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
Enable mdof trajectory execution #2740
Enable mdof trajectory execution #2740
Conversation
moveit_ros/move_group/src/default_capabilities/execute_trajectory_action_capability.cpp
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Overall, I like this change, nice work!
} | ||
} | ||
// clear velocities if we have an incomplete specification | ||
if (joint_trajectory.points[i].velocities.size() != onedof.size()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe print and error message here, since this probably indicates a bug somewhere
moveit_ros/move_group/src/default_capabilities/execute_trajectory_action_capability.cpp
Outdated
Show resolved
Hide resolved
…nterfaces" This reverts commit 885ee27.
I've put some of the open requests into #2773, since they seem out of scope of the new free function to me. I'm happy to provide API cleanup after mdof support has been completed. |
moveit_core/robot_trajectory/include/moveit/robot_trajectory/robot_trajectory.h
Show resolved
Hide resolved
if (!joint_trajectory.joint_names.empty()) | ||
{ | ||
joint_trajectory.header.frame_id = robot_model->getModelFrame(); | ||
joint_trajectory.header.stamp = rclcpp::Time(0, 0, RCL_ROS_TIME); | ||
joint_trajectory.points.resize(trajectory.getWayPointCount()); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (!joint_trajectory.joint_names.empty()) | |
{ | |
joint_trajectory.header.frame_id = robot_model->getModelFrame(); | |
joint_trajectory.header.stamp = rclcpp::Time(0, 0, RCL_ROS_TIME); | |
joint_trajectory.points.resize(trajectory.getWayPointCount()); | |
} | |
if (joint_trajectory.joint_names.empty()) | |
{ | |
return std::nullopt; | |
} | |
joint_trajectory.header.frame_id = robot_model->getModelFrame(); | |
joint_trajectory.header.stamp = rclcpp::Time(0, 0, RCL_ROS_TIME); | |
joint_trajectory.points.resize(trajectory.getWayPointCount()); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Shouldn't we just exit the function here if joint_names is empty?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
with the updated logic, I would just keep it the way it is probably
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Show resolved
Hide resolved
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Outdated
Show resolved
Hide resolved
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Show resolved
Hide resolved
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Outdated
Show resolved
Hide resolved
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Show resolved
Hide resolved
moveit_ros/planning/trajectory_execution_manager/src/trajectory_execution_manager.cpp
Outdated
Show resolved
Hide resolved
Signed-off-by: Paul Gesel <paulgesel@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is working in Pro and the CI failure appears to be a flaky test.
I will re-run the CI here a few times to see if it passes, but otherwise I propose we open another PR to temporarily disable the flaky test.
This implements preparative steps to enable mobile base trajectory execution using ros2_control JTC.
In particular, these changes convert mdof trajectories into joint trajectories using the local variables which in turn can be supported by ros2_control already.
An example for a functioning setup with the Stretch robot + JTC + chained DiffDrive is provided in PickNikRobotics/stretch_ros#48