mc att: use multiplatform subscriptions type

This commit is contained in:
Thomas Gubler
2014-12-12 10:15:33 +01:00
parent 59d26f5c30
commit c0d386bce0
5 changed files with 44 additions and 43 deletions
+3 -3
View File
@@ -79,7 +79,7 @@ public:
/**
* Get the last message value
*/
virtual const M& get_msg() = 0;
virtual const M& get() = 0;
};
#if defined(__linux) || (defined(__APPLE__) && defined(__MACH__))
@@ -120,7 +120,7 @@ public:
/**
* Get the last message value
*/
const M& get_msg() { return _msg_current; }
const M& get() { return _msg_current; }
protected:
/**
@@ -210,7 +210,7 @@ public:
/**
* Get the last message value
*/
const M& get_msg() { return uORB::Subscription<M>::getData(); }
const M& get() { return uORB::Subscription<M>::getData(); }
protected:
std::function<void(const M &)> _callback; /**< Callback handle,