I tried setting the parameter "/move_base/base_global_planner" as "global_planner/GlobalPlanner" when my custom planner fails to make a plan and return false in the function "makePlan" . But still keeps calling the same custom planner instead of the "global_planner/globalPlanner".
I have written below a piece of code from my custom global planner in the makePlan function,
bool success = client.call(srv);
if (!success)
{
ROS_ERROR_STREAM_THROTTLE(1, "Failed to call service planner");
n.setParam("move_base/base_global_planner","global_planner/GlobalPlanner");
return false;
}
Please help me out on this, or any other alternative ways of switching the global planner.
Originally posted by chandra8992 on ROS Answers with karma: 1 on 2018-08-23
Post score: 0