diff options
| author | Josh Blum <josh@joshknows.com> | 2010-07-06 16:55:59 -0700 | 
|---|---|---|
| committer | Josh Blum <josh@joshknows.com> | 2010-07-06 16:55:59 -0700 | 
| commit | 7f3c4791f7d19d02b7d4515c763b9c2044e96170 (patch) | |
| tree | 0375d90a0e16d75598b322e7d82c4dd9ce069b57 | |
| parent | e771e157f6d210fe2e66294c60581c5953006ba1 (diff) | |
| download | uhd-7f3c4791f7d19d02b7d4515c763b9c2044e96170.tar.gz uhd-7f3c4791f7d19d02b7d4515c763b9c2044e96170.tar.bz2 uhd-7f3c4791f7d19d02b7d4515c763b9c2044e96170.zip | |
uhd: mimo usrp replace sleep with boost thread sleep (windows fix)
| -rw-r--r-- | host/lib/usrp/mimo_usrp.cpp | 7 | 
1 files changed, 5 insertions, 2 deletions
| diff --git a/host/lib/usrp/mimo_usrp.cpp b/host/lib/usrp/mimo_usrp.cpp index f5441e19d..fd8225074 100644 --- a/host/lib/usrp/mimo_usrp.cpp +++ b/host/lib/usrp/mimo_usrp.cpp @@ -26,6 +26,7 @@  #include <uhd/usrp/dsp_props.hpp>  #include <boost/foreach.hpp>  #include <boost/format.hpp> +#include <boost/thread.hpp>  #include <stdexcept>  #include <iostream> @@ -125,7 +126,8 @@ public:      void set_time_unknown_pps(const time_spec_t &time_spec){          std::cout << "Set time with unknown pps edge:" << std::endl;          std::cout << "  1) set times next pps (race condition)" << std::endl; -        set_time_next_pps(time_spec); sleep(1); +        set_time_next_pps(time_spec); +        boost::this_thread::sleep(boost::posix_time::seconds(1));          std::cout << "  2) catch seconds rollover at pps edge" << std::endl;          time_t last_secs = 0, curr_secs = 0; @@ -135,7 +137,8 @@ public:          }          std::cout << "  3) set times next pps (synchronously)" << std::endl; -        set_time_next_pps(time_spec); sleep(1); +        set_time_next_pps(time_spec); +        boost::this_thread::sleep(boost::posix_time::seconds(1));      }      void issue_stream_cmd(const stream_cmd_t &stream_cmd){ | 
