aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/dboard/db_xcvr2450.cpp
diff options
context:
space:
mode:
authorNick Foster <nick@nerdnetworks.org>2010-08-18 14:48:35 -0700
committerNick Foster <nick@nerdnetworks.org>2010-08-18 14:48:35 -0700
commit2da87fa5082c507d324dce743d63667a6d21fd80 (patch)
treeead6d4b7e9af0a403d6079134f9fa992dc52102c /host/lib/usrp/dboard/db_xcvr2450.cpp
parent40faee2e6d87f7364a0c0c2cf310f1483c0331cf (diff)
parent8740197dfed997bb235b73ec649edb803d544326 (diff)
downloaduhd-2da87fa5082c507d324dce743d63667a6d21fd80.tar.gz
uhd-2da87fa5082c507d324dce743d63667a6d21fd80.tar.bz2
uhd-2da87fa5082c507d324dce743d63667a6d21fd80.zip
Merge branch 'master' of ettus.sourcerepo.com:ettus/uhdpriv into usrp2p
Diffstat (limited to 'host/lib/usrp/dboard/db_xcvr2450.cpp')
-rw-r--r--host/lib/usrp/dboard/db_xcvr2450.cpp32
1 files changed, 14 insertions, 18 deletions
diff --git a/host/lib/usrp/dboard/db_xcvr2450.cpp b/host/lib/usrp/dboard/db_xcvr2450.cpp
index 2c94bcd2d..798ff74a3 100644
--- a/host/lib/usrp/dboard/db_xcvr2450.cpp
+++ b/host/lib/usrp/dboard/db_xcvr2450.cpp
@@ -438,8 +438,7 @@ void xcvr2450::set_rx_gain(float gain, const std::string &name){
* RX Get and Set
**********************************************************************/
void xcvr2450::rx_get(const wax::obj &key_, wax::obj &val){
- wax::obj key; std::string name;
- boost::tie(key, name) = extract_named_prop(key_);
+ named_prop_t key = named_prop_t::extract(key_);
//handle the get request conditioned on the key
switch(key.as<subdev_prop_t>()){
@@ -452,13 +451,13 @@ void xcvr2450::rx_get(const wax::obj &key_, wax::obj &val){
return;
case SUBDEV_PROP_GAIN:
- assert_has(_rx_gains.keys(), name, "xcvr rx gain name");
- val = _rx_gains[name];
+ assert_has(_rx_gains.keys(), key.name, "xcvr rx gain name");
+ val = _rx_gains[key.name];
return;
case SUBDEV_PROP_GAIN_RANGE:
- assert_has(xcvr_rx_gain_ranges.keys(), name, "xcvr rx gain name");
- val = xcvr_rx_gain_ranges[name];
+ assert_has(xcvr_rx_gain_ranges.keys(), key.name, "xcvr rx gain name");
+ val = xcvr_rx_gain_ranges[key.name];
return;
case SUBDEV_PROP_GAIN_NAMES:
@@ -502,8 +501,7 @@ void xcvr2450::rx_get(const wax::obj &key_, wax::obj &val){
}
void xcvr2450::rx_set(const wax::obj &key_, const wax::obj &val){
- wax::obj key; std::string name;
- boost::tie(key, name) = extract_named_prop(key_);
+ named_prop_t key = named_prop_t::extract(key_);
//handle the get request conditioned on the key
switch(key.as<subdev_prop_t>()){
@@ -513,7 +511,7 @@ void xcvr2450::rx_set(const wax::obj &key_, const wax::obj &val){
return;
case SUBDEV_PROP_GAIN:
- this->set_rx_gain(val.as<float>(), name);
+ this->set_rx_gain(val.as<float>(), key.name);
return;
case SUBDEV_PROP_ANTENNA:
@@ -528,8 +526,7 @@ void xcvr2450::rx_set(const wax::obj &key_, const wax::obj &val){
* TX Get and Set
**********************************************************************/
void xcvr2450::tx_get(const wax::obj &key_, wax::obj &val){
- wax::obj key; std::string name;
- boost::tie(key, name) = extract_named_prop(key_);
+ named_prop_t key = named_prop_t::extract(key_);
//handle the get request conditioned on the key
switch(key.as<subdev_prop_t>()){
@@ -542,13 +539,13 @@ void xcvr2450::tx_get(const wax::obj &key_, wax::obj &val){
return;
case SUBDEV_PROP_GAIN:
- assert_has(_tx_gains.keys(), name, "xcvr tx gain name");
- val = _tx_gains[name];
+ assert_has(_tx_gains.keys(), key.name, "xcvr tx gain name");
+ val = _tx_gains[key.name];
return;
case SUBDEV_PROP_GAIN_RANGE:
- assert_has(xcvr_tx_gain_ranges.keys(), name, "xcvr tx gain name");
- val = xcvr_tx_gain_ranges[name];
+ assert_has(xcvr_tx_gain_ranges.keys(), key.name, "xcvr tx gain name");
+ val = xcvr_tx_gain_ranges[key.name];
return;
case SUBDEV_PROP_GAIN_NAMES:
@@ -588,8 +585,7 @@ void xcvr2450::tx_get(const wax::obj &key_, wax::obj &val){
}
void xcvr2450::tx_set(const wax::obj &key_, const wax::obj &val){
- wax::obj key; std::string name;
- boost::tie(key, name) = extract_named_prop(key_);
+ named_prop_t key = named_prop_t::extract(key_);
//handle the get request conditioned on the key
switch(key.as<subdev_prop_t>()){
@@ -599,7 +595,7 @@ void xcvr2450::tx_set(const wax::obj &key_, const wax::obj &val){
return;
case SUBDEV_PROP_GAIN:
- this->set_tx_gain(val.as<float>(), name);
+ this->set_tx_gain(val.as<float>(), key.name);
return;
case SUBDEV_PROP_ANTENNA: