diff options
author | Josh Blum <josh@joshknows.com> | 2010-05-03 01:20:11 -0700 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2010-05-03 01:20:11 -0700 |
commit | 4d5df2376b204afb724684d0d864ce0d93fe83fb (patch) | |
tree | c0552615c8f51eb89c3214c8fed7105387264cae /host/lib/usrp/dboard | |
parent | fd0d9b7dcca13b4d8a4e1912682f58eb6b6ab634 (diff) | |
download | uhd-4d5df2376b204afb724684d0d864ce0d93fe83fb.tar.gz uhd-4d5df2376b204afb724684d0d864ce0d93fe83fb.tar.bz2 uhd-4d5df2376b204afb724684d0d864ce0d93fe83fb.zip |
Expanded the dboard id API to create dboard id types from strings and ints.
And created utility functions to go between representations.
Created to_pp_string for pretty print strings for dboard ids and device addrs.
Minor changes to the various classes that call these utilities.
Diffstat (limited to 'host/lib/usrp/dboard')
-rw-r--r-- | host/lib/usrp/dboard/db_basic_and_lf.cpp | 4 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_rfx.cpp | 4 | ||||
-rw-r--r-- | host/lib/usrp/dboard/db_xcvr2450.cpp | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/host/lib/usrp/dboard/db_basic_and_lf.cpp b/host/lib/usrp/dboard/db_basic_and_lf.cpp index ebe3b2616..23ac98872 100644 --- a/host/lib/usrp/dboard/db_basic_and_lf.cpp +++ b/host/lib/usrp/dboard/db_basic_and_lf.cpp @@ -101,7 +101,7 @@ void basic_rx::rx_get(const wax::obj &key_, wax::obj &val){ switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: val = std::string(str(boost::format("%s - %s") - % dboard_id::to_string(get_rx_id()) + % get_rx_id().to_pp_string() % get_subdev_name() )); return; @@ -202,7 +202,7 @@ void basic_tx::tx_get(const wax::obj &key_, wax::obj &val){ //handle the get request conditioned on the key switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: - val = dboard_id::to_string(get_tx_id()); + val = get_tx_id().to_pp_string(); return; case SUBDEV_PROP_OTHERS: diff --git a/host/lib/usrp/dboard/db_rfx.cpp b/host/lib/usrp/dboard/db_rfx.cpp index 07159cd09..bbc9716b1 100644 --- a/host/lib/usrp/dboard/db_rfx.cpp +++ b/host/lib/usrp/dboard/db_rfx.cpp @@ -351,7 +351,7 @@ void rfx_xcvr::rx_get(const wax::obj &key_, wax::obj &val){ //handle the get request conditioned on the key switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: - val = dboard_id::to_string(get_rx_id()); + val = get_rx_id().to_pp_string(); return; case SUBDEV_PROP_OTHERS: @@ -448,7 +448,7 @@ void rfx_xcvr::tx_get(const wax::obj &key_, wax::obj &val){ //handle the get request conditioned on the key switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: - val = dboard_id::to_string(get_tx_id()); + val = get_tx_id().to_pp_string(); return; case SUBDEV_PROP_OTHERS: diff --git a/host/lib/usrp/dboard/db_xcvr2450.cpp b/host/lib/usrp/dboard/db_xcvr2450.cpp index 9b0fcbc5c..3bf866fc8 100644 --- a/host/lib/usrp/dboard/db_xcvr2450.cpp +++ b/host/lib/usrp/dboard/db_xcvr2450.cpp @@ -444,7 +444,7 @@ void xcvr2450::rx_get(const wax::obj &key_, wax::obj &val){ //handle the get request conditioned on the key switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: - val = dboard_id::to_string(get_rx_id()); + val = get_rx_id().to_pp_string(); return; case SUBDEV_PROP_OTHERS: @@ -542,7 +542,7 @@ void xcvr2450::tx_get(const wax::obj &key_, wax::obj &val){ //handle the get request conditioned on the key switch(key.as<subdev_prop_t>()){ case SUBDEV_PROP_NAME: - val = dboard_id::to_string(get_tx_id()); + val = get_tx_id().to_pp_string(); return; case SUBDEV_PROP_OTHERS: |