summaryrefslogtreecommitdiffstats
path: root/host
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-06-02 14:49:32 -0700
committerJosh Blum <josh@joshknows.com>2010-06-02 14:49:32 -0700
commit92fd3a514b6808e7b94f172c75afb2026b849fce (patch)
tree0655ace6b23980e3aebe60500d1955f2f0d16701 /host
parent906b93b28c59b3b704d47c617eabd1b4448fc4e5 (diff)
downloaduhd-92fd3a514b6808e7b94f172c75afb2026b849fce.tar.gz
uhd-92fd3a514b6808e7b94f172c75afb2026b849fce.tar.bz2
uhd-92fd3a514b6808e7b94f172c75afb2026b849fce.zip
disable boost thread interrupt when doing pop with timed wait, fixed error on exit
Diffstat (limited to 'host')
-rw-r--r--host/lib/usrp/usrp2/io_impl.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/host/lib/usrp/usrp2/io_impl.cpp b/host/lib/usrp/usrp2/io_impl.cpp
index efd64d4ab..43d6e814a 100644
--- a/host/lib/usrp/usrp2/io_impl.cpp
+++ b/host/lib/usrp/usrp2/io_impl.cpp
@@ -72,9 +72,9 @@ usrp2_impl::io_impl::~io_impl(void){
managed_recv_buffer::sptr usrp2_impl::io_impl::get_recv_buff(void){
managed_recv_buffer::sptr buff;
+ boost::this_thread::disable_interruption di; //disable because the wait can throw
recv_pirate_booty->pop_with_timed_wait(buff, boost::posix_time::milliseconds(100));
- //timeout means a null sptr...
- return buff;
+ return buff; //a timeout means that we return a null sptr...
}
void usrp2_impl::io_impl::recv_pirate_loop(zero_copy_if::sptr zc_if){
@@ -119,6 +119,8 @@ void usrp2_impl::io_init(void){
_iface->poke32(FR_RX_CTRL_VRT_STREAM_ID, 0);
_iface->poke32(FR_RX_CTRL_VRT_TRAILER, 0);
+ std::cout << "TX samples per packet: " << get_max_send_samps_per_packet() << std::endl;
+
//create new io impl
_io_impl = new io_impl(_data_transport);
}