Ask Your Question

how to change a map

asked 2014-05-14 06:35:09 -0500

Ico gravatar image

I have a question about how to change a map...I am new to ROS and Ubuntu 12.04 so I dont know really...

I am running SBPL Lattice planner and I want to compare that planner to the one i already have, so I should ride the robots on the same map. I need to change the map in SBPL Lattice planner to my map, so how can I do that?

And the other question would be, how can i type the coordinates where the Robot should go (there is 2D Nav Goal in rviz, but I need that the Robots go to the same place)

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted

answered 2014-05-14 10:23:40 -0500

updated 2014-05-14 10:31:59 -0500

Firstly, You have to include map of your environment in png format in your launch file. I assume that you are launching this file for SBPL planner : launch / move_base_sbpl_fake_localization_2.5cm.launch

If you open this file, there is a node which include map and publishes map to the /map topic.

<node name="map_server" pkg="map_server" type="map_server" args="$(find sbpl_lattice_planner)/worlds/willow.pgm 0.025"/>

remove willlow.pgm and instead give your map address. also remove next <node> line its for inbuilt simulator stage.

so, Once try to run it on your robot and see the /map data on rviz, ( roslaunch turtlebot_rviz_launchers view_navigation.launch ) is the best and simplest way to do it Here you can give 2D navigation goal by manually clicking on the 2D map.

If you want to give goal position from terminal or code, you can modify the value of topic /move_base/simple_navigation_goal

(But, as you are trying to compare navigation i dont think that you would be bothered about exact same goal for both the planner. If you want exactly same goal then you should publish nav_goal to the above topic.)

NOTE: If you re-launch the map-server, it might not give same coordinate value for same point, i.e, ( point (0,0) might become point (2,2) in next iteration) So, consider that, For that i suggest you launch a separate file for /map and just relaunch the planners.

Hope this helped, Sudeep

edit flag offensive delete link more

answered 2014-05-14 09:59:25 -0500

AbuIbra gravatar image

To make robots go to the same place, both robots have to subscribe to this same topic


and process the goal for both robots to make them go to the same place.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools


Asked: 2014-05-14 06:35:09 -0500

Seen: 1,630 times

Last updated: May 14 '14