GNU Radio Manual and C++ API Reference  3.10.9.1
The Free & Open Software Radio Ecosystem
constellation_receiver_cb.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2011,2012 Free Software Foundation, Inc.
4  *
5  * This file is part of GNU Radio
6  *
7  * SPDX-License-Identifier: GPL-3.0-or-later
8  *
9  */
10 
11 #ifndef INCLUDED_DIGITAL_CONSTELLATION_RECEIVER_CB_H
12 #define INCLUDED_DIGITAL_CONSTELLATION_RECEIVER_CB_H
13 
14 #include <gnuradio/block.h>
16 #include <gnuradio/digital/api.h>
18 
19 namespace gr {
20 namespace digital {
21 
22 /*!
23  * \brief This block makes hard decisions about the received
24  * symbols (using a constellation object) and also fine tunes
25  * phase synchronization.
26  *
27  * \details
28  *
29  * The phase and frequency synchronization are based on a Costas
30  * loop that finds the error of the incoming signal point compared
31  * to its nearest constellation point. The frequency and phase of
32  * the NCO are updated according to this error.
33  *
34  * Message Ports:
35  *
36  * set_constellation (input):
37  * Receives a PMT any containing a new gr::digital::constellation object.
38  * The PMT is cast back to a gr::digital::constellation_sptr
39  * and passes this to set_constellation.
40  *
41  * rotate_phase (input):
42  * Receives a PMT double to update the phase.
43  * The phase value passed in the message is added to the
44  * current phase of the receiver.
45  */
47  virtual public blocks::control_loop
48 {
49 public:
50  // gr::digital::constellation_receiver_cb::sptr
51  typedef std::shared_ptr<constellation_receiver_cb> sptr;
52 
53  /*!
54  * \brief Constructs a constellation receiver that (phase/fine
55  * freq) synchronizes and decodes constellation points specified
56  * by a constellation object.
57  *
58  * \param constellation constellation of points for generic modulation
59  * \param loop_bw Loop bandwidth of the Costas Loop (~ 2pi/100)
60  * \param fmin minimum normalized frequency value the loop can achieve
61  * \param fmax maximum normalized frequency value the loop can achieve
62  */
63  static sptr
64  make(constellation_sptr constellation, float loop_bw, float fmin, float fmax);
65 
66  virtual void phase_error_tracking(float phase_error) = 0;
67 };
68 
69 } /* namespace digital */
70 } /* namespace gr */
71 
72 #endif /* INCLUDED_DIGITAL_CONSTELLATION_RECEIVER_CB_H */
The abstract base class for all 'terminal' processing blocks.
Definition: gnuradio-runtime/include/gnuradio/block.h:63
A second-order control loop implementation class.
Definition: control_loop.h:51
This block makes hard decisions about the received symbols (using a constellation object) and also fi...
Definition: constellation_receiver_cb.h:48
std::shared_ptr< constellation_receiver_cb > sptr
Definition: constellation_receiver_cb.h:51
static sptr make(constellation_sptr constellation, float loop_bw, float fmin, float fmax)
Constructs a constellation receiver that (phase/fine freq) synchronizes and decodes constellation poi...
virtual void phase_error_tracking(float phase_error)=0
An abstracted constellation object.
Definition: constellation.h:50
#define DIGITAL_API
Definition: gr-digital/include/gnuradio/digital/api.h:18
GNU Radio logging wrapper.
Definition: basic_block.h:29