aboutsummaryrefslogtreecommitdiffstats
path: root/host/examples/rx_timed_samples.cpp
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-07-07 20:06:24 +0000
committerJosh Blum <josh@joshknows.com>2010-07-07 20:06:24 +0000
commitfe23fc7a0d038102f48be2c70813d06829fb3b61 (patch)
tree843dea1f343dbd4a1de43bed9dbda91daece8f6f /host/examples/rx_timed_samples.cpp
parent7c2e17b549fefb5a667cf77dd7d86ed55f7ebe13 (diff)
parent79c513d0b21127a5a4cfa6a70213630364a281db (diff)
downloaduhd-fe23fc7a0d038102f48be2c70813d06829fb3b61.tar.gz
uhd-fe23fc7a0d038102f48be2c70813d06829fb3b61.tar.bz2
uhd-fe23fc7a0d038102f48be2c70813d06829fb3b61.zip
Merge branch 'master' of ettus.sourcerepo.com:ettus/uhdpriv into usrp_e_wip
Diffstat (limited to 'host/examples/rx_timed_samples.cpp')
-rw-r--r--host/examples/rx_timed_samples.cpp5
1 files changed, 4 insertions, 1 deletions
diff --git a/host/examples/rx_timed_samples.cpp b/host/examples/rx_timed_samples.cpp
index 9ff8772bc..fcf662c4e 100644
--- a/host/examples/rx_timed_samples.cpp
+++ b/host/examples/rx_timed_samples.cpp
@@ -43,6 +43,7 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
("nsamps", po::value<size_t>(&total_num_samps)->default_value(1000), "total number of samples to receive")
("rxrate", po::value<double>(&rx_rate)->default_value(100e6/16), "rate of incoming samples")
("freq", po::value<double>(&freq)->default_value(0), "rf center frequency in Hz")
+ ("dilv", "specify to disable inner-loop verbose")
;
po::variables_map vm;
po::store(po::parse_command_line(argc, argv, desc), vm);
@@ -54,6 +55,8 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
return ~0;
}
+ bool verbose = vm.count("dilv") == 0;
+
//create a usrp device
std::cout << std::endl;
std::cout << boost::format("Creating the usrp device with: %s...") % args << std::endl;
@@ -95,7 +98,7 @@ int UHD_SAFE_MAIN(int argc, char *argv[]){
}
if (num_rx_samps == 0) continue; //wait for packets with contents
- std::cout << boost::format("Got packet: %u samples, %u full secs, %f frac secs")
+ if(verbose) std::cout << boost::format("Got packet: %u samples, %u full secs, %f frac secs")
% num_rx_samps % md.time_spec.get_full_secs() % md.time_spec.get_frac_secs() << std::endl;
num_acc_samps += num_rx_samps;