4#define MAVLINK_MSG_ID_RALLY_POINT 175
7typedef struct __mavlink_rally_point_t {
13 uint8_t target_system;
14 uint8_t target_component;
18}) mavlink_rally_point_t;
20#define MAVLINK_MSG_ID_RALLY_POINT_LEN 19
21#define MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN 19
22#define MAVLINK_MSG_ID_175_LEN 19
23#define MAVLINK_MSG_ID_175_MIN_LEN 19
25#define MAVLINK_MSG_ID_RALLY_POINT_CRC 138
26#define MAVLINK_MSG_ID_175_CRC 138
30#if MAVLINK_COMMAND_24BIT
31#define MAVLINK_MESSAGE_INFO_RALLY_POINT { \
35 { { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 14, offsetof(mavlink_rally_point_t, target_system) }, \
36 { "target_component", NULL, MAVLINK_TYPE_UINT8_T, 0, 15, offsetof(mavlink_rally_point_t, target_component) }, \
37 { "idx", NULL, MAVLINK_TYPE_UINT8_T, 0, 16, offsetof(mavlink_rally_point_t, idx) }, \
38 { "count", NULL, MAVLINK_TYPE_UINT8_T, 0, 17, offsetof(mavlink_rally_point_t, count) }, \
39 { "lat", NULL, MAVLINK_TYPE_INT32_T, 0, 0, offsetof(mavlink_rally_point_t, lat) }, \
40 { "lng", NULL, MAVLINK_TYPE_INT32_T, 0, 4, offsetof(mavlink_rally_point_t, lng) }, \
41 { "alt", NULL, MAVLINK_TYPE_INT16_T, 0, 8, offsetof(mavlink_rally_point_t, alt) }, \
42 { "break_alt", NULL, MAVLINK_TYPE_INT16_T, 0, 10, offsetof(mavlink_rally_point_t, break_alt) }, \
43 { "land_dir", NULL, MAVLINK_TYPE_UINT16_T, 0, 12, offsetof(mavlink_rally_point_t, land_dir) }, \
44 { "flags", NULL, MAVLINK_TYPE_UINT8_T, 0, 18, offsetof(mavlink_rally_point_t, flags) }, \
48#define MAVLINK_MESSAGE_INFO_RALLY_POINT { \
51 { { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 14, offsetof(mavlink_rally_point_t, target_system) }, \
52 { "target_component", NULL, MAVLINK_TYPE_UINT8_T, 0, 15, offsetof(mavlink_rally_point_t, target_component) }, \
53 { "idx", NULL, MAVLINK_TYPE_UINT8_T, 0, 16, offsetof(mavlink_rally_point_t, idx) }, \
54 { "count", NULL, MAVLINK_TYPE_UINT8_T, 0, 17, offsetof(mavlink_rally_point_t, count) }, \
55 { "lat", NULL, MAVLINK_TYPE_INT32_T, 0, 0, offsetof(mavlink_rally_point_t, lat) }, \
56 { "lng", NULL, MAVLINK_TYPE_INT32_T, 0, 4, offsetof(mavlink_rally_point_t, lng) }, \
57 { "alt", NULL, MAVLINK_TYPE_INT16_T, 0, 8, offsetof(mavlink_rally_point_t, alt) }, \
58 { "break_alt", NULL, MAVLINK_TYPE_INT16_T, 0, 10, offsetof(mavlink_rally_point_t, break_alt) }, \
59 { "land_dir", NULL, MAVLINK_TYPE_UINT16_T, 0, 12, offsetof(mavlink_rally_point_t, land_dir) }, \
60 { "flags", NULL, MAVLINK_TYPE_UINT8_T, 0, 18, offsetof(mavlink_rally_point_t, flags) }, \
83static inline uint16_t mavlink_msg_rally_point_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
84 uint8_t target_system, uint8_t target_component, uint8_t idx, uint8_t count, int32_t lat, int32_t lng, int16_t alt, int16_t break_alt, uint16_t land_dir, uint8_t flags)
86#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
87 char buf[MAVLINK_MSG_ID_RALLY_POINT_LEN];
88 _mav_put_int32_t(buf, 0, lat);
89 _mav_put_int32_t(buf, 4, lng);
90 _mav_put_int16_t(buf, 8, alt);
91 _mav_put_int16_t(buf, 10, break_alt);
92 _mav_put_uint16_t(buf, 12, land_dir);
93 _mav_put_uint8_t(buf, 14, target_system);
94 _mav_put_uint8_t(buf, 15, target_component);
95 _mav_put_uint8_t(buf, 16, idx);
96 _mav_put_uint8_t(buf, 17, count);
97 _mav_put_uint8_t(buf, 18, flags);
99 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_RALLY_POINT_LEN);
101 mavlink_rally_point_t packet;
105 packet.break_alt = break_alt;
106 packet.land_dir = land_dir;
107 packet.target_system = target_system;
108 packet.target_component = target_component;
110 packet.count = count;
111 packet.flags = flags;
113 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_RALLY_POINT_LEN);
116 msg->msgid = MAVLINK_MSG_ID_RALLY_POINT;
117 return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
138static inline uint16_t mavlink_msg_rally_point_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
139 mavlink_message_t* msg,
140 uint8_t target_system,uint8_t target_component,uint8_t idx,uint8_t count,int32_t lat,int32_t lng,int16_t alt,int16_t break_alt,uint16_t land_dir,uint8_t flags)
142#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
143 char buf[MAVLINK_MSG_ID_RALLY_POINT_LEN];
144 _mav_put_int32_t(buf, 0, lat);
145 _mav_put_int32_t(buf, 4, lng);
146 _mav_put_int16_t(buf, 8, alt);
147 _mav_put_int16_t(buf, 10, break_alt);
148 _mav_put_uint16_t(buf, 12, land_dir);
149 _mav_put_uint8_t(buf, 14, target_system);
150 _mav_put_uint8_t(buf, 15, target_component);
151 _mav_put_uint8_t(buf, 16, idx);
152 _mav_put_uint8_t(buf, 17, count);
153 _mav_put_uint8_t(buf, 18, flags);
155 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_RALLY_POINT_LEN);
157 mavlink_rally_point_t packet;
161 packet.break_alt = break_alt;
162 packet.land_dir = land_dir;
163 packet.target_system = target_system;
164 packet.target_component = target_component;
166 packet.count = count;
167 packet.flags = flags;
169 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_RALLY_POINT_LEN);
172 msg->msgid = MAVLINK_MSG_ID_RALLY_POINT;
173 return mavlink_finalize_message_chan(msg, system_id, component_id, chan, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
184static inline uint16_t mavlink_msg_rally_point_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_rally_point_t* rally_point)
186 return mavlink_msg_rally_point_pack(system_id, component_id, msg, rally_point->target_system, rally_point->target_component, rally_point->idx, rally_point->count, rally_point->lat, rally_point->lng, rally_point->alt, rally_point->break_alt, rally_point->land_dir, rally_point->flags);
198static inline uint16_t mavlink_msg_rally_point_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_rally_point_t* rally_point)
200 return mavlink_msg_rally_point_pack_chan(system_id, component_id, chan, msg, rally_point->target_system, rally_point->target_component, rally_point->idx, rally_point->count, rally_point->lat, rally_point->lng, rally_point->alt, rally_point->break_alt, rally_point->land_dir, rally_point->flags);
218#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
220static inline void mavlink_msg_rally_point_send(mavlink_channel_t chan, uint8_t target_system, uint8_t target_component, uint8_t idx, uint8_t count, int32_t lat, int32_t lng, int16_t alt, int16_t break_alt, uint16_t land_dir, uint8_t flags)
222#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
223 char buf[MAVLINK_MSG_ID_RALLY_POINT_LEN];
224 _mav_put_int32_t(buf, 0, lat);
225 _mav_put_int32_t(buf, 4, lng);
226 _mav_put_int16_t(buf, 8, alt);
227 _mav_put_int16_t(buf, 10, break_alt);
228 _mav_put_uint16_t(buf, 12, land_dir);
229 _mav_put_uint8_t(buf, 14, target_system);
230 _mav_put_uint8_t(buf, 15, target_component);
231 _mav_put_uint8_t(buf, 16, idx);
232 _mav_put_uint8_t(buf, 17, count);
233 _mav_put_uint8_t(buf, 18, flags);
235 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_RALLY_POINT, buf, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
237 mavlink_rally_point_t packet;
241 packet.break_alt = break_alt;
242 packet.land_dir = land_dir;
243 packet.target_system = target_system;
244 packet.target_component = target_component;
246 packet.count = count;
247 packet.flags = flags;
249 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_RALLY_POINT, (
const char *)&packet, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
258static inline void mavlink_msg_rally_point_send_struct(mavlink_channel_t chan,
const mavlink_rally_point_t* rally_point)
260#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
261 mavlink_msg_rally_point_send(chan, rally_point->target_system, rally_point->target_component, rally_point->idx, rally_point->count, rally_point->lat, rally_point->lng, rally_point->alt, rally_point->break_alt, rally_point->land_dir, rally_point->flags);
263 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_RALLY_POINT, (
const char *)rally_point, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
267#if MAVLINK_MSG_ID_RALLY_POINT_LEN <= MAVLINK_MAX_PAYLOAD_LEN
275static inline void mavlink_msg_rally_point_send_buf(mavlink_message_t *msgbuf, mavlink_channel_t chan, uint8_t target_system, uint8_t target_component, uint8_t idx, uint8_t count, int32_t lat, int32_t lng, int16_t alt, int16_t break_alt, uint16_t land_dir, uint8_t flags)
277#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
278 char *buf = (
char *)msgbuf;
279 _mav_put_int32_t(buf, 0, lat);
280 _mav_put_int32_t(buf, 4, lng);
281 _mav_put_int16_t(buf, 8, alt);
282 _mav_put_int16_t(buf, 10, break_alt);
283 _mav_put_uint16_t(buf, 12, land_dir);
284 _mav_put_uint8_t(buf, 14, target_system);
285 _mav_put_uint8_t(buf, 15, target_component);
286 _mav_put_uint8_t(buf, 16, idx);
287 _mav_put_uint8_t(buf, 17, count);
288 _mav_put_uint8_t(buf, 18, flags);
290 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_RALLY_POINT, buf, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
292 mavlink_rally_point_t *packet = (mavlink_rally_point_t *)msgbuf;
296 packet->break_alt = break_alt;
297 packet->land_dir = land_dir;
298 packet->target_system = target_system;
299 packet->target_component = target_component;
301 packet->count = count;
302 packet->flags = flags;
304 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_RALLY_POINT, (
const char *)packet, MAVLINK_MSG_ID_RALLY_POINT_MIN_LEN, MAVLINK_MSG_ID_RALLY_POINT_LEN, MAVLINK_MSG_ID_RALLY_POINT_CRC);
319static inline uint8_t mavlink_msg_rally_point_get_target_system(
const mavlink_message_t* msg)
321 return _MAV_RETURN_uint8_t(msg, 14);
329static inline uint8_t mavlink_msg_rally_point_get_target_component(
const mavlink_message_t* msg)
331 return _MAV_RETURN_uint8_t(msg, 15);
339static inline uint8_t mavlink_msg_rally_point_get_idx(
const mavlink_message_t* msg)
341 return _MAV_RETURN_uint8_t(msg, 16);
349static inline uint8_t mavlink_msg_rally_point_get_count(
const mavlink_message_t* msg)
351 return _MAV_RETURN_uint8_t(msg, 17);
359static inline int32_t mavlink_msg_rally_point_get_lat(
const mavlink_message_t* msg)
361 return _MAV_RETURN_int32_t(msg, 0);
369static inline int32_t mavlink_msg_rally_point_get_lng(
const mavlink_message_t* msg)
371 return _MAV_RETURN_int32_t(msg, 4);
379static inline int16_t mavlink_msg_rally_point_get_alt(
const mavlink_message_t* msg)
381 return _MAV_RETURN_int16_t(msg, 8);
389static inline int16_t mavlink_msg_rally_point_get_break_alt(
const mavlink_message_t* msg)
391 return _MAV_RETURN_int16_t(msg, 10);
399static inline uint16_t mavlink_msg_rally_point_get_land_dir(
const mavlink_message_t* msg)
401 return _MAV_RETURN_uint16_t(msg, 12);
409static inline uint8_t mavlink_msg_rally_point_get_flags(
const mavlink_message_t* msg)
411 return _MAV_RETURN_uint8_t(msg, 18);
420static inline void mavlink_msg_rally_point_decode(
const mavlink_message_t* msg, mavlink_rally_point_t* rally_point)
422#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
423 rally_point->lat = mavlink_msg_rally_point_get_lat(msg);
424 rally_point->lng = mavlink_msg_rally_point_get_lng(msg);
425 rally_point->alt = mavlink_msg_rally_point_get_alt(msg);
426 rally_point->break_alt = mavlink_msg_rally_point_get_break_alt(msg);
427 rally_point->land_dir = mavlink_msg_rally_point_get_land_dir(msg);
428 rally_point->target_system = mavlink_msg_rally_point_get_target_system(msg);
429 rally_point->target_component = mavlink_msg_rally_point_get_target_component(msg);
430 rally_point->idx = mavlink_msg_rally_point_get_idx(msg);
431 rally_point->count = mavlink_msg_rally_point_get_count(msg);
432 rally_point->flags = mavlink_msg_rally_point_get_flags(msg);
434 uint8_t len = msg->len < MAVLINK_MSG_ID_RALLY_POINT_LEN? msg->len : MAVLINK_MSG_ID_RALLY_POINT_LEN;
435 memset(rally_point, 0, MAVLINK_MSG_ID_RALLY_POINT_LEN);
436 memcpy(rally_point, _MAV_PAYLOAD(msg), len);