Public Member Functions | Private Types | Private Member Functions | Private Attributes
moveit_object_handling::ObjectMessageGenerator Class Reference

#include <ObjectMessageGenerator.h>

List of all members.

Public Member Functions

bool isConnected () const
 ObjectMessageGenerator (ros::NodeHandle &_node_priv, ros::NodeHandle &_node)
virtual ~ObjectMessageGenerator ()

Private Types

typedef object_msgs::ObjectInfo ObjectInfoMsg
typedef object_msgs::Object ObjectMsg
typedef std::map< std::string,
moveit_msgs::CollisionObject > 
ObjToPublishMap

Private Member Functions

void connectPub (const ros::SingleSubscriberPublisher &p)
void disconnectPub (const ros::SingleSubscriberPublisher &p)
moveit_msgs::CollisionObject getCollisionGeometry (const std::string &name)
std::set< std::string > getCurrentAttachedCollisionObjectNames ()
std::vector
< moveit_msgs::AttachedCollisionObject > 
getCurrentAttachedCollisionObjects ()
std::set< std::string > getCurrentCollisionObjectNames ()
std::vector
< moveit_msgs::CollisionObject > 
getCurrentCollisionObjects (bool only_names=true)
void publishCollisionsEvent (const ros::TimerEvent &e)
void receiveObject (const ObjectMsg &msg)
moveit_msgs::CollisionObject transferContent (const ObjectMsg &msg, bool skipGeometry)
void updatePose (const ObjectMsg &newObj, moveit_msgs::CollisionObject &obj)

Private Attributes

MoveItCollisionMatrixManipulator acmManip
std::set< std::string > addedObjects
std::vector< std::string > allowedCollisionLinks
std::string COLLISION_OBJECT_TOPIC
ros::Publisher collision_pub
std::string GET_PLANNING_SCENE_SERVICE
bool initExistingObj
boost::mutex mutex
ros::NodeHandle node
ros::NodeHandle node_priv
ros::ServiceClient object_info_client
ros::Subscriber object_sub
std::string OBJECTS_TOPIC
ObjToPublishMap objsToPublish
ros::ServiceClient planning_scene_client
ros::Publisher planning_scene_pub
float PUBLISH_COLLISION_RATE
ros::Timer publishCollisionsTimer
std::string REQUEST_OBJECTS_TOPIC
std::string SET_PLANNING_SCENE_TOPIC
std::set< std::string > skipObjects
bool USE_PLANNING_SCENE_DIFF

Detailed Description

Takes objects of type object_msgs/Object published a topic and transforms and re-publishes it into a moveit_msgs/CollisionObject.

The object information is read from incoming object_msgs/Object messages. If not all information is available, a service of type object_msgs/ObjectInfoRequest.srv is sent, e.g. to get the geometry details when required.

There are currently two ways to send object information to MoveIt!:

1. Publishing the collision object on /collision_objects which is read by move_group. 2. Another approach is described in [this PR2 tutorial](http://docs.ros.org/api/pr2_moveit_tutorials/html/planning/src/doc/planning_scene_ros_api_tutorial.html), in section *"Add object to environment": publising a planning scene diff (message moveit_msgs::PlanningScene)*.

The approach to be taken can be set with a ROS parameter is set for it.

The parameters for this class can be specified in a YAML file, which needs to be loaded onto the ROS parameter server under **namespace moveit_object_handling**. An example is given in the directory *config*, filename "CollisionObjectsGenerator.yaml"

Author:
Jennifer Buehler

Definition at line 45 of file ObjectMessageGenerator.h.


Member Typedef Documentation

typedef object_msgs::ObjectInfo moveit_object_handling::ObjectMessageGenerator::ObjectInfoMsg [private]

Definition at line 50 of file ObjectMessageGenerator.h.

typedef object_msgs::Object moveit_object_handling::ObjectMessageGenerator::ObjectMsg [private]

Definition at line 49 of file ObjectMessageGenerator.h.

typedef std::map<std::string, moveit_msgs::CollisionObject> moveit_object_handling::ObjectMessageGenerator::ObjToPublishMap [private]

Definition at line 51 of file ObjectMessageGenerator.h.


Constructor & Destructor Documentation

Definition at line 16 of file ObjectMessageGenerator.cpp.

Definition at line 90 of file ObjectMessageGenerator.cpp.


Member Function Documentation

Definition at line 94 of file ObjectMessageGenerator.cpp.

Definition at line 122 of file ObjectMessageGenerator.cpp.

moveit_msgs::CollisionObject ObjectMessageGenerator::getCollisionGeometry ( const std::string &  name) [private]

Definition at line 288 of file ObjectMessageGenerator.cpp.

Definition at line 415 of file ObjectMessageGenerator.cpp.

std::vector< moveit_msgs::AttachedCollisionObject > ObjectMessageGenerator::getCurrentAttachedCollisionObjects ( ) [private]

Definition at line 391 of file ObjectMessageGenerator.cpp.

Definition at line 380 of file ObjectMessageGenerator.cpp.

std::vector< moveit_msgs::CollisionObject > ObjectMessageGenerator::getCurrentCollisionObjects ( bool  only_names = true) [private]

Definition at line 351 of file ObjectMessageGenerator.cpp.

Definition at line 112 of file ObjectMessageGenerator.cpp.

Definition at line 132 of file ObjectMessageGenerator.cpp.

void ObjectMessageGenerator::receiveObject ( const ObjectMsg msg) [private]

Callback for object message

Definition at line 158 of file ObjectMessageGenerator.cpp.

moveit_msgs::CollisionObject ObjectMessageGenerator::transferContent ( const ObjectMsg msg,
bool  skipGeometry 
) [private]

Helper to transfer contents from ObjectMsg to moveit_msgs::CollisionObject

Definition at line 317 of file ObjectMessageGenerator.cpp.

void ObjectMessageGenerator::updatePose ( const ObjectMsg newObj,
moveit_msgs::CollisionObject &  obj 
) [private]

updates pose data in obj with information in newObj, leaves all other fields untouched

Definition at line 306 of file ObjectMessageGenerator.cpp.


Member Data Documentation

Definition at line 126 of file ObjectMessageGenerator.h.

Definition at line 112 of file ObjectMessageGenerator.h.

Definition at line 124 of file ObjectMessageGenerator.h.

Definition at line 95 of file ObjectMessageGenerator.h.

Definition at line 101 of file ObjectMessageGenerator.h.

Definition at line 96 of file ObjectMessageGenerator.h.

Definition at line 135 of file ObjectMessageGenerator.h.

Definition at line 130 of file ObjectMessageGenerator.h.

Definition at line 92 of file ObjectMessageGenerator.h.

Definition at line 92 of file ObjectMessageGenerator.h.

Definition at line 106 of file ObjectMessageGenerator.h.

Definition at line 104 of file ObjectMessageGenerator.h.

Definition at line 93 of file ObjectMessageGenerator.h.

Definition at line 128 of file ObjectMessageGenerator.h.

Definition at line 108 of file ObjectMessageGenerator.h.

Definition at line 102 of file ObjectMessageGenerator.h.

Definition at line 98 of file ObjectMessageGenerator.h.

Definition at line 132 of file ObjectMessageGenerator.h.

Definition at line 94 of file ObjectMessageGenerator.h.

Definition at line 97 of file ObjectMessageGenerator.h.

Definition at line 117 of file ObjectMessageGenerator.h.

Definition at line 99 of file ObjectMessageGenerator.h.


The documentation for this class was generated from the following files:


moveit_object_handling
Author(s): Jennifer Buehler
autogenerated on Sat Mar 2 2019 03:50:51