[Solved] Tutorial 7: Path planning (with Gazebo) --- poor performance, plus errors and warnings

When following “Tutorial 7. Path planning,” I ran into several errors and warnings. The fixes (?) I applied to them are detailed below. Even after the errors and most of the warnings have been resolved, the ROSbot (A) strays far from the global_plan Path, and (B) often runs into walls when navigating to a “2D Nav Goal,” despite the fact that the walls show up in the SLAM Map and the global_costmap Map. A brief experience with the physical ROSbot showed that it, too, deviated significantly from the global_plan Path. Is this behavior to be expected? If so, can you tell me why? If not, can you offer any suggestions for improving it?

Here are the messages I received when running the “Path planning” tutorial.

[ WARN] [1561746904.781913245, 2918.960000000]: 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 2918.96 timeout was 0.1.

This one is unresolved.

[ WARN] [1561747609.753177997, 2935.010000000]: MessageFilter [target=map laser_frame ]: Dropped 100.00% of messages so far. Please turn the [ros.costmap_2d.message_notifier] rosconsole logger to DEBUG for more information.

I resolved this by removing

if="$(arg use_rosbot)"

from this line in the launch file

<node if="$(arg use_rosbot)" pkg="tf" type="static_transform_publisher" name="laser_broadcaster" args="0 0 0 3.14 0 0 base_link laser_frame 100" />

Invalid roslaunch XML syntax: [Errno 2] No such file or directory: u’/home/mqm/ROSWorkspaces/catkin_ws/src/ROSbot/rosbot_description/src/rosbot_gazebo/launch/rosbot.launch’

I resolved this by changing

<include if="$(arg use_gazebo)" file="$(find rosbot_gazebo)/launch/rosbot.launch"/>

in the launchfile to

<include if="$(arg use_gazebo)" file="$(find rosbot_description)/launch/rosbot_gazebo.launch"/>

Hello thehandoftheking,

This is not the expected behaviour, ROSbot should not hit any obstacles.

You should not remove if="$(arg use_rosbot)" nor if="$(arg use_gazebo)" parts. They are required to distinguish components for simulated and real ROSbot.

Change of file="$(find rosbot_description)/launch/rosbot_gazebo.launch" is indeed correct.

Could you provide full output that you received when running tutorial?

Regards,
Łukasz

Thank you for the response. Today, I started over with Tutorial 7 and everything performs well. The only change I made from the launch file provided online is using rosbot_description/launch/rosbot_gazebo.launch as you prescribed. It seems there’s no need to investigate the bad performance in my first attempt.

Should I somehow mark this post as closed?

Thank you for update on this, I will mark it as closed.

Regards,
Łukasz