From 1991a5a2180fd5172a3cf7ab08292b8908d67cd9 Mon Sep 17 00:00:00 2001 From: Peter Barker Date: Thu, 5 Sep 2024 19:14:54 +1000 Subject: [PATCH] GCS_MAVLink: reject SET_MESSAGE_INTERVAL commands with p3 set this is going to be used for changing the rate of a specific instance of a message at some stage we have to reject it for now so that when the index is used the GCS is told that their message is invalid in this older version of the autopilot --- libraries/GCS_MAVLink/GCS_Common.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/libraries/GCS_MAVLink/GCS_Common.cpp b/libraries/GCS_MAVLink/GCS_Common.cpp index e6318c9e2a15f2..1c6976d7a263bc 100644 --- a/libraries/GCS_MAVLink/GCS_Common.cpp +++ b/libraries/GCS_MAVLink/GCS_Common.cpp @@ -3029,6 +3029,9 @@ MAV_RESULT GCS_MAVLINK::handle_command_do_aux_function(const mavlink_command_int MAV_RESULT GCS_MAVLINK::handle_command_set_message_interval(const mavlink_command_int_t &packet) { + if (!is_equal(packet.param3)) { + return MAV_RESULT_DENIED; + } return set_message_interval((uint32_t)packet.param1, (int32_t)packet.param2); }