aboutsummaryrefslogtreecommitdiffstats
path: root/host/lib/usrp/dboard/db_wbx_common.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'host/lib/usrp/dboard/db_wbx_common.hpp')
-rw-r--r--host/lib/usrp/dboard/db_wbx_common.hpp20
1 files changed, 16 insertions, 4 deletions
diff --git a/host/lib/usrp/dboard/db_wbx_common.hpp b/host/lib/usrp/dboard/db_wbx_common.hpp
index 6a4224048..0e339e4a3 100644
--- a/host/lib/usrp/dboard/db_wbx_common.hpp
+++ b/host/lib/usrp/dboard/db_wbx_common.hpp
@@ -19,8 +19,13 @@
#define INCLUDED_LIBUHD_USRP_DBOARD_DB_WBX_COMMON_HPP
#include <uhd/types/device_addr.hpp>
+#include "adf435x.hpp"
-#include "../common/adf435x_common.hpp"
+// LO Related
+#define ADF435X_CE (1 << 3)
+#define ADF435X_PDBRF (1 << 2)
+#define ADF435X_MUXOUT (1 << 1) // INPUT!!!
+#define LOCKDET_MASK (1 << 0) // INPUT!!!
// TX IO Pins
#define TX_PUP_5V (1 << 7) // enables 5.0V power supply
@@ -40,6 +45,9 @@
#define TX_ATTN_1 (1 << 1)
#define TX_ATTN_MASK (TX_ATTN_16|TX_ATTN_8|TX_ATTN_4|TX_ATTN_2|TX_ATTN_1) // valid bits of TX Attenuator Control
+#define RX_ATTN_SHIFT 8 //lsb of RX Attenuator Control
+#define RX_ATTN_MASK (63 << RX_ATTN_SHIFT) //valid bits of RX Attenuator Control
+
// Mixer functions
#define TX_MIXER_ENB (TXMOD_EN|ADF435X_PDBRF) // for v3, TXMOD_EN tied to ADF435X_PDBRF rather than separate
#define TX_MIXER_DIS 0
@@ -142,6 +150,10 @@ protected:
property_tree::sptr get_tx_subtree(void){
return self_base->get_tx_subtree();
}
+
+ adf435x_iface::sptr _txlo;
+ adf435x_iface::sptr _rxlo;
+ void write_lo_regs(dboard_iface::unit_t unit, const std::vector<boost::uint32_t> &regs);
};
@@ -153,7 +165,7 @@ protected:
class wbx_version2 : public wbx_versionx {
public:
wbx_version2(wbx_base *_self_wbx_base);
- ~wbx_version2(void);
+ virtual ~wbx_version2(void);
double set_tx_gain(double gain, const std::string &name);
void set_tx_enabled(bool enb);
@@ -168,7 +180,7 @@ protected:
class wbx_version3 : public wbx_versionx {
public:
wbx_version3(wbx_base *_self_wbx_base);
- ~wbx_version3(void);
+ virtual ~wbx_version3(void);
double set_tx_gain(double gain, const std::string &name);
void set_tx_enabled(bool enb);
@@ -183,7 +195,7 @@ protected:
class wbx_version4 : public wbx_versionx {
public:
wbx_version4(wbx_base *_self_wbx_base);
- ~wbx_version4(void);
+ virtual ~wbx_version4(void);
double set_tx_gain(double gain, const std::string &name);
void set_tx_enabled(bool enb);