Pausing or aborting movement to a goal
What's the best way to programatically pause or abort movement towards a goal location once it's in the process of being executed?
What's the best way to programatically pause or abort movement towards a goal location once it's in the process of being executed?
The move_base node uses an action interface for managing its goals which is built on top of ROS topics one of which is, in this case, move_base/cancel. You can send a message-based cancel request, but I'd recommend using an action client to interact with move_base. Documentation that will probably be useful includes, actionlib documentation (http://www.ros.org/wiki/actionlib), and a tutorial on sending goals to the navigation stack using actionlib (http://www.ros.org/wiki/navigation/Tutorials/SendingSimpleGoals).
Hope this helps.
Is it possible to cancel the goal inside the ActionServer
itself without adding a client side to it. I'm adding priorities to my multiple action servers and whenever any of the callbacks is triggered the server has to check if a goal with a higher priority is currently being executed.
If the received goal is with a higher priority of the currently running goal, the currently running goal needs to be canceled and the new goal is executed.
The action client also defines methods for canceling a goal which just sends a preemption request to the action server. If implemented correctly, the server then stops executing the goal as soon as possible. The method for canceling the goal in SimpleActionServer is cancelGoal.
There is no way to pause an action. You always need to cancel it and re-send the goal when you want to continue.
For an action server, sending an empty goal will stop it. However some action servers don't implement this feature (tuck_arm for example).
Hope this helps,
Guido
Please start posting anonymously - your entry will be published after you log in or create a new account.
Asked: 2011-04-09 02:23:14 -0600
Seen: 5,117 times
Last updated: Apr 11 '11
How to pause a mobile robot during navigation?
Control loop missed its desired rate
Simple move_base example without sensors?
Local costmap not showing obstacles
navigation parameters that work on raspberry pi 3B+ (CPU maxed with current)
inscribed and circumscribed radii of the robot used despite footprint being set