aboutsummaryrefslogtreecommitdiffstats
path: root/host
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-04-16 15:31:01 -0700
committerJosh Blum <josh@joshknows.com>2010-04-16 15:31:01 -0700
commit632ca4afbbc2e383b956a7abe8e35ee1020c7306 (patch)
tree67eea4606109e6b5d7fb100a80a1d6077374603b /host
parent6db1f998248dfe57dd2186c15fc33593eb194cc5 (diff)
downloaduhd-632ca4afbbc2e383b956a7abe8e35ee1020c7306.tar.gz
uhd-632ca4afbbc2e383b956a7abe8e35ee1020c7306.tar.bz2
uhd-632ca4afbbc2e383b956a7abe8e35ee1020c7306.zip
added automatic ref source enum
Diffstat (limited to 'host')
-rw-r--r--host/include/uhd/types/clock_config.hpp1
-rw-r--r--host/lib/usrp/usrp2/mboard_impl.cpp1
2 files changed, 2 insertions, 0 deletions
diff --git a/host/include/uhd/types/clock_config.hpp b/host/include/uhd/types/clock_config.hpp
index 42d74ad90..9342fbb7b 100644
--- a/host/include/uhd/types/clock_config.hpp
+++ b/host/include/uhd/types/clock_config.hpp
@@ -29,6 +29,7 @@ namespace uhd{
*/
struct UHD_API clock_config_t{
enum ref_source_t {
+ REF_AUTO = 'a', //automatic (device specific)
REF_INT = 'i', //internal reference
REF_SMA = 's', //external sma port
REF_MIMO = 'm' //mimo cable (usrp2 only)
diff --git a/host/lib/usrp/usrp2/mboard_impl.cpp b/host/lib/usrp/usrp2/mboard_impl.cpp
index d7728238c..f94806c9f 100644
--- a/host/lib/usrp/usrp2/mboard_impl.cpp
+++ b/host/lib/usrp/usrp2/mboard_impl.cpp
@@ -100,6 +100,7 @@ void usrp2_impl::update_clock_config(void){
case clock_config_t::REF_INT : _iface->poke32(FR_CLOCK_CONTROL, 0x10); break;
case clock_config_t::REF_SMA : _iface->poke32(FR_CLOCK_CONTROL, 0x1C); break;
case clock_config_t::REF_MIMO: _iface->poke32(FR_CLOCK_CONTROL, 0x15); break;
+ default: throw std::runtime_error("usrp2: unhandled clock configuration reference source");
}
//clock source ref 10mhz