diff options
Diffstat (limited to 'host/lib/usrp/dboard/rhodium')
-rw-r--r-- | host/lib/usrp/dboard/rhodium/rhodium_bands.cpp | 4 | ||||
-rw-r--r-- | host/lib/usrp/dboard/rhodium/rhodium_constants.hpp | 2 | ||||
-rw-r--r-- | host/lib/usrp/dboard/rhodium/rhodium_cpld_ctrl.cpp | 4 |
3 files changed, 4 insertions, 6 deletions
diff --git a/host/lib/usrp/dboard/rhodium/rhodium_bands.cpp b/host/lib/usrp/dboard/rhodium/rhodium_bands.cpp index 73f1bbe0c..6c16a7d7f 100644 --- a/host/lib/usrp/dboard/rhodium/rhodium_bands.cpp +++ b/host/lib/usrp/dboard/rhodium/rhodium_bands.cpp @@ -69,7 +69,7 @@ constexpr double RHODIUM_TX_BAND7_MIN_FREQ = 4100e6; rhodium_radio_control_impl::rx_band rhodium_radio_control_impl::_map_freq_to_rx_band( const double freq) { - auto freq_compare = fp_compare_epsilon<double>(freq, RHODIUM_FREQ_COMPARE_EPSILON); + const auto freq_compare = freq_compare_epsilon(freq); if (freq_compare < RHODIUM_RX_BAND0_MIN_FREQ) { return rx_band::RX_BAND_INVALID; @@ -97,7 +97,7 @@ rhodium_radio_control_impl::rx_band rhodium_radio_control_impl::_map_freq_to_rx_ rhodium_radio_control_impl::tx_band rhodium_radio_control_impl::_map_freq_to_tx_band( const double freq) { - auto freq_compare = fp_compare_epsilon<double>(freq, RHODIUM_FREQ_COMPARE_EPSILON); + const auto freq_compare = freq_compare_epsilon(freq); if (freq_compare < RHODIUM_TX_BAND0_MIN_FREQ) { return tx_band::TX_BAND_INVALID; diff --git a/host/lib/usrp/dboard/rhodium/rhodium_constants.hpp b/host/lib/usrp/dboard/rhodium/rhodium_constants.hpp index cc6a70dc3..7043c50af 100644 --- a/host/lib/usrp/dboard/rhodium/rhodium_constants.hpp +++ b/host/lib/usrp/dboard/rhodium/rhodium_constants.hpp @@ -12,8 +12,6 @@ #include <string> #include <vector> -static constexpr double RHODIUM_FREQ_COMPARE_EPSILON = 1e-5; - static constexpr size_t NUM_RHODIUM_RADIO_RATES = 3; static constexpr std::array<double, NUM_RHODIUM_RADIO_RATES> RHODIUM_RADIO_RATES = { diff --git a/host/lib/usrp/dboard/rhodium/rhodium_cpld_ctrl.cpp b/host/lib/usrp/dboard/rhodium/rhodium_cpld_ctrl.cpp index b95f03983..099b5d132 100644 --- a/host/lib/usrp/dboard/rhodium/rhodium_cpld_ctrl.cpp +++ b/host/lib/usrp/dboard/rhodium/rhodium_cpld_ctrl.cpp @@ -263,7 +263,7 @@ void rhodium_cpld_ctrl::set_rx_lo_path(const double freq, const bool defer_commi UHD_LOG_TRACE("RH_CPLD", "Configuring RX LO filter and settings. freq=" << freq); std::lock_guard<std::mutex> l(_set_mutex); - auto freq_compare = fp_compare_epsilon<double>(freq, RHODIUM_FREQ_COMPARE_EPSILON); + const auto freq_compare = freq_compare_epsilon(freq); if (freq_compare < RX_DEMOD_ADJ_1500OHM_THRESHOLD) { _regs.rx_demod_adj = @@ -296,7 +296,7 @@ void rhodium_cpld_ctrl::set_tx_lo_path(const double freq, const bool defer_commi UHD_LOG_TRACE("RH_CPLD", "Configuring TX LO filter and settings. freq=" << freq); std::lock_guard<std::mutex> l(_set_mutex); - auto freq_compare = fp_compare_epsilon<double>(freq, RHODIUM_FREQ_COMPARE_EPSILON); + const auto freq_compare = freq_compare_epsilon(freq); if (freq_compare < RHODIUM_LO_0_9_GHZ_LPF_THRESHOLD_FREQ) { _regs.tx_lo_filter_sel = |