Ask Your Question
0

Prefix transformations from OpenCR

asked 2018-02-08 19:58:07 -0600

qrfaalnz gravatar image

I am trying to run rrt_exploration on my turtlebot3. I need to prefix all per-robot nodes, topics, and transforms with a per-robot name such as "robot_1". I can do this the usual way for all nodes and topics with <group ns="robot_1"> in my launch file and for almost all transforms with <param name="tf_prefix", value="robot_1"/> in the node that provides the transform.

However, this does not work for transforms that are published by the OpenCR via rosserial_python such as odom. How can I change the name of the transforms published by the rosserial_python node? Re-flashing the openCR is not an option, as this must be extensible to multi-robot systems.

edit retag flag offensive close merge delete

Comments

1

How about adding tf_prefix support to rosserial_python, and only the python on the computer would have to be changed?

lucasw gravatar imagelucasw ( 2018-02-20 20:10:39 -0600 )edit

Hello! Did you ever solve this? Having the same issue and the answers to this question were not correct.

AmateurHour gravatar imageAmateurHour ( 2018-08-01 14:18:49 -0600 )edit

I solved this similarly to @lucasw's comment. Modify rosserial_python to accept a tf_prefix parameter and change Publisher's handlePacket() to add the prefix to child_frame_id and header.frame_id of each tf/tfMessage. Unfortunately I can't post code.

qrfaalnz gravatar imageqrfaalnz ( 2018-08-01 15:00:35 -0600 )edit

Ok! Do you think you could post the code as an answer to my question https://answers.ros.org/question/2993... ?

AmateurHour gravatar imageAmateurHour ( 2018-08-01 15:14:06 -0600 )edit

or could you perhaps elaborate on where to find Publisher's handlePacket()?

AmateurHour gravatar imageAmateurHour ( 2018-08-01 15:29:42 -0600 )edit

That is part of rosserial in SerialClient.py. Clone rosserial into your catkin_ws and you should be able to search for it. Look at how other parameters are handled.

qrfaalnz gravatar imageqrfaalnz ( 2018-08-01 16:25:49 -0600 )edit

TurtleBot3 supports multi-robot application. This link might be help you http://emanual.robotis.com/docs/en/pl...

Darby Lim gravatar imageDarby Lim ( 2018-08-01 19:15:23 -0600 )edit

2 Answers

Sort by ยป oldest newest most voted
0

answered 2018-03-16 12:40:51 -0600

hasauino gravatar image

The package has been updated, now you don't need namespace prefixing for single robot. There is an example launch file (simple.launch) you can check it out.

edit flag offensive delete link more
0

answered 2018-02-20 19:49:30 -0600

Gilbert gravatar image

Yes, you can change the topic name.

  1. Add remap in your launch file. I recommend this way. <remap from="original_topic" to="changed_topic_name"/>

  2. Change topic name and update fimware in OpenCR scripts using arduino. Open the OpenCR example -> Turtlebot3 -> Turtlebot3 burger & waffle -> turtlebot3_core. and change topic name in turtlebot3_core_config.h please see : http://emanual.robotis.com/docs/en/pl...

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

Stats

Asked: 2018-02-08 19:58:07 -0600

Seen: 261 times

Last updated: Mar 16 '18