commit-gnuradio
[Top][All Lists]
Advanced

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

[Commit-gnuradio] r7219 - gnuradio/branches/developers/jcorgan/t127/usrp


From: jcorgan
Subject: [Commit-gnuradio] r7219 - gnuradio/branches/developers/jcorgan/t127/usrpdb/src
Date: Mon, 17 Dec 2007 10:54:13 -0700 (MST)

Author: jcorgan
Date: 2007-12-17 10:54:12 -0700 (Mon, 17 Dec 2007)
New Revision: 7219

Added:
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/qa_dbsrx.py
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.cc
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.h
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.i
Modified:
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/Makefile.am
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb.i
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.h
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.i
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.cc
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.h
   gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.i
Log:
WIP adding dbsrx class, incomplete.

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/Makefile.am
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/Makefile.am    
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/Makefile.am    
2007-12-17 17:54:12 UTC (rev 7219)
@@ -36,6 +36,7 @@
        usrpdb_base.i                   \
        usrpdb_basic_rx.i               \
        usrpdb_basic_tx.i               \
+       usrpdb_dbsrx.i                  \
        usrpdb_hwa.i                    \
        usrpdb_hwa_qa.i                 \
        usrpdb_lfrx.i                   \
@@ -63,6 +64,7 @@
        usrpdb_base.cc                  \
        usrpdb_basic_rx.cc              \
        usrpdb_basic_tx.cc              \
+       usrpdb_dbsrx.cc                 \
        usrpdb_hwa.cc                   \
        usrpdb_hwa_qa.cc                \
        usrpdb_lfrx.cc                  \
@@ -86,6 +88,7 @@
        usrpdb_base.h                   \
        usrpdb_basic_rx.h               \
        usrpdb_basic_tx.h               \
+       usrpdb_dbsrx.h                  \
        usrpdb_hwa.h                    \
        usrpdb_hwa_qa.h                 \
        usrpdb_lfrx.h                   \
@@ -105,6 +108,7 @@
 noinst_PYTHON =                        \
        qa_basic_rx.py                  \
        qa_basic_tx.py                  \
+       qa_dbsrx.py                     \
        qa_lfrx.py                      \
        qa_lftx.py                      \
        qa_usrpdb.py

Added: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/qa_dbsrx.py
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/qa_dbsrx.py            
                (rev 0)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/qa_dbsrx.py    
2007-12-17 17:54:12 UTC (rev 7219)
@@ -0,0 +1,63 @@
+#!/usr/bin/env python
+#
+# Copyright 2007 Free Software Foundation, Inc.
+# 
+# This file is part of GNU Radio
+# 
+# GNU Radio is free software; you can redistribute it and/or modify
+# it under the terms of the GNU General Public License as published by
+# the Free Software Foundation; either version 3, or (at your option)
+# any later version.
+# 
+# GNU Radio is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+# GNU General Public License for more details.
+# 
+# You should have received a copy of the GNU General Public License
+# along with GNU Radio; see the file COPYING.  If not, write to
+# the Free Software Foundation, Inc., 51 Franklin Street,
+# Boston, MA 02110-1301, USA.
+# 
+
+from gnuradio import gr, gr_unittest
+import usrpdb
+
+class qa_dbsrx(gr_unittest.TestCase):
+
+    def setUp(self):
+       self.hwa = usrpdb.hwa_qa()
+       self.db = usrpdb.dbsrx(self.hwa)
+
+    def tearDown(self):
+       self.db = None
+       self.hwa = None
+
+    def test_000_freq_range(self):
+       expected_range = (500e6, 2.6e9, 1e6)
+       freq_range = self.db.freq_range()
+       self.assertFloatTuplesAlmostEqual(freq_range, expected_range, 5)
+
+    def test_001_set_freq(self):
+       actual_baseband_freq = self.db.set_freq(2.4e9)
+       self.assertEqual(actual_baseband_freq, 2.4e9)
+
+    def test_002_gain_range(self):
+       expected_range = (0, 104, 1)
+       gain_range = self.db.gain_range()
+       self.assertFloatTuplesAlmostEqual(gain_range, expected_range, 5)
+
+    def test_003_set_gain(self):
+       self.db.set_gain(52)    
+       pass # TODO: check gc values
+       
+    # FIXME: disabled due to ticket:181
+    def xtest_004_set_gain_bad(self):
+       self.assertRaises(ValueError,
+           lambda: self.db.set_gain(-10.0))    
+
+    def test_005_is_quadrature(self):
+       self.assertTrue(self.db.is_quadrature())
+       
+if __name__ == '__main__':
+    gr_unittest.main ()


