commit-gnuradio
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Commit-gnuradio] r9753 - gnuradio/branches/developers/eb/cppdb-wip/usrp


From: eb
Subject: [Commit-gnuradio] r9753 - gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy
Date: Wed, 8 Oct 2008 16:10:21 -0600 (MDT)

Author: eb
Date: 2008-10-08 16:10:18 -0600 (Wed, 08 Oct 2008)
New Revision: 9753

Modified:
   gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.cc
   gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.h
Log:
Applied two patches from Stefan Br?\195?\188ns <address@hidden>
dated 30 September 2008.

Remove superfulous d_tx variable in _AD4360_common
 * db_flexrf-remove-d_tx-p1.diff
 * db_flexrf-remove-d_tx-p2.diff


Modified: 
gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.cc
===================================================================
--- gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.cc 
2008-10-08 21:53:42 UTC (rev 9752)
+++ gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.cc 
2008-10-08 22:10:18 UTC (rev 9753)
@@ -536,8 +536,7 @@
 // ----------------------------------------------------------------
 
 
-_AD4360_common::_AD4360_common(bool tx)
-  : d_tx(tx)
+_AD4360_common::_AD4360_common()
 {
   // R-Register Common Values
   d_R_RSV = 0;  // bits 23,22
@@ -659,8 +658,8 @@
 
 //----------------------------------------------------------------------
 
-_2400_common::_2400_common(bool tx)
-  : _AD4360_common(tx)
+_2400_common::_2400_common()
+  : _AD4360_common()
 {
   // Band-specific R-Register Values
   d_R_DIV = 16;  // bits 15:2
@@ -691,8 +690,8 @@
 
 //----------------------------------------------------------------------
 
-_1200_common::_1200_common(bool tx)
-  : _AD4360_common(tx)
+_1200_common::_1200_common()
+  : _AD4360_common()
 {
   // Band-specific R-Register Values
   d_R_DIV = 16;  // bits 15:2  DIV by 16 for a 1 MHz phase detector freq
@@ -723,8 +722,8 @@
 
 //-------------------------------------------------------------------------
 
-_1800_common::_1800_common(bool tx)
-  : _AD4360_common(tx)
+_1800_common::_1800_common()
+  : _AD4360_common()
 {
   // Band-specific R-Register Values
   d_R_DIV = 16;  // bits 15:2  DIV by 16 for a 1 MHz phase detector freq
@@ -755,8 +754,8 @@
 
 //-------------------------------------------------------------------------
 
-_900_common::_900_common(bool tx)
-  : _AD4360_common(tx)
+_900_common::_900_common()
+  : _AD4360_common()
 {
   // Band-specific R-Register Values
   d_R_DIV = 16;  // bits 15:2  DIV by 16 for a 1 MHz phase detector freq
@@ -787,8 +786,8 @@
 
 //-------------------------------------------------------------------------
 
-_400_common::_400_common(bool tx)
-  : _AD4360_common(tx)
+_400_common::_400_common()
+  : _AD4360_common()
 {
   // Band-specific R-Register Values
   d_R_DIV = 16;   // bits 15:2 
@@ -800,12 +799,6 @@
   
   // Band specifc N-Register Values  These are different for TX/RX
   d_DIVSEL = 0;   // bit 23
-  if(d_tx) {
-    d_DIV2 = 1;   // bit 22
-  }
-  else {
-    d_DIV2 = 0;   // bit 22   // RX side has built-in DIV2 in AD8348
-  }
   d_freq_mult = 2;
   
   d_CPGAIN = 0;   // bit 21
@@ -823,12 +816,24 @@
   return 500e6;
 }  
 
+_400_tx::_400_tx()
+  : _400_common()
+{
+  d_DIV2 = 1;     // bit 22
+}
+
+_400_rx::_400_rx()
+  : _400_common()
+{
+  d_DIV2 = 0;    // bit 22   // RX side has built-in DIV2 in AD8348
+}
+
 //------------------------------------------------------------    
 
 db_flexrf_2400_tx::db_flexrf_2400_tx(usrp_basic *usrp, int which)
   : flexrf_base_tx(usrp, which)
 {
-  d_common = new _2400_common(d_tx);
+  d_common = new _2400_common();
 }
 
 db_flexrf_2400_tx::~db_flexrf_2400_tx()
@@ -860,7 +865,7 @@
 db_flexrf_2400_rx::db_flexrf_2400_rx(usrp_basic *usrp, int which)
   : flexrf_base_rx(usrp, which)
 {
-  d_common = new _2400_common(d_tx);
+  d_common = new _2400_common();
 }
 
 db_flexrf_2400_rx::~db_flexrf_2400_rx()
@@ -918,7 +923,7 @@
 db_flexrf_1200_tx::db_flexrf_1200_tx(usrp_basic *usrp, int which)
   : flexrf_base_tx(usrp, which)
 {
-  d_common = new _1200_common(d_tx);
+  d_common = new _1200_common();
 }
 
 db_flexrf_1200_tx::~db_flexrf_1200_tx()
@@ -951,7 +956,7 @@
 db_flexrf_1200_rx::db_flexrf_1200_rx(usrp_basic *usrp, int which)
   : flexrf_base_rx(usrp, which)
 {
-  d_common = new _1200_common(d_tx);
+  d_common = new _1200_common();
 }
 
 db_flexrf_1200_rx::~db_flexrf_1200_rx()
@@ -1009,7 +1014,7 @@
 db_flexrf_1800_tx::db_flexrf_1800_tx(usrp_basic *usrp, int which)
   : flexrf_base_tx(usrp, which)
 {
-  d_common = new _1800_common(d_tx);
+  d_common = new _1800_common();
 }
 
 db_flexrf_1800_tx::~db_flexrf_1800_tx()
@@ -1041,7 +1046,7 @@
 db_flexrf_1800_rx::db_flexrf_1800_rx(usrp_basic *usrp, int which)
   : flexrf_base_rx(usrp, which)
 {
-  d_common = new _1800_common(d_tx);
+  d_common = new _1800_common();
 }
 
 db_flexrf_1800_rx::~db_flexrf_1800_rx()
@@ -1100,7 +1105,7 @@
 db_flexrf_900_tx::db_flexrf_900_tx(usrp_basic *usrp, int which)
   : flexrf_base_tx(usrp, which)
 {
-  d_common = new _900_common(d_tx);
+  d_common = new _900_common();
 }
 
 db_flexrf_900_tx::~db_flexrf_900_tx()
@@ -1131,7 +1136,7 @@
 db_flexrf_900_rx::db_flexrf_900_rx(usrp_basic *usrp, int which)
   : flexrf_base_rx(usrp, which)
 {
-  d_common = new _900_common(d_tx);
+  d_common = new _900_common();
 }
 
 db_flexrf_900_rx::~db_flexrf_900_rx()
@@ -1188,7 +1193,7 @@
 db_flexrf_400_tx::db_flexrf_400_tx(usrp_basic *usrp, int which)
   : flexrf_base_tx(usrp, which, POWER_UP)
 {
-  d_common = new _400_common(d_tx);
+  d_common = new _400_tx();
 }
 
 db_flexrf_400_tx::~db_flexrf_400_tx()
@@ -1220,7 +1225,7 @@
 db_flexrf_400_rx::db_flexrf_400_rx(usrp_basic *usrp, int which)
   : flexrf_base_rx(usrp, which, POWER_UP)
 {
-  d_common = new _400_common(d_tx);
+  d_common = new _400_rx();
 }
 
 db_flexrf_400_rx::~db_flexrf_400_rx()

Modified: 
gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.h
===================================================================
--- gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.h  
2008-10-08 21:53:42 UTC (rev 9752)
+++ gnuradio/branches/developers/eb/cppdb-wip/usrp/host/lib/legacy/db_flexrf.h  
2008-10-08 22:10:18 UTC (rev 9753)
@@ -112,7 +112,7 @@
 class _AD4360_common
 {
 public:
-  _AD4360_common(bool tx);
+  _AD4360_common();
   virtual ~_AD4360_common();
 
   virtual double freq_min();
@@ -127,8 +127,6 @@
   void R_DIV(int div) { d_R_DIV = div; }
 
 protected:
-  bool d_tx;
-
   int d_R_RSV, d_BSC, d_TEST, d_LDP, d_ABP, d_N_RSV, d_PL, d_MTLD;
   int d_CPG, d_CP3S, d_PDP, d_MUXOUT, d_CR, d_PC;
 
@@ -143,7 +141,7 @@
 class _2400_common : public _AD4360_common
 {
  public:
-  _2400_common(bool tx);
+  _2400_common();
   ~_2400_common() {}
  
   double freq_min();
@@ -155,7 +153,7 @@
 class _1200_common : public _AD4360_common
 {
 public:
-  _1200_common(bool tx);
+  _1200_common();
   ~_1200_common() {}
 
   double freq_min();
@@ -167,7 +165,7 @@
 class _1800_common : public _AD4360_common
 {
  public:
-  _1800_common(bool tx);
+  _1800_common();
   ~_1800_common() {}
 
   double freq_min();
@@ -179,7 +177,7 @@
 class _900_common : public _AD4360_common
 {
 public:
-  _900_common(bool tx);
+  _900_common();
   ~_900_common() {}
   
   double freq_min();
@@ -191,14 +189,27 @@
 class _400_common : public _AD4360_common
 {
 public:
-  _400_common(bool tx);
+  _400_common();
   ~_400_common() {}
 
   double freq_min();
   double freq_max();
 };
 
+class _400_tx : public _400_common
+{
+public:
+  _400_tx();
+  ~_400_tx() {}
+};
 
+class _400_rx : public _400_common
+{
+public:
+  _400_rx();
+  ~_400_rx() {}
+};
+
 //------------------------------------------------------------    
 
 class db_flexrf_2400_tx : public flexrf_base_tx





reply via email to

[Prev in Thread] Current Thread [Next in Thread]