Ask Your Question
0

Warning with hector_exploration_node (problem with the tf tree)

asked 2016-08-12 20:23:24 -0600

patrchri gravatar image

updated 2016-08-13 08:04:10 -0600

Hello,

I recently started using the nodes of the hector algorithms and today I tried to use the hector_exploration_node on my 3 wheel differential driven robot on which I have put a hokuyo lidar. I am generally new in ros, so some follow up questions may occur.

After the roslaunch of my model in gazebo and the state_publisher I did the following:

roslaunch hector_exploration_node exploration_planner.launch

After the command, I got the following warnings:

[ WARN] [1471047689.018501831, 134.995000000]: Timed out waiting for transform from base_link to map to become available before running costmap, tf error: . canTransform returned after 134.995 timeout was 0.1.
[ WARN] [1471047695.188449599, 140.033000000]: Timed out waiting for transform from base_link to map to become available before running costmap, tf error: Could not find a connection between 'map' and 'base_link' because they are not part of the same tree.Tf has two or more unconnected trees.. canTransform returned after 0.102 timeout was 0.1.
[ WARN] [1471047701.360674352, 145.134000000]: Timed out waiting for transform from base_link to map to become available before running costmap, tf error: Could not find a connection between 'map' and 'base_link' because they are not part of the same tree.Tf has two or more unconnected trees.. canTransform returned after 0.105 timeout was 0.1.

As the warning suggested I checked my tf tree by running:

rosrun tf view_frames

The results of the command was this tree .

As you can see I have 3 unconnected tf trees and the weird part is that I have 2 different base_footprints (one as /labrob/base_footprint and one as base_footprint) which I don't know why happens, since in my urdf code I just mention the frames as 'base_footprint', 'base_link', 'r_wheel', 'l_wheel' etc. Labrob is the name of my robot. I don't want to forget to mention that I am using the following state_publisher, which I roslaunch after I roslaunch the robot model in gazebo:

<launch>
        <param name="robot_description" command="cat $(find labrob_description)/urdf/labrob.urdf" />
        <node name="robot_state_publisher" pkg="robot_state_publisher" type="state_publisher" />
</launch>

The warning also mentions that there is no connection between map and base_link, which is correct according to my tree.

To sum up, I have the following questions regarding all the above:

  1. What does practically mean tf connection between map and base_link (I mean the robot moves on the map, if that's the practical connection between the two) ?

  2. What tutorial should I follow to establish a connection between these 2 frames (map and base_link) ?

  3. Is there something wrong on the launch file of my state_publisher?

  4. Could you please explain me why I see two different base_footprints?

Thank you for your time and for your answers in advance,

Chris

EDITED:

About my 4th question, I changed some things in the urdf code of the robot and I saw that the issue evolves because I have 2 different broadcasters (gazebo and state_publisher). To be more specific, at the end of my urdf file i use the following plugin:

  <gazebo ...
(more)
edit retag flag offensive close merge delete

1 Answer

Sort by ยป oldest newest most voted
0

answered 2016-08-13 10:44:19 -0600

patrchri gravatar image

updated 2016-08-13 10:46:37 -0600

After testing various things I managed to solve all of my problems on my own, so I will answer my questions in case someone meets the same issues as me:

  1. The connection between the map frame and base_link, as I understand it, is the pose of the base_link frame within the map. So you have to find a topic like /slam_out_pose for example, to get that position of the robot on the map (pose and orientation) and broadcast it. The tf tutorials are really helpful with that, but you also need to have understood what actually happens with the code in the tutorials. It's important to note that this connection between these two frames is not based on odometry, but on the high frequency of the lidar samples.

  2. This tutorial helps a lot. Also check this link regarding Quaternion and this link regarding Transforms, they help a lot on writing our own code.

  3. The state publisher I have posted works good. No problems have occurred till now, so I think it's correct.

  4. This tree linkage doesn't bother the hector's packages to do their job. I solved the issue temporarily with the broadcaster I wrote. I don't know how it got solved by on its own, but the job was done.

Chris

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: 2016-08-12 20:23:24 -0600

Seen: 149 times

Last updated: Aug 13 '16