✨feat: 更好兼容matlab
uin64->uint32 payload64->payload
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
|
||||
#define MAVLINK_MSG_ID_COMPASSMOT_STATUS 177
|
||||
|
||||
MAVPACKED(
|
||||
|
||||
typedef struct __mavlink_compassmot_status_t {
|
||||
float current; /*< [A] Current.*/
|
||||
float CompensationX; /*< Motor Compensation X.*/
|
||||
@@ -11,7 +11,7 @@ typedef struct __mavlink_compassmot_status_t {
|
||||
float CompensationZ; /*< Motor Compensation Z.*/
|
||||
uint16_t throttle; /*< [d%] Throttle.*/
|
||||
uint16_t interference; /*< [%] Interference.*/
|
||||
}) mavlink_compassmot_status_t;
|
||||
} mavlink_compassmot_status_t;
|
||||
|
||||
#define MAVLINK_MSG_ID_COMPASSMOT_STATUS_LEN 20
|
||||
#define MAVLINK_MSG_ID_COMPASSMOT_STATUS_MIN_LEN 20
|
||||
@@ -64,7 +64,7 @@ typedef struct __mavlink_compassmot_status_t {
|
||||
* @param CompensationZ Motor Compensation Z.
|
||||
* @return length of the message in bytes (excluding serial stream start sign)
|
||||
*/
|
||||
static inline uint16_t mavlink_msg_compassmot_status_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
|
||||
static inline uint16_t mavlink_msg_compassmot_status_pack(uint16_t system_id, uint8_t component_id, mavlink_message_t* msg,
|
||||
uint16_t throttle, float current, uint16_t interference, float CompensationX, float CompensationY, float CompensationZ)
|
||||
{
|
||||
#if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
|
||||
@@ -107,7 +107,7 @@ static inline uint16_t mavlink_msg_compassmot_status_pack(uint8_t system_id, uin
|
||||
* @param CompensationZ Motor Compensation Z.
|
||||
* @return length of the message in bytes (excluding serial stream start sign)
|
||||
*/
|
||||
static inline uint16_t mavlink_msg_compassmot_status_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
|
||||
static inline uint16_t mavlink_msg_compassmot_status_pack_chan(uint16_t system_id, uint8_t component_id, uint8_t chan,
|
||||
mavlink_message_t* msg,
|
||||
uint16_t throttle,float current,uint16_t interference,float CompensationX,float CompensationY,float CompensationZ)
|
||||
{
|
||||
@@ -145,7 +145,7 @@ static inline uint16_t mavlink_msg_compassmot_status_pack_chan(uint8_t system_id
|
||||
* @param msg The MAVLink message to compress the data into
|
||||
* @param compassmot_status C-struct to read the message contents from
|
||||
*/
|
||||
static inline uint16_t mavlink_msg_compassmot_status_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_compassmot_status_t* compassmot_status)
|
||||
static inline uint16_t mavlink_msg_compassmot_status_encode(uint16_t system_id, uint8_t component_id, mavlink_message_t* msg, const mavlink_compassmot_status_t* compassmot_status)
|
||||
{
|
||||
return mavlink_msg_compassmot_status_pack(system_id, component_id, msg, compassmot_status->throttle, compassmot_status->current, compassmot_status->interference, compassmot_status->CompensationX, compassmot_status->CompensationY, compassmot_status->CompensationZ);
|
||||
}
|
||||
@@ -159,7 +159,7 @@ static inline uint16_t mavlink_msg_compassmot_status_encode(uint8_t system_id, u
|
||||
* @param msg The MAVLink message to compress the data into
|
||||
* @param compassmot_status C-struct to read the message contents from
|
||||
*/
|
||||
static inline uint16_t mavlink_msg_compassmot_status_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_compassmot_status_t* compassmot_status)
|
||||
static inline uint16_t mavlink_msg_compassmot_status_encode_chan(uint16_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg, const mavlink_compassmot_status_t* compassmot_status)
|
||||
{
|
||||
return mavlink_msg_compassmot_status_pack_chan(system_id, component_id, chan, msg, compassmot_status->throttle, compassmot_status->current, compassmot_status->interference, compassmot_status->CompensationX, compassmot_status->CompensationY, compassmot_status->CompensationZ);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user