GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
raw_array_signal_source.h
Go to the documentation of this file.
1 /*!
2  * \file raw_array_signal_source.h
3  * \brief CTTC Experimental GNSS 8 channels array signal source
4  * \author Javier Arribas, jarribas(at)cttc.es
5  *
6  * -----------------------------------------------------------------------------
7  *
8  * GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
9  * This file is part of GNSS-SDR.
10  *
11  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
12  * SPDX-License-Identifier: GPL-3.0-or-later
13  *
14  * -----------------------------------------------------------------------------
15  */
16 
17 
18 #ifndef GNSS_SDR_RAW_ARRAY_SIGNAL_SOURCE_H
19 #define GNSS_SDR_RAW_ARRAY_SIGNAL_SOURCE_H
20 
21 #include "concurrent_queue.h"
22 #include "signal_source_base.h"
23 #include <gnuradio/blocks/file_sink.h>
24 #include <gnuradio/hier_block2.h>
25 #include <pmt/pmt.h>
26 #include <cstdint>
27 #include <memory>
28 #include <string>
29 
30 
31 /** \addtogroup Signal_Source
32  * \{ */
33 /** \addtogroup Signal_Source_adapters
34  * \{ */
35 
36 
38 
39 /*!
40  * \brief This class reads samples from an antenna array RF front-end signal sampler
41  */
43 {
44 public:
45  RawArraySignalSource(const ConfigurationInterface* configuration,
46  std::string role, unsigned int in_stream,
47  unsigned int out_stream, Concurrent_Queue<pmt::pmt_t>* queue);
48 
49  ~RawArraySignalSource() = default;
50 
51  inline size_t item_size() override
52  {
53  return item_size_;
54  }
55 
56  void connect(gr::top_block_sptr top_block) override;
57  void disconnect(gr::top_block_sptr top_block) override;
58  gr::basic_block_sptr get_left_block() override;
59  gr::basic_block_sptr get_right_block() override;
60 
61 private:
62  gr::block_sptr raw_array_source_;
63  gr::blocks::file_sink::sptr file_sink_;
64  std::string item_type_;
65  std::string dump_filename_;
66  std::string eth_device_;
67  size_t item_size_;
68  [[maybe_unused]] int64_t samples_;
69  unsigned int in_stream_;
70  unsigned int out_stream_;
71  bool dump_;
72 };
73 
74 
75 /** \} */
76 /** \} */
77 #endif // GNSS_SDR_RAW_ARRAY_SIGNAL_SOURCE_H
Interface of a thread-safe std::queue.
Header file of the base class to signal_source GNSS blocks.
This class reads samples from an antenna array RF front-end signal sampler.
This abstract class represents an interface to configuration parameters.