Property changes on: 
gnuradio/branches/developers/jcorgan/t127/usrpdb/src/qa_dbsrx.py
___________________________________________________________________
Name: svn:executable
   + *

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb.i
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb.i       
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb.i       
2007-12-17 17:54:12 UTC (rev 7219)
@@ -27,11 +27,14 @@
 
 namespace std {
   %template() vector<float>;
+  %template() vector<unsigned char>;
 }
 
+%include "usrpdb_hwa.i"
 %include "usrpdb_hwa_qa.i"
 %include "usrpdb_base.i"
 %include "usrpdb_basic_rx.i"
 %include "usrpdb_basic_tx.i"
+%include "usrpdb_dbsrx.i"
 %include "usrpdb_lfrx.i"
 %include "usrpdb_lftx.i"

Added: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.cc
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.cc        
                        (rev 0)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.cc        
2007-12-17 17:54:12 UTC (rev 7219)
@@ -0,0 +1,166 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2007 Free Software Foundation, Inc.
+ * 
+ * This file is part of GNU Radio
+ * 
+ * GNU Radio is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3, or (at your option)
+ * any later version.
+ * 
+ * GNU Radio is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with GNU Radio; see the file COPYING.  If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#ifdef HAVE_CONFIG_H
+#include "config.h"
+#endif
+
+#include <usrpdb_dbsrx.h>
+#include <stdexcept>
+
+// i2c bus id, side A, side B
+static char s_i2c_addr[2] = { 0x67, 0x65 };
+
+usrpdb_base_sptr
+usrpdb_make_dbsrx(usrpdb_hwa_sptr hwa)
+{
+  return usrpdb_base_sptr(new usrpdb_dbsrx(hwa));
+}
+
+usrpdb_dbsrx::usrpdb_dbsrx(usrpdb_hwa_sptr hwa)
+  : usrpdb_base(hwa),
+    d_n(950),
+    d_div2(0),
+    d_osc(5),
+    d_cp(3),
+    d_r(4),
+    d_r_int(1),
+    d_fdac(127),
+    d_m(2),
+    d_dl(0),
+    d_ade(0),
+    d_adl(0),
+    d_gc2(31),
+    d_diag(0)
+{
+  d_addr = s_i2c_addr[d_hwa->side()];
+  d_hwa->write_oe(0x0001, 0x0001);
+  d_hwa->set_refclk_divisor(16);
+  d_hwa->enable_refclk(true);
+  d_hwa->bypass_adc_buffers(true);
+
+  // Set startup gain to mid-point
+  std::vector<float> g = gain_range();
+  set_gain((g[0]+g[1])/2);
+}
+
+usrpdb_dbsrx::~usrpdb_dbsrx()
+{
+  d_hwa->enable_refclk(false);
+}
+
+std::vector<float>
+usrpdb_dbsrx::freq_range()
+{
+  std::vector<float> result(3);
+  result[0] = 500e6;
+  result[1] = 2.6e9;
+  result[2] = 1e6;
+  return result;
+}
+
+void
+usrpdb_dbsrx::write_reg(unsigned char regno, unsigned char val)
+{
+  assert(regno <= 5);
+  std::vector<unsigned char> seq(2);
+  seq[0] = regno;
+  seq[1] = val;
+  d_hwa->write_i2c(d_addr, seq);
+}
+
+void
+usrpdb_dbsrx::send_reg(unsigned char regno)
+{
+  assert(regno <= 5);
+
+  switch(regno) {
+    case 0:
+      write_reg(0, d_div2<<7 + d_n>>8);
+      break;
+      
+    case 4:
+      write_reg(4, d_m + (d_dl<<5) + (d_ade<<6) + (d_adl<<7));
+      break;
+  }
+}
+
+void
+usrpdb_dbsrx::set_div2(int div2)
+{
+  assert(div2 == 0 || div2 == 1);
+  d_div2 = div2;
+  send_reg(0);
+}
+
+void
+usrpdb_dbsrx::set_ade(int ade)
+{
+  assert(ade == 0 || ade == 1);
+  d_ade = ade;
+  send_reg(4);
+}
+
+float
+usrpdb_dbsrx::set_freq(float target_freq)
+{
+  if (target_freq < 500e6 || target_freq > 2.6e9)
+    throw std::invalid_argument("frequency out of range");
+
+  float vco_freq;
+    
+  if (target_freq < 1150e6) {
+    set_div2(0);
+    vco_freq = 4*target_freq;
+  }
+  else {
+    set_div2(1);
+    vco_freq = 2*target_freq;
+  }
+
+  set_ade(1);
+  // resume with rmin=
+}
+
+std::vector<float>
+usrpdb_dbsrx::gain_range()
+{
+  std::vector<float> result(3);
+  result[0] = 0;
+  result[1] = 104;
+  result[2] = 1;
+  return result;
+}
+
+void
+usrpdb_dbsrx::set_gain(float gain)
+{
+  if (gain < 0 || gain > 104) {
+    throw std::invalid_argument("gain value is out of range");
+  }
+}
+
+bool
+usrpdb_dbsrx::is_quadrature()
+{
+  return true;
+}

