aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp')
-rw-r--r--host/lib/usrp/dboard/db_ubx.cpp11
1 files changed, 7 insertions, 4 deletions
diff --git a/host/lib/usrp/dboard/db_ubx.cpp b/host/lib/usrp/dboard/db_ubx.cpp
index 7b153d170..0e85cf188 100644
--- a/host/lib/usrp/dboard/db_ubx.cpp
+++ b/host/lib/usrp/dboard/db_ubx.cpp
@@ -474,7 +474,7 @@ public:
get_tx_subtree()->create<std::vector<std::string> >("antenna/options")
.set(ubx_tx_antennas);
get_tx_subtree()->create<std::string>("antenna/value")
- .add_coerced_subscriber(boost::bind(&ubx_xcvr::set_tx_ant, this, _1))
+ .set_coercer(boost::bind(&ubx_xcvr::set_tx_ant, this, _1))
.set(ubx_tx_antennas.at(0));
get_tx_subtree()->create<std::string>("connection")
.set("QI");
@@ -511,7 +511,7 @@ public:
get_rx_subtree()->create<std::vector<std::string> >("antenna/options")
.set(ubx_rx_antennas);
get_rx_subtree()->create<std::string>("antenna/value")
- .add_coerced_subscriber(boost::bind(&ubx_xcvr::set_rx_ant, this, _1)).set("RX2");
+ .set_coercer(boost::bind(&ubx_xcvr::set_rx_ant, this, _1)).set("RX2");
get_rx_subtree()->create<std::string>("connection")
.set("IQ");
get_rx_subtree()->create<bool>("enabled")
@@ -735,16 +735,17 @@ private:
return sensor_value_t("Unknown", false, "locked", "unlocked");
}
- void set_tx_ant(const std::string &ant)
+ std::string set_tx_ant(const std::string &ant)
{
//validate input
assert_has(ubx_tx_antennas, ant, "ubx tx antenna name");
set_cpld_field(CAL_ENABLE, (ant == "CAL"));
write_cpld_reg();
+ return ant;
}
// Set RX antennas
- void set_rx_ant(const std::string &ant)
+ std::string set_rx_ant(const std::string &ant)
{
boost::mutex::scoped_lock lock(_mutex);
//validate input
@@ -767,6 +768,8 @@ private:
}
write_gpio();
write_cpld_reg();
+
+ return ant;
}
/***********************************************************************