3 #define MAVLINK_MSG_ID_AUTOPILOT_VERSION 148
20 #define MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN 60
21 #define MAVLINK_MSG_ID_148_LEN 60
23 #define MAVLINK_MSG_ID_AUTOPILOT_VERSION_CRC 178
24 #define MAVLINK_MSG_ID_148_CRC 178
26 #define MAVLINK_MSG_AUTOPILOT_VERSION_FIELD_FLIGHT_CUSTOM_VERSION_LEN 8
27 #define MAVLINK_MSG_AUTOPILOT_VERSION_FIELD_MIDDLEWARE_CUSTOM_VERSION_LEN 8
28 #define MAVLINK_MSG_AUTOPILOT_VERSION_FIELD_OS_CUSTOM_VERSION_LEN 8
30 #define MAVLINK_MESSAGE_INFO_AUTOPILOT_VERSION { \
31 "AUTOPILOT_VERSION", \
33 { { "capabilities", NULL, MAVLINK_TYPE_UINT64_T, 0, 0, offsetof(mavlink_autopilot_version_t, capabilities) }, \
34 { "uid", NULL, MAVLINK_TYPE_UINT64_T, 0, 8, offsetof(mavlink_autopilot_version_t, uid) }, \
35 { "flight_sw_version", NULL, MAVLINK_TYPE_UINT32_T, 0, 16, offsetof(mavlink_autopilot_version_t, flight_sw_version) }, \
36 { "middleware_sw_version", NULL, MAVLINK_TYPE_UINT32_T, 0, 20, offsetof(mavlink_autopilot_version_t, middleware_sw_version) }, \
37 { "os_sw_version", NULL, MAVLINK_TYPE_UINT32_T, 0, 24, offsetof(mavlink_autopilot_version_t, os_sw_version) }, \
38 { "board_version", NULL, MAVLINK_TYPE_UINT32_T, 0, 28, offsetof(mavlink_autopilot_version_t, board_version) }, \
39 { "vendor_id", NULL, MAVLINK_TYPE_UINT16_T, 0, 32, offsetof(mavlink_autopilot_version_t, vendor_id) }, \
40 { "product_id", NULL, MAVLINK_TYPE_UINT16_T, 0, 34, offsetof(mavlink_autopilot_version_t, product_id) }, \
41 { "flight_custom_version", NULL, MAVLINK_TYPE_UINT8_T, 8, 36, offsetof(mavlink_autopilot_version_t, flight_custom_version) }, \
42 { "middleware_custom_version", NULL, MAVLINK_TYPE_UINT8_T, 8, 44, offsetof(mavlink_autopilot_version_t, middleware_custom_version) }, \
43 { "os_custom_version", NULL, MAVLINK_TYPE_UINT8_T, 8, 52, offsetof(mavlink_autopilot_version_t, os_custom_version) }, \
67 static inline uint16_t mavlink_msg_autopilot_version_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
68 uint64_t capabilities, uint32_t flight_sw_version, uint32_t middleware_sw_version, uint32_t os_sw_version, uint32_t board_version,
const uint8_t *flight_custom_version,
const uint8_t *middleware_custom_version,
const uint8_t *os_custom_version, uint16_t vendor_id, uint16_t product_id, uint64_t uid)
70 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
80 _mav_put_uint8_t_array(buf, 36, flight_custom_version, 8);
81 _mav_put_uint8_t_array(buf, 44, middleware_custom_version, 8);
82 _mav_put_uint8_t_array(buf, 52, os_custom_version, 8);
101 #if MAVLINK_CRC_EXTRA
127 static inline uint16_t mavlink_msg_autopilot_version_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
128 mavlink_message_t* msg,
129 uint64_t capabilities,uint32_t flight_sw_version,uint32_t middleware_sw_version,uint32_t os_sw_version,uint32_t board_version,
const uint8_t *flight_custom_version,
const uint8_t *middleware_custom_version,
const uint8_t *os_custom_version,uint16_t vendor_id,uint16_t product_id,uint64_t uid)
131 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
141 _mav_put_uint8_t_array(buf, 36, flight_custom_version, 8);
142 _mav_put_uint8_t_array(buf, 44, middleware_custom_version, 8);
143 _mav_put_uint8_t_array(buf, 52, os_custom_version, 8);
157 mav_array_memcpy(packet.
os_custom_version, os_custom_version,
sizeof(uint8_t)*8);
162 #if MAVLINK_CRC_EXTRA
177 static inline uint16_t mavlink_msg_autopilot_version_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_autopilot_version_t* autopilot_version)
179 return mavlink_msg_autopilot_version_pack(system_id, component_id, msg, autopilot_version->
capabilities, autopilot_version->
flight_sw_version, autopilot_version->
middleware_sw_version, autopilot_version->
os_sw_version, autopilot_version->
board_version, autopilot_version->
flight_custom_version, autopilot_version->
middleware_custom_version, autopilot_version->
os_custom_version, autopilot_version->
vendor_id, autopilot_version->
product_id, autopilot_version->
uid);
191 static inline uint16_t mavlink_msg_autopilot_version_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_autopilot_version_t* autopilot_version)
193 return mavlink_msg_autopilot_version_pack_chan(system_id, component_id, chan, msg, autopilot_version->
capabilities, autopilot_version->
flight_sw_version, autopilot_version->
middleware_sw_version, autopilot_version->
os_sw_version, autopilot_version->
board_version, autopilot_version->
flight_custom_version, autopilot_version->
middleware_custom_version, autopilot_version->
os_custom_version, autopilot_version->
vendor_id, autopilot_version->
product_id, autopilot_version->
uid);
212 #ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
214 static inline void mavlink_msg_autopilot_version_send(
mavlink_channel_t chan, uint64_t capabilities, uint32_t flight_sw_version, uint32_t middleware_sw_version, uint32_t os_sw_version, uint32_t board_version,
const uint8_t *flight_custom_version,
const uint8_t *middleware_custom_version,
const uint8_t *os_custom_version, uint16_t vendor_id, uint16_t product_id, uint64_t uid)
216 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
226 _mav_put_uint8_t_array(buf, 36, flight_custom_version, 8);
227 _mav_put_uint8_t_array(buf, 44, middleware_custom_version, 8);
228 _mav_put_uint8_t_array(buf, 52, os_custom_version, 8);
229 #if MAVLINK_CRC_EXTRA
246 mav_array_memcpy(packet.
os_custom_version, os_custom_version,
sizeof(uint8_t)*8);
247 #if MAVLINK_CRC_EXTRA
255 #if MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN <= MAVLINK_MAX_PAYLOAD_LEN
263 static inline void mavlink_msg_autopilot_version_send_buf(mavlink_message_t *msgbuf,
mavlink_channel_t chan, uint64_t capabilities, uint32_t flight_sw_version, uint32_t middleware_sw_version, uint32_t os_sw_version, uint32_t board_version,
const uint8_t *flight_custom_version,
const uint8_t *middleware_custom_version,
const uint8_t *os_custom_version, uint16_t vendor_id, uint16_t product_id, uint64_t uid)
265 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
266 char *buf = (
char *)msgbuf;
275 _mav_put_uint8_t_array(buf, 36, flight_custom_version, 8);
276 _mav_put_uint8_t_array(buf, 44, middleware_custom_version, 8);
277 _mav_put_uint8_t_array(buf, 52, os_custom_version, 8);
278 #if MAVLINK_CRC_EXTRA
295 mav_array_memcpy(packet->
os_custom_version, os_custom_version,
sizeof(uint8_t)*8);
296 #if MAVLINK_CRC_EXTRA
315 static inline uint64_t mavlink_msg_autopilot_version_get_capabilities(
const mavlink_message_t* msg)
317 return _MAV_RETURN_uint64_t(msg, 0);
325 static inline uint32_t mavlink_msg_autopilot_version_get_flight_sw_version(
const mavlink_message_t* msg)
327 return _MAV_RETURN_uint32_t(msg, 16);
335 static inline uint32_t mavlink_msg_autopilot_version_get_middleware_sw_version(
const mavlink_message_t* msg)
337 return _MAV_RETURN_uint32_t(msg, 20);
345 static inline uint32_t mavlink_msg_autopilot_version_get_os_sw_version(
const mavlink_message_t* msg)
347 return _MAV_RETURN_uint32_t(msg, 24);
355 static inline uint32_t mavlink_msg_autopilot_version_get_board_version(
const mavlink_message_t* msg)
357 return _MAV_RETURN_uint32_t(msg, 28);
365 static inline uint16_t mavlink_msg_autopilot_version_get_flight_custom_version(
const mavlink_message_t* msg, uint8_t *flight_custom_version)
367 return _MAV_RETURN_uint8_t_array(msg, flight_custom_version, 8, 36);
375 static inline uint16_t mavlink_msg_autopilot_version_get_middleware_custom_version(
const mavlink_message_t* msg, uint8_t *middleware_custom_version)
377 return _MAV_RETURN_uint8_t_array(msg, middleware_custom_version, 8, 44);
385 static inline uint16_t mavlink_msg_autopilot_version_get_os_custom_version(
const mavlink_message_t* msg, uint8_t *os_custom_version)
387 return _MAV_RETURN_uint8_t_array(msg, os_custom_version, 8, 52);
395 static inline uint16_t mavlink_msg_autopilot_version_get_vendor_id(
const mavlink_message_t* msg)
397 return _MAV_RETURN_uint16_t(msg, 32);
405 static inline uint16_t mavlink_msg_autopilot_version_get_product_id(
const mavlink_message_t* msg)
407 return _MAV_RETURN_uint16_t(msg, 34);
415 static inline uint64_t mavlink_msg_autopilot_version_get_uid(
const mavlink_message_t* msg)
417 return _MAV_RETURN_uint64_t(msg, 8);
426 static inline void mavlink_msg_autopilot_version_decode(
const mavlink_message_t* msg,
mavlink_autopilot_version_t* autopilot_version)
428 #if MAVLINK_NEED_BYTE_SWAP
429 autopilot_version->
capabilities = mavlink_msg_autopilot_version_get_capabilities(msg);
430 autopilot_version->
uid = mavlink_msg_autopilot_version_get_uid(msg);
431 autopilot_version->
flight_sw_version = mavlink_msg_autopilot_version_get_flight_sw_version(msg);
432 autopilot_version->
middleware_sw_version = mavlink_msg_autopilot_version_get_middleware_sw_version(msg);
433 autopilot_version->
os_sw_version = mavlink_msg_autopilot_version_get_os_sw_version(msg);
434 autopilot_version->
board_version = mavlink_msg_autopilot_version_get_board_version(msg);
435 autopilot_version->
vendor_id = mavlink_msg_autopilot_version_get_vendor_id(msg);
436 autopilot_version->
product_id = mavlink_msg_autopilot_version_get_product_id(msg);
437 mavlink_msg_autopilot_version_get_flight_custom_version(msg, autopilot_version->
flight_custom_version);
439 mavlink_msg_autopilot_version_get_os_custom_version(msg, autopilot_version->
os_custom_version);
uint32_t middleware_sw_version
Middleware version number.
Definition: mavlink_msg_autopilot_version.h:10
uint8_t middleware_custom_version[8]
Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier...
Definition: mavlink_msg_autopilot_version.h:16
uint64_t uid
UID if provided by hardware.
Definition: mavlink_msg_autopilot_version.h:8
#define MAVLINK_MSG_ID_AUTOPILOT_VERSION_LEN
Definition: mavlink_msg_autopilot_version.h:20
uint16_t vendor_id
ID of the board vendor.
Definition: mavlink_msg_autopilot_version.h:13
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_uint64_t(buf, wire_offset, b)
Definition: protocol.h:143
#define _MAV_PAYLOAD_NON_CONST(msg)
Definition: mavlink_types.h:172
mavlink_channel_t
Definition: mavlink_types.h:178
#define _MAV_PAYLOAD(msg)
Definition: mavlink_types.h:171
uint8_t os_custom_version[8]
Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier...
Definition: mavlink_msg_autopilot_version.h:17
Definition: mavlink_msg_autopilot_version.h:5
uint32_t flight_sw_version
Firmware version number.
Definition: mavlink_msg_autopilot_version.h:9
#define MAVLINK_MSG_ID_AUTOPILOT_VERSION
Definition: mavlink_msg_autopilot_version.h:3
uint32_t os_sw_version
Operating system version number.
Definition: mavlink_msg_autopilot_version.h:11
struct __mavlink_autopilot_version_t mavlink_autopilot_version_t
uint32_t board_version
HW / board version (last 8 bytes should be silicon ID, if any)
Definition: mavlink_msg_autopilot_version.h:12
#define MAVLINK_MSG_ID_AUTOPILOT_VERSION_CRC
Definition: mavlink_msg_autopilot_version.h:23
uint8_t flight_custom_version[8]
Custom version field, commonly the first 8 bytes of the git hash. This is not an unique identifier...
Definition: mavlink_msg_autopilot_version.h:15
uint64_t capabilities
bitmask of capabilities (see MAV_PROTOCOL_CAPABILITY enum)
Definition: mavlink_msg_autopilot_version.h:7
#define _mav_put_uint16_t(buf, wire_offset, b)
Definition: protocol.h:139
uint16_t product_id
ID of the product.
Definition: mavlink_msg_autopilot_version.h:14
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
#define _mav_put_uint32_t(buf, wire_offset, b)
Definition: protocol.h:141