ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | ros @ Robotics Stack Exchange
Ask Your Question
0

Local planner not working in ROS noetic - Ubuntu 20.04 LTS

asked 2023-07-09 10:01:36 -0600

iamsdevaprasad gravatar image

updated 2023-07-10 02:14:03 -0600

gvdhoorn gravatar image

I am navigating my custom mobile robot in GAZEBO simulation (ROS Noetic). I have generated map , used AMCL for localization, then used global and local planner for path planning.

My issue is while running the global and local planner i can do global path planning and the robot moves(from initial to final point), but the local planner doesn't generate its cost map and doesn't avoid obstacles (colides with obstacles not present while generating map).

It shows a single warning " Timed out waiting for transform from base_link to map to become available before running costmap, tf error: canTransform: target_frame map does not exist.. canTransform returned after 96.134 timeout was 0.1."

I hope think this warning might prevent local planner and costmap to work. I have tried a lot of methods but couldn't solve it. Please help as soon as posible. It would be helpful for my final year project.

Below is the video for navigation and parameters used. Since the parameters file is long i have attached a text file .

Link of navigation : link text

maap_amcl_kob4.launch:

<launch>

  <!-- Map Server Arguments -->
  <arg name="map_file" default="$(find kob_4_description)/maps/3rd_t3_home/3rd_tb3_home.yaml"/>
  <node name="map_server" pkg="map_server" type="map_server" args="$(arg map_file)" />

  <!-- Arguments -->
  <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"/>

  <!-- AMCL -->
  <include file = "$(find kob_4_description)/launch/kob_amcl.launch" />

</launch>

kob_amcl.launch

<launch>
<node pkg="amcl" type="amcl" name="amcl" output="screen">
  <!-- 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="30"/>
  <param name="min_particles" value="500"/>
  <param name="max_particles" value="5000"/>
  <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.8"/>
  <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.2"/>
  <param name="update_min_a" value="0.5"/>
  <param name="odom_frame_id" value="odom"/>
  <param name="resample_interval" value="1"/>
  <param name="transform_tolerance" value="0.1"/>
  <param name="recovery_alpha_slow" value="0.0"/>
  <param name="recovery_alpha_fast" value="0.0"/>
</node>
</launch>

common_costmap.yaml:

robot_radius: 0.175

robot_base_frame: base_footprint
update_frequency: 4.0
publish_frequency: 3.0
transform_tolerance: 0.5

resolution: 0.05

obstacle_range: 5 ...
(more)
edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2023-07-10 03:09:29 -0600

MaxHuang gravatar image

You can try to debug step by step,

  1. Set the inflaction radius in global_cost_map to 0.
  2. Set the inflaction radius in local_cost_map lager than 0.
  3. Figure out whether there is an inflaction radius shown on the map or not, if there is no inflaction radius shown, then you can figure out that the problem must caused by setting of the local cost map.

Otherwise, check the data source of the local cost map, ensure the tf work well.

edit flag offensive delete link more

Comments

i have tried it but it doesnt work, still the local costmap is blank. *Timed out waiting for transform from base_link to map to become available before running costmap, tf error: canTransform: target_frame map does not exist. canTransform: source_frame base_link does not exist.. canTransform returned after 239.837 timeout was 0.1. * is this warning message is the reason.

iamsdevaprasad gravatar image iamsdevaprasad  ( 2023-07-16 10:26:35 -0600 )edit
0

answered 2023-07-09 15:31:31 -0600

IvanV gravatar image

In a quick look, I see you have not defined any layer in your local costmap. Thus, the costmap will be empty and will not consider obstacles. You need to add at least one obstacles layer so it considers laser imputs for obstacle detection.

edit flag offensive delete link more

Comments

Thanks for the answer, i will update soon after trying it...

iamsdevaprasad gravatar image iamsdevaprasad  ( 2023-07-09 21:52:46 -0600 )edit

Sir could you share any resources regarding it , as far i searched in the internet there is no layers in local cost map file.

iamsdevaprasad gravatar image iamsdevaprasad  ( 2023-07-16 10:28:23 -0600 )edit

Question Tools

1 follower

Stats

Asked: 2023-07-09 10:01:36 -0600

Seen: 85 times

Last updated: Jul 10 '23