aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2011-08-22 03:59:57 +0000
committerJosh Blum <josh@joshknows.com>2011-08-31 18:44:34 -0700
commit26bfe6d54a4ecd82f4efcf6cc1c6f69d216adb1c (patch)
tree701770e2acc8941eaabf8aa713edf5d4c711a704 /host/lib
parent0fa5508ccca415c82fa005312f42060e5ed3c2bf (diff)
downloaduhd-26bfe6d54a4ecd82f4efcf6cc1c6f69d216adb1c.tar.gz
uhd-26bfe6d54a4ecd82f4efcf6cc1c6f69d216adb1c.tar.bz2
uhd-26bfe6d54a4ecd82f4efcf6cc1c6f69d216adb1c.zip
e100: changed compat numbers, and tweaks
Diffstat (limited to 'host/lib')
-rw-r--r--host/lib/usrp/e100/e100_impl.cpp4
-rw-r--r--host/lib/usrp/e100/e100_impl.hpp6
-rw-r--r--host/lib/usrp/e100/include/linux/usrp_e.h2
3 files changed, 7 insertions, 5 deletions
diff --git a/host/lib/usrp/e100/e100_impl.cpp b/host/lib/usrp/e100/e100_impl.cpp
index 0defb2973..d3d9e32e6 100644
--- a/host/lib/usrp/e100/e100_impl.cpp
+++ b/host/lib/usrp/e100/e100_impl.cpp
@@ -232,7 +232,7 @@ e100_impl::e100_impl(const uhd::device_addr_t &device_addr){
_fpga_ctrl, E100_REG_SR_ADDR(UE_SR_RX_DSP1), E100_REG_SR_ADDR(UE_SR_RX_CTRL1), E100_RX_SID_BASE + 1
));
for (size_t dspno = 0; dspno < _rx_dsps.size(); dspno++){
- _rx_dsps[dspno]->set_link_rate(E100_LINK_RATE_BPS);
+ _rx_dsps[dspno]->set_link_rate(E100_RX_LINK_RATE_BPS);
_tree->access<double>(mb_path / "tick_rate")
.subscribe(boost::bind(&rx_dsp_core_200::set_tick_rate, _rx_dsps[dspno], _1));
fs_path rx_dsp_path = mb_path / str(boost::format("rx_dsps/%u") % dspno);
@@ -253,7 +253,7 @@ e100_impl::e100_impl(const uhd::device_addr_t &device_addr){
_tx_dsp = tx_dsp_core_200::make(
_fpga_ctrl, E100_REG_SR_ADDR(UE_SR_TX_DSP), E100_REG_SR_ADDR(UE_SR_TX_CTRL), E100_TX_ASYNC_SID
);
- _tx_dsp->set_link_rate(E100_LINK_RATE_BPS);
+ _tx_dsp->set_link_rate(E100_TX_LINK_RATE_BPS);
_tree->access<double>(mb_path / "tick_rate")
.subscribe(boost::bind(&tx_dsp_core_200::set_tick_rate, _tx_dsp, _1));
_tree->create<double>(mb_path / "tx_dsps/0/rate/value")
diff --git a/host/lib/usrp/e100/e100_impl.hpp b/host/lib/usrp/e100/e100_impl.hpp
index 76af828d0..1800e15b5 100644
--- a/host/lib/usrp/e100/e100_impl.hpp
+++ b/host/lib/usrp/e100/e100_impl.hpp
@@ -42,10 +42,12 @@
uhd::transport::zero_copy_if::sptr e100_make_mmap_zero_copy(e100_ctrl::sptr iface);
-static const double E100_LINK_RATE_BPS = 166e6/4*2; //gpmc_clock_rate/clk_div*bytes_per_transaction
+// = gpmc_clock_rate/clk_div/cycles_per_transaction*bytes_per_transaction
+static const double E100_RX_LINK_RATE_BPS = 166e6/3/2*2;
+static const double E100_TX_LINK_RATE_BPS = 166e6/3/1*2;
static const std::string E100_I2C_DEV_NODE = "/dev/i2c-3";
static const std::string E100_FPGA_FILE_NAME = "usrp_e100_fpga_v2.bin";
-static const boost::uint16_t E100_FPGA_COMPAT_NUM = 0x05;
+static const boost::uint16_t E100_FPGA_COMPAT_NUM = 0x06;
static const boost::uint32_t E100_RX_SID_BASE = 2;
static const boost::uint32_t E100_TX_ASYNC_SID = 1;
static const double E100_DEFAULT_CLOCK_RATE = 64e6;
diff --git a/host/lib/usrp/e100/include/linux/usrp_e.h b/host/lib/usrp/e100/include/linux/usrp_e.h
index 2c4aa2ac1..37e9ee31a 100644
--- a/host/lib/usrp/e100/include/linux/usrp_e.h
+++ b/host/lib/usrp/e100/include/linux/usrp_e.h
@@ -36,7 +36,7 @@ struct usrp_e_ctl32 {
#define USRP_E_GET_RB_INFO _IOR(USRP_E_IOC_MAGIC, 0x27, struct usrp_e_ring_buffer_size_t)
#define USRP_E_GET_COMPAT_NUMBER _IO(USRP_E_IOC_MAGIC, 0x28)
-#define USRP_E_COMPAT_NUMBER 2
+#define USRP_E_COMPAT_NUMBER 3
/* Flag defines */
#define RB_USER (1<<0)