summaryrefslogtreecommitdiff
path: root/usrp/host/include
diff options
context:
space:
mode:
authorJohnathan Corgan2010-06-04 23:02:03 -0700
committerJohnathan Corgan2010-06-04 23:02:03 -0700
commitd4766ba22b22a3f7730f8bcb32cd0d71422f96a8 (patch)
tree851a4a012336ca30b0fb7800760742b5dd901608 /usrp/host/include
parent42321e57612176b828edeb8334f17f1434c2828b (diff)
parent0ea8bff6d0c62e0ddd0a344365c5e345d0a10d07 (diff)
downloadgnuradio-d4766ba22b22a3f7730f8bcb32cd0d71422f96a8.tar.gz
gnuradio-d4766ba22b22a3f7730f8bcb32cd0d71422f96a8.tar.bz2
gnuradio-d4766ba22b22a3f7730f8bcb32cd0d71422f96a8.zip
Merge branch 'master' into next
* master: Fixed WBX RX PLL enable Refactor WBX and adf4350 to avoid passing usrp pointer Clean up annoying class structure in wbx Fixing wbx to use _refclk_freq() Typo in error message
Diffstat (limited to 'usrp/host/include')
-rw-r--r--usrp/host/include/usrp/db_wbxng.h39
1 files changed, 11 insertions, 28 deletions
diff --git a/usrp/host/include/usrp/db_wbxng.h b/usrp/host/include/usrp/db_wbxng.h
index 8611d4787..9a7829278 100644
--- a/usrp/host/include/usrp/db_wbxng.h
+++ b/usrp/host/include/usrp/db_wbxng.h
@@ -30,7 +30,7 @@ class adf4350;
class wbxng_base : public db_base
{
public:
- wbxng_base(usrp_basic_sptr usrp, int which, int _power_on=0);
+ wbxng_base(usrp_basic_sptr usrp, int which);
~wbxng_base();
struct freq_result_t set_freq(double freq);
@@ -40,31 +40,30 @@ public:
double freq_max();
protected:
- bool _lock_detect();
+ void _write_spi(std::string data);
+ int _refclk_divisor();
+ bool _get_locked();
bool _set_pga(float pga_gain);
- int power_on() { return d_power_on; }
- int power_off() { return 0; }
-
bool d_first;
int d_spi_format;
int d_spi_enable;
int d_power_on;
int d_PD;
- adf4350 *d_common;
+ boost::shared_ptr<adf4350> d_common;
};
// ----------------------------------------------------------------
-class wbxng_base_tx : public wbxng_base
+class db_wbxng_tx : public wbxng_base
{
protected:
void shutdown();
public:
- wbxng_base_tx(usrp_basic_sptr usrp, int which, int _power_on=0);
- ~wbxng_base_tx();
+ db_wbxng_tx(usrp_basic_sptr usrp, int which);
+ ~db_wbxng_tx();
float gain_min();
float gain_max();
@@ -75,36 +74,20 @@ public:
bool set_gain(float gain);
};
-class wbxng_base_rx : public wbxng_base
+class db_wbxng_rx : public wbxng_base
{
protected:
void shutdown();
bool _set_attn(float attn);
public:
- wbxng_base_rx(usrp_basic_sptr usrp, int which, int _power_on=0);
- ~wbxng_base_rx();
+ db_wbxng_rx(usrp_basic_sptr usrp, int which);
+ ~db_wbxng_rx();
bool set_auto_tr(bool on);
bool select_rx_antenna(int which_antenna);
bool select_rx_antenna(const std::string &which_antenna);
bool set_gain(float gain);
-};
-
-// ----------------------------------------------------------------
-
-class db_wbxng_tx : public wbxng_base_tx
-{
- public:
- db_wbxng_tx(usrp_basic_sptr usrp, int which);
- ~db_wbxng_tx();
-};
-
-class db_wbxng_rx : public wbxng_base_rx
-{
-public:
- db_wbxng_rx(usrp_basic_sptr usrp, int which);
- ~db_wbxng_rx();
float gain_min();
float gain_max();