Arduino Mavlink
Loading...
Searching...
No Matches
mavlink_msg_local_position_ned_system_global_offset.h
Go to the documentation of this file.
1#pragma once
2// MESSAGE LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET PACKING
3
4#define MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET 89
5
6
8 uint32_t time_boot_ms; /*< [ms] Timestamp (time since system boot).*/
9 float x; /*< [m] X Position*/
10 float y; /*< [m] Y Position*/
11 float z; /*< [m] Z Position*/
12 float roll; /*< [rad] Roll*/
13 float pitch; /*< [rad] Pitch*/
14 float yaw; /*< [rad] Yaw*/
15} mavlink_local_position_ned_system_global_offset_t;
16
17#define MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN 28
18#define MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN 28
19#define MAVLINK_MSG_ID_89_LEN 28
20#define MAVLINK_MSG_ID_89_MIN_LEN 28
21
22#define MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC 231
23#define MAVLINK_MSG_ID_89_CRC 231
24
25
26
27#if MAVLINK_COMMAND_24BIT
28#define MAVLINK_MESSAGE_INFO_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET {
29 89,
30 "LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET",
31 7,
32 { { "time_boot_ms", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_local_position_ned_system_global_offset_t, time_boot_ms) },
33 { "x", NULL, MAVLINK_TYPE_FLOAT, 0, 4, offsetof(mavlink_local_position_ned_system_global_offset_t, x) },
34 { "y", NULL, MAVLINK_TYPE_FLOAT, 0, 8, offsetof(mavlink_local_position_ned_system_global_offset_t, y) },
35 { "z", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_local_position_ned_system_global_offset_t, z) },
36 { "roll", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_local_position_ned_system_global_offset_t, roll) },
37 { "pitch", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_local_position_ned_system_global_offset_t, pitch) },
38 { "yaw", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_local_position_ned_system_global_offset_t, yaw) },
39 } \
40}
41#else
42#define MAVLINK_MESSAGE_INFO_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET {
43 "LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET",
44 7,
45 { { "time_boot_ms", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_local_position_ned_system_global_offset_t, time_boot_ms) },
46 { "x", NULL, MAVLINK_TYPE_FLOAT, 0, 4, offsetof(mavlink_local_position_ned_system_global_offset_t, x) },
47 { "y", NULL, MAVLINK_TYPE_FLOAT, 0, 8, offsetof(mavlink_local_position_ned_system_global_offset_t, y) },
48 { "z", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_local_position_ned_system_global_offset_t, z) },
49 { "roll", NULL, MAVLINK_TYPE_FLOAT, 0, 16, offsetof(mavlink_local_position_ned_system_global_offset_t, roll) },
50 { "pitch", NULL, MAVLINK_TYPE_FLOAT, 0, 20, offsetof(mavlink_local_position_ned_system_global_offset_t, pitch) },
51 { "yaw", NULL, MAVLINK_TYPE_FLOAT, 0, 24, offsetof(mavlink_local_position_ned_system_global_offset_t, yaw) },
52 } \
53}
54#endif
55
56/**
57 * @brief Pack a local_position_ned_system_global_offset message
58 * @param system_id ID of this system
59 * @param component_id ID of this component (e.g. 200 for IMU)
60 * @param msg The MAVLink message to compress the data into
61 *
62 * @param time_boot_ms [ms] Timestamp (time since system boot).
63 * @param x [m] X Position
64 * @param y [m] Y Position
65 * @param z [m] Z Position
66 * @param roll [rad] Roll
67 * @param pitch [rad] Pitch
68 * @param yaw [rad] Yaw
69 * @return length of the message in bytes (excluding serial stream start sign)
70 */
71static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
72 uint32_t time_boot_ms, float x, float y, float z, float roll, float pitch, float yaw)
73{
74#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
76 _mav_put_uint32_t(buf, 0, time_boot_ms);
77 _mav_put_float(buf, 4, x);
78 _mav_put_float(buf, 8, y);
79 _mav_put_float(buf, 12, z);
80 _mav_put_float(buf, 16, roll);
81 _mav_put_float(buf, 20, pitch);
82 _mav_put_float(buf, 24, yaw);
83
84 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
85#else
86 mavlink_local_position_ned_system_global_offset_t packet;
87 packet.time_boot_ms = time_boot_ms;
88 packet.x = x;
89 packet.y = y;
90 packet.z = z;
91 packet.roll = roll;
92 packet.pitch = pitch;
93 packet.yaw = yaw;
94
95 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
96#endif
97
100}
101
102/**
103 * @brief Pack a local_position_ned_system_global_offset message
104 * @param system_id ID of this system
105 * @param component_id ID of this component (e.g. 200 for IMU)
106 * @param status MAVLink status structure
107 * @param msg The MAVLink message to compress the data into
108 *
109 * @param time_boot_ms [ms] Timestamp (time since system boot).
110 * @param x [m] X Position
111 * @param y [m] Y Position
112 * @param z [m] Z Position
113 * @param roll [rad] Roll
114 * @param pitch [rad] Pitch
115 * @param yaw [rad] Yaw
116 * @return length of the message in bytes (excluding serial stream start sign)
117 */
118static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_pack_status(uint8_t system_id, uint8_t component_id, mavlink_status_t *_status, mavlink_message_t* msg,
119 uint32_t time_boot_ms, float x, float y, float z, float roll, float pitch, float yaw)
120{
121#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
123 _mav_put_uint32_t(buf, 0, time_boot_ms);
124 _mav_put_float(buf, 4, x);
125 _mav_put_float(buf, 8, y);
126 _mav_put_float(buf, 12, z);
127 _mav_put_float(buf, 16, roll);
128 _mav_put_float(buf, 20, pitch);
129 _mav_put_float(buf, 24, yaw);
130
131 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
132#else
133 mavlink_local_position_ned_system_global_offset_t packet;
134 packet.time_boot_ms = time_boot_ms;
135 packet.x = x;
136 packet.y = y;
137 packet.z = z;
138 packet.roll = roll;
139 packet.pitch = pitch;
140 packet.yaw = yaw;
141
142 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
143#endif
144
146#if MAVLINK_CRC_EXTRA
147 return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
148#else
149 return mavlink_finalize_message_buffer(msg, system_id, component_id, _status, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
150#endif
151}
152
153/**
154 * @brief Pack a local_position_ned_system_global_offset message on a channel
155 * @param system_id ID of this system
156 * @param component_id ID of this component (e.g. 200 for IMU)
157 * @param chan The MAVLink channel this message will be sent over
158 * @param msg The MAVLink message to compress the data into
159 * @param time_boot_ms [ms] Timestamp (time since system boot).
160 * @param x [m] X Position
161 * @param y [m] Y Position
162 * @param z [m] Z Position
163 * @param roll [rad] Roll
164 * @param pitch [rad] Pitch
165 * @param yaw [rad] Yaw
166 * @return length of the message in bytes (excluding serial stream start sign)
167 */
168static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
169 mavlink_message_t* msg,
170 uint32_t time_boot_ms,float x,float y,float z,float roll,float pitch,float yaw)
171{
172#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
174 _mav_put_uint32_t(buf, 0, time_boot_ms);
175 _mav_put_float(buf, 4, x);
176 _mav_put_float(buf, 8, y);
177 _mav_put_float(buf, 12, z);
178 _mav_put_float(buf, 16, roll);
179 _mav_put_float(buf, 20, pitch);
180 _mav_put_float(buf, 24, yaw);
181
182 memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
183#else
184 mavlink_local_position_ned_system_global_offset_t packet;
185 packet.time_boot_ms = time_boot_ms;
186 packet.x = x;
187 packet.y = y;
188 packet.z = z;
189 packet.roll = roll;
190 packet.pitch = pitch;
191 packet.yaw = yaw;
192
193 memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
194#endif
195
198}
199
200/**
201 * @brief Encode a local_position_ned_system_global_offset struct
202 *
203 * @param system_id ID of this system
204 * @param component_id ID of this component (e.g. 200 for IMU)
205 * @param msg The MAVLink message to compress the data into
206 * @param local_position_ned_system_global_offset C-struct to read the message contents from
207 */
208static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_local_position_ned_system_global_offset_t* local_position_ned_system_global_offset)
209{
210 return mavlink_msg_local_position_ned_system_global_offset_pack(system_id, component_id, msg, local_position_ned_system_global_offset->time_boot_ms, local_position_ned_system_global_offset->x, local_position_ned_system_global_offset->y, local_position_ned_system_global_offset->z, local_position_ned_system_global_offset->roll, local_position_ned_system_global_offset->pitch, local_position_ned_system_global_offset->yaw);
211}
212
213/**
214 * @brief Encode a local_position_ned_system_global_offset struct on a channel
215 *
216 * @param system_id ID of this system
217 * @param component_id ID of this component (e.g. 200 for IMU)
218 * @param chan The MAVLink channel this message will be sent over
219 * @param msg The MAVLink message to compress the data into
220 * @param local_position_ned_system_global_offset C-struct to read the message contents from
221 */
222static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_local_position_ned_system_global_offset_t* local_position_ned_system_global_offset)
223{
224 return mavlink_msg_local_position_ned_system_global_offset_pack_chan(system_id, component_id, chan, msg, local_position_ned_system_global_offset->time_boot_ms, local_position_ned_system_global_offset->x, local_position_ned_system_global_offset->y, local_position_ned_system_global_offset->z, local_position_ned_system_global_offset->roll, local_position_ned_system_global_offset->pitch, local_position_ned_system_global_offset->yaw);
225}
226
227/**
228 * @brief Encode a local_position_ned_system_global_offset struct with provided status structure
229 *
230 * @param system_id ID of this system
231 * @param component_id ID of this component (e.g. 200 for IMU)
232 * @param status MAVLink status structure
233 * @param msg The MAVLink message to compress the data into
234 * @param local_position_ned_system_global_offset C-struct to read the message contents from
235 */
236static inline uint16_t mavlink_msg_local_position_ned_system_global_offset_encode_status(uint8_t system_id, uint8_t component_id, mavlink_status_t* _status, mavlink_message_t* msg, const mavlink_local_position_ned_system_global_offset_t* local_position_ned_system_global_offset)
237{
238 return mavlink_msg_local_position_ned_system_global_offset_pack_status(system_id, component_id, _status, msg, local_position_ned_system_global_offset->time_boot_ms, local_position_ned_system_global_offset->x, local_position_ned_system_global_offset->y, local_position_ned_system_global_offset->z, local_position_ned_system_global_offset->roll, local_position_ned_system_global_offset->pitch, local_position_ned_system_global_offset->yaw);
239}
240
241/**
242 * @brief Send a local_position_ned_system_global_offset message
243 * @param chan MAVLink channel to send the message
244 *
245 * @param time_boot_ms [ms] Timestamp (time since system boot).
246 * @param x [m] X Position
247 * @param y [m] Y Position
248 * @param z [m] Z Position
249 * @param roll [rad] Roll
250 * @param pitch [rad] Pitch
251 * @param yaw [rad] Yaw
252 */
253#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
254
255static inline void mavlink_msg_local_position_ned_system_global_offset_send(mavlink_channel_t chan, uint32_t time_boot_ms, float x, float y, float z, float roll, float pitch, float yaw)
256{
257#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
258 char buf[MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN];
259 _mav_put_uint32_t(buf, 0, time_boot_ms);
260 _mav_put_float(buf, 4, x);
261 _mav_put_float(buf, 8, y);
262 _mav_put_float(buf, 12, z);
263 _mav_put_float(buf, 16, roll);
264 _mav_put_float(buf, 20, pitch);
265 _mav_put_float(buf, 24, yaw);
266
267 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET, buf, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
268#else
269 mavlink_local_position_ned_system_global_offset_t packet;
270 packet.time_boot_ms = time_boot_ms;
271 packet.x = x;
272 packet.y = y;
273 packet.z = z;
274 packet.roll = roll;
275 packet.pitch = pitch;
276 packet.yaw = yaw;
277
278 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET, (const char *)&packet, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
279#endif
280}
281
282/**
283 * @brief Send a local_position_ned_system_global_offset message
284 * @param chan MAVLink channel to send the message
285 * @param struct The MAVLink struct to serialize
286 */
287static inline void mavlink_msg_local_position_ned_system_global_offset_send_struct(mavlink_channel_t chan, const mavlink_local_position_ned_system_global_offset_t* local_position_ned_system_global_offset)
288{
289#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
290 mavlink_msg_local_position_ned_system_global_offset_send(chan, local_position_ned_system_global_offset->time_boot_ms, local_position_ned_system_global_offset->x, local_position_ned_system_global_offset->y, local_position_ned_system_global_offset->z, local_position_ned_system_global_offset->roll, local_position_ned_system_global_offset->pitch, local_position_ned_system_global_offset->yaw);
291#else
292 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET, (const char *)local_position_ned_system_global_offset, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
293#endif
294}
295
296#if MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN <= MAVLINK_MAX_PAYLOAD_LEN
297/*
298 This variant of _send() can be used to save stack space by reusing
299 memory from the receive buffer. The caller provides a
300 mavlink_message_t which is the size of a full mavlink message. This
301 is usually the receive buffer for the channel, and allows a reply to an
302 incoming message with minimum stack space usage.
303 */
304static inline void mavlink_msg_local_position_ned_system_global_offset_send_buf(mavlink_message_t *msgbuf, mavlink_channel_t chan, uint32_t time_boot_ms, float x, float y, float z, float roll, float pitch, float yaw)
305{
306#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
307 char *buf = (char *)msgbuf;
308 _mav_put_uint32_t(buf, 0, time_boot_ms);
309 _mav_put_float(buf, 4, x);
310 _mav_put_float(buf, 8, y);
311 _mav_put_float(buf, 12, z);
312 _mav_put_float(buf, 16, roll);
313 _mav_put_float(buf, 20, pitch);
314 _mav_put_float(buf, 24, yaw);
315
316 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET, buf, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
317#else
318 mavlink_local_position_ned_system_global_offset_t *packet = (mavlink_local_position_ned_system_global_offset_t *)msgbuf;
319 packet->time_boot_ms = time_boot_ms;
320 packet->x = x;
321 packet->y = y;
322 packet->z = z;
323 packet->roll = roll;
324 packet->pitch = pitch;
325 packet->yaw = yaw;
326
327 _mav_finalize_message_chan_send(chan, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET, (const char *)packet, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_MIN_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_CRC);
328#endif
329}
330#endif
331
332#endif
333
334// MESSAGE LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET UNPACKING
335
336
337/**
338 * @brief Get field time_boot_ms from local_position_ned_system_global_offset message
339 *
340 * @return [ms] Timestamp (time since system boot).
341 */
342static inline uint32_t mavlink_msg_local_position_ned_system_global_offset_get_time_boot_ms(const mavlink_message_t* msg)
343{
344 return _MAV_RETURN_uint32_t(msg, 0);
345}
346
347/**
348 * @brief Get field x from local_position_ned_system_global_offset message
349 *
350 * @return [m] X Position
351 */
352static inline float mavlink_msg_local_position_ned_system_global_offset_get_x(const mavlink_message_t* msg)
353{
354 return _MAV_RETURN_float(msg, 4);
355}
356
357/**
358 * @brief Get field y from local_position_ned_system_global_offset message
359 *
360 * @return [m] Y Position
361 */
362static inline float mavlink_msg_local_position_ned_system_global_offset_get_y(const mavlink_message_t* msg)
363{
364 return _MAV_RETURN_float(msg, 8);
365}
366
367/**
368 * @brief Get field z from local_position_ned_system_global_offset message
369 *
370 * @return [m] Z Position
371 */
372static inline float mavlink_msg_local_position_ned_system_global_offset_get_z(const mavlink_message_t* msg)
373{
374 return _MAV_RETURN_float(msg, 12);
375}
376
377/**
378 * @brief Get field roll from local_position_ned_system_global_offset message
379 *
380 * @return [rad] Roll
381 */
382static inline float mavlink_msg_local_position_ned_system_global_offset_get_roll(const mavlink_message_t* msg)
383{
384 return _MAV_RETURN_float(msg, 16);
385}
386
387/**
388 * @brief Get field pitch from local_position_ned_system_global_offset message
389 *
390 * @return [rad] Pitch
391 */
392static inline float mavlink_msg_local_position_ned_system_global_offset_get_pitch(const mavlink_message_t* msg)
393{
394 return _MAV_RETURN_float(msg, 20);
395}
396
397/**
398 * @brief Get field yaw from local_position_ned_system_global_offset message
399 *
400 * @return [rad] Yaw
401 */
402static inline float mavlink_msg_local_position_ned_system_global_offset_get_yaw(const mavlink_message_t* msg)
403{
404 return _MAV_RETURN_float(msg, 24);
405}
406
407/**
408 * @brief Decode a local_position_ned_system_global_offset message into a struct
409 *
410 * @param msg The message to decode
411 * @param local_position_ned_system_global_offset C-struct to decode the message contents into
412 */
413static inline void mavlink_msg_local_position_ned_system_global_offset_decode(const mavlink_message_t* msg, mavlink_local_position_ned_system_global_offset_t* local_position_ned_system_global_offset)
414{
415#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
416 local_position_ned_system_global_offset->time_boot_ms = mavlink_msg_local_position_ned_system_global_offset_get_time_boot_ms(msg);
417 local_position_ned_system_global_offset->x = mavlink_msg_local_position_ned_system_global_offset_get_x(msg);
418 local_position_ned_system_global_offset->y = mavlink_msg_local_position_ned_system_global_offset_get_y(msg);
419 local_position_ned_system_global_offset->z = mavlink_msg_local_position_ned_system_global_offset_get_z(msg);
420 local_position_ned_system_global_offset->roll = mavlink_msg_local_position_ned_system_global_offset_get_roll(msg);
421 local_position_ned_system_global_offset->pitch = mavlink_msg_local_position_ned_system_global_offset_get_pitch(msg);
422 local_position_ned_system_global_offset->yaw = mavlink_msg_local_position_ned_system_global_offset_get_yaw(msg);
423#else
424 uint8_t len = msg->len < MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN? msg->len : MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN;
425 memset(local_position_ned_system_global_offset, 0, MAVLINK_MSG_ID_LOCAL_POSITION_NED_SYSTEM_GLOBAL_OFFSET_LEN);
426 memcpy(local_position_ned_system_global_offset, _MAV_PAYLOAD(msg), len);
427#endif
428}