Intermodalics / tango_ros

ROS related software for Tango
Apache License 2.0
67 stars 22 forks source link

Add configuration option for device frame_id or a tf prefix #380

Open meyerj opened 6 years ago

meyerj commented 6 years ago

The device frame_id used for tf should be configurable via a ROS parameter, in the same way as tango/area_description_frame_id and tango/start_of_service_frame_id. If the Tango device is part of a bigger tree, the device pose is typically part of the robot description and published by something like robot_state_publisher.

As a workaround you could introduce additional static transforms that identify the two frames, but in general just "device" is a bit unspecific in a wider scope and should be configurable.

An alternative solution that also applies to all other frames attached to device would be to prefix the frame ids with the value of the tango/tf_prefix parameter, if set. While tf_prefix support has been removed as a core feature of tf2 (see tf2 migration guide), it can still be applied and useful for user code and many nodes have such a parameter. ros::names::resolve(namespace, name, remap) can help with that, even though it is not meant for tf frame ids.