From 083c7adc7ea9b09b92ac0f61b7c7b442875ffbd9 Mon Sep 17 00:00:00 2001 From: Stephen Dade Date: Wed, 29 Jan 2025 19:26:11 +1100 Subject: [PATCH] AP_Scripting: Update rockblock and MAVLinkHL with gcs:run_command and MISSION_SET_CURRENT --- libraries/AP_Scripting/applets/RockBlock.lua | 73 +++++++------------ libraries/AP_Scripting/examples/MAVLinkHL.lua | 73 +++++++------------ 2 files changed, 50 insertions(+), 96 deletions(-) diff --git a/libraries/AP_Scripting/applets/RockBlock.lua b/libraries/AP_Scripting/applets/RockBlock.lua index 2c5e175b1be1c..c2e7451cf2361 100644 --- a/libraries/AP_Scripting/applets/RockBlock.lua +++ b/libraries/AP_Scripting/applets/RockBlock.lua @@ -102,7 +102,8 @@ local function MAVLinkProcessor() COMMAND_INT = 75, HIGH_LATENCY2 = 235, MISSION_ITEM_INT = 73, - SET_MODE = 11 + SET_MODE = 11, + MISSION_SET_CURRENT = 41 } -- private fields @@ -121,6 +122,7 @@ local function MAVLinkProcessor() _crc_extra[235] = 0xb3 _crc_extra[73] = 0x26 _crc_extra[11] = 0x59 + _crc_extra[41] = 0x1c local _messages = {} _messages[75] = { -- COMMAND_INT @@ -156,6 +158,9 @@ local function MAVLinkProcessor() _messages[11] = { -- SET_MODE { "custom_mode", "