aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/common
diff options
context:
space:
mode:
authorBalint Seeber <balint@ettus.com>2014-02-13 15:26:54 -0800
committerBalint Seeber <balint@ettus.com>2014-02-14 15:40:30 -0800
commit383128e2c9c3539e1bc8de7d13a894f50fc9719a (patch)
tree9b2a5c5603e2c781bcae6e3edbd4d8408cae951a /host/lib/usrp/common
parent7fef199d194c9a63b3312845979fa353f90f4d23 (diff)
downloaduhd-383128e2c9c3539e1bc8de7d13a894f50fc9719a.tar.gz
uhd-383128e2c9c3539e1bc8de7d13a894f50fc9719a.tar.bz2
uhd-383128e2c9c3539e1bc8de7d13a894f50fc9719a.zip
b200: throw exception when master clock rate (tick rate) is requested to be > max for certain # of channels (i.e. restrict to 30.72MHz for MIMO)
Also includes sscanf type fix in b200_impl and longer timeout for AD9361 read
Diffstat (limited to 'host/lib/usrp/common')
-rw-r--r--host/lib/usrp/common/ad9361_ctrl.hpp7
1 files changed, 6 insertions, 1 deletions
diff --git a/host/lib/usrp/common/ad9361_ctrl.hpp b/host/lib/usrp/common/ad9361_ctrl.hpp
index fd8012764..7a13d1439 100644
--- a/host/lib/usrp/common/ad9361_ctrl.hpp
+++ b/host/lib/usrp/common/ad9361_ctrl.hpp
@@ -28,6 +28,11 @@
#include <string>
+static const double AD9361_CLOCK_RATE_MAX = 61.44e6;
+static const double AD9361_1_CHAN_CLOCK_RATE_MAX = AD9361_CLOCK_RATE_MAX;
+static const double AD9361_2_CHAN_CLOCK_RATE_MAX = (AD9361_1_CHAN_CLOCK_RATE_MAX / 2);
+
+
struct ad9361_ctrl_iface_type
{
virtual void ad9361_transact(const unsigned char in_buff[64], unsigned char out_buff[64]) = 0;
@@ -100,7 +105,7 @@ public:
static uhd::meta_range_t get_clock_rate_range(void)
{
//return uhd::meta_range_t(220e3, 61.44e6);
- return uhd::meta_range_t(5e6, 61.44e6); //5 MHz DCM low end
+ return uhd::meta_range_t(5e6, AD9361_CLOCK_RATE_MAX); //5 MHz DCM low end
}
//! set the filter bandwidth for the frontend