3 #define MAVLINK_MSG_ID_DETECTION_STATS 205
21 #define MAVLINK_MSG_ID_DETECTION_STATS_LEN 48
22 #define MAVLINK_MSG_ID_205_LEN 48
24 #define MAVLINK_MSG_ID_DETECTION_STATS_CRC 87
25 #define MAVLINK_MSG_ID_205_CRC 87
29 #define MAVLINK_MESSAGE_INFO_DETECTION_STATS { \
32 { { "detections", NULL, MAVLINK_TYPE_UINT32_T, 0, 0, offsetof(mavlink_detection_stats_t, detections) }, \
33 { "cluster_iters", NULL, MAVLINK_TYPE_UINT32_T, 0, 4, offsetof(mavlink_detection_stats_t, cluster_iters) }, \
34 { "best_score", NULL, MAVLINK_TYPE_FLOAT, 0, 8, offsetof(mavlink_detection_stats_t, best_score) }, \
35 { "best_lat", NULL, MAVLINK_TYPE_INT32_T, 0, 12, offsetof(mavlink_detection_stats_t, best_lat) }, \
36 { "best_lon", NULL, MAVLINK_TYPE_INT32_T, 0, 16, offsetof(mavlink_detection_stats_t, best_lon) }, \
37 { "best_alt", NULL, MAVLINK_TYPE_INT32_T, 0, 20, offsetof(mavlink_detection_stats_t, best_alt) }, \
38 { "best_detection_id", NULL, MAVLINK_TYPE_UINT32_T, 0, 24, offsetof(mavlink_detection_stats_t, best_detection_id) }, \
39 { "best_cluster_id", NULL, MAVLINK_TYPE_UINT32_T, 0, 28, offsetof(mavlink_detection_stats_t, best_cluster_id) }, \
40 { "best_cluster_iter_id", NULL, MAVLINK_TYPE_UINT32_T, 0, 32, offsetof(mavlink_detection_stats_t, best_cluster_iter_id) }, \
41 { "images_done", NULL, MAVLINK_TYPE_UINT32_T, 0, 36, offsetof(mavlink_detection_stats_t, images_done) }, \
42 { "images_todo", NULL, MAVLINK_TYPE_UINT32_T, 0, 40, offsetof(mavlink_detection_stats_t, images_todo) }, \
43 { "fps", NULL, MAVLINK_TYPE_FLOAT, 0, 44, offsetof(mavlink_detection_stats_t, fps) }, \
68 static inline uint16_t mavlink_msg_detection_stats_pack(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
69 uint32_t detections, uint32_t cluster_iters,
float best_score, int32_t best_lat, int32_t best_lon, int32_t best_alt, uint32_t best_detection_id, uint32_t best_cluster_id, uint32_t best_cluster_iter_id, uint32_t images_done, uint32_t images_todo,
float fps)
71 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
106 #if MAVLINK_CRC_EXTRA
133 static inline uint16_t mavlink_msg_detection_stats_pack_chan(uint8_t system_id, uint8_t component_id, uint8_t chan,
134 mavlink_message_t* msg,
135 uint32_t detections,uint32_t cluster_iters,
float best_score,int32_t best_lat,int32_t best_lon,int32_t best_alt,uint32_t best_detection_id,uint32_t best_cluster_id,uint32_t best_cluster_iter_id,uint32_t images_done,uint32_t images_todo,
float fps)
137 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
172 #if MAVLINK_CRC_EXTRA
187 static inline uint16_t mavlink_msg_detection_stats_encode(uint8_t system_id, uint8_t component_id, mavlink_message_t* msg,
const mavlink_detection_stats_t* detection_stats)
189 return mavlink_msg_detection_stats_pack(system_id, component_id, msg, detection_stats->
detections, detection_stats->
cluster_iters, detection_stats->
best_score, detection_stats->
best_lat, detection_stats->
best_lon, detection_stats->
best_alt, detection_stats->
best_detection_id, detection_stats->
best_cluster_id, detection_stats->
best_cluster_iter_id, detection_stats->
images_done, detection_stats->
images_todo, detection_stats->
fps);
201 static inline uint16_t mavlink_msg_detection_stats_encode_chan(uint8_t system_id, uint8_t component_id, uint8_t chan, mavlink_message_t* msg,
const mavlink_detection_stats_t* detection_stats)
203 return mavlink_msg_detection_stats_pack_chan(system_id, component_id, chan, msg, detection_stats->
detections, detection_stats->
cluster_iters, detection_stats->
best_score, detection_stats->
best_lat, detection_stats->
best_lon, detection_stats->
best_alt, detection_stats->
best_detection_id, detection_stats->
best_cluster_id, detection_stats->
best_cluster_iter_id, detection_stats->
images_done, detection_stats->
images_todo, detection_stats->
fps);
223 #ifdef MAVLINK_USE_CONVENIENCE_FUNCTIONS
225 static inline void mavlink_msg_detection_stats_send(
mavlink_channel_t chan, uint32_t detections, uint32_t cluster_iters,
float best_score, int32_t best_lat, int32_t best_lon, int32_t best_alt, uint32_t best_detection_id, uint32_t best_cluster_id, uint32_t best_cluster_iter_id, uint32_t images_done, uint32_t images_todo,
float fps)
227 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
242 #if MAVLINK_CRC_EXTRA
262 #if MAVLINK_CRC_EXTRA
270 #if MAVLINK_MSG_ID_DETECTION_STATS_LEN <= MAVLINK_MAX_PAYLOAD_LEN
278 static inline void mavlink_msg_detection_stats_send_buf(mavlink_message_t *msgbuf,
mavlink_channel_t chan, uint32_t detections, uint32_t cluster_iters,
float best_score, int32_t best_lat, int32_t best_lon, int32_t best_alt, uint32_t best_detection_id, uint32_t best_cluster_id, uint32_t best_cluster_iter_id, uint32_t images_done, uint32_t images_todo,
float fps)
280 #if MAVLINK_NEED_BYTE_SWAP || !MAVLINK_ALIGNED_FIELDS
281 char *buf = (
char *)msgbuf;
295 #if MAVLINK_CRC_EXTRA
315 #if MAVLINK_CRC_EXTRA
334 static inline uint32_t mavlink_msg_detection_stats_get_detections(
const mavlink_message_t* msg)
336 return _MAV_RETURN_uint32_t(msg, 0);
344 static inline uint32_t mavlink_msg_detection_stats_get_cluster_iters(
const mavlink_message_t* msg)
346 return _MAV_RETURN_uint32_t(msg, 4);
354 static inline float mavlink_msg_detection_stats_get_best_score(
const mavlink_message_t* msg)
356 return _MAV_RETURN_float(msg, 8);
364 static inline int32_t mavlink_msg_detection_stats_get_best_lat(
const mavlink_message_t* msg)
366 return _MAV_RETURN_int32_t(msg, 12);
374 static inline int32_t mavlink_msg_detection_stats_get_best_lon(
const mavlink_message_t* msg)
376 return _MAV_RETURN_int32_t(msg, 16);
384 static inline int32_t mavlink_msg_detection_stats_get_best_alt(
const mavlink_message_t* msg)
386 return _MAV_RETURN_int32_t(msg, 20);
394 static inline uint32_t mavlink_msg_detection_stats_get_best_detection_id(
const mavlink_message_t* msg)
396 return _MAV_RETURN_uint32_t(msg, 24);
404 static inline uint32_t mavlink_msg_detection_stats_get_best_cluster_id(
const mavlink_message_t* msg)
406 return _MAV_RETURN_uint32_t(msg, 28);
414 static inline uint32_t mavlink_msg_detection_stats_get_best_cluster_iter_id(
const mavlink_message_t* msg)
416 return _MAV_RETURN_uint32_t(msg, 32);
424 static inline uint32_t mavlink_msg_detection_stats_get_images_done(
const mavlink_message_t* msg)
426 return _MAV_RETURN_uint32_t(msg, 36);
434 static inline uint32_t mavlink_msg_detection_stats_get_images_todo(
const mavlink_message_t* msg)
436 return _MAV_RETURN_uint32_t(msg, 40);
444 static inline float mavlink_msg_detection_stats_get_fps(
const mavlink_message_t* msg)
446 return _MAV_RETURN_float(msg, 44);
455 static inline void mavlink_msg_detection_stats_decode(
const mavlink_message_t* msg,
mavlink_detection_stats_t* detection_stats)
457 #if MAVLINK_NEED_BYTE_SWAP
458 detection_stats->
detections = mavlink_msg_detection_stats_get_detections(msg);
459 detection_stats->
cluster_iters = mavlink_msg_detection_stats_get_cluster_iters(msg);
460 detection_stats->
best_score = mavlink_msg_detection_stats_get_best_score(msg);
461 detection_stats->
best_lat = mavlink_msg_detection_stats_get_best_lat(msg);
462 detection_stats->
best_lon = mavlink_msg_detection_stats_get_best_lon(msg);
463 detection_stats->
best_alt = mavlink_msg_detection_stats_get_best_alt(msg);
464 detection_stats->
best_detection_id = mavlink_msg_detection_stats_get_best_detection_id(msg);
465 detection_stats->
best_cluster_id = mavlink_msg_detection_stats_get_best_cluster_id(msg);
466 detection_stats->
best_cluster_iter_id = mavlink_msg_detection_stats_get_best_cluster_iter_id(msg);
467 detection_stats->
images_done = mavlink_msg_detection_stats_get_images_done(msg);
468 detection_stats->
images_todo = mavlink_msg_detection_stats_get_images_todo(msg);
469 detection_stats->
fps = mavlink_msg_detection_stats_get_fps(msg);
#define _mav_put_float(buf, wire_offset, b)
Definition: protocol.h:145
uint32_t cluster_iters
Number of cluster iterations.
Definition: mavlink_msg_detection_stats.h:8
float fps
Average images per seconds processed.
Definition: mavlink_msg_detection_stats.h:18
uint32_t best_cluster_id
Best cluster ID.
Definition: mavlink_msg_detection_stats.h:14
MAVLINK_HELPER uint16_t mavlink_finalize_message(mavlink_message_t *msg, uint8_t system_id, uint8_t component_id, uint8_t length)
Finalize a MAVLink message with MAVLINK_COMM_0 as default channel.
Definition: mavlink_helpers.h:105
#define MAVLINK_MSG_ID_DETECTION_STATS_CRC
Definition: mavlink_msg_detection_stats.h:24
#define _mav_put_int32_t(buf, wire_offset, b)
Definition: protocol.h:142
#define _MAV_PAYLOAD_NON_CONST(msg)
Definition: mavlink_types.h:172
Definition: mavlink_msg_detection_stats.h:5
mavlink_channel_t
Definition: mavlink_types.h:178
uint32_t detections
Number of detections.
Definition: mavlink_msg_detection_stats.h:7
float best_score
Best score.
Definition: mavlink_msg_detection_stats.h:9
#define _MAV_PAYLOAD(msg)
Definition: mavlink_types.h:171
#define MAVLINK_MSG_ID_DETECTION_STATS_LEN
Definition: mavlink_msg_detection_stats.h:21
struct __mavlink_detection_stats_t mavlink_detection_stats_t
#define MAVLINK_MSG_ID_DETECTION_STATS
Definition: mavlink_msg_detection_stats.h:3
uint32_t images_todo
Number of images still to process.
Definition: mavlink_msg_detection_stats.h:17
uint32_t best_detection_id
Best detection ID.
Definition: mavlink_msg_detection_stats.h:13
uint32_t images_done
Number of images already processed.
Definition: mavlink_msg_detection_stats.h:16
int32_t best_lon
Longitude of the best detection * 1E7.
Definition: mavlink_msg_detection_stats.h:11
int32_t best_alt
Altitude of the best detection * 1E3.
Definition: mavlink_msg_detection_stats.h:12
uint32_t best_cluster_iter_id
Best cluster ID.
Definition: mavlink_msg_detection_stats.h:15
MAVLINK_HELPER uint16_t mavlink_finalize_message_chan(mavlink_message_t *msg, uint8_t system_id, uint8_t component_id, uint8_t chan, uint8_t length)
Finalize a MAVLink message with channel assignment.
Definition: mavlink_helpers.h:71
int32_t best_lat
Latitude of the best detection * 1E7.
Definition: mavlink_msg_detection_stats.h:10
#define _mav_put_uint32_t(buf, wire_offset, b)
Definition: protocol.h:141