Navigation......Exercise 3.10

Dear Prof,
I studied the solution of exe 3.10

Would you please tell me the following:

  1. Do we call the map_server so that the amcl node can publish to it ? Also, how are amcl and map connected. map_server is a separate node while amcl is a separate. Apparently they don’t have any connection with each other.
  2. What’s the function of the line:
    <remap from="scan" to="$(arg scan_topic)"/>
  3. Where is the /odom topic. Because, I read in the notebook that the amcl node subsribes to both laser and odom topics and publishes to /map.

Hello @abdulbasitisdost,

  1. The amcl node is used for localizing your robot while the map_server node is used for providing a map of the environment (as you saw in the previous Unit). But you can’t localize a robot if you don’t have a map of the environment where the robot is. It makes no sense to localize a robot in a completely unknown space. Therefore, you need to get a map of the environment so that you can localize your robot in this environment.

  2. It remaps the default laser topic /scan to the topic used by this robot, which is defined in the argument scan_topic. By checking the code I can see that the argument scan_topic topic is set to /scan, therefore, here you are remapping from /scan to /scan, which is actually doing nothing. However, in many cases, the laser topic will be named differently (for instance, /kobuki/laser/scan in the Turtlebot robot.)

  3. By default, the amcl node subscribes to a topic named /odom in order to get this Odometry data. In most cases the Odometry topic will be named /odom, so we don’t need to do any remapping here. However, in the case that the Odometry topic is named differently (for instance, /odometry), then you would need to do a remap as well.


1 Like