From 3e4f64188bec333d8884a3849ec2377165b0017c Mon Sep 17 00:00:00 2001 From: Josh Blum Date: Fri, 11 Nov 2011 12:28:08 -0800 Subject: uhd: lots of tweaks for calibration utility --- host/lib/usrp/common/apply_corrections.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'host/lib/usrp/common') diff --git a/host/lib/usrp/common/apply_corrections.cpp b/host/lib/usrp/common/apply_corrections.cpp index 95036e386..6929696bb 100644 --- a/host/lib/usrp/common/apply_corrections.cpp +++ b/host/lib/usrp/common/apply_corrections.cpp @@ -23,6 +23,7 @@ #include #include #include +#include #include #include #include @@ -39,7 +40,7 @@ static bool tx_fe_cal_comp(tx_fe_cal_t a, tx_fe_cal_t b){ return (a.tx_lo_freq < b.tx_lo_freq); } -//TODO should lock access to this +boost::mutex corrections_mutex;; static uhd::dict > cache; static double linear_interp(double x, double x0, double y0, double x1, double y1){ @@ -127,6 +128,7 @@ void uhd::usrp::apply_tx_fe_corrections( const std::string &slot, //name of dboard slot const double tx_lo_freq //actual lo freq ){ + boost::mutex::scoped_lock l(corrections_mutex); try{ _apply_tx_fe_corrections(sub_tree, slot, tx_lo_freq); } -- cgit v1.2.3