Ask Your Question

rosbag2 remap topic

asked 2020-03-05 05:47:42 -0500

hannatao gravatar image

Ros2 supoport remap topics in command line. But when I try to use rosbag2 to play and remap topics, the command line can't recognize my input for "--ros-args -r chatter:=demo". Is there any ideas of playing bags with remapped topics?

edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted

answered 2020-09-18 03:35:55 -0500

Phgo gravatar image

In the mean time this function has been added to rosbag2 (see PR #388). However, as far as I can tell the feature has not been back-ported to the eloquent branch so far. So if you need this you might need to build rosbag2 from source (including the PR mentioned above).

With this changes, that are already in the latest ROS foxy release, you can now remap topics when playing bagfiles as:

ros2 bag play my_bagfile --remap old_topic:=new_topic
edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

1 follower


Asked: 2020-03-05 05:47:42 -0500

Seen: 50 times

Last updated: Sep 18