summaryrefslogtreecommitdiff
path: root/gr-analog/include/gnuradio/analog/phase_modulator_fc.h
blob: 6e61b9c471a49152eca723f648dbcd25cb8bce80 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
/* -*- c++ -*- */
/*
 * Copyright 2005,2006,2012 Free Software Foundation, Inc.
 *
 * This file is part of GNU Radio
 *
 * SPDX-License-Identifier: GPL-3.0-or-later
 *
 */

#ifndef INCLUDED_ANALOG_PHASE_MODULATOR_FC_H
#define INCLUDED_ANALOG_PHASE_MODULATOR_FC_H

#include <gnuradio/analog/api.h>
#include <gnuradio/sync_block.h>

namespace gr {
namespace analog {

/*!
 * \brief Phase modulator block
 * \ingroup modulators_blk
 *
 * \details
 * output = complex(cos(in*sensitivity), sin(in*sensitivity))
 *
 * Input stream 0: floats
 * Output stream 0: complex
 */
class ANALOG_API phase_modulator_fc : virtual public sync_block
{
public:
    // gr::analog::phase_modulator_fc::sptr
    typedef boost::shared_ptr<phase_modulator_fc> sptr;

    /* \brief Make a phase modulator block.
     *
     * \param sensitivity Phase change sensitivity of input amplitude.
     */
    static sptr make(double sensitivity);

    virtual double sensitivity() const = 0;
    virtual double phase() const = 0;

    virtual void set_sensitivity(double s) = 0;
    virtual void set_phase(double p) = 0;
};

} /* namespace analog */
} /* namespace gr */

#endif /* INCLUDED_ANALOG_PHASE_MODULATOR_FC_H */