Skip to content

Multi DOF Trajectory only providing translation not velocity - #555

Merged
davetcoleman merged 4 commits into
moveit:kinetic-develfrom
TroyCordie:cleaned_multi_dof
Aug 17, 2017
Merged

davetcoleman merged 4 commits into
moveit:kinetic-develfrom
TroyCordie:cleaned_multi_dof

Conversation

@TroyCordie

Copy link
Copy Markdown
Contributor

Description

Currently, multi DOF joints are only publishing the translation this fix adds velocity.

Checklist

Thank you!

@davetcoleman davetcoleman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is a great addition, but lets make it a little more generic


geometry_msgs::Twist point_velocity;

for (std::size_t ii = 0; ii < names.size(); ++ii)

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

instead of having an i, j, and ii iterator var, how about naming it k or something more descriptive?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Done

trajectory.multi_dof_joint_trajectory.points[i].transforms[j]);
if (waypoints_[i]->hasVelocities())
{
const std::vector<std::string> names = mdof[j]->getVariableNames();

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

please add a check for the type of mdof joint and only use the code below if its a planar joint. if you are inclined, add support for a floating joint also. Note that you'd have to check for trans_[x|y|z] and rot_x, rot_y, rot_z, , rot_w which is a quaternion - I'm not sure how a velocity vector would work for that. If you don't want to implement support for that joint type, add a comment with a TODO

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't currently have anything to test a floating joint but it will likely come into my scope soon enough. I have added the todo and will get back to it another time.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spelling: plainer -> planar

@davetcoleman davetcoleman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

almost ready to merge :)

trajectory.multi_dof_joint_trajectory.points[i].transforms[j]);
if (waypoints_[i]->hasVelocities())
{
const std::vector<std::string> names = mdof[j]->getVariableNames();

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

spelling: plainer -> planar

{
tf::transformEigenToMsg(waypoints_[i]->getJointTransform(mdof[j]),
trajectory.multi_dof_joint_trajectory.points[i].transforms[j]);
// [TODO] currently only checking for plainer multi DOF joints need to add check for floating

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

plainer -> planar

@v4hn

v4hn commented Aug 3, 2017

Copy link
Copy Markdown
Contributor

@davetcoleman I fixed up the comment and approve this pull-request. I believe this is ready for merge (unless CI stabs me in the back...)

@TroyCordie

Copy link
Copy Markdown
Contributor Author

@v4hn thanks for that I have been off this work for a few days.

@v4hn v4hn added the awaits 2nd review one maintainer approved this request label Aug 16, 2017
@davetcoleman
davetcoleman merged commit f5a6df0 into moveit:kinetic-devel Aug 17, 2017
130s pushed a commit to 130s/moveit-2 that referenced this pull request Dec 9, 2017
Multi DOF Trajectory only providing translation not velocity (moveit#555)

* fixes for multi dof velocties

* cleaned up for pull request

* check added for planar joint TODO added for floating, for loop cleaned up

* cleanup comment
@130s

130s commented Dec 9, 2017

Copy link
Copy Markdown
Contributor

Document update would be great for this?

v4hn pushed a commit to v4hn/moveit that referenced this pull request Dec 10, 2017
)

* fixes for multi dof velocties

* cleaned up for pull request

* check added for planar joint TODO added for floating, for loop cleaned up

* cleanup comment

=> v4hn added an include that was missing in indigo
v4hn pushed a commit to v4hn/moveit that referenced this pull request Dec 10, 2017
)

* fixes for multi dof velocties

* cleaned up for pull request

* check added for planar joint TODO added for floating, for loop cleaned up

* cleanup comment

=> v4hn changed a namespace to compile with indigo
JafarAbdi added a commit to JafarAbdi/moveit that referenced this pull request Mar 24, 2022
* Update CMakeLists.txt

* Revert "Update CMakeLists.txt"

This reverts commit afa8c8da9e320d83313ce94b1181945c2ba71da1.

* move template function to .h

* re-added default_value

* Update moveit_ros/moveit_servo/include/moveit_servo/servo_parameters.h

Co-authored-by: Jafar Abdi <[email protected]>

* rerun CI

* rerun CI

* rerun CI

* rerun CI

* added note about duplicate symbols

Co-authored-by: Jafar Abdi <[email protected]>
Co-authored-by: Tyler Weaver <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

awaits 2nd review one maintainer approved this request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants