aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/b100/b100_ctrl.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp/b100/b100_ctrl.hpp')
-rw-r--r--host/lib/usrp/b100/b100_ctrl.hpp17
1 files changed, 9 insertions, 8 deletions
diff --git a/host/lib/usrp/b100/b100_ctrl.hpp b/host/lib/usrp/b100/b100_ctrl.hpp
index 17887181d..74884d525 100644
--- a/host/lib/usrp/b100/b100_ctrl.hpp
+++ b/host/lib/usrp/b100/b100_ctrl.hpp
@@ -18,25 +18,28 @@
#ifndef INCLUDED_B100_CTRL_HPP
#define INCLUDED_B100_CTRL_HPP
-#include <uhd/transport/bounded_buffer.hpp>
+#include "wb_iface.hpp"
#include <uhd/transport/usb_zero_copy.hpp>
-#include <uhd/types/metadata.hpp>
#include <uhd/types/serial.hpp>
#include <boost/shared_ptr.hpp>
#include <boost/utility.hpp>
#include "ctrl_packet.hpp"
-#include <boost/thread.hpp>
+#include <boost/function.hpp>
-class b100_ctrl : boost::noncopyable{
+class b100_ctrl : boost::noncopyable, public wb_iface{
public:
typedef boost::shared_ptr<b100_ctrl> sptr;
+ typedef boost::function<void(uhd::transport::managed_recv_buffer::sptr)> async_cb_type;
/*!
* Make a USRP control object from a data transport
* \param ctrl_transport a USB data transport
* \return a new b100 control object
*/
- static sptr make(uhd::transport::usb_zero_copy::sptr ctrl_transport);
+ static sptr make(uhd::transport::zero_copy_if::sptr ctrl_transport);
+
+ //! set an async callback for messages
+ virtual void set_async_cb(const async_cb_type &async_cb) = 0;
/*!
* Write a byte vector to an FPGA register
@@ -61,9 +64,7 @@ public:
* \return true if it got something
*/
virtual bool get_ctrl_data(ctrl_data_t &pkt_data, double timeout) = 0;
-
- virtual bool recv_async_msg(uhd::async_metadata_t &async_metadata, double timeout) = 0;
-
+
};
#endif /* INCLUDED_B100_CTRL_HPP */