Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Q
qgroundcontrol
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Valentin Platzgummer
qgroundcontrol
Commits
34fb9118
Commit
34fb9118
authored
Feb 04, 2014
by
Lorenz Meier
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
MAVLink update
parent
5c6015c8
Changes
39
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
39 changed files
with
5257 additions
and
1189 deletions
+5257
-1189
ardupilotmega.h
...avlink/include/mavlink/v1.0/ardupilotmega/ardupilotmega.h
+20
-4
mavlink_msg_ahrs2.h
...nk/include/mavlink/v1.0/ardupilotmega/mavlink_msg_ahrs2.h
+287
-0
mavlink_msg_rally_fetch_point.h
...avlink/v1.0/ardupilotmega/mavlink_msg_rally_fetch_point.h
+221
-0
mavlink_msg_rally_point.h
...lude/mavlink/v1.0/ardupilotmega/mavlink_msg_rally_point.h
+375
-0
testsuite.h
libs/mavlink/include/mavlink/v1.0/ardupilotmega/testsuite.h
+281
-117
version.h
libs/mavlink/include/mavlink/v1.0/ardupilotmega/version.h
+2
-2
autoquad.h
libs/mavlink/include/mavlink/v1.0/autoquad/autoquad.h
+3
-3
testsuite.h
libs/mavlink/include/mavlink/v1.0/autoquad/testsuite.h
+20
-20
version.h
libs/mavlink/include/mavlink/v1.0/autoquad/version.h
+2
-2
common.h
libs/mavlink/include/mavlink/v1.0/common/common.h
+46
-4
mavlink_msg_battery_status.h
.../include/mavlink/v1.0/common/mavlink_msg_battery_status.h
+99
-55
mavlink_msg_data_transmission_handshake.h
...ink/v1.0/common/mavlink_msg_data_transmission_handshake.h
+34
-34
mavlink_msg_encapsulated_data.h
...clude/mavlink/v1.0/common/mavlink_msg_encapsulated_data.h
+3
-3
mavlink_msg_gps2_raw.h
...avlink/include/mavlink/v1.0/common/mavlink_msg_gps2_raw.h
+419
-0
mavlink_msg_gps_inject_data.h
...include/mavlink/v1.0/common/mavlink_msg_gps_inject_data.h
+237
-0
mavlink_msg_gps_raw_int.h
...ink/include/mavlink/v1.0/common/mavlink_msg_gps_raw_int.h
+5
-5
mavlink_msg_hil_gps.h
...mavlink/include/mavlink/v1.0/common/mavlink_msg_hil_gps.h
+5
-5
mavlink_msg_log_data.h
...avlink/include/mavlink/v1.0/common/mavlink_msg_log_data.h
+237
-0
mavlink_msg_log_entry.h
...vlink/include/mavlink/v1.0/common/mavlink_msg_log_entry.h
+265
-0
mavlink_msg_log_erase.h
...vlink/include/mavlink/v1.0/common/mavlink_msg_log_erase.h
+199
-0
mavlink_msg_log_request_data.h
...nclude/mavlink/v1.0/common/mavlink_msg_log_request_data.h
+265
-0
mavlink_msg_log_request_end.h
...include/mavlink/v1.0/common/mavlink_msg_log_request_end.h
+199
-0
mavlink_msg_log_request_list.h
...nclude/mavlink/v1.0/common/mavlink_msg_log_request_list.h
+243
-0
mavlink_msg_mission_item.h
...nk/include/mavlink/v1.0/common/mavlink_msg_mission_item.h
+25
-25
mavlink_msg_scaled_imu2.h
...ink/include/mavlink/v1.0/common/mavlink_msg_scaled_imu2.h
+375
-0
mavlink_msg_sys_status.h
...link/include/mavlink/v1.0/common/mavlink_msg_sys_status.h
+15
-15
testsuite.h
libs/mavlink/include/mavlink/v1.0/common/testsuite.h
+1089
-509
version.h
libs/mavlink/include/mavlink/v1.0/common/version.h
+2
-2
matrixpilot.h
libs/mavlink/include/mavlink/v1.0/matrixpilot/matrixpilot.h
+3
-3
testsuite.h
libs/mavlink/include/mavlink/v1.0/matrixpilot/testsuite.h
+141
-141
version.h
libs/mavlink/include/mavlink/v1.0/matrixpilot/version.h
+2
-2
mavlink_conversions.h
libs/mavlink/include/mavlink/v1.0/mavlink_conversions.h
+8
-4
mavlink_types.h
libs/mavlink/include/mavlink/v1.0/mavlink_types.h
+1
-1
pixhawk.h
libs/mavlink/include/mavlink/v1.0/pixhawk/pixhawk.h
+3
-5
testsuite.h
libs/mavlink/include/mavlink/v1.0/pixhawk/testsuite.h
+107
-209
version.h
libs/mavlink/include/mavlink/v1.0/pixhawk/version.h
+1
-1
sensesoar.h
libs/mavlink/include/mavlink/v1.0/sensesoar/sensesoar.h
+3
-3
testsuite.h
libs/mavlink/include/mavlink/v1.0/sensesoar/testsuite.h
+13
-13
version.h
libs/mavlink/include/mavlink/v1.0/sensesoar/version.h
+2
-2
No files found.
libs/mavlink/include/mavlink/v1.0/ardupilotmega/ardupilotmega.h
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/ardupilotmega/mavlink_msg_ahrs2.h
0 → 100644
View file @
34fb9118
// MESSAGE AHRS2 PACKING
#define MAVLINK_MSG_ID_AHRS2 178
typedef
struct
__mavlink_ahrs2_t
{
float
roll
;
///< Roll angle (rad)
float
pitch
;
///< Pitch angle (rad)
float
yaw
;
///< Yaw angle (rad)
float
altitude
;
///< Altitude (MSL)
int32_t
lat
;
///< Latitude in degrees * 1E7
int32_t
lng
;
///< Longitude in degrees * 1E7
}
mavlink_ahrs2_t
;
#define MAVLINK_MSG_ID_AHRS2_LEN 24
#define MAVLINK_MSG_ID_178_LEN 24
#define MAVLINK_MSG_ID_AHRS2_CRC 47
#define MAVLINK_MSG_ID_178_CRC 47
#define MAVLINK_MESSAGE_INFO_AHRS2 { \
"AHRS2", \
6, \
{ { "roll", NULL, MAVLINK_TYPE_FLOAT, 0, 0, offsetof(mavlink_ahrs2_t, roll) }, \
{ "pitch", NULL, MAVLINK_TYPE_FLOAT, 0, 4, offsetof(mavlink_ahrs2_t, pitch) }, \
{ "yaw", NULL, MAVLINK_TYPE_FLOAT, 0, 8, offsetof(mavlink_ahrs2_t, yaw) }, \
{ "altitude", NULL, MAVLINK_TYPE_FLOAT, 0, 12, offsetof(mavlink_ahrs2_t, altitude) }, \
{ "lat", NULL, MAVLINK_TYPE_INT32_T, 0, 16, offsetof(mavlink_ahrs2_t, lat) }, \
{ "lng", NULL, MAVLINK_TYPE_INT32_T, 0, 20, offsetof(mavlink_ahrs2_t, lng) }, \
} \
}
/**
* @brief Pack a ahrs2 message
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param msg The MAVLink message to compress the data into
*
* @param roll Roll angle (rad)
* @param pitch Pitch angle (rad)
* @param yaw Yaw angle (rad)
* @param altitude Altitude (MSL)
* @param lat Latitude in degrees * 1E7
* @param lng Longitude in degrees * 1E7
* @return length of the message in bytes (excluding serial stream start sign)
*/
static
inline
uint16_t
mavlink_msg_ahrs2_pack
(
uint8_t
system_id
,
uint8_t
component_id
,
mavlink_message_t
*
msg
,
float
roll
,
float
pitch
,
float
yaw
,
float
altitude
,
int32_t
lat
,
int32_t
lng
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_AHRS2_LEN
];
_mav_put_float
(
buf
,
0
,
roll
);
_mav_put_float
(
buf
,
4
,
pitch
);
_mav_put_float
(
buf
,
8
,
yaw
);
_mav_put_float
(
buf
,
12
,
altitude
);
_mav_put_int32_t
(
buf
,
16
,
lat
);
_mav_put_int32_t
(
buf
,
20
,
lng
);
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
buf
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#else
mavlink_ahrs2_t
packet
;
packet
.
roll
=
roll
;
packet
.
pitch
=
pitch
;
packet
.
yaw
=
yaw
;
packet
.
altitude
=
altitude
;
packet
.
lat
=
lat
;
packet
.
lng
=
lng
;
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
&
packet
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
msg
->
msgid
=
MAVLINK_MSG_ID_AHRS2
;
#if MAVLINK_CRC_EXTRA
return
mavlink_finalize_message
(
msg
,
system_id
,
component_id
,
MAVLINK_MSG_ID_AHRS2_LEN
,
MAVLINK_MSG_ID_AHRS2_CRC
);
#else
return
mavlink_finalize_message
(
msg
,
system_id
,
component_id
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
}
/**
* @brief Pack a ahrs2 message on a channel
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param chan The MAVLink channel this message will be sent over
* @param msg The MAVLink message to compress the data into
* @param roll Roll angle (rad)
* @param pitch Pitch angle (rad)
* @param yaw Yaw angle (rad)
* @param altitude Altitude (MSL)
* @param lat Latitude in degrees * 1E7
* @param lng Longitude in degrees * 1E7
* @return length of the message in bytes (excluding serial stream start sign)
*/
static
inline
uint16_t
mavlink_msg_ahrs2_pack_chan
(
uint8_t
system_id
,
uint8_t
component_id
,
uint8_t
chan
,
mavlink_message_t
*
msg
,
float
roll
,
float
pitch
,
float
yaw
,
float
altitude
,
int32_t
lat
,
int32_t
lng
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_AHRS2_LEN
];
_mav_put_float
(
buf
,
0
,
roll
);
_mav_put_float
(
buf
,
4
,
pitch
);
_mav_put_float
(
buf
,
8
,
yaw
);
_mav_put_float
(
buf
,
12
,
altitude
);
_mav_put_int32_t
(
buf
,
16
,
lat
);
_mav_put_int32_t
(
buf
,
20
,
lng
);
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
buf
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#else
mavlink_ahrs2_t
packet
;
packet
.
roll
=
roll
;
packet
.
pitch
=
pitch
;
packet
.
yaw
=
yaw
;
packet
.
altitude
=
altitude
;
packet
.
lat
=
lat
;
packet
.
lng
=
lng
;
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
&
packet
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
msg
->
msgid
=
MAVLINK_MSG_ID_AHRS2
;
#if MAVLINK_CRC_EXTRA
return
mavlink_finalize_message_chan
(
msg
,
system_id
,
component_id
,
chan
,
MAVLINK_MSG_ID_AHRS2_LEN
,
MAVLINK_MSG_ID_AHRS2_CRC
);
#else
return
mavlink_finalize_message_chan
(
msg
,
system_id
,
component_id
,
chan
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
}
/**
* @brief Encode a ahrs2 struct
*
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param msg The MAVLink message to compress the data into
* @param ahrs2 C-struct to read the message contents from
*/
static
inline
uint16_t
mavlink_msg_ahrs2_encode
(
uint8_t
system_id
,
uint8_t
component_id
,
mavlink_message_t
*
msg
,
const
mavlink_ahrs2_t
*
ahrs2
)
{
return
mavlink_msg_ahrs2_pack
(
system_id
,
component_id
,
msg
,
ahrs2
->
roll
,
ahrs2
->
pitch
,
ahrs2
->
yaw
,
ahrs2
->
altitude
,
ahrs2
->
lat
,
ahrs2
->
lng
);
}
/**
* @brief Encode a ahrs2 struct on a channel
*
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param chan The MAVLink channel this message will be sent over
* @param msg The MAVLink message to compress the data into
* @param ahrs2 C-struct to read the message contents from
*/
static
inline
uint16_t
mavlink_msg_ahrs2_encode_chan
(
uint8_t
system_id
,
uint8_t
component_id
,
uint8_t
chan
,
mavlink_message_t
*
msg
,
const
mavlink_ahrs2_t
*
ahrs2
)
{
return
mavlink_msg_ahrs2_pack_chan
(
system_id
,
component_id
,
chan
,
msg
,
ahrs2
->
roll
,
ahrs2
->
pitch
,
ahrs2
->
yaw
,
ahrs2
->
altitude
,
ahrs2
->
lat
,
ahrs2
->
lng
);
}
/**
* @brief Send a ahrs2 message
* @param chan MAVLink channel to send the message
*
* @param roll Roll angle (rad)
* @param pitch Pitch angle (rad)
* @param yaw Yaw angle (rad)
* @param altitude Altitude (MSL)
* @param lat Latitude in degrees * 1E7
* @param lng Longitude in degrees * 1E7
*/
#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
static
inline
void
mavlink_msg_ahrs2_send
(
mavlink_channel_t
chan
,
float
roll
,
float
pitch
,
float
yaw
,
float
altitude
,
int32_t
lat
,
int32_t
lng
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_AHRS2_LEN
];
_mav_put_float
(
buf
,
0
,
roll
);
_mav_put_float
(
buf
,
4
,
pitch
);
_mav_put_float
(
buf
,
8
,
yaw
);
_mav_put_float
(
buf
,
12
,
altitude
);
_mav_put_int32_t
(
buf
,
16
,
lat
);
_mav_put_int32_t
(
buf
,
20
,
lng
);
#if MAVLINK_CRC_EXTRA
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_AHRS2
,
buf
,
MAVLINK_MSG_ID_AHRS2_LEN
,
MAVLINK_MSG_ID_AHRS2_CRC
);
#else
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_AHRS2
,
buf
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
#else
mavlink_ahrs2_t
packet
;
packet
.
roll
=
roll
;
packet
.
pitch
=
pitch
;
packet
.
yaw
=
yaw
;
packet
.
altitude
=
altitude
;
packet
.
lat
=
lat
;
packet
.
lng
=
lng
;
#if MAVLINK_CRC_EXTRA
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_AHRS2
,
(
const
char
*
)
&
packet
,
MAVLINK_MSG_ID_AHRS2_LEN
,
MAVLINK_MSG_ID_AHRS2_CRC
);
#else
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_AHRS2
,
(
const
char
*
)
&
packet
,
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
#endif
}
#endif
// MESSAGE AHRS2 UNPACKING
/**
* @brief Get field roll from ahrs2 message
*
* @return Roll angle (rad)
*/
static
inline
float
mavlink_msg_ahrs2_get_roll
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_float
(
msg
,
0
);
}
/**
* @brief Get field pitch from ahrs2 message
*
* @return Pitch angle (rad)
*/
static
inline
float
mavlink_msg_ahrs2_get_pitch
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_float
(
msg
,
4
);
}
/**
* @brief Get field yaw from ahrs2 message
*
* @return Yaw angle (rad)
*/
static
inline
float
mavlink_msg_ahrs2_get_yaw
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_float
(
msg
,
8
);
}
/**
* @brief Get field altitude from ahrs2 message
*
* @return Altitude (MSL)
*/
static
inline
float
mavlink_msg_ahrs2_get_altitude
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_float
(
msg
,
12
);
}
/**
* @brief Get field lat from ahrs2 message
*
* @return Latitude in degrees * 1E7
*/
static
inline
int32_t
mavlink_msg_ahrs2_get_lat
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_int32_t
(
msg
,
16
);
}
/**
* @brief Get field lng from ahrs2 message
*
* @return Longitude in degrees * 1E7
*/
static
inline
int32_t
mavlink_msg_ahrs2_get_lng
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_int32_t
(
msg
,
20
);
}
/**
* @brief Decode a ahrs2 message into a struct
*
* @param msg The message to decode
* @param ahrs2 C-struct to decode the message contents into
*/
static
inline
void
mavlink_msg_ahrs2_decode
(
const
mavlink_message_t
*
msg
,
mavlink_ahrs2_t
*
ahrs2
)
{
#if MAVLINK_NEED_BYTE_SWAP
ahrs2
->
roll
=
mavlink_msg_ahrs2_get_roll
(
msg
);
ahrs2
->
pitch
=
mavlink_msg_ahrs2_get_pitch
(
msg
);
ahrs2
->
yaw
=
mavlink_msg_ahrs2_get_yaw
(
msg
);
ahrs2
->
altitude
=
mavlink_msg_ahrs2_get_altitude
(
msg
);
ahrs2
->
lat
=
mavlink_msg_ahrs2_get_lat
(
msg
);
ahrs2
->
lng
=
mavlink_msg_ahrs2_get_lng
(
msg
);
#else
memcpy
(
ahrs2
,
_MAV_PAYLOAD
(
msg
),
MAVLINK_MSG_ID_AHRS2_LEN
);
#endif
}
libs/mavlink/include/mavlink/v1.0/ardupilotmega/mavlink_msg_rally_fetch_point.h
0 → 100644
View file @
34fb9118
// MESSAGE RALLY_FETCH_POINT PACKING
#define MAVLINK_MSG_ID_RALLY_FETCH_POINT 176
typedef
struct
__mavlink_rally_fetch_point_t
{
uint8_t
target_system
;
///< System ID
uint8_t
target_component
;
///< Component ID
uint8_t
idx
;
///< point index (first point is 0)
}
mavlink_rally_fetch_point_t
;
#define MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN 3
#define MAVLINK_MSG_ID_176_LEN 3
#define MAVLINK_MSG_ID_RALLY_FETCH_POINT_CRC 234
#define MAVLINK_MSG_ID_176_CRC 234
#define MAVLINK_MESSAGE_INFO_RALLY_FETCH_POINT { \
"RALLY_FETCH_POINT", \
3, \
{ { "target_system", NULL, MAVLINK_TYPE_UINT8_T, 0, 0, offsetof(mavlink_rally_fetch_point_t, target_system) }, \
{ "target_component", NULL, MAVLINK_TYPE_UINT8_T, 0, 1, offsetof(mavlink_rally_fetch_point_t, target_component) }, \
{ "idx", NULL, MAVLINK_TYPE_UINT8_T, 0, 2, offsetof(mavlink_rally_fetch_point_t, idx) }, \
} \
}
/**
* @brief Pack a rally_fetch_point message
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param msg The MAVLink message to compress the data into
*
* @param target_system System ID
* @param target_component Component ID
* @param idx point index (first point is 0)
* @return length of the message in bytes (excluding serial stream start sign)
*/
static
inline
uint16_t
mavlink_msg_rally_fetch_point_pack
(
uint8_t
system_id
,
uint8_t
component_id
,
mavlink_message_t
*
msg
,
uint8_t
target_system
,
uint8_t
target_component
,
uint8_t
idx
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
];
_mav_put_uint8_t
(
buf
,
0
,
target_system
);
_mav_put_uint8_t
(
buf
,
1
,
target_component
);
_mav_put_uint8_t
(
buf
,
2
,
idx
);
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
buf
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#else
mavlink_rally_fetch_point_t
packet
;
packet
.
target_system
=
target_system
;
packet
.
target_component
=
target_component
;
packet
.
idx
=
idx
;
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
&
packet
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
msg
->
msgid
=
MAVLINK_MSG_ID_RALLY_FETCH_POINT
;
#if MAVLINK_CRC_EXTRA
return
mavlink_finalize_message
(
msg
,
system_id
,
component_id
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_CRC
);
#else
return
mavlink_finalize_message
(
msg
,
system_id
,
component_id
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
}
/**
* @brief Pack a rally_fetch_point message on a channel
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param chan The MAVLink channel this message will be sent over
* @param msg The MAVLink message to compress the data into
* @param target_system System ID
* @param target_component Component ID
* @param idx point index (first point is 0)
* @return length of the message in bytes (excluding serial stream start sign)
*/
static
inline
uint16_t
mavlink_msg_rally_fetch_point_pack_chan
(
uint8_t
system_id
,
uint8_t
component_id
,
uint8_t
chan
,
mavlink_message_t
*
msg
,
uint8_t
target_system
,
uint8_t
target_component
,
uint8_t
idx
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
];
_mav_put_uint8_t
(
buf
,
0
,
target_system
);
_mav_put_uint8_t
(
buf
,
1
,
target_component
);
_mav_put_uint8_t
(
buf
,
2
,
idx
);
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
buf
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#else
mavlink_rally_fetch_point_t
packet
;
packet
.
target_system
=
target_system
;
packet
.
target_component
=
target_component
;
packet
.
idx
=
idx
;
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
&
packet
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
msg
->
msgid
=
MAVLINK_MSG_ID_RALLY_FETCH_POINT
;
#if MAVLINK_CRC_EXTRA
return
mavlink_finalize_message_chan
(
msg
,
system_id
,
component_id
,
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_CRC
);
#else
return
mavlink_finalize_message_chan
(
msg
,
system_id
,
component_id
,
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
}
/**
* @brief Encode a rally_fetch_point struct
*
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param msg The MAVLink message to compress the data into
* @param rally_fetch_point C-struct to read the message contents from
*/
static
inline
uint16_t
mavlink_msg_rally_fetch_point_encode
(
uint8_t
system_id
,
uint8_t
component_id
,
mavlink_message_t
*
msg
,
const
mavlink_rally_fetch_point_t
*
rally_fetch_point
)
{
return
mavlink_msg_rally_fetch_point_pack
(
system_id
,
component_id
,
msg
,
rally_fetch_point
->
target_system
,
rally_fetch_point
->
target_component
,
rally_fetch_point
->
idx
);
}
/**
* @brief Encode a rally_fetch_point struct on a channel
*
* @param system_id ID of this system
* @param component_id ID of this component (e.g. 200 for IMU)
* @param chan The MAVLink channel this message will be sent over
* @param msg The MAVLink message to compress the data into
* @param rally_fetch_point C-struct to read the message contents from
*/
static
inline
uint16_t
mavlink_msg_rally_fetch_point_encode_chan
(
uint8_t
system_id
,
uint8_t
component_id
,
uint8_t
chan
,
mavlink_message_t
*
msg
,
const
mavlink_rally_fetch_point_t
*
rally_fetch_point
)
{
return
mavlink_msg_rally_fetch_point_pack_chan
(
system_id
,
component_id
,
chan
,
msg
,
rally_fetch_point
->
target_system
,
rally_fetch_point
->
target_component
,
rally_fetch_point
->
idx
);
}
/**
* @brief Send a rally_fetch_point message
* @param chan MAVLink channel to send the message
*
* @param target_system System ID
* @param target_component Component ID
* @param idx point index (first point is 0)
*/
#ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
static
inline
void
mavlink_msg_rally_fetch_point_send
(
mavlink_channel_t
chan
,
uint8_t
target_system
,
uint8_t
target_component
,
uint8_t
idx
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
];
_mav_put_uint8_t
(
buf
,
0
,
target_system
);
_mav_put_uint8_t
(
buf
,
1
,
target_component
);
_mav_put_uint8_t
(
buf
,
2
,
idx
);
#if MAVLINK_CRC_EXTRA
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT
,
buf
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_CRC
);
#else
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT
,
buf
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
#else
mavlink_rally_fetch_point_t
packet
;
packet
.
target_system
=
target_system
;
packet
.
target_component
=
target_component
;
packet
.
idx
=
idx
;
#if MAVLINK_CRC_EXTRA
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT
,
(
const
char
*
)
&
packet
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_CRC
);
#else
_mav_finalize_message_chan_send
(
chan
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT
,
(
const
char
*
)
&
packet
,
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
#endif
}
#endif
// MESSAGE RALLY_FETCH_POINT UNPACKING
/**
* @brief Get field target_system from rally_fetch_point message
*
* @return System ID
*/
static
inline
uint8_t
mavlink_msg_rally_fetch_point_get_target_system
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_uint8_t
(
msg
,
0
);
}
/**
* @brief Get field target_component from rally_fetch_point message
*
* @return Component ID
*/
static
inline
uint8_t
mavlink_msg_rally_fetch_point_get_target_component
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_uint8_t
(
msg
,
1
);
}
/**
* @brief Get field idx from rally_fetch_point message
*
* @return point index (first point is 0)
*/
static
inline
uint8_t
mavlink_msg_rally_fetch_point_get_idx
(
const
mavlink_message_t
*
msg
)
{
return
_MAV_RETURN_uint8_t
(
msg
,
2
);
}
/**
* @brief Decode a rally_fetch_point message into a struct
*
* @param msg The message to decode
* @param rally_fetch_point C-struct to decode the message contents into
*/
static
inline
void
mavlink_msg_rally_fetch_point_decode
(
const
mavlink_message_t
*
msg
,
mavlink_rally_fetch_point_t
*
rally_fetch_point
)
{
#if MAVLINK_NEED_BYTE_SWAP
rally_fetch_point
->
target_system
=
mavlink_msg_rally_fetch_point_get_target_system
(
msg
);
rally_fetch_point
->
target_component
=
mavlink_msg_rally_fetch_point_get_target_component
(
msg
);
rally_fetch_point
->
idx
=
mavlink_msg_rally_fetch_point_get_idx
(
msg
);
#else
memcpy
(
rally_fetch_point
,
_MAV_PAYLOAD
(
msg
),
MAVLINK_MSG_ID_RALLY_FETCH_POINT_LEN
);
#endif
}
libs/mavlink/include/mavlink/v1.0/ardupilotmega/mavlink_msg_rally_point.h
0 → 100644
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/ardupilotmega/testsuite.h
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/ardupilotmega/version.h
View file @
34fb9118
...
...
@@ -5,8 +5,8 @@
#ifndef MAVLINK_VERSION_H
#define MAVLINK_VERSION_H
#define MAVLINK_BUILD_DATE "Tue
Sep 10 23:49:25 2013
"
#define MAVLINK_BUILD_DATE "Tue
Feb 4 15:27:33 2014
"
#define MAVLINK_WIRE_PROTOCOL_VERSION "1.0"
#define MAVLINK_MAX_DIALECT_PAYLOAD_SIZE 25
4
#define MAVLINK_MAX_DIALECT_PAYLOAD_SIZE 25
5
#endif // MAVLINK_VERSION_H
libs/mavlink/include/mavlink/v1.0/autoquad/autoquad.h
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/autoquad/testsuite.h
View file @
34fb9118
...
...
@@ -31,26 +31,26 @@ static void mavlink_test_aq_telemetry_f(uint8_t system_id, uint8_t component_id,
uint16_t
i
;
mavlink_aq_telemetry_f_t
packet_in
=
{
17
.
0
,
45
.
0
,
73
.
0
,
101
.
0
,
129
.
0
,
157
.
0
,
185
.
0
,
213
.
0
,
241
.
0
,
269
.
0
,
297
.
0
,
325
.
0
,
353
.
0
,
381
.
0
,
409
.
0
,
437
.
0
,
465
.
0
,
493
.
0
,
521
.
0
,
549
.
0
,
21395
,
}
45
.
0
,
}
73
.
0
,
}
101
.
0
,
}
129
.
0
,
}
157
.
0
,
}
185
.
0
,
}
213
.
0
,
}
241
.
0
,
}
269
.
0
,
}
297
.
0
,
}
325
.
0
,
}
353
.
0
,
}
381
.
0
,
}
409
.
0
,
}
437
.
0
,
}
465
.
0
,
}
493
.
0
,
}
521
.
0
,
}
549
.
0
,
}
21395
,
}
;
mavlink_aq_telemetry_f_t
packet1
,
packet2
;
memset
(
&
packet1
,
0
,
sizeof
(
packet1
));
...
...
libs/mavlink/include/mavlink/v1.0/autoquad/version.h
View file @
34fb9118
...
...
@@ -5,8 +5,8 @@
#ifndef MAVLINK_VERSION_H
#define MAVLINK_VERSION_H
#define MAVLINK_BUILD_DATE "Tue
Sep 10 23:49:36 2013
"
#define MAVLINK_BUILD_DATE "Tue
Feb 4 15:27:43 2014
"
#define MAVLINK_WIRE_PROTOCOL_VERSION "1.0"
#define MAVLINK_MAX_DIALECT_PAYLOAD_SIZE 25
4
#define MAVLINK_MAX_DIALECT_PAYLOAD_SIZE 25
5
#endif // MAVLINK_VERSION_H
libs/mavlink/include/mavlink/v1.0/common/common.h
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/common/mavlink_msg_battery_status.h
View file @
34fb9118
This diff is collapsed.
Click to expand it.
libs/mavlink/include/mavlink/v1.0/
pixhawk
/mavlink_msg_data_transmission_handshake.h
→
libs/mavlink/include/mavlink/v1.0/
common
/mavlink_msg_data_transmission_handshake.h
View file @
34fb9118
// MESSAGE DATA_TRANSMISSION_HANDSHAKE PACKING
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE 1
93
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE 1
30
typedef
struct
__mavlink_data_transmission_handshake_t
{
uint32_t
size
;
///< total data size in bytes (set on ACK only)
uint16_t
width
;
///< Width of a matrix or image
uint16_t
height
;
///< Height of a matrix or image
uint16_t
packets
;
///< number of packets beeing sent (set on ACK only)
uint8_t
type
;
///< type of requested/acknowledged data (as defined in ENUM DATA_TYPES in mavlink/include/mavlink_types.h)
uint8_t
packets
;
///< number of packets beeing sent (set on ACK only)
uint8_t
payload
;
///< payload size per packet (normally 253 byte, see DATA field size in message ENCAPSULATED_DATA) (set on ACK only)
uint8_t
jpg_quality
;
///< JPEG quality out of [1,100]
}
mavlink_data_transmission_handshake_t
;
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN 1
2
#define MAVLINK_MSG_ID_1
93_LEN 12
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN 1
3
#define MAVLINK_MSG_ID_1
30_LEN 13
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_CRC 2
3
#define MAVLINK_MSG_ID_1
93_CRC 23
#define MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_CRC 2
9
#define MAVLINK_MSG_ID_1
30_CRC 29
...
...
@@ -27,10 +27,10 @@ typedef struct __mavlink_data_transmission_handshake_t
{ { "size", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_data_transmission_handshake_t, size) }, \
{ "width", NULL, MAVLINK_TYPE_UINT16_T, 0, 4, offsetof(mavlink_data_transmission_handshake_t, width) }, \
{ "height", NULL, MAVLINK_TYPE_UINT16_T, 0, 6, offsetof(mavlink_data_transmission_handshake_t, height) }, \
{ "
type", NULL, MAVLINK_TYPE_UINT8_T, 0, 8, offsetof(mavlink_data_transmission_handshake_t, type
) }, \
{ "
packets", NULL, MAVLINK_TYPE_UINT8_T, 0, 9, offsetof(mavlink_data_transmission_handshake_t, packets
) }, \
{ "payload", NULL, MAVLINK_TYPE_UINT8_T, 0, 1
0
, offsetof(mavlink_data_transmission_handshake_t, payload) }, \
{ "jpg_quality", NULL, MAVLINK_TYPE_UINT8_T, 0, 1
1
, offsetof(mavlink_data_transmission_handshake_t, jpg_quality) }, \
{ "
packets", NULL, MAVLINK_TYPE_UINT16_T, 0, 8, offsetof(mavlink_data_transmission_handshake_t, packets
) }, \
{ "
type", NULL, MAVLINK_TYPE_UINT8_T, 0, 10, offsetof(mavlink_data_transmission_handshake_t, type
) }, \
{ "payload", NULL, MAVLINK_TYPE_UINT8_T, 0, 1
1
, offsetof(mavlink_data_transmission_handshake_t, payload) }, \
{ "jpg_quality", NULL, MAVLINK_TYPE_UINT8_T, 0, 1
2
, offsetof(mavlink_data_transmission_handshake_t, jpg_quality) }, \
} \
}
...
...
@@ -51,17 +51,17 @@ typedef struct __mavlink_data_transmission_handshake_t
* @return length of the message in bytes (excluding serial stream start sign)
*/
static
inline
uint16_t
mavlink_msg_data_transmission_handshake_pack
(
uint8_t
system_id
,
uint8_t
component_id
,
mavlink_message_t
*
msg
,
uint8_t
type
,
uint32_t
size
,
uint16_t
width
,
uint16_t
height
,
uint
8
_t
packets
,
uint8_t
payload
,
uint8_t
jpg_quality
)
uint8_t
type
,
uint32_t
size
,
uint16_t
width
,
uint16_t
height
,
uint
16
_t
packets
,
uint8_t
payload
,
uint8_t
jpg_quality
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN
];
_mav_put_uint32_t
(
buf
,
0
,
size
);
_mav_put_uint16_t
(
buf
,
4
,
width
);
_mav_put_uint16_t
(
buf
,
6
,
height
);
_mav_put_uint
8_t
(
buf
,
8
,
type
);
_mav_put_uint8_t
(
buf
,
9
,
packets
);
_mav_put_uint8_t
(
buf
,
1
0
,
payload
);
_mav_put_uint8_t
(
buf
,
1
1
,
jpg_quality
);
_mav_put_uint
16_t
(
buf
,
8
,
packets
);
_mav_put_uint8_t
(
buf
,
10
,
type
);
_mav_put_uint8_t
(
buf
,
1
1
,
payload
);
_mav_put_uint8_t
(
buf
,
1
2
,
jpg_quality
);
memcpy
(
_MAV_PAYLOAD_NON_CONST
(
msg
),
buf
,
MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN
);
#else
...
...
@@ -69,8 +69,8 @@ static inline uint16_t mavlink_msg_data_transmission_handshake_pack(uint8_t syst
packet
.
size
=
size
;
packet
.
width
=
width
;
packet
.
height
=
height
;
packet
.
type
=
type
;
packet
.
packets
=
packets
;
packet
.
type
=
type
;
packet
.
payload
=
payload
;
packet
.
jpg_quality
=
jpg_quality
;
...
...
@@ -102,17 +102,17 @@ static inline uint16_t mavlink_msg_data_transmission_handshake_pack(uint8_t syst
*/
static
inline
uint16_t
mavlink_msg_data_transmission_handshake_pack_chan
(
uint8_t
system_id
,
uint8_t
component_id
,
uint8_t
chan
,
mavlink_message_t
*
msg
,
uint8_t
type
,
uint32_t
size
,
uint16_t
width
,
uint16_t
height
,
uint
8
_t
packets
,
uint8_t
payload
,
uint8_t
jpg_quality
)
uint8_t
type
,
uint32_t
size
,
uint16_t
width
,
uint16_t
height
,
uint
16
_t
packets
,
uint8_t
payload
,
uint8_t
jpg_quality
)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
char
buf
[
MAVLINK_MSG_ID_DATA_TRANSMISSION_HANDSHAKE_LEN
];