[mavlink] Updated mavlink code to work with the current Arducopter (and probably plane and rover). Mavlink library has been updated to V 1.0.
This commit is contained in:
@@ -44,14 +44,14 @@ static inline uint16_t mavlink_msg_debug_pack(uint8_t system_id, uint8_t compone
|
||||
_mav_put_float(buf, 4, value);
|
||||
_mav_put_uint8_t(buf, 8, ind);
|
||||
|
||||
memcpy(_MAV_PAYLOAD(msg), buf, 9);
|
||||
memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, 9);
|
||||
#else
|
||||
mavlink_debug_t packet;
|
||||
packet.time_boot_ms = time_boot_ms;
|
||||
packet.value = value;
|
||||
packet.ind = ind;
|
||||
|
||||
memcpy(_MAV_PAYLOAD(msg), &packet, 9);
|
||||
memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, 9);
|
||||
#endif
|
||||
|
||||
msg->msgid = MAVLINK_MSG_ID_DEBUG;
|
||||
@@ -79,14 +79,14 @@ static inline uint16_t mavlink_msg_debug_pack_chan(uint8_t system_id, uint8_t co
|
||||
_mav_put_float(buf, 4, value);
|
||||
_mav_put_uint8_t(buf, 8, ind);
|
||||
|
||||
memcpy(_MAV_PAYLOAD(msg), buf, 9);
|
||||
memcpy(_MAV_PAYLOAD_NON_CONST(msg), buf, 9);
|
||||
#else
|
||||
mavlink_debug_t packet;
|
||||
packet.time_boot_ms = time_boot_ms;
|
||||
packet.value = value;
|
||||
packet.ind = ind;
|
||||
|
||||
memcpy(_MAV_PAYLOAD(msg), &packet, 9);
|
||||
memcpy(_MAV_PAYLOAD_NON_CONST(msg), &packet, 9);
|
||||
#endif
|
||||
|
||||
msg->msgid = MAVLINK_MSG_ID_DEBUG;
|
||||
|
||||
Reference in New Issue
Block a user