Added: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.h
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.h         
                (rev 0)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.h 
2007-12-17 17:54:12 UTC (rev 7219)
@@ -0,0 +1,68 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2007 Free Software Foundation, Inc.
+ * 
+ * This file is part of GNU Radio
+ * 
+ * GNU Radio is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3, or (at your option)
+ * any later version.
+ * 
+ * GNU Radio is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with GNU Radio; see the file COPYING.  If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ */
+
+#ifndef INCLUDED_USRPDB_DBSRX_H
+#define INCLUDED_USRPDB_DBSRX_H
+
+#include <usrpdb_base.h>
+
+usrpdb_base_sptr usrpdb_make_dbsrx(usrpdb_hwa_sptr hwa);
+
+class usrpdb_dbsrx : public usrpdb_base
+{
+private:
+  void write_reg(unsigned char regno, unsigned char value);
+  void send_reg(unsigned char regno);
+  void set_div2(int div2);
+  void set_ade(int ade);
+  
+  char d_addr;
+  int d_n;
+  int d_div2;
+  int d_osc;
+  int d_cp;
+  int d_r;
+  int d_r_int;
+  int d_fdac;
+  int d_m;
+  int d_dl;
+  int d_ade;
+  int d_adl;
+  int d_gc2;
+  int d_diag;
+
+protected:
+  usrpdb_dbsrx(usrpdb_hwa_sptr hwa);
+  friend usrpdb_base_sptr usrpdb_make_dbsrx(usrpdb_hwa_sptr hwa);
+
+public:
+  virtual ~usrpdb_dbsrx();
+
+  // These are mandatory overrides
+  virtual std::vector<float> freq_range();
+  virtual float set_freq(float target_freq);
+  virtual std::vector<float> gain_range();
+  virtual void set_gain(float gain);
+  virtual bool is_quadrature();
+};
+
+#endif /* INCLUDED_USRPDB_DBSRX_H */

Added: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.i
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.i         
                (rev 0)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_dbsrx.i 
