mirror of
https://github.com/ArduPilot/ardupilot
synced 2025-01-21 16:18:29 -04:00
GCS_MAVLink: deprecate handling of AUTOPILOT_VERSION_REQUEST
This can be done equivalently with MAV_CMD_REQUEST_MESSAGE
This commit is contained in:
parent
b2de8e0f6e
commit
d0b96d4cd9
@ -587,7 +587,9 @@ protected:
|
||||
|
||||
virtual MAV_RESULT handle_flight_termination(const mavlink_command_long_t &packet);
|
||||
|
||||
#if AP_MAVLINK_AUTOPILOT_VERSION_REQUEST_ENABLED
|
||||
void handle_send_autopilot_version(const mavlink_message_t &msg);
|
||||
#endif
|
||||
MAV_RESULT handle_command_request_autopilot_capabilities(const mavlink_command_long_t &packet);
|
||||
|
||||
virtual void send_banner();
|
||||
|
@ -3869,9 +3869,11 @@ void GCS_MAVLINK::handle_common_message(const mavlink_message_t &msg)
|
||||
handle_set_mode(msg);
|
||||
break;
|
||||
|
||||
#if AP_MAVLINK_AUTOPILOT_VERSION_REQUEST_ENABLED
|
||||
case MAVLINK_MSG_ID_AUTOPILOT_VERSION_REQUEST:
|
||||
handle_send_autopilot_version(msg);
|
||||
break;
|
||||
#endif
|
||||
|
||||
case MAVLINK_MSG_ID_MISSION_WRITE_PARTIAL_LIST:
|
||||
case MAVLINK_MSG_ID_MISSION_REQUEST_LIST:
|
||||
@ -4141,10 +4143,12 @@ void GCS_MAVLINK::handle_common_mission_message(const mavlink_message_t &msg)
|
||||
}
|
||||
}
|
||||
|
||||
#if AP_MAVLINK_AUTOPILOT_VERSION_REQUEST_ENABLED
|
||||
void GCS_MAVLINK::handle_send_autopilot_version(const mavlink_message_t &msg)
|
||||
{
|
||||
send_message(MSG_AUTOPILOT_VERSION);
|
||||
}
|
||||
#endif
|
||||
|
||||
void GCS_MAVLINK::send_banner()
|
||||
{
|
||||
|
@ -18,3 +18,10 @@
|
||||
#ifndef AP_MAVLINK_MISSION_SET_CURRENT_ENABLED
|
||||
#define AP_MAVLINK_MISSION_SET_CURRENT_ENABLED 1
|
||||
#endif
|
||||
|
||||
// AUTOPILOT_VERSION_REQUEST is slated to be removed; an instance of
|
||||
// AUTOPILOT_VERSION can be requested with MAV_CMD_REQUEST_MESSAGE,
|
||||
// which gets you an ACK/NACK
|
||||
#ifndef AP_MAVLINK_AUTOPILOT_VERSION_REQUEST_ENABLED
|
||||
#define AP_MAVLINK_AUTOPILOT_VERSION_REQUEST_ENABLED 1
|
||||
#endif
|
||||
|
Loading…
Reference in New Issue
Block a user