3 #define MAVLINK_MSG_ID_HIL_GPS 113
22 #define MAVLINK_MSG_ID_HIL_GPS_LEN 36
23 #define MAVLINK_MSG_ID_113_LEN 36
25 #define MAVLINK_MSG_ID_HIL_GPS_CRC 124
26 #define MAVLINK_MSG_ID_113_CRC 124
30 #define MAVLINK_MESSAGE_INFO_HIL_GPS { \
33 { { "time_usec", NULL, MAVLINK_TYPE_UINT64_T, 0, 0, offsetof(mavlink_hil_gps_t, time_usec) }, \
34 { "lat", NULL, MAVLINK_TYPE_INT32_T, 0, 8, offsetof(mavlink_hil_gps_t, lat) }, \
35 { "lon", NULL, MAVLINK_TYPE_INT32_T, 0, 12, offsetof(mavlink_hil_gps_t, lon) }, \
36 { "alt", NULL, MAVLINK_TYPE_INT32_T, 0, 16, offsetof(mavlink_hil_gps_t, alt) }, \
37 { "eph", NULL, MAVLINK_TYPE_UINT16_T, 0, 20, offsetof(mavlink_hil_gps_t, eph) }, \
38 { "epv", NULL, MAVLINK_TYPE_UINT16_T, 0, 22, offsetof(mavlink_hil_gps_t, epv) }, \
39 { "vel", NULL, MAVLINK_TYPE_UINT16_T, 0, 24, offsetof(mavlink_hil_gps_t, vel) }, \
40 { "vn", NULL, MAVLINK_TYPE_INT16_T, 0, 26, offsetof(mavlink_hil_gps_t, vn) }, \
41 { "ve", NULL, MAVLINK_TYPE_INT16_T, 0, 28, offsetof(mavlink_hil_gps_t, ve) }, \
42 { "vd", NULL, MAVLINK_TYPE_INT16_T, 0, 30, offsetof(mavlink_hil_gps_t, vd) }, \
43 { "cog", NULL, MAVLINK_TYPE_UINT16_T, 0, 32, offsetof(mavlink_hil_gps_t, cog) }, \
44 { "fix_type", NULL, MAVLINK_TYPE_UINT8_T, 0, 34, offsetof(mavlink_hil_gps_t, fix_type) }, \
45 { "satellites_visible", NULL, MAVLINK_TYPE_UINT8_T, 0, 35, offsetof(mavlink_hil_gps_t, satellites_visible) }, \
71 static inline uint16_t mavlink_msg_hil_gps_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
72 uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, int16_t vn, int16_t ve, int16_t vd, uint16_t cog, uint8_t satellites_visible)
74 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
111 #if MAVLINK_CRC_EXTRA
139 static inline uint16_t mavlink_msg_hil_gps_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
140 mavlink_message_t* msg,
141 uint64_t time_usec,uint8_t fix_type,int32_t lat,int32_t lon,int32_t alt,uint16_t eph,uint16_t epv,uint16_t vel,int16_t vn,int16_t ve,int16_t vd,uint16_t cog,uint8_t satellites_visible)
143 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
180 #if MAVLINK_CRC_EXTRA
195 static inline uint16_t mavlink_msg_hil_gps_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_hil_gps_t* hil_gps)
197 return mavlink_msg_hil_gps_pack(system_id, component_id, msg, hil_gps->
time_usec, hil_gps->
fix_type, hil_gps->
lat, hil_gps->
lon, hil_gps->
alt, hil_gps->
eph, hil_gps->
epv, hil_gps->
vel, hil_gps->
vn, hil_gps->
ve, hil_gps->
vd, hil_gps->
cog, hil_gps->
satellites_visible);
209 static inline uint16_t mavlink_msg_hil_gps_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_hil_gps_t* hil_gps)
211 return mavlink_msg_hil_gps_pack_chan(system_id, component_id, chan, msg, hil_gps->
time_usec, hil_gps->
fix_type, hil_gps->
lat, hil_gps->
lon, hil_gps->
alt, hil_gps->
eph, hil_gps->
epv, hil_gps->
vel, hil_gps->
vn, hil_gps->
ve, hil_gps->
vd, hil_gps->
cog, hil_gps->
satellites_visible);
232 #ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
234 static inline void mavlink_msg_hil_gps_send(
mavlink_channel_t chan, uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, int16_t vn, int16_t ve, int16_t vd, uint16_t cog, uint8_t satellites_visible)
236 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
252 #if MAVLINK_CRC_EXTRA
273 #if MAVLINK_CRC_EXTRA
281 #if MAVLINK_MSG_ID_HIL_GPS_LEN <= MAVLINK_MAX_PAYLOAD_LEN
289 static inline void mavlink_msg_hil_gps_send_buf(mavlink_message_t *msgbuf,
mavlink_channel_t chan, uint64_t time_usec, uint8_t fix_type, int32_t lat, int32_t lon, int32_t alt, uint16_t eph, uint16_t epv, uint16_t vel, int16_t vn, int16_t ve, int16_t vd, uint16_t cog, uint8_t satellites_visible)
291 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
292 char *buf = (
char *)msgbuf;
307 #if MAVLINK_CRC_EXTRA
328 #if MAVLINK_CRC_EXTRA
347 static inline uint64_t mavlink_msg_hil_gps_get_time_usec(
const mavlink_message_t* msg)
349 return _MAV_RETURN_uint64_t(msg, 0);
357 static inline uint8_t mavlink_msg_hil_gps_get_fix_type(
const mavlink_message_t* msg)
367 static inline int32_t mavlink_msg_hil_gps_get_lat(
const mavlink_message_t* msg)
369 return _MAV_RETURN_int32_t(msg, 8);
377 static inline int32_t mavlink_msg_hil_gps_get_lon(
const mavlink_message_t* msg)
379 return _MAV_RETURN_int32_t(msg, 12);
387 static inline int32_t mavlink_msg_hil_gps_get_alt(
const mavlink_message_t* msg)
389 return _MAV_RETURN_int32_t(msg, 16);
397 static inline uint16_t mavlink_msg_hil_gps_get_eph(
const mavlink_message_t* msg)
399 return _MAV_RETURN_uint16_t(msg, 20);
407 static inline uint16_t mavlink_msg_hil_gps_get_epv(
const mavlink_message_t* msg)
409 return _MAV_RETURN_uint16_t(msg, 22);
417 static inline uint16_t mavlink_msg_hil_gps_get_vel(
const mavlink_message_t* msg)
419 return _MAV_RETURN_uint16_t(msg, 24);
427 static inline int16_t mavlink_msg_hil_gps_get_vn(
const mavlink_message_t* msg)
429 return _MAV_RETURN_int16_t(msg, 26);
437 static inline int16_t mavlink_msg_hil_gps_get_ve(
const mavlink_message_t* msg)
439 return _MAV_RETURN_int16_t(msg, 28);
447 static inline int16_t mavlink_msg_hil_gps_get_vd(
const mavlink_message_t* msg)
449 return _MAV_RETURN_int16_t(msg, 30);
457 static inline uint16_t mavlink_msg_hil_gps_get_cog(
const mavlink_message_t* msg)
459 return _MAV_RETURN_uint16_t(msg, 32);
467 static inline uint8_t mavlink_msg_hil_gps_get_satellites_visible(
const mavlink_message_t* msg)
478 static inline void mavlink_msg_hil_gps_decode(
const mavlink_message_t* msg,
mavlink_hil_gps_t* hil_gps)
480 #if MAVLINK_NEED_BYTE_SWAP
481 hil_gps->
time_usec = mavlink_msg_hil_gps_get_time_usec(msg);
482 hil_gps->
lat = mavlink_msg_hil_gps_get_lat(msg);
483 hil_gps->
lon = mavlink_msg_hil_gps_get_lon(msg);
484 hil_gps->
alt = mavlink_msg_hil_gps_get_alt(msg);
485 hil_gps->
eph = mavlink_msg_hil_gps_get_eph(msg);
486 hil_gps->
epv = mavlink_msg_hil_gps_get_epv(msg);
487 hil_gps->
vel = mavlink_msg_hil_gps_get_vel(msg);
488 hil_gps->
vn = mavlink_msg_hil_gps_get_vn(msg);
489 hil_gps->
ve = mavlink_msg_hil_gps_get_ve(msg);
490 hil_gps->
vd = mavlink_msg_hil_gps_get_vd(msg);
491 hil_gps->
cog = mavlink_msg_hil_gps_get_cog(msg);
492 hil_gps->
fix_type = mavlink_msg_hil_gps_get_fix_type(msg);
int32_t lat
Latitude (WGS84), in degrees * 1E7.
Definition: mavlink_msg_hil_gps.h:8
struct __mavlink_hil_gps_t mavlink_hil_gps_t
int16_t vd
GPS velocity in cm/s in DOWN direction in earth-fixed NED frame.
Definition: mavlink_msg_hil_gps.h:16
#define _MAV_RETURN_uint8_t(msg, wire_offset)
Definition: protocol.h:238
#define MAVLINK_MSG_ID_HIL_GPS
Definition: mavlink_msg_hil_gps.h:3
uint8_t fix_type
0-1: no fix, 2: 2D fix, 3: 3D fix. Some applications will not use the value of this field unless it i...
Definition: mavlink_msg_hil_gps.h:18
uint16_t cog
Course over ground (NOT heading, but direction of movement) in degrees * 100, 0.0..359.99 degrees. If unknown, set to: 65535.
Definition: mavlink_msg_hil_gps.h:17
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
int16_t ve
GPS velocity in cm/s in EAST direction in earth-fixed NED frame.
Definition: mavlink_msg_hil_gps.h:15
#define _mav_put_uint8_t(buf, wire_offset, b)
Definition: protocol.h:134
#define _mav_put_uint64_t(buf, wire_offset, b)
Definition: protocol.h:143
#define _mav_put_int32_t(buf, wire_offset, b)
Definition: protocol.h:142
uint16_t epv
GPS VDOP vertical dilution of position in cm (m*100). If unknown, set to: 65535.
Definition: mavlink_msg_hil_gps.h:12
#define MAVLINK_MSG_ID_HIL_GPS_LEN
Definition: mavlink_msg_hil_gps.h:22
#define _MAV_PAYLOAD_NON_CONST(msg)
Definition: mavlink_types.h:172
uint16_t eph
GPS HDOP horizontal dilution of position in cm (m*100). If unknown, set to: 65535.
Definition: mavlink_msg_hil_gps.h:11
mavlink_channel_t
Definition: mavlink_types.h:178
#define MAVLINK_MSG_ID_HIL_GPS_CRC
Definition: mavlink_msg_hil_gps.h:25
#define _MAV_PAYLOAD(msg)
Definition: mavlink_types.h:171
uint16_t vel
GPS ground speed (m/s * 100). If unknown, set to: 65535.
Definition: mavlink_msg_hil_gps.h:13
Definition: mavlink_msg_hil_gps.h:5
uint8_t satellites_visible
Number of satellites visible. If unknown, set to 255.
Definition: mavlink_msg_hil_gps.h:19
int16_t vn
GPS velocity in cm/s in NORTH direction in earth-fixed NED frame.
Definition: mavlink_msg_hil_gps.h:14
int32_t alt
Altitude (AMSL, not WGS84), in meters * 1000 (positive for up)
Definition: mavlink_msg_hil_gps.h:10
uint64_t time_usec
Timestamp (microseconds since UNIX epoch or microseconds since system boot)
Definition: mavlink_msg_hil_gps.h:7
#define _mav_put_uint16_t(buf, wire_offset, b)
Definition: protocol.h:139
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_int16_t(buf, wire_offset, b)
Definition: protocol.h:140
int32_t lon
Longitude (WGS84), in degrees * 1E7.
Definition: mavlink_msg_hil_gps.h:9