GNSS-SDR  0.0.13
An Open Source GNSS Software Defined Receiver
galileo_e5a_dll_pll_tracking_fpga.h
Go to the documentation of this file.
1 /*!
2  * \file galileo_e5a_dll_pll_tracking_fpga.h
3  * \brief Adapts a code DLL + carrier PLL
4  * tracking block to a TrackingInterface for Galileo E5a signals for the FPGA
5  * \author Marc Majoral, 2019. mmajoral(at)cttc.cat
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 #ifndef GNSS_SDR_GALILEO_E5A_DLL_PLL_TRACKING_FPGA_H
22 #define GNSS_SDR_GALILEO_E5A_DLL_PLL_TRACKING_FPGA_H
23 
25 #include "tracking_interface.h"
26 #include <string>
27 
29 
30 /*!
31  * \brief This class implements a code DLL + carrier PLL tracking loop
32  */
34 {
35 public:
36  /*!
37  * \brief Constructor
38  */
40  const ConfigurationInterface* configuration,
41  const std::string& role,
42  unsigned int in_streams,
43  unsigned int out_streams);
44 
45  /*!
46  * \brief Destructor
47  */
49 
50  /*!
51  * \brief Role
52  */
53  inline std::string role() override
54  {
55  return role_;
56  }
57 
58  /*!
59  * \brief Returns "Galileo_E5a_DLL_PLL_Tracking_Fpga"
60  */
61  inline std::string implementation() override
62  {
63  return "Galileo_E5a_DLL_PLL_Tracking_Fpga";
64  }
65 
66  /*!
67  * \brief Returns size of lv_16sc_t
68  */
69  size_t item_size() override
70  {
71  return sizeof(int16_t);
72  }
73 
74  /*!
75  * \brief Connect
76  */
77  void connect(gr::top_block_sptr top_block) override;
78 
79  /*!
80  * \brief Disconnect
81  */
82  void disconnect(gr::top_block_sptr top_block) override;
83 
84  /*!
85  * \brief Get left block
86  */
87  gr::basic_block_sptr get_left_block() override;
88 
89  /*!
90  * \brief Get right block
91  */
92  gr::basic_block_sptr get_right_block() override;
93 
94  /*!
95  * \brief Set tracking channel unique ID
96  */
97  void set_channel(unsigned int channel) override;
98 
99  /*!
100  * \brief Set acquisition/tracking common Gnss_Synchro object pointer
101  * to efficiently exchange synchronization data between acquisition and tracking blocks
102  */
103  void set_gnss_synchro(Gnss_Synchro* p_gnss_synchro) override;
104 
105  /*!
106  * \brief Start the tracking process in the FPGA
107  */
108  void start_tracking() override;
109 
110  /*!
111  * \brief Stop the tracking process in the FPGA
112  */
113  void stop_tracking() override;
114 
115 private:
116  // the following flags are FPGA-specific and they are using arrange the values of the local code in the way the FPGA
117  // expects. This arrangement is done in the initialisation to avoid consuming unnecessary clock cycles during tracking.
118  static const int32_t LOCAL_CODE_FPGA_ENABLE_WRITE_MEMORY = 0x0C000000; // flag that enables WE (Write Enable) of the local code FPGA
119  static const int32_t LOCAL_CODE_FPGA_CORRELATOR_SELECT_COUNT = 0x20000000; // flag that selects the writing of the pilot code in the FPGA (as opposed to the data code)
120 
121 
122  dll_pll_veml_tracking_fpga_sptr tracking_fpga_sc;
123  uint32_t channel_;
124  std::string role_;
125  uint32_t in_streams_;
126  uint32_t out_streams_;
127  int32_t* d_ca_codes;
128  int32_t* d_data_codes;
129  bool d_track_pilot;
130 };
131 
132 #endif // GNSS_SDR_GALILEO_E5A_DLL_PLL_TRACKING_FPGA_H
Implementation of a code DLL + carrier PLL tracking block using an FPGA.
void connect(gr::top_block_sptr top_block) override
Connect.
GalileoE5aDllPllTrackingFpga(const ConfigurationInterface *configuration, const std::string &role, unsigned int in_streams, unsigned int out_streams)
Constructor.
std::string implementation() override
Returns "Galileo_E5a_DLL_PLL_Tracking_Fpga".
This is the class that contains the information that is shared by the processing blocks.
Definition: gnss_synchro.h:33
This abstract class represents an interface to configuration parameters.
void set_channel(unsigned int channel) override
Set tracking channel unique ID.
This class implements a code DLL + carrier PLL tracking loop.
gr::basic_block_sptr get_left_block() override
Get left block.
void set_gnss_synchro(Gnss_Synchro *p_gnss_synchro) override
Set acquisition/tracking common Gnss_Synchro object pointer to efficiently exchange synchronization d...
virtual ~GalileoE5aDllPllTrackingFpga()
Destructor.
This abstract class represents an interface to a tracking block.
void stop_tracking() override
Stop the tracking process in the FPGA.
gr::basic_block_sptr get_right_block() override
Get right block.
void start_tracking() override
Start the tracking process in the FPGA.
size_t item_size() override
Returns size of lv_16sc_t.
void disconnect(gr::top_block_sptr top_block) override
Disconnect.
This class represents an interface to a tracking block.