From 694dc3c7bc6f07b9660aef0c5ace9f6e11f98066 Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Mon, 22 Mar 2010 17:52:08 -0700 Subject: merged usrp2 stuff from u1e branch (without merging the u1e stuff) --- host/lib/usrp/usrp2/usrp2_impl.cpp | 4 +++- host/lib/usrp/usrp2/usrp2_impl.hpp | 2 -- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/host/lib/usrp/usrp2/usrp2_impl.cpp b/host/lib/usrp/usrp2/usrp2_impl.cpp index bdf8cc55b..85d73e83a 100644 --- a/host/lib/usrp/usrp2/usrp2_impl.cpp +++ b/host/lib/usrp/usrp2/usrp2_impl.cpp @@ -26,7 +26,7 @@ using namespace uhd::usrp; using namespace uhd::transport; namespace asio = boost::asio; -STATIC_BLOCK(register_device){ +STATIC_BLOCK(register_usrp2_device){ device::register_device(&usrp2::discover, &usrp2::make); } @@ -36,6 +36,8 @@ STATIC_BLOCK(register_device){ uhd::device_addrs_t usrp2::discover(const device_addr_t &hint){ device_addrs_t usrp2_addrs; + if (not hint.has_key("addr")) return usrp2_addrs; + //create a udp transport to communicate //TODO if an addr is not provided, search all interfaces? std::string ctrl_port = boost::lexical_cast(USRP2_UDP_CTRL_PORT); diff --git a/host/lib/usrp/usrp2/usrp2_impl.hpp b/host/lib/usrp/usrp2/usrp2_impl.hpp index 70420fd49..55ac0b192 100644 --- a/host/lib/usrp/usrp2/usrp2_impl.hpp +++ b/host/lib/usrp/usrp2/usrp2_impl.hpp @@ -86,8 +86,6 @@ private: */ class usrp2_impl : public uhd::device{ public: - typedef boost::shared_ptr sptr; - /*! * Create a new usrp2 impl base. * \param ctrl_transport the udp transport for control -- cgit v1.2.3