feat: 更好兼容matlab

uin64->uint32
payload64->payload
This commit is contained in:
matt
2020-09-20 10:12:24 +08:00
parent 1465895353
commit e79d1f21fb
289 changed files with 6428 additions and 15915 deletions
+6 -6
View File
@@ -3,7 +3,7 @@
#define MAVLINK_MSG_ID_DEVICE_OP_READ 11000
MAVPACKED(
typedef struct __mavlink_device_op_read_t {
uint32_t request_id; /*< Request ID - copied to reply.*/
uint8_t target_system; /*< System ID.*/
@@ -14,7 +14,7 @@ typedef struct __mavlink_device_op_read_t {
char busname[40]; /*< Name of device on bus (for SPI).*/
uint8_t regstart; /*< First register to read.*/
uint8_t count; /*< Count of registers to read.*/
}) mavlink_device_op_read_t;
} mavlink_device_op_read_t;
#define MAVLINK_MSG_ID_DEVICE_OP_READ_LEN 51
#define MAVLINK_MSG_ID_DEVICE_OP_READ_MIN_LEN 51
@@ -76,7 +76,7 @@ typedef struct __mavlink_device_op_read_t {
* @param count Count of registers to read.
* @return length of the message in bytes (excluding serial stream start sign)
*/
static inline uint16_t mavlink_msg_device_op_read_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
static inline uint16_t mavlink_msg_device_op_read_pack(uint16_t system_id, uint8_t component_id, mavlink_message_t* msg,
uint8_t target_system, uint8_t target_component, uint32_t request_id, uint8_t bustype, uint8_t bus, uint8_t address, const char *busname, uint8_t regstart, uint8_t count)
{
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
@@ -126,7 +126,7 @@ static inline uint16_t mavlink_msg_device_op_read_pack(uint8_t system_id, uint8_
* @param count Count of registers to read.
* @return length of the message in bytes (excluding serial stream start sign)
*/
static inline uint16_t mavlink_msg_device_op_read_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
static inline uint16_t mavlink_msg_device_op_read_pack_chan(uint16_t system_id, uint8_t component_id, uint8_t chan,
mavlink_message_t* msg,
uint8_t target_system,uint8_t target_component,uint32_t request_id,uint8_t bustype,uint8_t bus,uint8_t address,const char *busname,uint8_t regstart,uint8_t count)
{
@@ -168,7 +168,7 @@ static inline uint16_t mavlink_msg_device_op_read_pack_chan(uint8_t system_id, u
* @param msg The MAVLink message to compress the data into
* @param device_op_read C-struct to read the message contents from
*/
static inline uint16_t mavlink_msg_device_op_read_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_device_op_read_t* device_op_read)
static inline uint16_t mavlink_msg_device_op_read_encode(uint16_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_device_op_read_t* device_op_read)
{
return mavlink_msg_device_op_read_pack(system_id, component_id, msg, device_op_read->target_system, device_op_read->target_component, device_op_read->request_id, device_op_read->bustype, device_op_read->bus, device_op_read->address, device_op_read->busname, device_op_read->regstart, device_op_read->count);
}
@@ -182,7 +182,7 @@ static inline uint16_t mavlink_msg_device_op_read_encode(uint8_t system_id, uint
* @param msg The MAVLink message to compress the data into
* @param device_op_read C-struct to read the message contents from
*/
static inline uint16_t mavlink_msg_device_op_read_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_device_op_read_t* device_op_read)
static inline uint16_t mavlink_msg_device_op_read_encode_chan(uint16_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_device_op_read_t* device_op_read)
{
return mavlink_msg_device_op_read_pack_chan(system_id, component_id, chan, msg, device_op_read->target_system, device_op_read->target_component, device_op_read->request_id, device_op_read->bustype, device_op_read->bus, device_op_read->address, device_op_read->busname, device_op_read->regstart, device_op_read->count);
}