aboutsummaryrefslogtreecommitdiffstats
path: root/host/utils
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-03-30 15:11:23 -0700
committerJosh Blum <josh@joshknows.com>2010-03-30 15:11:23 -0700
commit281307833c8275031bd2469e6aef3f472490749a (patch)
tree2ffe095d5f4a741c65cfee08f52adc43e5cf148a /host/utils
parentf9be69cae7c0fd9bca8b310ff79dd6aad958dc2b (diff)
downloaduhd-281307833c8275031bd2469e6aef3f472490749a.tar.gz
uhd-281307833c8275031bd2469e6aef3f472490749a.tar.bz2
uhd-281307833c8275031bd2469e6aef3f472490749a.zip
use find to discover devices
Diffstat (limited to 'host/utils')
-rw-r--r--host/utils/CMakeLists.txt6
-rw-r--r--host/utils/uhd_find_devices.cpp (renamed from host/utils/discover_usrps.cpp)10
2 files changed, 8 insertions, 8 deletions
diff --git a/host/utils/CMakeLists.txt b/host/utils/CMakeLists.txt
index 1fb132937..aa01d1e35 100644
--- a/host/utils/CMakeLists.txt
+++ b/host/utils/CMakeLists.txt
@@ -15,9 +15,9 @@
# along with this program. If not, see <http://www.gnu.org/licenses/>.
#
-ADD_EXECUTABLE(discover_usrps discover_usrps.cpp)
-TARGET_LINK_LIBRARIES(discover_usrps uhd)
-INSTALL(TARGETS discover_usrps RUNTIME DESTINATION ${RUNTIME_DIR})
+ADD_EXECUTABLE(uhd_find_devices uhd_find_devices.cpp)
+TARGET_LINK_LIBRARIES(uhd_find_devices uhd)
+INSTALL(TARGETS uhd_find_devices RUNTIME DESTINATION ${RUNTIME_DIR})
ADD_EXECUTABLE(usrp2_burner usrp2_burner.cpp)
TARGET_LINK_LIBRARIES(usrp2_burner uhd)
diff --git a/host/utils/discover_usrps.cpp b/host/utils/uhd_find_devices.cpp
index 72c5b8822..b328216d0 100644
--- a/host/utils/discover_usrps.cpp
+++ b/host/utils/uhd_find_devices.cpp
@@ -34,11 +34,11 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
po::variables_map vm;
po::store(po::parse_command_line(argc, argv, desc), vm);
- po::notify(vm);
+ po::notify(vm);
//print the help message
if (vm.count("help")){
- std::cout << boost::format("Discover USRPs %s") % desc << std::endl;
+ std::cout << boost::format("UHD Find Devices %s") % desc << std::endl;
return ~0;
}
@@ -52,16 +52,16 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
}
//discover the usrps and print the results
- uhd::device_addrs_t device_addrs = uhd::device::discover(device_addr);
+ uhd::device_addrs_t device_addrs = uhd::device::find(device_addr);
if (device_addrs.size() == 0){
- std::cerr << "No USRP Devices Found" << std::endl;
+ std::cerr << "No UHD Devices Found" << std::endl;
return ~0;
}
for (size_t i = 0; i < device_addrs.size(); i++){
std::cout << "--------------------------------------------------" << std::endl;
- std::cout << "-- USRP Device " << i << std::endl;
+ std::cout << "-- UHD Device " << i << std::endl;
std::cout << "--------------------------------------------------" << std::endl;
std::cout << device_addrs[i].to_string() << std::endl << std::endl;
uhd::device::make(device_addrs[i]); //test make