2007-12-17 17:54:12 UTC (rev 7219)
@@ -0,0 +1,47 @@
+/* -*- c++ -*- */
+/*
+ * Copyright 2007 Free Software Foundation, Inc.
+ * 
+ * This file is part of GNU Radio
+ * 
+ * GNU Radio is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 3, or (at your option)
+ * any later version.
+ * 
+ * GNU Radio is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with GNU Radio; see the file COPYING.  If not, write to
+ * the Free Software Foundation, Inc., 51 Franklin Street,
+ * Boston, MA 02110-1301, USA.
+ */
+
+%{
+#include <usrpdb_dbsrx.h>
+%}
+
+%include "usrpdb_base.i"
+
+%rename(dbsrx) usrpdb_make_dbsrx;
+%ignore dbsrx;
+
+usrpdb_base_sptr usrpdb_make_dbsrx(usrpdb_hwa_sptr hwa);
+
+class usrpdb_dbsrx : public usrpdb_base
+{
+protected:
+  usrpdb_dbsrx(usrpdb_hwa_sptr hwa);
+  
+public:
+  ~usrpdb_dbsrx();
+
+  std::vector<float> freq_range();
+  float set_freq(float target_freq);
+  std::vector<float> gain_range();
+  void set_gain(float gain) throw (std::invalid_argument);
+  bool is_quadrature();
+};

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.h
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.h   
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.h   
2007-12-17 17:54:12 UTC (rev 7219)
@@ -24,6 +24,7 @@
 #define INCLUDED_USRPDB_HWA_H
 
 #include <boost/shared_ptr.hpp>
+#include <vector>
 
 class usrpdb_hwa 
 {
@@ -31,6 +32,7 @@
   usrpdb_hwa();
   virtual ~usrpdb_hwa() = 0;
 
+  virtual unsigned int side() = 0;
   virtual float dac_pga_gain() = 0;
   virtual float dac_pga_min() = 0;
   virtual float dac_pga_max() = 0;
@@ -41,8 +43,11 @@
   virtual float adc_pga_max() = 0;
   virtual float adc_pga_db_per_step() = 0;
   virtual void set_adc_pga(float gain) = 0;
-
   virtual void bypass_adc_buffers(bool bypass) = 0;
+  virtual void write_oe(unsigned short mask, unsigned short val) = 0;
+  virtual void set_refclk_divisor(int divisor) = 0;
+  virtual void enable_refclk(bool enable) = 0;
+  virtual void write_i2c(char addr, std::vector<unsigned char> seq) = 0;
 };
 
 typedef boost::shared_ptr<usrpdb_hwa> usrpdb_hwa_sptr;

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.i
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.i   
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa.i   
2007-12-17 17:54:12 UTC (rev 7219)
@@ -34,6 +34,7 @@
   usrpdb_hwa();
   virtual ~usrpdb_hwa() = 0;
 
+  virtual unsigned int side() = 0;
   virtual float dac_pga_gain() = 0;
   virtual float dac_pga_min() = 0;
   virtual float dac_pga_max() = 0;
@@ -44,6 +45,9 @@
   virtual float adc_pga_max() = 0;
   virtual float adc_pga_db_per_step() = 0;
   virtual void set_adc_pga(float gain) = 0;
-  
   virtual void bypass_adc_buffers(bool bypass);
+  virtual void write_oe(unsigned short mask, unsigned short value);
+  virtual void set_refclk_divisor(int divisor);
+  virtual void enable_refclk(bool enable);
+  virtual void write_i2c(char addr, std::vector<unsigned char> seq);
 };

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.cc
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.cc       
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.cc       
2007-12-17 17:54:12 UTC (rev 7219)
@@ -36,11 +36,25 @@
 }
 
 usrpdb_hwa_qa::usrpdb_hwa_qa()
-  : d_adc_pga_gain(0.0),
-    d_dac_pga_gain(0.0)
+  : d_side(0),
+    d_adc_pga_gain(0.0),
+    d_dac_pga_gain(0.0),
+    d_output_enable(0x0000),
+    d_refclk_divisor(0),
+    d_refclk_enabled(false)
 {
 }
 
