添加MAVLINK协议库
This commit is contained in:
34
app/drivers/sertrf/protocol/mavlinkv2/standard/mavlink.h
Normal file
34
app/drivers/sertrf/protocol/mavlinkv2/standard/mavlink.h
Normal file
@@ -0,0 +1,34 @@
|
||||
/** @file
|
||||
* @brief MAVLink comm protocol built from standard.xml
|
||||
* @see http://mavlink.org
|
||||
*/
|
||||
#pragma once
|
||||
#ifndef MAVLINK_H
|
||||
#define MAVLINK_H
|
||||
|
||||
#define MAVLINK_PRIMARY_XML_IDX 0
|
||||
|
||||
#ifndef MAVLINK_STX
|
||||
#define MAVLINK_STX 253
|
||||
#endif
|
||||
|
||||
#ifndef MAVLINK_ENDIAN
|
||||
#define MAVLINK_ENDIAN MAVLINK_LITTLE_ENDIAN
|
||||
#endif
|
||||
|
||||
#ifndef MAVLINK_ALIGNED_FIELDS
|
||||
#define MAVLINK_ALIGNED_FIELDS 1
|
||||
#endif
|
||||
|
||||
#ifndef MAVLINK_CRC_EXTRA
|
||||
#define MAVLINK_CRC_EXTRA 1
|
||||
#endif
|
||||
|
||||
#ifndef MAVLINK_COMMAND_24BIT
|
||||
#define MAVLINK_COMMAND_24BIT 1
|
||||
#endif
|
||||
|
||||
#include "version.h"
|
||||
#include "standard.h"
|
||||
|
||||
#endif // MAVLINK_H
|
||||
69
app/drivers/sertrf/protocol/mavlinkv2/standard/standard.h
Normal file
69
app/drivers/sertrf/protocol/mavlinkv2/standard/standard.h
Normal file
File diff suppressed because one or more lines are too long
37
app/drivers/sertrf/protocol/mavlinkv2/standard/testsuite.h
Normal file
37
app/drivers/sertrf/protocol/mavlinkv2/standard/testsuite.h
Normal file
@@ -0,0 +1,37 @@
|
||||
/** @file
|
||||
* @brief MAVLink comm protocol testsuite generated from standard.xml
|
||||
* @see http://qgroundcontrol.org/mavlink/
|
||||
*/
|
||||
#pragma once
|
||||
#ifndef STANDARD_TESTSUITE_H
|
||||
#define STANDARD_TESTSUITE_H
|
||||
|
||||
#ifdef __cplusplus
|
||||
extern "C" {
|
||||
#endif
|
||||
|
||||
#ifndef MAVLINK_TEST_ALL
|
||||
#define MAVLINK_TEST_ALL
|
||||
static void mavlink_test_common(uint8_t, uint8_t, mavlink_message_t *last_msg);
|
||||
static void mavlink_test_standard(uint8_t, uint8_t, mavlink_message_t *last_msg);
|
||||
|
||||
static void mavlink_test_all(uint8_t system_id, uint8_t component_id, mavlink_message_t *last_msg)
|
||||
{
|
||||
mavlink_test_common(system_id, component_id, last_msg);
|
||||
mavlink_test_standard(system_id, component_id, last_msg);
|
||||
}
|
||||
#endif
|
||||
|
||||
#include "../common/testsuite.h"
|
||||
|
||||
|
||||
|
||||
static void mavlink_test_standard(uint8_t system_id, uint8_t component_id, mavlink_message_t *last_msg)
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif // __cplusplus
|
||||
#endif // STANDARD_TESTSUITE_H
|
||||
14
app/drivers/sertrf/protocol/mavlinkv2/standard/version.h
Normal file
14
app/drivers/sertrf/protocol/mavlinkv2/standard/version.h
Normal file
@@ -0,0 +1,14 @@
|
||||
/** @file
|
||||
* @brief MAVLink comm protocol built from standard.xml
|
||||
* @see http://mavlink.org
|
||||
*/
|
||||
#pragma once
|
||||
|
||||
#ifndef MAVLINK_VERSION_H
|
||||
#define MAVLINK_VERSION_H
|
||||
|
||||
#define MAVLINK_BUILD_DATE "Thu Aug 30 2018"
|
||||
#define MAVLINK_WIRE_PROTOCOL_VERSION "2.0"
|
||||
#define MAVLINK_MAX_DIALECT_PAYLOAD_SIZE 255
|
||||
|
||||
#endif // MAVLINK_VERSION_H
|
||||
Reference in New Issue
Block a user