diff options
author | Josh Blum <josh@joshknows.com> | 2010-08-15 01:41:35 -0700 |
---|---|---|
committer | Josh Blum <josh@joshknows.com> | 2010-08-15 01:41:35 -0700 |
commit | 6c3d37caa3a47ca534c5e3a110adad0137d5d06d (patch) | |
tree | c3d314679464f7a23f99fde9bbe0dae5adee3a74 /host/lib/usrp/usrp2 | |
parent | f0960e79489c6702d3bd79c40f9e24f2b9e5b42d (diff) | |
download | uhd-6c3d37caa3a47ca534c5e3a110adad0137d5d06d.tar.gz uhd-6c3d37caa3a47ca534c5e3a110adad0137d5d06d.tar.bz2 uhd-6c3d37caa3a47ca534c5e3a110adad0137d5d06d.zip |
usrp: give dboards a name (not a blank string), do automatic selection when not provided
Diffstat (limited to 'host/lib/usrp/usrp2')
-rw-r--r-- | host/lib/usrp/usrp2/mboard_impl.cpp | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/host/lib/usrp/usrp2/mboard_impl.cpp b/host/lib/usrp/usrp2/mboard_impl.cpp index fe3ec6785..533b60bae 100644 --- a/host/lib/usrp/usrp2/mboard_impl.cpp +++ b/host/lib/usrp/usrp2/mboard_impl.cpp @@ -186,6 +186,8 @@ void usrp2_mboard_impl::issue_ddc_stream_cmd(const stream_cmd_t &stream_cmd){ /*********************************************************************** * MBoard Get Properties **********************************************************************/ +static const std::string dboard_name = "0"; + void usrp2_mboard_impl::get(const wax::obj &key_, wax::obj &val){ wax::obj key; std::string name; boost::tie(key, name) = extract_named_prop(key_); @@ -222,21 +224,21 @@ void usrp2_mboard_impl::get(const wax::obj &key_, wax::obj &val){ return; case MBOARD_PROP_RX_DBOARD: - UHD_ASSERT_THROW(name == ""); + UHD_ASSERT_THROW(name == dboard_name); val = _rx_dboard_proxy->get_link(); return; case MBOARD_PROP_RX_DBOARD_NAMES: - val = prop_names_t(1, ""); + val = prop_names_t(1, dboard_name); return; case MBOARD_PROP_TX_DBOARD: - UHD_ASSERT_THROW(name == ""); + UHD_ASSERT_THROW(name == dboard_name); val = _tx_dboard_proxy->get_link(); return; case MBOARD_PROP_TX_DBOARD_NAMES: - val = prop_names_t(1, ""); + val = prop_names_t(1, dboard_name); return; case MBOARD_PROP_RX_DSP: |