From 4e391500b54a22dbaae8692750ec25ae8a97ee6d Mon Sep 17 00:00:00 2001 From: Lane Kolbly Date: Wed, 8 Dec 2021 14:12:28 -0600 Subject: host: Implement nameless_gain_mixin --- .../include/uhdlib/usrp/dboard/zbx/zbx_dboard.hpp | 26 +++++++++------------- 1 file changed, 10 insertions(+), 16 deletions(-) (limited to 'host/lib/include/uhdlib/usrp/dboard/zbx') diff --git a/host/lib/include/uhdlib/usrp/dboard/zbx/zbx_dboard.hpp b/host/lib/include/uhdlib/usrp/dboard/zbx/zbx_dboard.hpp index 6e1d31381..60666fd83 100644 --- a/host/lib/include/uhdlib/usrp/dboard/zbx/zbx_dboard.hpp +++ b/host/lib/include/uhdlib/usrp/dboard/zbx/zbx_dboard.hpp @@ -22,6 +22,7 @@ #include #include #include +#include #include #include #include @@ -43,7 +44,8 @@ const static uint16_t ZBX_PID = 0x4002; */ class zbx_dboard_impl : public uhd::usrp::x400::x400_dboard_iface, - public uhd::rfnoc::rf_control::antenna_radio_control_mixin + public uhd::rfnoc::rf_control::antenna_radio_control_mixin, + public uhd::rfnoc::rf_control::nameless_gain_mixin { public: using sptr = std::shared_ptr; @@ -140,28 +142,20 @@ public: .get(); } - double set_tx_gain(const double gain, const size_t chan) override; + using core_iface::set_tx_gain; + using core_iface::get_tx_gain; + using core_iface::set_rx_gain; + using core_iface::get_rx_gain; + using core_iface::get_tx_gain_range; + using core_iface::get_rx_gain_range; + double set_tx_gain( const double gain, const std::string& name, const size_t chan) override; - double set_rx_gain(const double gain, const size_t chan) override; double set_rx_gain( const double gain, const std::string& name, const size_t chan) override; - double get_rx_gain(const size_t chan) override; - double get_tx_gain(const size_t chan) override; double get_rx_gain(const std::string& name, const size_t chan) override; double get_tx_gain(const std::string& name, const size_t chan) override; - uhd::gain_range_t get_tx_gain_range(const size_t /*chan*/) const override - { - return ZBX_TX_GAIN_RANGE; - } - uhd::gain_range_t get_rx_gain_range(const size_t /*chan*/) const override - { - // FIXME This should return a ZBX_RX_LOW_FREQ_GAIN_RANGE when freq is - // low, but this function is const - return ZBX_RX_GAIN_RANGE; - } - // LO Property Getters std::vector get_tx_lo_names(const size_t /*chan*/) const override { -- cgit v1.2.3