From 0d2205758561682fed5490fb783b3eea380a387a Mon Sep 17 00:00:00 2001 From: Johnathan Corgan Date: Fri, 19 Aug 2011 19:05:05 -0700 Subject: Revert "gr-uhd: post received async messages to user supplied msg queue" This reverts commit 25b1550dba377b6dc86bee3e6f269a721efee655. --- gr-uhd/lib/gr_uhd_usrp_source.cc | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) (limited to 'gr-uhd/lib') diff --git a/gr-uhd/lib/gr_uhd_usrp_source.cc b/gr-uhd/lib/gr_uhd_usrp_source.cc index 2987d528c..669f890ea 100644 --- a/gr-uhd/lib/gr_uhd_usrp_source.cc +++ b/gr-uhd/lib/gr_uhd_usrp_source.cc @@ -33,8 +33,7 @@ public: uhd_usrp_source_impl( const uhd::device_addr_t &device_addr, const uhd::io_type_t &io_type, - size_t num_channels, - gr_msg_queue_sptr async_queue + size_t num_channels ): gr_sync_block( "gr uhd usrp source", @@ -44,8 +43,7 @@ public: _type(io_type), _nchan(num_channels), _stream_now(_nchan == 1), - _tmp_buffs(_nchan), - _async_queue(async_queue) + _tmp_buffs(_nchan) { _dev = uhd::usrp::multi_usrp::make(device_addr); } @@ -224,15 +222,6 @@ public: return num_samps; } - // Scan queue and post async events - while (_dev->get_device()->recv_async_msg(_asyncdata, 0.0)) { - if (_async_queue) { - gr_message_sptr m = gr_make_message(0, 0.0, 0.0, sizeof(_asyncdata)); - memcpy(m->msg(), &_asyncdata, sizeof(_asyncdata)); - _async_queue->insert_tail(m); - } - } - return num_samps; } @@ -258,8 +247,6 @@ private: bool _stream_now; gr_vector_void_star _tmp_buffs; uhd::rx_metadata_t _metadata; - uhd::async_metadata_t _asyncdata; - gr_msg_queue_sptr _async_queue; }; @@ -269,10 +256,9 @@ private: boost::shared_ptr uhd_make_usrp_source( const uhd::device_addr_t &device_addr, const uhd::io_type_t &io_type, - size_t num_channels, - gr_msg_queue_sptr async_queue + size_t num_channels ){ return boost::shared_ptr( - new uhd_usrp_source_impl(device_addr, io_type, num_channels, async_queue) + new uhd_usrp_source_impl(device_addr, io_type, num_channels) ); } -- cgit