GNU Radio 3.4.2 C++ API
db_bitshark_rx.h
Go to the documentation of this file.
00001 /* -*- c++ -*- */
00002 //
00003 // Copyright 2010 Free Software Foundation, Inc.
00004 // 
00005 // This file is part of GNU Radio
00006 // 
00007 // GNU Radio is free software; you can redistribute it and/or modify
00008 // it under the terms of the GNU General Public License as published by
00009 // the Free Software Foundation; either asversion 3, or (at your option)
00010 // any later version.
00011 // 
00012 // GNU Radio is distributed in the hope that it will be useful,
00013 // but WITHOUT ANY WARRANTY; without even the implied warranty of
00014 // MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015 // GNU General Public License for more details.
00016 // 
00017 // You should have received a copy of the GNU General Public License
00018 // along with GNU Radio; see the file COPYING.  If not, write to
00019 // the Free Software Foundation, Inc., 51 Franklin Street,
00020 // Boston, MA 02110-1301, USA.
00021 
00022 #ifndef DB_BITSHARK_RX_H
00023 #define DB_BITSHARK_RX_H
00024 
00025 #include <usrp/db_base.h>
00026 #include <vector>
00027 #include <stdint.h>
00028 
00029 class db_bitshark_rx : public db_base
00030 {
00031 private:
00032     int d_i2c_addr;
00033     // Internal function for interfacing to the card
00034     void _set_pga(int pga_gain);
00035     
00036 protected:
00037     void shutdown();
00038     
00039 public:
00040     db_bitshark_rx(usrp_basic_sptr usrp, int which);
00041     ~db_bitshark_rx();
00042     
00043     float gain_min();
00044     float gain_max();
00045     float gain_db_per_step();
00046     double freq_min();
00047     double freq_max();
00048     struct freq_result_t set_freq(double freq);
00049     bool  set_gain(float gain);
00050     bool  set_bw(float bw);
00051     bool  set_clock_scheme(uint8_t clock_scheme, uint32_t ref_clock_freq);
00052     bool  is_quadrature();
00053     bool  i_and_q_swapped();
00054 };
00055 
00056 #endif