Offboard Mode

The vehicle obeys a position, velocity or attitude setpoint provided over MAVLink. The setpoint may be provided by a MAVLink API (e.g. MAVSDK or MAVROS) running on a companion computer (and usually connected via serial cable or wifi).

Offboard mode is not supported by Fixed Wing vehicles. It is supported for Copter and VTOL vehicles.

  • This mode requires position or pose/attitude information - e.g. GPS, optical flow, visual-inertial odometry, mocap, etc.
  • RC control is disabled except to change modes.
  • The vehicle must be armed before this mode can be engaged.
  • The vehicle must be already be receiving a stream of target setpoints before this mode can be engaged.
  • The vehicle will exit the mode if target setpoints are not received at a rate of > 2Hz.

Description

Offboard mode is primarily used for controlling vehicle movement and attitude, and supports only a very limited set of MAVLink commands (more may be supported in future). It can be used to:

Other operations, like taking off, landing, return to launch, are best handled using the appropriate modes. Operations like uploading, downloading missions can be performed in any mode.

A stream of setpoint commands must be received by the vehicle prior to engaging the mode, and in order to remain in the mode (if the message rate falls below 2Hz the vehicle will stop). In order to hold position while in this mode, the vehicle must receive a stream of setpoints for the current position.

Offboard mode requires an active connection to a remote MAVLink system (e.g. companion computer or GCS). If the connection is lost, after a timeout (COM_OF_LOSS_T) the vehicle will attempt to land or perform some other failsafe action. The action is defined in the parameters COM_OBL_ACT and COM_OBL_RC_ACT.

Offboard Parameters

Offboard mode is affected by the following parameters:

Parameter Description
COM_OF_LOSS_T Time-out (in seconds) to wait when offboard connection is lost before triggering offboard lost failsafe (COM_OBL_ACT and COM_OBL_RC_ACT)
COM_OBL_ACT Mode to switch to if offboard control is lost when not connected to RC (Values are - 0: Land, 1: Hold, 2: Return ).
COM_OBL_RC_ACT Mode to switch to if offboard control is lost while still connected to RC control (Values are - 0: Position, 1: Altitude, 2: Manual, 3: Return , 4: Land).

Developer Resources

Typically developers do not directly work at the MAVLink layer, but instead use a robotics API like Dronecode SDK or ROS (these provide a developer friendly API, and take care of managing and maintaining connections, sending messages and monitoring responses - the minutiae of working with Offboard mode and MAVLink).

The following resources may be useful for a developer audience:

© PX4 Dev Team. License: CC BY 4.0            Updated: 2020-10-28 22:06:47

results matching ""

    No results matching ""