From 4749dc3ea02a9068169023eb4854d574fe508ac3 Mon Sep 17 00:00:00 2001 From: michael-west Date: Wed, 10 Aug 2016 15:31:25 -0700 Subject: X300: Change so radio check so it only makes sure needed frontends are enabled (prevent function from disabling frontends) --- host/lib/usrp/x300/x300_radio_ctrl_impl.cpp | 18 ++++++++++++------ 1 file changed, 12 insertions(+), 6 deletions(-) (limited to 'host') diff --git a/host/lib/usrp/x300/x300_radio_ctrl_impl.cpp b/host/lib/usrp/x300/x300_radio_ctrl_impl.cpp index 3a129b334..1d268623c 100644 --- a/host/lib/usrp/x300/x300_radio_ctrl_impl.cpp +++ b/host/lib/usrp/x300/x300_radio_ctrl_impl.cpp @@ -863,9 +863,12 @@ bool x300_radio_ctrl_impl::check_radio_config() for (size_t chan = 0; chan < _get_num_radios(); chan++) { if (_tree->exists(rx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled")) { const bool chan_active = _is_streamer_active(RX_DIRECTION, chan); - _tree->access(rx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled") - .set(chan_active) - ; + if (chan_active) + { + _tree->access(rx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled") + .set(chan_active) + ; + } } } @@ -873,9 +876,12 @@ bool x300_radio_ctrl_impl::check_radio_config() for (size_t chan = 0; chan < _get_num_radios(); chan++) { if (_tree->exists(tx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled")) { const bool chan_active = _is_streamer_active(TX_DIRECTION, chan); - _tree->access(tx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled") - .set(chan_active) - ; + if (chan_active) + { + _tree->access(tx_fe_path / _rx_fe_map.at(chan).db_fe_name / "enabled") + .set(chan_active) + ; + } } } -- cgit v1.2.3