4#define MAVLINK_MSG_ID_CTRL_SRFC_PT 181
7typedef struct __mavlink_ctrl_srfc_pt_t {
10}) mavlink_ctrl_srfc_pt_t;
12#define MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN 3
13#define MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN 3
14#define MAVLINK_MSG_ID_181_LEN 3
15#define MAVLINK_MSG_ID_181_MIN_LEN 3
17#define MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC 104
18#define MAVLINK_MSG_ID_181_CRC 104
22#if MAVLINK_COMMAND_24BIT
23#define MAVLINK_MESSAGE_INFO_CTRL_SRFC_PT { \
27 { { "target", NULL, MAVLINK_TYPE_UINT8_T, 0, 2, offsetof(mavlink_ctrl_srfc_pt_t, target) }, \
28 { "bitfieldPt", NULL, MAVLINK_TYPE_UINT16_T, 0, 0, offsetof(mavlink_ctrl_srfc_pt_t, bitfieldPt) }, \
32#define MAVLINK_MESSAGE_INFO_CTRL_SRFC_PT { \
35 { { "target", NULL, MAVLINK_TYPE_UINT8_T, 0, 2, offsetof(mavlink_ctrl_srfc_pt_t, target) }, \
36 { "bitfieldPt", NULL, MAVLINK_TYPE_UINT16_T, 0, 0, offsetof(mavlink_ctrl_srfc_pt_t, bitfieldPt) }, \
51static inline uint16_t mavlink_msg_ctrl_srfc_pt_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
52 uint8_t target, uint16_t bitfieldPt)
54#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
55 char buf[MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN];
56 _mav_put_uint16_t(buf, 0, bitfieldPt);
57 _mav_put_uint8_t(buf, 2, target);
59 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN);
61 mavlink_ctrl_srfc_pt_t packet;
62 packet.bitfieldPt = bitfieldPt;
63 packet.target = target;
65 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN);
68 msg->msgid = MAVLINK_MSG_ID_CTRL_SRFC_PT;
69 return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
82static inline uint16_t mavlink_msg_ctrl_srfc_pt_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
83 mavlink_message_t* msg,
84 uint8_t target,uint16_t bitfieldPt)
86#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
87 char buf[MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN];
88 _mav_put_uint16_t(buf, 0, bitfieldPt);
89 _mav_put_uint8_t(buf, 2, target);
91 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN);
93 mavlink_ctrl_srfc_pt_t packet;
94 packet.bitfieldPt = bitfieldPt;
95 packet.target = target;
97 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN);
100 msg->msgid = MAVLINK_MSG_ID_CTRL_SRFC_PT;
101 return mavlink_finalize_message_chan(msg, system_id, component_id, chan, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
112static inline uint16_t mavlink_msg_ctrl_srfc_pt_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_ctrl_srfc_pt_t* ctrl_srfc_pt)
114 return mavlink_msg_ctrl_srfc_pt_pack(system_id, component_id, msg, ctrl_srfc_pt->target, ctrl_srfc_pt->bitfieldPt);
126static inline uint16_t mavlink_msg_ctrl_srfc_pt_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_ctrl_srfc_pt_t* ctrl_srfc_pt)
128 return mavlink_msg_ctrl_srfc_pt_pack_chan(system_id, component_id, chan, msg, ctrl_srfc_pt->target, ctrl_srfc_pt->bitfieldPt);
138#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
140static inline void mavlink_msg_ctrl_srfc_pt_send(mavlink_channel_t chan, uint8_t target, uint16_t bitfieldPt)
142#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
143 char buf[MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN];
144 _mav_put_uint16_t(buf, 0, bitfieldPt);
145 _mav_put_uint8_t(buf, 2, target);
147 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_CTRL_SRFC_PT, buf, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
149 mavlink_ctrl_srfc_pt_t packet;
150 packet.bitfieldPt = bitfieldPt;
151 packet.target = target;
153 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_CTRL_SRFC_PT, (
const char *)&packet, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
162static inline void mavlink_msg_ctrl_srfc_pt_send_struct(mavlink_channel_t chan,
const mavlink_ctrl_srfc_pt_t* ctrl_srfc_pt)
164#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
165 mavlink_msg_ctrl_srfc_pt_send(chan, ctrl_srfc_pt->target, ctrl_srfc_pt->bitfieldPt);
167 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_CTRL_SRFC_PT, (
const char *)ctrl_srfc_pt, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
171#if MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN <= MAVLINK_MAX_PAYLOAD_LEN
179static inline void mavlink_msg_ctrl_srfc_pt_send_buf(mavlink_message_t *msgbuf, mavlink_channel_t chan, uint8_t target, uint16_t bitfieldPt)
181#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
182 char *buf = (
char *)msgbuf;
183 _mav_put_uint16_t(buf, 0, bitfieldPt);
184 _mav_put_uint8_t(buf, 2, target);
186 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_CTRL_SRFC_PT, buf, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
188 mavlink_ctrl_srfc_pt_t *packet = (mavlink_ctrl_srfc_pt_t *)msgbuf;
189 packet->bitfieldPt = bitfieldPt;
190 packet->target = target;
192 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_CTRL_SRFC_PT, (
const char *)packet, MAVLINK_MSG_ID_CTRL_SRFC_PT_MIN_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN, MAVLINK_MSG_ID_CTRL_SRFC_PT_CRC);
207static inline uint8_t mavlink_msg_ctrl_srfc_pt_get_target(
const mavlink_message_t* msg)
209 return _MAV_RETURN_uint8_t(msg, 2);
217static inline uint16_t mavlink_msg_ctrl_srfc_pt_get_bitfieldPt(
const mavlink_message_t* msg)
219 return _MAV_RETURN_uint16_t(msg, 0);
228static inline void mavlink_msg_ctrl_srfc_pt_decode(
const mavlink_message_t* msg, mavlink_ctrl_srfc_pt_t* ctrl_srfc_pt)
230#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
231 ctrl_srfc_pt->bitfieldPt = mavlink_msg_ctrl_srfc_pt_get_bitfieldPt(msg);
232 ctrl_srfc_pt->target = mavlink_msg_ctrl_srfc_pt_get_target(msg);
234 uint8_t len = msg->len < MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN? msg->len : MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN;
235 memset(ctrl_srfc_pt, 0, MAVLINK_MSG_ID_CTRL_SRFC_PT_LEN);
236 memcpy(ctrl_srfc_pt, _MAV_PAYLOAD(msg), len);