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

[gazebo_plugins] Add vacuum gripper plugin #389

Merged
merged 1 commit into from
Apr 27, 2016

Conversation

wkentaro
Copy link
Contributor

@wkentaro wkentaro commented Feb 11, 2016

@rethink-imcmahon
Copy link

Huge +1. This is so cool, @wkentaro! Well done generalizing the interface to a plugin as well.

@@ -0,0 +1,161 @@
/*
* Copyright (C) 2012-2014 Open Source Robotics Foundation
Copy link
Member

Choose a reason for hiding this comment

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

This date could be updated to 2015-2016

@scpeters
Copy link
Member

closing and re-opening to trigger CI builds

@scpeters scpeters closed this Apr 26, 2016
@scpeters scpeters reopened this Apr 26, 2016
physics::Link_V links = models[i]->GetLinks();
for (size_t j = 0; j < links.size(); j++) {
math::Pose link_pose = links[j]->GetWorldPose();
math::Pose diff = parent_pose - link_pose;
Copy link
Member

Choose a reason for hiding this comment

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

This uses the difference in link pose between the end effector and an object to determine whether they are close enough for force to be applied, but this depends on where the coordinate frames are defined. This might work for small objects, but it would be better to use collision checking (such as ray-casting) to determine the proximity to the actual surface, which won't be affected by how coordinate frames are defined.

Let me know if that didn't make sense and we can discuss further.

Copy link
Member

Choose a reason for hiding this comment

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

now I realize that you said exactly this in the description of the pull request

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Actually, I don't know how to get the distance between robot link and object collision for now.
Do you know how to do this? Or example?

Choose a reason for hiding this comment

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

Wada San,
This is a wonderful , plugin and very helpful. How can I do a specific modification, such as applying force to the links position (x,y,z) with an offset, (x+10,y,z)
This way, I can solve a specifc problem, that I have, i.e. to apply force at the corners of a large cylindrical object, rather than applying force on the center of the cylinder?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I think you should change the direction of the force.
https://github.com/ros-simulation/gazebo_ros_pkgs/blob/jade-devel/gazebo_plugins/src/gazebo_ros_vacuum_gripper.cpp#L210-L211
Currently the direction is from gripper link to object link.

@scpeters scpeters modified the milestones: untargeted, kinetic release Apr 26, 2016
if (norm_force > 20) {
norm_force = 20; // max_force
}
math::Vector3 force = norm_force * diff.pos.Normalize();
Copy link
Member

Choose a reason for hiding this comment

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

it also applies the force in every direction, when it should apply it in a single direction only. We would need a way to specify this direction to implement this

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yeah, it should be.
Maybe, It will be not single direction but restricted.

@scpeters
Copy link
Member

This is a working plugin even if it isn't perfect, as you stated. I'll be ready to merge this if the copyright year is updated. We can create an issue to address the other comments I made (poses of coordinate frames instead of collision proximity, directionality of force, parameterization).

@j-rivero
Copy link
Contributor

I'll be ready to merge this if the copyright year is updated.

I will create a new pull request to fix the problem with the copyright.

Thanks to everyone for the pull request.

@j-rivero j-rivero merged commit d2bc7ab into ros-simulation:jade-devel Apr 27, 2016
@wkentaro
Copy link
Contributor Author

I will create a new pull request to fix the problem with the copyright.
Thanks to everyone for the pull request.

Thanks.

@wkentaro wkentaro deleted the vacuum-gripper-plugin branch April 27, 2016 20:49
@wkentaro
Copy link
Contributor Author

This is a working plugin even if it isn't perfect, as you stated. I'll be ready to merge this if the copyright year is updated. We can create an issue to address the other comments I made (poses of coordinate frames instead of collision proximity, directionality of force, parameterization).

Thanks for the review. I watch the issue on #446 and will work for this when I have time.

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

Successfully merging this pull request may close these issues.

5 participants