Robotics StackExchange | Archived questions

Transform from [robot_name]/base_footprint to map

I have a problem configuring and running navigation stack on a turtlebot 2 kobuki base. In general, I try to make a system of multiple turtlebots which navigate using one map. That is why I have one map frame and multiple turtlebots' frames which have a map as common parent. When I run my launch file for each turtlebot I get the following error:

Waiting on transform from pinky/base_footprint to map to become available before running costmap, tf error:

As I understood there is no transform between pinky/basefootprint and map. However, it works when don't specify tfprefix and group name. Therefore, I am not sure where is the problem. I checked all the launch files and changed global paths (e.g. /basefootprint to /pinky/basefootprint). Does it mean that I have to specify the transformation manually? (e.g. statictransformpublisher 0.0 0.0 0.0 0.0 0.0 0.0 1.0 /map /pinky/odom 100). When I specify the transformation between pinky/odom and map frames using this command rosrun tf static_transform_publisher 0.0 0.0 0.0 0.0 0.0 0.0 1.0 /map /pinky/odom 100 It says everything is ok and the tree looks normal but when I try to send goal to my turtlebot "pinky" I get warning: MessageFilter [target=map ]: Dropped 100.00% of messages so far. Please turn the [ros.costmap2d.messagenotifier] rosconsole logger to DEBUG for more information. Here is the code for my launch file:

<launch>
   <group ns="pinky">
  <param name="tf_prefix" value="pinky" />
  <include file="$(find turtlebot_bringup)/launch/3dsensor.launch">
     <arg name="rgb_processing" value="false" />
     <arg name="depth_registration" value="false" />
     <arg name="depth_processing" value="false" />

     <!-- We must specify an absolute topic name because if not it will be prefixed by "$(arg camera)".
     Probably is a bug in the nodelet manager: https://github.com/ros/nodelet_core/issues/7 --> 
     <arg name="scan_topic" value="/pinky/scan" />
  </include>

 <arg name="initial_pose_x" default="0.0"/> <!-- Use 17.0 for willow's map in simulation -->
 <arg name="initial_pose_y" default="0.0"/> <!-- Use 17.0 for willow's map in simulation -->
 <arg name="initial_pose_a" default="0.0"/>

 <include file="$(find turtlebot_navigation)/launch/includes/DG_amcl.launch.xml">
     <arg name="initial_pose_x" value="$(arg initial_pose_x)"/>
     <arg name="initial_pose_y" value="$(arg initial_pose_y)"/>
     <arg name="initial_pose_a" value="$(arg initial_pose_a)"/>
 </include>

 <include file="$(find turtlebot_navigation)/launch/includes/move_base.launch.xml"/>
 </group>
</launch>

In the movebase.launch.xml file I also remapped topic map to /map (because I want to make map shareable between all the turtlebots). In addition I have changed robotbase_frame global and local cotmap params.


It looks to me that the problem in the DG_amcl.launch.xml file. Here is this file:

<launch>
<arg name="use_map_topic"  default="false"/>
<arg name="scan_topic"     default="scan"/>
<arg name="initial_pose_x" default="0.0"/>
<arg name="initial_pose_y" default="0.0"/>
<arg name="initial_pose_a" default="0.0"/>

<node pkg="amcl" type="amcl" name="amcl">
  <param name="use_map_topic"             value="$(arg use_map_topic)"/>
  <!-- Publish scans from best pose at a max of 10 Hz -->
  <param name="odom_model_type"           value="diff"/>
  <param name="odom_alpha5"               value="0.1"/>
  <param name="gui_publish_rate"          value="10.0"/>
  <param name="laser_max_beams"             value="60"/>
  <param name="laser_max_range"           value="12.0"/>
  <param name="min_particles"             value="500"/>
  <param name="max_particles"             value="2000"/>
  <param name="kld_err"                   value="0.05"/>
  <param name="kld_z"                     value="0.99"/>
  <param name="odom_alpha1"               value="0.2"/>
  <param name="odom_alpha2"               value="0.2"/>
<!-- translation std dev, m -->
<param name="odom_alpha3"               value="0.2"/>
<param name="odom_alpha4"               value="0.2"/>
<param name="laser_z_hit"               value="0.5"/>
<param name="laser_z_short"             value="0.05"/>
<param name="laser_z_max"               value="0.05"/>
<param name="laser_z_rand"              value="0.5"/>
<param name="laser_sigma_hit"           value="0.2"/>
<param name="laser_lambda_short"        value="0.1"/>
<param name="laser_model_type"          value="likelihood_field"/>
<!-- <param name="laser_model_type" value="beam"/> -->
<param name="laser_likelihood_max_dist" value="2.0"/>
<param name="update_min_d"              value="0.25"/>
<param name="update_min_a"              value="0.2"/>
<param name="odom_frame_id"             value="odom"/>
<param name="base_frame_id"             value="base_footprint"/>
<param name="global_frame_id"           value="/map"/>
<param name="resample_interval"         value="1"/>
<!-- Increase tolerance because the computer can get quite busy -->
<param name="transform_tolerance"       value="1.0"/>
<param name="recovery_alpha_slow"       value="0.0"/>
<param name="recovery_alpha_fast"       value="0.0"/>
<param name="initial_pose_x"            value="$(arg initial_pose_x)"/>
<param name="initial_pose_y"            value="$(arg initial_pose_y)"/>
<param name="initial_pose_a"            value="$(arg initial_pose_a)"/>
<remap from="scan"                      to="$(arg scan_topic)"/>
</node>
</launch>

Could someone please give me an advice what am I doing wrong? Thanks in advance!

Asked by David_Zizu on 2016-07-16 19:18:22 UTC

Comments

Answers