3 #define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL 5
13 #define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN 28
14 #define MAVLINK_MSG_ID_5_LEN 28
16 #define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_CRC 217
17 #define MAVLINK_MSG_ID_5_CRC 217
19 #define MAVLINK_MSG_CHANGE_OPERATOR_CONTROL_FIELD_PASSKEY_LEN 25
21 #define MAVLINK_MESSAGE_INFO_CHANGE_OPERATOR_CONTROL { \
22 "CHANGE_OPERATOR_CONTROL", \
24 { { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 0, offsetof(mavlink_change_operator_control_t, target_system) }, \
25 { "control_request", NULL, MAVLINK_TYPE_UINT8_T, 0, 1, offsetof(mavlink_change_operator_control_t, control_request) }, \
26 { "version", NULL, MAVLINK_TYPE_UINT8_T, 0, 2, offsetof(mavlink_change_operator_control_t, version) }, \
27 { "passkey", NULL, MAVLINK_TYPE_CHAR, 25, 3, offsetof(mavlink_change_operator_control_t, passkey) }, \
44 static inline uint16_t mavlink_msg_change_operator_control_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
45 uint8_t target_system, uint8_t control_request, uint8_t version,
const char *passkey)
47 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
52 _mav_put_char_array(buf, 3, passkey, 25);
59 mav_array_memcpy(packet.
passkey, passkey,
sizeof(
char)*25);
83 static inline uint16_t mavlink_msg_change_operator_control_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
84 mavlink_message_t* msg,
85 uint8_t target_system,uint8_t control_request,uint8_t version,
const char *passkey)
87 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
92 _mav_put_char_array(buf, 3, passkey, 25);
99 mav_array_memcpy(packet.
passkey, passkey,
sizeof(
char)*25);
104 #if MAVLINK_CRC_EXTRA
119 static inline uint16_t mavlink_msg_change_operator_control_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_change_operator_control_t* change_operator_control)
121 return mavlink_msg_change_operator_control_pack(system_id, component_id, msg, change_operator_control->
target_system, change_operator_control->
control_request, change_operator_control->
version, change_operator_control->
passkey);
133 static inline uint16_t mavlink_msg_change_operator_control_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_change_operator_control_t* change_operator_control)
135 return mavlink_msg_change_operator_control_pack_chan(system_id, component_id, chan, msg, change_operator_control->
target_system, change_operator_control->
control_request, change_operator_control->
version, change_operator_control->
passkey);
147 #ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
149 static inline void mavlink_msg_change_operator_control_send(
mavlink_channel_t chan, uint8_t target_system, uint8_t control_request, uint8_t version,
const char *passkey)
151 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
156 _mav_put_char_array(buf, 3, passkey, 25);
157 #if MAVLINK_CRC_EXTRA
167 mav_array_memcpy(packet.
passkey, passkey,
sizeof(
char)*25);
168 #if MAVLINK_CRC_EXTRA
176 #if MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN <= MAVLINK_MAX_PAYLOAD_LEN
184 static inline void mavlink_msg_change_operator_control_send_buf(mavlink_message_t *msgbuf,
mavlink_channel_t chan, uint8_t target_system, uint8_t control_request, uint8_t version,
const char *passkey)
186 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
187 char *buf = (
char *)msgbuf;
191 _mav_put_char_array(buf, 3, passkey, 25);
192 #if MAVLINK_CRC_EXTRA
202 mav_array_memcpy(packet->
passkey, passkey,
sizeof(
char)*25);
203 #if MAVLINK_CRC_EXTRA
222 static inline uint8_t mavlink_msg_change_operator_control_get_target_system(
const mavlink_message_t* msg)
232 static inline uint8_t mavlink_msg_change_operator_control_get_control_request(
const mavlink_message_t* msg)
242 static inline uint8_t mavlink_msg_change_operator_control_get_version(
const mavlink_message_t* msg)
252 static inline uint16_t mavlink_msg_change_operator_control_get_passkey(
const mavlink_message_t* msg,
char *passkey)
254 return _MAV_RETURN_char_array(msg, passkey, 25, 3);
265 #if MAVLINK_NEED_BYTE_SWAP
266 change_operator_control->
target_system = mavlink_msg_change_operator_control_get_target_system(msg);
267 change_operator_control->
control_request = mavlink_msg_change_operator_control_get_control_request(msg);
268 change_operator_control->
version = mavlink_msg_change_operator_control_get_version(msg);
269 mavlink_msg_change_operator_control_get_passkey(msg, change_operator_control->
passkey);
Definition: mavlink_msg_change_operator_control.h:5
uint8_t version
0: key as plaintext, 1-255: future, different hashing/encryption variants. The GCS should in general ...
Definition: mavlink_msg_change_operator_control.h:9
#define _MAV_RETURN_uint8_t(msg, wire_offset)
Definition: protocol.h:238
MAVLINK_HELPER uint16_t mavlink_finalize_message(mavlink_message_t *msg, uint8_t system_id, uint8_t component_id, uint8_t length)
Finalize a MAVLink message with MAVLINK_COMM_0 as default channel.
Definition: mavlink_helpers.h:105
#define _mav_put_uint8_t(buf, wire_offset, b)
Definition: protocol.h:134
#define _MAV_PAYLOAD_NON_CONST(msg)
Definition: mavlink_types.h:172
uint8_t control_request
0: request control of this MAV, 1: Release control of this MAV
Definition: mavlink_msg_change_operator_control.h:8
mavlink_channel_t
Definition: mavlink_types.h:178
#define _MAV_PAYLOAD(msg)
Definition: mavlink_types.h:171
char passkey[25]
Password / Key, depending on version plaintext or encrypted. 25 or less characters, NULL terminated. The characters may involve A-Z, a-z, 0-9, and "!?,.-".
Definition: mavlink_msg_change_operator_control.h:10
#define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_CRC
Definition: mavlink_msg_change_operator_control.h:16
#define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL_LEN
Definition: mavlink_msg_change_operator_control.h:13
#define MAVLINK_MSG_ID_CHANGE_OPERATOR_CONTROL
Definition: mavlink_msg_change_operator_control.h:3
struct __mavlink_change_operator_control_t mavlink_change_operator_control_t
MAVLINK_HELPER uint16_t mavlink_finalize_message_chan(mavlink_message_t *msg, uint8_t system_id, uint8_t component_id, uint8_t chan, uint8_t length)
Finalize a MAVLink message with channel assignment.
Definition: mavlink_helpers.h:71
uint8_t target_system
System the GCS requests control for.
Definition: mavlink_msg_change_operator_control.h:7