Enable/disable obstacle avoidance during operation
Hi All,
Is there an easy way to enable and disable obstacle avoidance when the robot is in operation? I would like to do this without editing config files and restarting ROS. Restarting ROS would be acceptable if necessary (i.e. rebooting the computer).
For some background, I use LiDAR for obstacle detection and I want to be able to enable / disable obstacle avoidance when the robot moves to a different terrain. For example when the robot is surrounded with vegetation (grass) the LiDAR will see obstacles everywhere making navigation impossible even if the robot could move. On a clear area obstacle avoidance could be turned back on.
What would be an elegant way to achieve this? Thank you!
Asked by tbondar on 2020-09-10 10:52:44 UTC
Answers
Hi tbondar,
If you are using move_base with costmap_2d, the layers of the costmap can be enabled/disabled using the dynamic reconfigure server. If you have your system running, and use:
rosrun rqt_reconfigure rqt_reconfigure
You can manually enable/disable the obstacle layer and let move_base etc path plan using other layers. If you want to make your own node to do this on your behalf take a look at running a dynamic reconfigure client.
Asked by Andy West on 2020-09-21 03:29:35 UTC
Comments