GNSS-SDR  0.0.13
An Open Source GNSS Software Defined Receiver
gps_l2c_telemetry_decoder.h
Go to the documentation of this file.
1 /*!
2  * \file gps_l2c_telemetry_decoder.h
3  * \brief Interface of an adapter of a GPS L2C (CNAV) data decoder block
4  * to a TelemetryDecoderInterface
5  * \author Javier Arribas, 2015. 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_GPS_L2C_TELEMETRY_DECODER_H
23 #define GNSS_SDR_GPS_L2C_TELEMETRY_DECODER_H
24 
25 #include "gnss_satellite.h" // for Gnss_Satellite
26 #include "gnss_synchro.h"
29 #include <gnuradio/runtime_types.h> // for basic_block_sptr, top_block_sptr
30 #include <cstddef> // for size_t
31 #include <string>
32 
34 
35 /*!
36  * \brief This class implements a NAV data decoder for GPS L2 M
37  */
39 {
40 public:
42  const ConfigurationInterface* configuration,
43  const std::string& role,
44  unsigned int in_streams,
45  unsigned int out_streams);
46 
47  ~GpsL2CTelemetryDecoder() = default;
48 
49  inline std::string role() override
50  {
51  return role_;
52  }
53 
54  //! Returns "GPS_L2C_Telemetry_Decoder"
55  inline std::string implementation() override
56  {
57  return "GPS_L2C_Telemetry_Decoder";
58  }
59 
60  void connect(gr::top_block_sptr top_block) override;
61  void disconnect(gr::top_block_sptr top_block) override;
62  gr::basic_block_sptr get_left_block() override;
63  gr::basic_block_sptr get_right_block() override;
64 
65  void set_satellite(const Gnss_Satellite& satellite) override;
66 
67  inline void set_channel(int channel) override { telemetry_decoder_->set_channel(channel); }
68 
69  inline void reset() override
70  {
71  telemetry_decoder_->reset();
72  }
73 
74  inline size_t item_size() override
75  {
76  return sizeof(Gnss_Synchro);
77  }
78 
79 private:
80  gps_l2c_telemetry_decoder_gs_sptr telemetry_decoder_;
81  Gnss_Satellite satellite_;
82  std::string dump_filename_;
83  std::string role_;
84  int channel_;
85  unsigned int in_streams_;
86  unsigned int out_streams_;
87  bool dump_;
88 };
89 
90 #endif
This class represents an interface to a telemetry decoder block.
Interface of a CNAV message demodulator block.
This is the class that contains the information that is shared by the processing blocks.
Definition: gnss_synchro.h:33
This class implements a NAV data decoder for GPS L2 M.
This abstract class represents an interface to configuration parameters.
Interface of the Gnss_Satellite class.
This class represents a GNSS satellite.
This abstract class represents an interface to a navigation GNSS block.
Interface of the Gnss_Synchro class.
std::string implementation() override
Returns "GPS_L2C_Telemetry_Decoder".