Created
March 26, 2013 03:02
-
-
Save evenator/5242794 to your computer and use it in GitHub Desktop.
attaching objects to gripper in ROS
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
void MechanismInterface::attachObjectToGripper(std::string arm_name, std::string collision_object_name) | |
{ | |
arm_navigation_msgs::AttachedCollisionObject obj; | |
obj.object.header.stamp = ros::Time::now(); | |
obj.object.header.frame_id = handDescription().robotFrame(arm_name); | |
obj.object.operation.operation = arm_navigation_msgs::CollisionObjectOperation::ATTACH_AND_REMOVE_AS_OBJECT; | |
obj.object.id = collision_object_name; | |
obj.link_name = handDescription().attachLinkName(arm_name); | |
obj.touch_links = handDescription().gripperTouchLinkNames(arm_name); | |
attached_object_pub_.publish(obj); | |
} | |
https://code.ros.org/svn/wg-ros-pkg/stacks/object_manipulation/trunk/object_manipulator/src/tools/mechanism_interface.cpp |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment