Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

Multi-robot navigation

Hi,

I have problem with implementing navigation to work with multiple robots. Errors:

Waiting on transform from /robot_1/base to /map to become available before running costmap, tf error: Frame id /robot_1/base does not exist!
Waiting on transform from /robot_2/base to /map to become available before running costmap, tf error: Frame id /robot_2/base does not exist!

Probably, the problem is in transformations that transform /map to /base and not from /map to /robot_1/base. I use groups/namespaces in launch file to separate each robot node with correspondiong move_base node from other nodes. To run navigation stack I launch robot_configuaration.launch and move_base.launch. I have found the following solution:

<launch>
  <group ns="robot_1">
    <param name="tf_prefix" value="robot_1"/>
    <node pkg="robot_conf" type="robot_conf" respawn="false" name="robot_conf" output="screen">
  </group>
  <group ns="robot_2">
    <param name="tf_prefix" value="robot_2"/>
    <node pkg="robot_conf" type="robot_conf2" respawn="false" name="robot_conf2" output="screen">
  </group>

and

<launch>
  <node name="map_server" pkg="map_server" type="map_server" args="/home/user/Desktop/ROS/map.pgm 0.05" respawn="false">
  </node>

  <group ns="robot_1"><br>
    <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
      <rosparam file="$(find robot_2dnav)/costmap_common_params.yaml" command="load" ns="global_costmap" />
      <rosparam file="$(find robot_2dnav)/costmap_common_params.yaml" command="load" ns="local_costmap" />
      <rosparam file="$(find robot_2dnav)/local_costmap_params.yaml" command="load" />
      <rosparam file="$(find robot_2dnav)/global_costmap_params.yaml" command="load" />
      <rosparam file="$(find robot_2dnav)/base_local_planner_params.yaml" command="load" /><br>
    </node><br>
  </group>

  <group ns="robot_2">
    <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
    ...same as for group_1

but this doesn't work. Is there some solution to automatically map all topics and tf's directly from .launch file?

Multi-robot navigation

Hi,

I have problem with implementing navigation to work with multiple robots. Errors:

Waiting on transform from /robot_1/base to /map to become available before running costmap, tf error: Frame id /robot_1/base does not exist!
Waiting on transform from /robot_2/base to /map to become available before running costmap, tf error: Frame id /robot_2/base does not exist!

Probably, the problem is in transformations that transform /map to /base and not from /map to /robot_1/base. I use groups/namespaces in launch file to separate each robot node with correspondiong move_base node from other nodes. To run navigation stack I launch robot_configuaration.launch and move_base.launch. I have found the following solution:

<launch>
  <group ns="robot_1">
    <param name="tf_prefix" value="robot_1"/>
    <node pkg="robot_conf" type="robot_conf" pkg="usarsim" type="usarsim.py" respawn="false" name="robot_conf" name="usarsim_1" output="screen">
  </group>
  <group ns="robot_2">
    <param name="tf_prefix" value="robot_2"/>
    <node pkg="robot_conf" type="robot_conf2" pkg="usarsim" type="usarsim2.py" respawn="false" name="robot_conf2" name="usarsim_2" output="screen">
  </group>

and

<launch>
  <node name="map_server" pkg="map_server" type="map_server" args="/home/user/Desktop/ROS/map.pgm 0.05" respawn="false">
  </node>

  <group ns="robot_1"><br>
    <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
      <rosparam file="$(find robot_2dnav)/costmap_common_params.yaml" command="load" ns="global_costmap" />
      <rosparam file="$(find robot_2dnav)/costmap_common_params.yaml" command="load" ns="local_costmap" />
      <rosparam file="$(find robot_2dnav)/local_costmap_params.yaml" command="load" />
      <rosparam file="$(find robot_2dnav)/global_costmap_params.yaml" command="load" />
      <rosparam file="$(find robot_2dnav)/base_local_planner_params.yaml" command="load" /><br>
    </node><br>
  </group>

  <group ns="robot_2">
    <node pkg="move_base" type="move_base" respawn="false" name="move_base" output="screen">
    ...same as for group_1

but this doesn't work. Is there some solution to automatically map all topics and tf's directly from .launch file?