GNSS-SDR  0.0.14
An Open Source GNSS Software Defined Receiver
gnmax_signal_source.h
Go to the documentation of this file.
1 /*!
2  * \file gnmax_signal_source.h
3  * \brief gnMAX2769 USB dongle GPS RF front-end signal sampler driver
4  * \author Wojciech Kazubski, wk(at)ire.pw.edu.pl
5  * \author Javier Arribas, jarribas(at)cttc.es
6  *
7  * -----------------------------------------------------------------------------
8  *
9  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
10  *
11  * GNSS-SDR is a software defined Global Navigation
12  * Satellite Systems receiver
13  *
14  * This file is part of GNSS-SDR.
15  *
16  * SPDX-License-Identifier: GPL-3.0-or-later
17  *
18  * -----------------------------------------------------------------------------
19  */
20 
21 
22 #ifndef GNSS_SDR_GNMAX_SIGNAL_SOURCE_H_
23 #define GNSS_SDR_GNMAX_SIGNAL_SOURCE_H_
24 
25 #include "concurrent_queue.h"
26 #include "gnss_block_interface.h"
27 #include <gnuradio/blocks/file_sink.h>
28 #include <gnuradio/hier_block2.h>
29 #include <pmt/pmt.h>
30 #include <string>
31 
32 
34 
35 /*!
36  * \brief This class reads samples from a gnMAX2769 USB dongle, a RF front-end signal sampler
37  */
39 {
40 public:
41  GnMaxSignalSource(const ConfigurationInterface* configuration,
42  std::string role, unsigned int in_stream,
43  unsigned int out_stream, Concurrent_Queue<pmt::pmt_t>* queue);
44 
45  virtual ~GnMaxSignalSource();
46 
47  inline std::string role() override
48  {
49  return role_;
50  }
51 
52  /*!
53  * \brief Returns "GNMAX_Signal_Source".
54  */
55  inline std::string implementation() override
56  {
57  return "GNMAX_Signal_Source";
58  }
59 
60  inline size_t item_size() override
61  {
62  return item_size_;
63  }
64 
65  void connect(gr::top_block_sptr top_block) override;
66  void disconnect(gr::top_block_sptr top_block) override;
67  gr::basic_block_sptr get_left_block() override;
68  gr::basic_block_sptr get_right_block() override;
69 
70 private:
71  std::string role_;
72  bool bias_;
73  int bias__;
74  int ant_;
75  unsigned long freq_; // frequency of local oscilator
76  float freq__;
77  unsigned long bw_;
78  int bw__;
79  bool zeroif_;
80  int zeroif__;
81  unsigned int in_stream_;
82  unsigned int out_stream_;
83  std::string item_type_;
84  size_t item_size_;
85  long samples_;
86  bool dump_;
87  std::string dump_filename_;
88  gr::block_sptr gnmax_source_;
89  gr::blocks::file_sink::sptr file_sink_;
90 };
91 
92 #endif /*GNSS_SDR_GNMAX_SIGNAL_SOURCE_H_*/
Interface of a thread-safe std::queue.
This class reads samples from a gnMAX2769 USB dongle, a RF front-end signal sampler.
This interface represents a GNSS block.
This abstract class represents an interface to configuration parameters.
std::string implementation() override
Returns "GNMAX_Signal_Source".
This abstract class represents an interface to GNSS blocks.