GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
channel_msg_receiver_cc.h
Go to the documentation of this file.
1 /*!
2  * \file channel_msg_receiver_cc.h
3  * \brief GNU Radio block that receives asynchronous channel messages from acquisition and tracking blocks
4  * \author Javier Arribas, 2016. 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 #ifndef GNSS_SDR_CHANNEL_MSG_RECEIVER_CC_H
18 #define GNSS_SDR_CHANNEL_MSG_RECEIVER_CC_H
19 
20 #include "channel_fsm.h"
21 #include <gnuradio/block.h>
22 #include <pmt/pmt.h>
23 #include <memory>
24 
25 /** \addtogroup Channel
26  * \{ */
27 /** \addtogroup Channel_libs
28  * \{ */
29 
30 
32 
33 using channel_msg_receiver_cc_sptr = gnss_shared_ptr<channel_msg_receiver_cc>;
34 
35 channel_msg_receiver_cc_sptr channel_msg_receiver_make_cc(std::shared_ptr<ChannelFsm> channel_fsm, bool repeat);
36 
37 /*!
38  * \brief GNU Radio block that receives asynchronous channel messages from acquisition and tracking blocks
39  */
40 class channel_msg_receiver_cc : public gr::block
41 {
42 public:
43  ~channel_msg_receiver_cc() = default; //!< Default destructor
44 
45 private:
46  friend channel_msg_receiver_cc_sptr channel_msg_receiver_make_cc(std::shared_ptr<ChannelFsm> channel_fsm, bool repeat);
47  channel_msg_receiver_cc(std::shared_ptr<ChannelFsm> channel_fsm, bool repeat);
48  void msg_handler_channel_events(const pmt::pmt_t& msg);
49  std::shared_ptr<ChannelFsm> d_channel_fsm;
50  bool d_repeat; // todo: change FSM to include repeat value
51 };
52 
53 
54 /** \} */
55 /** \} */
56 #endif // GNSS_SDR_CHANNEL_MSG_RECEIVER_CC_H
Interface of the State Machine for channel.
GNU Radio block that receives asynchronous channel messages from acquisition and tracking blocks...
~channel_msg_receiver_cc()=default
Default destructor.