Function rc_mav_send_heartbeat#
Defined in File mavlink_udp_helpers.h
Function Documentation#
-
int rc_mav_send_heartbeat(uint32_t custom_mode, uint8_t type, uint8_t autopilot, uint8_t base_mode, uint8_t system_status)#
Constructs and sends a heartbeat packet of type MAVLINK_MSG_ID_HEARTBEAT.
Constructs and sends a heartbeat packet to the previously set destination ip address. The arguments encompass all available parameters in the heartbeat packet. However, many users will not be bothered to populate these parameters and may opt to use rc_mav_send_heartbeat_abbreviated() instead.
- Parameters:
custom_mode – [in] A bitfield for use for autopilot-specific flags.
type – [in] Type of the MAV (quadrotor, helicopter, etc., up to 15 types, defined in MAV_TYPE ENUM)
autopilot – [in] Autopilot type / class. defined in MAV_AUTOPILOT ENUM
base_mode – [in] System mode bitfield, see MAV_MODE_FLAGS ENUM in mavlink/include/mavlink_types.h
system_status – [in] System status flag, see MAV_STATE ENUM
- Returns:
0 on success, -1 on failure