From 8aeb34d7699d95190674adceb5769dc9dc56b555 Mon Sep 17 00:00:00 2001 From: Martin Braun Date: Tue, 19 May 2020 13:07:52 -0700 Subject: fixup! lib: Add power cal manager - The tracking mode was not set to power when calling set_power() - The data consistency check had an inverted logic, thus always printing a warning --- host/lib/usrp/common/pwr_cal_mgr.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'host/lib/usrp/common') diff --git a/host/lib/usrp/common/pwr_cal_mgr.cpp b/host/lib/usrp/common/pwr_cal_mgr.cpp index 1fdd15645..0c30be7ad 100644 --- a/host/lib/usrp/common/pwr_cal_mgr.cpp +++ b/host/lib/usrp/common/pwr_cal_mgr.cpp @@ -123,6 +123,7 @@ public: << " dB, Actual total power: " << coerced_total_power << " dBm -> actual total gain: " << coerced_total_gain << " dB"); + _mode = tracking_mode::TRACK_POWER; // We directly scale the power with the residual gain return coerced_total_power; } @@ -221,7 +222,7 @@ public: if (std::any_of(_cal_data.cbegin(), _cal_data.cend(), [](const cal_data_map_type::value_type& data) { - return bool(data.second); + return !bool(data.second); })) { UHD_LOG_WARNING(_log_id, "Some ports for " << _serial -- cgit v1.2.3