+usrpdb_hwa_qa::~usrpdb_hwa_qa()
+{
+}
+
+unsigned int
+usrpdb_hwa_qa::side()
+{
+    return d_side;
+}
+
 float
 usrpdb_hwa_qa::dac_pga_gain()
 {
@@ -118,6 +132,36 @@
     std::cout << "usrpdb_hwa_qa: bypassing ADC buffers: " << bypass << 
std::endl;
 }
 
-usrpdb_hwa_qa::~usrpdb_hwa_qa()
+void
+usrpdb_hwa_qa::write_oe(unsigned short mask, unsigned short val)
 {
+  if (USRPDB_HWA_QA_DEBUG)
+    std::cout << "usrpdb_hwa_qa: writing output enable with mask: " 
+             << mask << ", val: " << val << std::endl;
+
+  d_output_enable |= (val && mask);
+  d_output_enable &= (val | ~mask);
 }
+
+void
+usrpdb_hwa_qa::set_refclk_divisor(int divisor)
+{
+  if (USRPDB_HWA_QA_DEBUG)
+    std::cout << "usrpdb_hwa_qa: setting refclk divisor to " << divisor << 
std::endl;
+  d_refclk_divisor = divisor;
+}
+
+void
+usrpdb_hwa_qa::enable_refclk(bool enable)
+{
+  if (USRPDB_HWA_QA_DEBUG)
+    std::cout << "usrpdb_hwa_qa: setting refclk enable to " << enable << 
std::endl;
+  d_refclk_enabled = enable;
+}
+
+void
+usrpdb_hwa_qa::write_i2c(char addr, std::vector<unsigned char> seq)
+{
+  if (USRPDB_HWA_QA_DEBUG)
+    std::cout << "usrpdb_hwa_qa: writing to I2C addr: " << (int)addr << 
std::endl;
+}

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.h
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.h        
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.h        
2007-12-17 17:54:12 UTC (rev 7219)
@@ -35,13 +35,18 @@
   friend usrpdb_hwa_sptr usrpdb_make_qa_hwa();
 
   // Mimic dummy hardware
+  unsigned int d_side;
   float d_adc_pga_gain;
   float d_dac_pga_gain;
-    
+  unsigned short d_output_enable;
+  int d_refclk_divisor;
+  bool d_refclk_enabled;
+        
 public:
 
   ~usrpdb_hwa_qa();
 
+  unsigned int side();
   float dac_pga_gain();
   float dac_pga_min();
   float dac_pga_max();
@@ -52,8 +57,11 @@
   float adc_pga_max();
   float adc_pga_db_per_step();
   void set_adc_pga(float gain);
-
   void bypass_adc_buffers(bool bypass);
+  void write_oe(unsigned short mask, unsigned short val);
+  void set_refclk_divisor(int divisor);
+  void enable_refclk(bool enable);
+  void write_i2c(char addr, std::vector<unsigned char> seq);
 };
 
 #endif /* INCLUDED_USRPDB_HWA_QA_H */

Modified: gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.i
===================================================================
--- gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.i        
2007-12-17 17:10:11 UTC (rev 7218)
+++ gnuradio/branches/developers/jcorgan/t127/usrpdb/src/usrpdb_hwa_qa.i        
2007-12-17 17:54:12 UTC (rev 7219)
@@ -24,8 +24,6 @@
 #include <usrpdb_hwa_qa.h>
 %}
 
-%include <usrpdb_hwa.i>
-
 %rename(hwa_qa) usrpdb_make_qa_hwa;
 %ignore hwa_qa;
 
@@ -38,6 +36,7 @@
 public:
   ~usrpdb_hwa_qa();
 
+  unsigned int side();
   float dac_pga_gain();
   float dac_pga_min();
   float dac_pga_max();
@@ -48,6 +47,9 @@
   float adc_pga_max();
   float adc_pga_db_per_step();
   void set_adc_pga(float gain);
-
   void bypass_adc_buffers(bool bypass);
+  void write_oe(int mask, int val);
+  void set_refclk_divisor(int divisor);
+  void enable_refclk(bool enable);
+  void write_i2c(char addr, std::vector<unsigned char> seq);
 };





reply via email to

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