ros-planning/navigation — pull request #168 by muhrix (2014-02-11 11:36:04+00:00)
Title: Fix for issue #167: hardcoded tf frames

This is my suggested fix for issue #167. At the moment, robot_pose_ekf makes use of hardcoded string literals "odom_combined" and "base_footprint" as names for output and base frames. Since support for tf_prefix was dropped, having multiple robots with separate tf trees means having unique frame names (e.g., `robot1_base_footprint`).

The changes are backwards compatible with tf_prefix and hence it would not break any launch file. I have made some tests myself, but I hope someone else can assert these proposed changes.

It is rather straightforward: I added 2 string variables (output_frame_ and base_footprint_frame_) to OdomEstimation class to represent output and base frames, along with 2 mutator methods to set their values after fetching them from the parameter server. Then, the hardcoded references (string literals) to the output ("odom_combined") and base ("base_footprint") frames were replaced with output_frame_ and base_footprint_frame_, respectively.

With these changes it is possible to set the output and base frames using parameters "output_frame" and "base_footprint_frame".

I modified the example launch file to illustrate how to set the base frame as well as the output frame.