RflySimSDK v3.05
RflySimSDK说明文档
载入中...
搜索中...
未找到
mavlink_msg_set_position_target_global_int.h
1#pragma once
2// MESSAGE SET_POSITION_TARGET_GLOBAL_INT PACKING
3
4#define MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT 86
5
6MAVPACKED(
7typedef struct __mavlink_set_position_target_global_int_t {
8 uint32_t time_boot_ms; /*< Timestamp in milliseconds since system boot. The rationale for the timestamp in the setpoint is to allow the system to compensate for the transport delay of the setpoint. This allows the system to compensate processing latency.*/
9 int32_t lat_int; /*< X Position in WGS84 frame in 1e7 * meters*/
10 int32_t lon_int; /*< Y Position in WGS84 frame in 1e7 * meters*/
11 float alt; /*< Altitude in meters in AMSL altitude, not WGS84 if absolute or relative, above terrain if GLOBAL_TERRAIN_ALT_INT*/
12 float vx; /*< X velocity in NED frame in meter / s*/
13 float vy; /*< Y velocity in NED frame in meter / s*/
14 float vz; /*< Z velocity in NED frame in meter / s*/
15 float afx; /*< X acceleration or force (if bit 10 of type_mask is set) in NED frame in meter / s^2 or N*/
16 float afy; /*< Y acceleration or force (if bit 10 of type_mask is set) in NED frame in meter / s^2 or N*/
17 float afz; /*< Z acceleration or force (if bit 10 of type_mask is set) in NED frame in meter / s^2 or N*/
18 float yaw; /*< yaw setpoint in rad*/
19 float yaw_rate; /*< yaw rate setpoint in rad/s*/
20 uint16_t type_mask; /*< Bitmask to indicate which dimensions should be ignored by the vehicle: a value of 0b0000000000000000 or 0b0000001000000000 indicates that none of the setpoint dimensions should be ignored. If bit 10 is set the floats afx afy afz should be interpreted as force instead of acceleration. Mapping: bit 1: x, bit 2: y, bit 3: z, bit 4: vx, bit 5: vy, bit 6: vz, bit 7: ax, bit 8: ay, bit 9: az, bit 10: is force setpoint, bit 11: yaw, bit 12: yaw rate*/
21 uint8_t target_system; /*< System ID*/
22 uint8_t target_component; /*< Component ID*/
23 uint8_t coordinate_frame; /*< Valid options are: MAV_FRAME_GLOBAL_INT = 5, MAV_FRAME_GLOBAL_RELATIVE_ALT_INT = 6, MAV_FRAME_GLOBAL_TERRAIN_ALT_INT = 11*/
24}) mavlink_set_position_target_global_int_t;
25
26#define MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN 53
27#define MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN 53
28#define MAVLINK_MSG_ID_86_LEN 53
29#define MAVLINK_MSG_ID_86_MIN_LEN 53
30
31#define MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC 5
32#define MAVLINK_MSG_ID_86_CRC 5
33
34
35
36#if MAVLINK_COMMAND_24BIT
37#define MAVLINK_MESSAGE_INFO_SET_POSITION_TARGET_GLOBAL_INT { \
38 86, \
39 "SET_POSITION_TARGET_GLOBAL_INT", \
40 16, \
41 { { "time_boot_ms", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_set_position_target_global_int_t, time_boot_ms) }, \
42 { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 50, offsetof(mavlink_set_position_target_global_int_t, target_system) }, \
43 { "target_component", NULL, MAVLINK_TYPE_UINT8_T, 0, 51, offsetof(mavlink_set_position_target_global_int_t, target_component) }, \
44 { "coordinate_frame", NULL, MAVLINK_TYPE_UINT8_T, 0, 52, offsetof(mavlink_set_position_target_global_int_t, coordinate_frame) }, \
45 { "type_mask", NULL, MAVLINK_TYPE_UINT16_T, 0, 48, offsetof(mavlink_set_position_target_global_int_t, type_mask) }, \
46 { "lat_int", NULL, MAVLINK_TYPE_INT32_T, 0, 4, offsetof(mavlink_set_position_target_global_int_t, lat_int) }, \
47 { "lon_int", NULL, MAVLINK_TYPE_INT32_T, 0, 8, offsetof(mavlink_set_position_target_global_int_t, lon_int) }, \
48 { "alt", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_set_position_target_global_int_t, alt) }, \
49 { "vx", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_set_position_target_global_int_t, vx) }, \
50 { "vy", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_set_position_target_global_int_t, vy) }, \
51 { "vz", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_set_position_target_global_int_t, vz) }, \
52 { "afx", NULL, MAVLINK_TYPE_FLOAT, 0, 28, offsetof(mavlink_set_position_target_global_int_t, afx) }, \
53 { "afy", NULL, MAVLINK_TYPE_FLOAT, 0, 32, offsetof(mavlink_set_position_target_global_int_t, afy) }, \
54 { "afz", NULL, MAVLINK_TYPE_FLOAT, 0, 36, offsetof(mavlink_set_position_target_global_int_t, afz) }, \
55 { "yaw", NULL, MAVLINK_TYPE_FLOAT, 0, 40, offsetof(mavlink_set_position_target_global_int_t, yaw) }, \
56 { "yaw_rate", NULL, MAVLINK_TYPE_FLOAT, 0, 44, offsetof(mavlink_set_position_target_global_int_t, yaw_rate) }, \
57 } \
58}
59#else
60#define MAVLINK_MESSAGE_INFO_SET_POSITION_TARGET_GLOBAL_INT { \
61 "SET_POSITION_TARGET_GLOBAL_INT", \
62 16, \
63 { { "time_boot_ms", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_set_position_target_global_int_t, time_boot_ms) }, \
64 { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 50, offsetof(mavlink_set_position_target_global_int_t, target_system) }, \
65 { "target_component", NULL, MAVLINK_TYPE_UINT8_T, 0, 51, offsetof(mavlink_set_position_target_global_int_t, target_component) }, \
66 { "coordinate_frame", NULL, MAVLINK_TYPE_UINT8_T, 0, 52, offsetof(mavlink_set_position_target_global_int_t, coordinate_frame) }, \
67 { "type_mask", NULL, MAVLINK_TYPE_UINT16_T, 0, 48, offsetof(mavlink_set_position_target_global_int_t, type_mask) }, \
68 { "lat_int", NULL, MAVLINK_TYPE_INT32_T, 0, 4, offsetof(mavlink_set_position_target_global_int_t, lat_int) }, \
69 { "lon_int", NULL, MAVLINK_TYPE_INT32_T, 0, 8, offsetof(mavlink_set_position_target_global_int_t, lon_int) }, \
70 { "alt", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_set_position_target_global_int_t, alt) }, \
71 { "vx", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_set_position_target_global_int_t, vx) }, \
72 { "vy", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_set_position_target_global_int_t, vy) }, \
73 { "vz", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_set_position_target_global_int_t, vz) }, \
74 { "afx", NULL, MAVLINK_TYPE_FLOAT, 0, 28, offsetof(mavlink_set_position_target_global_int_t, afx) }, \
75 { "afy", NULL, MAVLINK_TYPE_FLOAT, 0, 32, offsetof(mavlink_set_position_target_global_int_t, afy) }, \
76 { "afz", NULL, MAVLINK_TYPE_FLOAT, 0, 36, offsetof(mavlink_set_position_target_global_int_t, afz) }, \
77 { "yaw", NULL, MAVLINK_TYPE_FLOAT, 0, 40, offsetof(mavlink_set_position_target_global_int_t, yaw) }, \
78 { "yaw_rate", NULL, MAVLINK_TYPE_FLOAT, 0, 44, offsetof(mavlink_set_position_target_global_int_t, yaw_rate) }, \
79 } \
80}
81#endif
82
107static inline uint16_t mavlink_msg_set_position_target_global_int_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
108 uint32_t time_boot_ms, uint8_t target_system, uint8_t target_component, uint8_t coordinate_frame, uint16_t type_mask, int32_t lat_int, int32_t lon_int, float alt, float vx, float vy, float vz, float afx, float afy, float afz, float yaw, float yaw_rate)
109{
110#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
111 char buf[MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN];
112 _mav_put_uint32_t(buf, 0, time_boot_ms);
113 _mav_put_int32_t(buf, 4, lat_int);
114 _mav_put_int32_t(buf, 8, lon_int);
115 _mav_put_float(buf, 12, alt);
116 _mav_put_float(buf, 16, vx);
117 _mav_put_float(buf, 20, vy);
118 _mav_put_float(buf, 24, vz);
119 _mav_put_float(buf, 28, afx);
120 _mav_put_float(buf, 32, afy);
121 _mav_put_float(buf, 36, afz);
122 _mav_put_float(buf, 40, yaw);
123 _mav_put_float(buf, 44, yaw_rate);
124 _mav_put_uint16_t(buf, 48, type_mask);
125 _mav_put_uint8_t(buf, 50, target_system);
126 _mav_put_uint8_t(buf, 51, target_component);
127 _mav_put_uint8_t(buf, 52, coordinate_frame);
128
129 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN);
130#else
131 mavlink_set_position_target_global_int_t packet;
132 packet.time_boot_ms = time_boot_ms;
133 packet.lat_int = lat_int;
134 packet.lon_int = lon_int;
135 packet.alt = alt;
136 packet.vx = vx;
137 packet.vy = vy;
138 packet.vz = vz;
139 packet.afx = afx;
140 packet.afy = afy;
141 packet.afz = afz;
142 packet.yaw = yaw;
143 packet.yaw_rate = yaw_rate;
144 packet.type_mask = type_mask;
145 packet.target_system = target_system;
146 packet.target_component = target_component;
147 packet.coordinate_frame = coordinate_frame;
148
149 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN);
150#endif
151
152 msg->msgid = MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT;
153 return mavlink_finalize_message(msg, system_id, component_id, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
154}
155
180static inline uint16_t mavlink_msg_set_position_target_global_int_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
181 mavlink_message_t* msg,
182 uint32_t time_boot_ms,uint8_t target_system,uint8_t target_component,uint8_t coordinate_frame,uint16_t type_mask,int32_t lat_int,int32_t lon_int,float alt,float vx,float vy,float vz,float afx,float afy,float afz,float yaw,float yaw_rate)
183{
184#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
185 char buf[MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN];
186 _mav_put_uint32_t(buf, 0, time_boot_ms);
187 _mav_put_int32_t(buf, 4, lat_int);
188 _mav_put_int32_t(buf, 8, lon_int);
189 _mav_put_float(buf, 12, alt);
190 _mav_put_float(buf, 16, vx);
191 _mav_put_float(buf, 20, vy);
192 _mav_put_float(buf, 24, vz);
193 _mav_put_float(buf, 28, afx);
194 _mav_put_float(buf, 32, afy);
195 _mav_put_float(buf, 36, afz);
196 _mav_put_float(buf, 40, yaw);
197 _mav_put_float(buf, 44, yaw_rate);
198 _mav_put_uint16_t(buf, 48, type_mask);
199 _mav_put_uint8_t(buf, 50, target_system);
200 _mav_put_uint8_t(buf, 51, target_component);
201 _mav_put_uint8_t(buf, 52, coordinate_frame);
202
203 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN);
204#else
205 mavlink_set_position_target_global_int_t packet;
206 packet.time_boot_ms = time_boot_ms;
207 packet.lat_int = lat_int;
208 packet.lon_int = lon_int;
209 packet.alt = alt;
210 packet.vx = vx;
211 packet.vy = vy;
212 packet.vz = vz;
213 packet.afx = afx;
214 packet.afy = afy;
215 packet.afz = afz;
216 packet.yaw = yaw;
217 packet.yaw_rate = yaw_rate;
218 packet.type_mask = type_mask;
219 packet.target_system = target_system;
220 packet.target_component = target_component;
221 packet.coordinate_frame = coordinate_frame;
222
223 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN);
224#endif
225
226 msg->msgid = MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT;
227 return mavlink_finalize_message_chan(msg, system_id, component_id, chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
228}
229
238static inline uint16_t mavlink_msg_set_position_target_global_int_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_set_position_target_global_int_t* set_position_target_global_int)
239{
240 return mavlink_msg_set_position_target_global_int_pack(system_id, component_id, msg, set_position_target_global_int->time_boot_ms, set_position_target_global_int->target_system, set_position_target_global_int->target_component, set_position_target_global_int->coordinate_frame, set_position_target_global_int->type_mask, set_position_target_global_int->lat_int, set_position_target_global_int->lon_int, set_position_target_global_int->alt, set_position_target_global_int->vx, set_position_target_global_int->vy, set_position_target_global_int->vz, set_position_target_global_int->afx, set_position_target_global_int->afy, set_position_target_global_int->afz, set_position_target_global_int->yaw, set_position_target_global_int->yaw_rate);
241}
242
252static inline uint16_t mavlink_msg_set_position_target_global_int_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_set_position_target_global_int_t* set_position_target_global_int)
253{
254 return mavlink_msg_set_position_target_global_int_pack_chan(system_id, component_id, chan, msg, set_position_target_global_int->time_boot_ms, set_position_target_global_int->target_system, set_position_target_global_int->target_component, set_position_target_global_int->coordinate_frame, set_position_target_global_int->type_mask, set_position_target_global_int->lat_int, set_position_target_global_int->lon_int, set_position_target_global_int->alt, set_position_target_global_int->vx, set_position_target_global_int->vy, set_position_target_global_int->vz, set_position_target_global_int->afx, set_position_target_global_int->afy, set_position_target_global_int->afz, set_position_target_global_int->yaw, set_position_target_global_int->yaw_rate);
255}
256
278#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
279
280static inline void mavlink_msg_set_position_target_global_int_send(mavlink_channel_t chan, uint32_t time_boot_ms, uint8_t target_system, uint8_t target_component, uint8_t coordinate_frame, uint16_t type_mask, int32_t lat_int, int32_t lon_int, float alt, float vx, float vy, float vz, float afx, float afy, float afz, float yaw, float yaw_rate)
281{
282#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
283 char buf[MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN];
284 _mav_put_uint32_t(buf, 0, time_boot_ms);
285 _mav_put_int32_t(buf, 4, lat_int);
286 _mav_put_int32_t(buf, 8, lon_int);
287 _mav_put_float(buf, 12, alt);
288 _mav_put_float(buf, 16, vx);
289 _mav_put_float(buf, 20, vy);
290 _mav_put_float(buf, 24, vz);
291 _mav_put_float(buf, 28, afx);
292 _mav_put_float(buf, 32, afy);
293 _mav_put_float(buf, 36, afz);
294 _mav_put_float(buf, 40, yaw);
295 _mav_put_float(buf, 44, yaw_rate);
296 _mav_put_uint16_t(buf, 48, type_mask);
297 _mav_put_uint8_t(buf, 50, target_system);
298 _mav_put_uint8_t(buf, 51, target_component);
299 _mav_put_uint8_t(buf, 52, coordinate_frame);
300
301 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT, buf, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
302#else
303 mavlink_set_position_target_global_int_t packet;
304 packet.time_boot_ms = time_boot_ms;
305 packet.lat_int = lat_int;
306 packet.lon_int = lon_int;
307 packet.alt = alt;
308 packet.vx = vx;
309 packet.vy = vy;
310 packet.vz = vz;
311 packet.afx = afx;
312 packet.afy = afy;
313 packet.afz = afz;
314 packet.yaw = yaw;
315 packet.yaw_rate = yaw_rate;
316 packet.type_mask = type_mask;
317 packet.target_system = target_system;
318 packet.target_component = target_component;
319 packet.coordinate_frame = coordinate_frame;
320
321 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT, (const char *)&packet, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
322#endif
323}
324
330static inline void mavlink_msg_set_position_target_global_int_send_struct(mavlink_channel_t chan, const mavlink_set_position_target_global_int_t* set_position_target_global_int)
331{
332#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
333 mavlink_msg_set_position_target_global_int_send(chan, set_position_target_global_int->time_boot_ms, set_position_target_global_int->target_system, set_position_target_global_int->target_component, set_position_target_global_int->coordinate_frame, set_position_target_global_int->type_mask, set_position_target_global_int->lat_int, set_position_target_global_int->lon_int, set_position_target_global_int->alt, set_position_target_global_int->vx, set_position_target_global_int->vy, set_position_target_global_int->vz, set_position_target_global_int->afx, set_position_target_global_int->afy, set_position_target_global_int->afz, set_position_target_global_int->yaw, set_position_target_global_int->yaw_rate);
334#else
335 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT, (const char *)set_position_target_global_int, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
336#endif
337}
338
339#if MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN <= MAVLINK_MAX_PAYLOAD_LEN
340/*
341 This varient of _send() can be used to save stack space by re-using
342 memory from the receive buffer. The caller provides a
343 mavlink_message_t which is the size of a full mavlink message. This
344 is usually the receive buffer for the channel, and allows a reply to an
345 incoming message with minimum stack space usage.
346 */
347static inline void mavlink_msg_set_position_target_global_int_send_buf(mavlink_message_t *msgbuf, mavlink_channel_t chan, uint32_t time_boot_ms, uint8_t target_system, uint8_t target_component, uint8_t coordinate_frame, uint16_t type_mask, int32_t lat_int, int32_t lon_int, float alt, float vx, float vy, float vz, float afx, float afy, float afz, float yaw, float yaw_rate)
348{
349#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
350 char *buf = (char *)msgbuf;
351 _mav_put_uint32_t(buf, 0, time_boot_ms);
352 _mav_put_int32_t(buf, 4, lat_int);
353 _mav_put_int32_t(buf, 8, lon_int);
354 _mav_put_float(buf, 12, alt);
355 _mav_put_float(buf, 16, vx);
356 _mav_put_float(buf, 20, vy);
357 _mav_put_float(buf, 24, vz);
358 _mav_put_float(buf, 28, afx);
359 _mav_put_float(buf, 32, afy);
360 _mav_put_float(buf, 36, afz);
361 _mav_put_float(buf, 40, yaw);
362 _mav_put_float(buf, 44, yaw_rate);
363 _mav_put_uint16_t(buf, 48, type_mask);
364 _mav_put_uint8_t(buf, 50, target_system);
365 _mav_put_uint8_t(buf, 51, target_component);
366 _mav_put_uint8_t(buf, 52, coordinate_frame);
367
368 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT, buf, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
369#else
370 mavlink_set_position_target_global_int_t *packet = (mavlink_set_position_target_global_int_t *)msgbuf;
371 packet->time_boot_ms = time_boot_ms;
372 packet->lat_int = lat_int;
373 packet->lon_int = lon_int;
374 packet->alt = alt;
375 packet->vx = vx;
376 packet->vy = vy;
377 packet->vz = vz;
378 packet->afx = afx;
379 packet->afy = afy;
380 packet->afz = afz;
381 packet->yaw = yaw;
382 packet->yaw_rate = yaw_rate;
383 packet->type_mask = type_mask;
384 packet->target_system = target_system;
385 packet->target_component = target_component;
386 packet->coordinate_frame = coordinate_frame;
387
388 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT, (const char *)packet, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_MIN_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_CRC);
389#endif
390}
391#endif
392
393#endif
394
395// MESSAGE SET_POSITION_TARGET_GLOBAL_INT UNPACKING
396
397
403static inline uint32_t mavlink_msg_set_position_target_global_int_get_time_boot_ms(const mavlink_message_t* msg)
404{
405 return _MAV_RETURN_uint32_t(msg, 0);
406}
407
413static inline uint8_t mavlink_msg_set_position_target_global_int_get_target_system(const mavlink_message_t* msg)
414{
415 return _MAV_RETURN_uint8_t(msg, 50);
416}
417
423static inline uint8_t mavlink_msg_set_position_target_global_int_get_target_component(const mavlink_message_t* msg)
424{
425 return _MAV_RETURN_uint8_t(msg, 51);
426}
427
433static inline uint8_t mavlink_msg_set_position_target_global_int_get_coordinate_frame(const mavlink_message_t* msg)
434{
435 return _MAV_RETURN_uint8_t(msg, 52);
436}
437
443static inline uint16_t mavlink_msg_set_position_target_global_int_get_type_mask(const mavlink_message_t* msg)
444{
445 return _MAV_RETURN_uint16_t(msg, 48);
446}
447
453static inline int32_t mavlink_msg_set_position_target_global_int_get_lat_int(const mavlink_message_t* msg)
454{
455 return _MAV_RETURN_int32_t(msg, 4);
456}
457
463static inline int32_t mavlink_msg_set_position_target_global_int_get_lon_int(const mavlink_message_t* msg)
464{
465 return _MAV_RETURN_int32_t(msg, 8);
466}
467
473static inline float mavlink_msg_set_position_target_global_int_get_alt(const mavlink_message_t* msg)
474{
475 return _MAV_RETURN_float(msg, 12);
476}
477
483static inline float mavlink_msg_set_position_target_global_int_get_vx(const mavlink_message_t* msg)
484{
485 return _MAV_RETURN_float(msg, 16);
486}
487
493static inline float mavlink_msg_set_position_target_global_int_get_vy(const mavlink_message_t* msg)
494{
495 return _MAV_RETURN_float(msg, 20);
496}
497
503static inline float mavlink_msg_set_position_target_global_int_get_vz(const mavlink_message_t* msg)
504{
505 return _MAV_RETURN_float(msg, 24);
506}
507
513static inline float mavlink_msg_set_position_target_global_int_get_afx(const mavlink_message_t* msg)
514{
515 return _MAV_RETURN_float(msg, 28);
516}
517
523static inline float mavlink_msg_set_position_target_global_int_get_afy(const mavlink_message_t* msg)
524{
525 return _MAV_RETURN_float(msg, 32);
526}
527
533static inline float mavlink_msg_set_position_target_global_int_get_afz(const mavlink_message_t* msg)
534{
535 return _MAV_RETURN_float(msg, 36);
536}
537
543static inline float mavlink_msg_set_position_target_global_int_get_yaw(const mavlink_message_t* msg)
544{
545 return _MAV_RETURN_float(msg, 40);
546}
547
553static inline float mavlink_msg_set_position_target_global_int_get_yaw_rate(const mavlink_message_t* msg)
554{
555 return _MAV_RETURN_float(msg, 44);
556}
557
564static inline void mavlink_msg_set_position_target_global_int_decode(const mavlink_message_t* msg, mavlink_set_position_target_global_int_t* set_position_target_global_int)
565{
566#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
567 set_position_target_global_int->time_boot_ms = mavlink_msg_set_position_target_global_int_get_time_boot_ms(msg);
568 set_position_target_global_int->lat_int = mavlink_msg_set_position_target_global_int_get_lat_int(msg);
569 set_position_target_global_int->lon_int = mavlink_msg_set_position_target_global_int_get_lon_int(msg);
570 set_position_target_global_int->alt = mavlink_msg_set_position_target_global_int_get_alt(msg);
571 set_position_target_global_int->vx = mavlink_msg_set_position_target_global_int_get_vx(msg);
572 set_position_target_global_int->vy = mavlink_msg_set_position_target_global_int_get_vy(msg);
573 set_position_target_global_int->vz = mavlink_msg_set_position_target_global_int_get_vz(msg);
574 set_position_target_global_int->afx = mavlink_msg_set_position_target_global_int_get_afx(msg);
575 set_position_target_global_int->afy = mavlink_msg_set_position_target_global_int_get_afy(msg);
576 set_position_target_global_int->afz = mavlink_msg_set_position_target_global_int_get_afz(msg);
577 set_position_target_global_int->yaw = mavlink_msg_set_position_target_global_int_get_yaw(msg);
578 set_position_target_global_int->yaw_rate = mavlink_msg_set_position_target_global_int_get_yaw_rate(msg);
579 set_position_target_global_int->type_mask = mavlink_msg_set_position_target_global_int_get_type_mask(msg);
580 set_position_target_global_int->target_system = mavlink_msg_set_position_target_global_int_get_target_system(msg);
581 set_position_target_global_int->target_component = mavlink_msg_set_position_target_global_int_get_target_component(msg);
582 set_position_target_global_int->coordinate_frame = mavlink_msg_set_position_target_global_int_get_coordinate_frame(msg);
583#else
584 uint8_t len = msg->len < MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN? msg->len : MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN;
585 memset(set_position_target_global_int, 0, MAVLINK_MSG_ID_SET_POSITION_TARGET_GLOBAL_INT_LEN);
586 memcpy(set_position_target_global_int, _MAV_PAYLOAD(msg), len);
587#endif
588}