ROS Resources: Documentation | Support | Discussion Forum | Index | Service Status | Q&A answers.ros.org
Ask Your Question
0

How to change maps for path planning in navigation stack?

asked 2021-04-14 09:20:20 -0500

iamalostbot gravatar image

I am trying to swap the map that the map server provides at runtime for the navigation stack.

Currently I have made a multiplexer node that saves the output from 2 different map servers that were remapped to different topics, and then publishes the map corresponding to a service request to the /map topic.

However, this does not update the cost map, and our TF tree has issues when I do this as I get the error no tree from LaserScan to Map. The TF error may be because no map is published to /map until the mux node is up, and it coming online later than the move_base node.

edit retag flag offensive close merge delete

Comments

First of all, it would be a good idea to check if your hypothesis is correct. I think we can confirm this by starting the mux node first and then running the other nodes.

miura gravatar image miura  ( 2021-04-15 11:07:36 -0500 )edit

So I moved the multiplexer to be first on the launch file and the costmap now updates.

However, when I first use the multiplexer the cost map doesn't update, only after I load in a map, then swap the map does the cost map start to load. Any idea the causes/fixes for this?

iamalostbot gravatar image iamalostbot  ( 2021-04-17 15:14:31 -0500 )edit

1 Answer

Sort by ยป oldest newest most voted
0

answered 2021-04-18 01:51:35 -0500

gvdhoorn gravatar image

Related I believe: #q326929 (and #q270129).

The mux idea was a good one, but unless something has changed, I don't believe it'll work.

There is an open PR (ros-planning/navigation#1029) which will add a service to the map server to ask it to switch the map. You could see whether that works for you, and if it does, leave some feedback on the PR which could help get it merged.

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

2 followers

Stats

Asked: 2021-04-14 09:20:20 -0500

Seen: 133 times

Last updated: Apr 18 '21