aboutsummaryrefslogtreecommitdiff
path: root/src/modules/mavlink/mavlink_main.h
diff options
context:
space:
mode:
authorAnton Babushkin <anton.babushkin@me.com>2014-07-24 12:10:21 +0200
committerAnton Babushkin <anton.babushkin@me.com>2014-07-24 12:10:21 +0200
commit9df1da1b7cd140e9452c73c6307befeadd6ce4c5 (patch)
tree018235f3577491420d844ea66174a82c1202f92f /src/modules/mavlink/mavlink_main.h
parentea2dce39927b7afcdfae79c059cc57342c70904e (diff)
downloadpx4-firmware-9df1da1b7cd140e9452c73c6307befeadd6ce4c5.tar.gz
px4-firmware-9df1da1b7cd140e9452c73c6307befeadd6ce4c5.tar.bz2
px4-firmware-9df1da1b7cd140e9452c73c6307befeadd6ce4c5.zip
mavlink: STATUSTEXT implemented via streams API
Diffstat (limited to 'src/modules/mavlink/mavlink_main.h')
-rw-r--r--src/modules/mavlink/mavlink_main.h18
1 files changed, 12 insertions, 6 deletions
diff --git a/src/modules/mavlink/mavlink_main.h b/src/modules/mavlink/mavlink_main.h
index 7fcbae72e..87bb9d9ad 100644
--- a/src/modules/mavlink/mavlink_main.h
+++ b/src/modules/mavlink/mavlink_main.h
@@ -188,29 +188,33 @@ public:
*
* @param string the message to send (will be capped by mavlink max string length)
*/
- int send_statustext_info(const char *string);
+ void send_statustext_info(const char *string);
/**
* Send a status text with loglevel CRITICAL
*
* @param string the message to send (will be capped by mavlink max string length)
*/
- int send_statustext_critical(const char *string);
+ void send_statustext_critical(const char *string);
/**
* Send a status text with loglevel EMERGENCY
*
* @param string the message to send (will be capped by mavlink max string length)
*/
- int send_statustext_emergency(const char *string);
+ void send_statustext_emergency(const char *string);
/**
- * Send a status text with loglevel
+ * Send a status text with loglevel, the difference from mavlink_log_xxx() is that message sent
+ * only on this mavlink connection. Useful for reporting communication specific, not system-wide info
+ * only to client interested in it. Message will be not sent immediately but queued in buffer as
+ * for mavlink_log_xxx().
*
* @param string the message to send (will be capped by mavlink max string length)
- * @param severity the log level, one of
+ * @param severity the log level
*/
- int send_statustext(unsigned severity, const char *string);
+ void send_statustext(unsigned severity, const char *string);
+
MavlinkStream * get_streams() const { return _streams; }
float get_rate_mult();
@@ -259,6 +263,8 @@ public:
*/
struct telemetry_status_s& get_rx_status() { return _rstatus; }
+ struct mavlink_logbuffer *get_logbuffer() { return &_logbuffer; }
+
protected:
Mavlink *next;