costar_stack

Integrated ROS capabilities for planning, predicate inference, gripper control, and perception for use with the KUKA LBR IIWA and Universal Robots.

View the Project on GitHub cpaxton/costar_stack

moveit_collision_environment

This is rosnode package that publishes MoveIt planning scene that contains the collision object and table taht detected thru the TF.
The node will get the object name based on the TF frame id (ie the TF name should have some special format).
The default format for the TF frame id for this rosnode is: Obj::name of the object::index.
Sample TF name: Obj::link_uniform::1

The rosnode will publish the planning scene in /planningscene topic.

Installation

Dependencies: No external dependencies Instructions:

  1. Go to catkin workspace src. Example: cd ~/catkin_ws/src
  2. Clone this repo with git clone https://github.com/fjonath1/moveit_collision_environment.git
  3. Do catkin_make or catkin build moveit_collision_environment

Executing moveit_collision_environment

To execute this rosnode use:

roslaunch moveit_collision_environment collision_env.launch  <optional args1>  <optional args2> <optional args n>

The roslaunch support these arguments:

Example:

To update the planning scene, use:

rosservice call /planningSceneGenerator/planningSceneGenerator

Useful Param: (set to false to disable table update so we can remove the ar Tag) renewTable : This parameter will be read every service call. If it is true, the Table will be updated by reading the tableTF. Default: true

To ignore any further change in Table AR tag, use: rosparam set /planningSceneGenerator/renewTable false , otherwise use: rosparam set /planningSceneGenerator/renewTable true to keep updating table collision object for each service call

How To Use this rosnode

  1. Open node with moveit setup. Example: roslaunch ur5_moveit_config demo.launch
  2. Run this node with roslaunch moveit_collision_environment collision_env.launch
  3. Have another rosnode that publishes object TF in the specified TF name format and/or put the tableTF object in the middle of the table.
  4. Run rosservice call /planningSceneGenerator/planningSceneGenerator to update the environment according to TF that correspond to the object naming convention and table TF if available.
  5. If removing the tableTF object is necessary or you want to keep the table collision object constant, use rosparam set /planningSceneGenerator/renewTable false . This param will be read on each service call and enable/disable the table collision object update.

For example:

roslaunch moveit_collision_environment colision_env.launch mesh_source:=$(find moveit_collision_environment)/data/mesh tableTFname:=ar_marker_2 defineParent:=true parentFrameName:=/world