aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp')
-rw-r--r--host/lib/usrp/usrp_e/dboard_iface.cpp5
-rw-r--r--host/lib/usrp/usrp_e/dboard_impl.cpp17
2 files changed, 21 insertions, 1 deletions
diff --git a/host/lib/usrp/usrp_e/dboard_iface.cpp b/host/lib/usrp/usrp_e/dboard_iface.cpp
index a9831ebc4..c9efd0c9e 100644
--- a/host/lib/usrp/usrp_e/dboard_iface.cpp
+++ b/host/lib/usrp/usrp_e/dboard_iface.cpp
@@ -44,6 +44,9 @@ public:
//init the clock rate shadows
this->set_clock_rate(UNIT_RX, _clock->get_fpga_clock_rate());
this->set_clock_rate(UNIT_TX, _clock->get_fpga_clock_rate());
+
+ _iface->poke16(UE_REG_GPIO_RX_DBG, 0);
+ _iface->poke16(UE_REG_GPIO_TX_DBG, 0);
}
~usrp_e_dboard_iface(void){
@@ -165,8 +168,8 @@ boost::uint16_t usrp_e_dboard_iface::read_gpio(unit_t unit){
switch(unit){
case UNIT_RX: return _iface->peek16(UE_REG_GPIO_RX_IO);
case UNIT_TX: return _iface->peek16(UE_REG_GPIO_TX_IO);
+ default: UHD_THROW_INVALID_CODE_PATH();
}
- UHD_ASSERT_THROW(false);
}
void usrp_e_dboard_iface::set_atr_reg(unit_t unit, atr_reg_t atr, boost::uint16_t value){
diff --git a/host/lib/usrp/usrp_e/dboard_impl.cpp b/host/lib/usrp/usrp_e/dboard_impl.cpp
index 79ff54c9d..d4a27cb72 100644
--- a/host/lib/usrp/usrp_e/dboard_impl.cpp
+++ b/host/lib/usrp/usrp_e/dboard_impl.cpp
@@ -20,6 +20,7 @@
#include <uhd/utils/assert.hpp>
#include <uhd/usrp/dboard_props.hpp>
#include <uhd/usrp/subdev_props.hpp>
+#include <uhd/usrp/misc_utils.hpp>
#include <boost/bind.hpp>
#include <iostream>
@@ -84,6 +85,14 @@ void usrp_e_impl::rx_dboard_get(const wax::obj &key_, wax::obj &val){
val = _rx_codec_proxy->get_link();
return;
+ case DBOARD_PROP_GAIN_GROUP:
+ val = make_gain_group(
+ _dboard_manager->get_rx_subdev(key.name),
+ _rx_codec_proxy->get_link(),
+ GAIN_GROUP_POLICY_RX
+ );
+ return;
+
default: UHD_THROW_PROP_GET_ERROR();
}
}
@@ -134,6 +143,14 @@ void usrp_e_impl::tx_dboard_get(const wax::obj &key_, wax::obj &val){
val = _tx_codec_proxy->get_link();
return;
+ case DBOARD_PROP_GAIN_GROUP:
+ val = make_gain_group(
+ _dboard_manager->get_tx_subdev(key.name),
+ _tx_codec_proxy->get_link(),
+ GAIN_GROUP_POLICY_TX
+ );
+ return;
+
default: UHD_THROW_PROP_GET_ERROR();
}
}