FirmwareArchitecture: Multirotor Navigation

James Cotton edited this page Feb 2, 2014 · 2 revisions

The VTOL navigation is factored into a few tiers spread across two modules, described in more detail below:

  • PathPlanner (common to planes): high level module that iterates between waypoints sequentially
  • VtolPathFollower: lower level module that supports following the path as well as RTH and PH
  • FSM: allows multistep messages like RTH, PH with loiter, as well as passing messages from PathPlanner
  • Control: implements the control algorithms
  • Paths: a library that contains the math for working out distance along and away from the path. Called from the control code

There is some awkwardness with this layout. The FSM architecture of the VtolPathFollower would be powerful enough to handle sequencing waypoints too. As is, it is somewhat underutilized.

  1. PathPlanner - the highest level module. Not usable on F3 platforms or below for lack of memory. This manages lists of Waypoints as copies the appropriate Waypoint (determined by WaypointActive) to PathDesired. The information to indicate this comes from PathStatus.Status becoming complete.
  2. FSM - certain goals can be activated that the VtolPathFollower module will attempt to achieve. Some flight modes map to these modes.
  3. ReturnToHome: activates GOAL_LAND_HOME which will ascend to 15m (if below), hover, fly to the home location, and finally land.
  4. PositionHold: this mode will attempt to remain where it was activated. It also supports loitering, where using pitch and roll will move the setpoint forward or laterally.
  5. PathPlanner: this follows the sequence of waypoints passed from PathPlanner via PathDesired
  6. Control - this implements the control algorithms (mostly PID). There are three implemented currently
  7. vtol_follower_control_path - follow a linear or curved path segment
  8. vtol_follower_control_endpoint - attempt to stay (or move to) the requested location
  9. vtol_follower_control_land - attempt to descend at the requested location
  10. Paths - the math that works with straight lines and curves to compute the distance along the path segment and calculate the tangential error
Clone this wiki locally
You can’t perform that action at this time.
You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session.
Press h to open a hovercard with more details.