From 0303f1ed558b21e40f80c388b096432b4bf6e883 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Thu, 26 Apr 2018 09:30:48 -0700 Subject: lib: Purge all references to boost::this_thread::sleep() Replace with std::this_thread::sleep_for(). --- host/lib/types/serial.cpp | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'host/lib/types') diff --git a/host/lib/types/serial.cpp b/host/lib/types/serial.cpp index 381bb2181..24da51e7f 100644 --- a/host/lib/types/serial.cpp +++ b/host/lib/types/serial.cpp @@ -6,8 +6,9 @@ // #include -#include //for sleeping #include +#include +#include using namespace uhd; @@ -43,7 +44,7 @@ void i2c_iface::write_eeprom( //write a byte at a time, its easy that way byte_vector_t cmd = boost::assign::list_of(offset+i)(bytes[i]); this->write_i2c(addr, cmd); - boost::this_thread::sleep(boost::posix_time::milliseconds(10)); //worst case write + std::this_thread::sleep_for(std::chrono::milliseconds(10)); //worst case write } } @@ -104,7 +105,7 @@ struct eeprom16_impl : i2c_iface uint16_t offset_i = offset+i; byte_vector_t cmd = boost::assign::list_of(offset_i >> 8)(offset_i & 0xff)(bytes[i]); this->write_i2c(addr, cmd); - boost::this_thread::sleep(boost::posix_time::milliseconds(10)); //worst case write + std::this_thread::sleep_for(std::chrono::milliseconds(10)); //worst case write } } }; -- cgit v1.2.3