PX4 / PX4-Avoidance

PX4 avoidance ROS node for obstacle detection and avoidance.
http://px4.io
BSD 3-Clause "New" or "Revised" License
630 stars 330 forks source link

Discussion on unifying behavioral differences between local planner and global planner #337

Open Jaeyoung-Lim opened 5 years ago

Jaeyoung-Lim commented 5 years ago

Describe problem solved by the proposed feature I have been looking into understand how global planner works, and it seems that the implementation is quite different compared to the local planner.

This alone is not too bad, but the real problem is that the general interaction with the firmware becomes different. The recent failsafe features in local_planner are not implemented in global_planner.

For example, global_planner will never send MAV_STATE_CRITICAL to the firmware.

Re-implementing the same behavior doesn't seem quite straight forward as both planners are tightly integrated into their use cases. Moreover, it would be hard to maintain both cmdloops to show the same behavior everytime there is something changing in the local_planner

Describe your preferred solution One solution can be that there is a single node that handles all interaction with mavros including the failsafe features, while global and local planners only have planner specific functions.

I would like to implement something like a PathHandlerNode which does the following things, on top of #334

Please give any inputs or comments regarding this issue. I would be willing to implement this, but this would need to bring changes on both global_planner and local_planner cmdloops.

Therefore I wanted some consensus from the community if this is something we want, or worth considering, or if it is too early to move in this direction.

nicovanduijn commented 5 years ago

Personally, I like the idea.

Modularizing these things would also make it easier to use things like OMPL, or quickly sketch out new planners and test them. Maybe a semi-global planner will be the future? (To be honest, that's what the current local planner pretty much is...)

Obviously, I'm biased by my thesis though

Jaeyoung-Lim commented 5 years ago

@nicovanduijn Awesome!

I agree. The direction I would like to see the avoidance repo go, is that anybody should be able to easily plug in their planner to the avoidance. This unloads people from tightly integrating their stuff to PX4. but this will be far in the future.