aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/include
diff options
context:
space:
mode:
authorMartin Braun <martin.braun@ettus.com>2020-05-12 13:44:05 -0700
committerAaron Rossetto <aaron.rossetto@ni.com>2020-06-10 12:44:10 -0500
commit0af68addaa7d2b2abb362b3b9f941b37b4b692e8 (patch)
treeff706faf7979d90a94d0e6a22a8873dfd6722953 /host/lib/include
parentdac56ff0dcf35c4bf8ecb1e127465f6f726de737 (diff)
downloaduhd-0af68addaa7d2b2abb362b3b9f941b37b4b692e8.tar.gz
uhd-0af68addaa7d2b2abb362b3b9f941b37b4b692e8.tar.bz2
uhd-0af68addaa7d2b2abb362b3b9f941b37b4b692e8.zip
radio_control: Provide default implementations for ref power APIs
The various implementations for the reference power APIs are always the same, assuming the existence of a pwr_cal_mgr object. We therefore store references to power cal managers in radio_control_impl, which radios can choose to populate. The APIs then don't have to be reimplemented in the various radio classes, unless they want to for whatever reason.
Diffstat (limited to 'host/lib/include')
-rw-r--r--host/lib/include/uhdlib/rfnoc/radio_control_impl.hpp8
1 files changed, 8 insertions, 0 deletions
diff --git a/host/lib/include/uhdlib/rfnoc/radio_control_impl.hpp b/host/lib/include/uhdlib/rfnoc/radio_control_impl.hpp
index db723a6f6..956280007 100644
--- a/host/lib/include/uhdlib/rfnoc/radio_control_impl.hpp
+++ b/host/lib/include/uhdlib/rfnoc/radio_control_impl.hpp
@@ -9,6 +9,7 @@
#include <uhd/rfnoc/defaults.hpp>
#include <uhd/rfnoc/multichan_register_iface.hpp>
#include <uhd/rfnoc/radio_control.hpp>
+#include <uhdlib/usrp/common/pwr_cal_mgr.hpp>
#include <unordered_map>
#include <mutex>
@@ -310,6 +311,13 @@ protected:
//! Block-specific register interface
multichan_register_iface _radio_reg_iface;
+ //! Power manager for RX power cal. If the radio doesn't have a power API,
+ // simply leave these empty.
+ std::vector<uhd::usrp::pwr_cal_mgr::sptr> _rx_pwr_mgr;
+ //! Power manager for TX power cal. If the radio doesn't have a power API,
+ // simply leave these empty.
+ std::vector<uhd::usrp::pwr_cal_mgr::sptr> _tx_pwr_mgr;
+
private:
//! Validator for the async messages
//