GNU Radio's TEST Package
fix_cc.h
Go to the documentation of this file.
1/* -*- c++ -*- */
2/*
3 * Copyright 2011-2020 Free Software Foundation, Inc.
4 * Copyright 2013-2021 Sylvain Munaut <tnt@246tNt.com>
5 *
6 * This file is part of gr-iqbalance
7 *
8 * SPDX-License-Identifier: GPL-3.0-or-later
9 */
10
11#pragma once
12
14#include <gnuradio/sync_block.h>
15
16namespace gr {
17 namespace iqbalance {
18
19 class IQBALANCE_API fix_cc : public gr::sync_block
20 {
21 private:
22 fix_cc(float mag, float phase);
23
24 float d_mag, d_phase;
25
26 public:
27 typedef std::shared_ptr<fix_cc> sptr;
28
29 static sptr make(float mag=0.0f, float phase=0.0f);
30
32
33 void set_mag(float mag) { this->d_mag = mag; }
34 void set_phase(float phase) { this->d_phase = phase; }
35
36 float mag() const { return this->d_mag; }
37 float phase() const { return this->d_phase; }
38
39 void apply_new_corrections (pmt::pmt_t msg);
40
41 int work (int noutput_items,
42 gr_vector_const_void_star &input_items,
43 gr_vector_void_star &output_items);
44 };
45
46 } // namespace iqbalance
47} // namespace gr
#define IQBALANCE_API
Definition api.h:17
Definition fix_cc.h:20
int work(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
float phase() const
Definition fix_cc.h:37
void apply_new_corrections(pmt::pmt_t msg)
float mag() const
Definition fix_cc.h:36
static sptr make(float mag=0.0f, float phase=0.0f)
std::shared_ptr< fix_cc > sptr
Definition fix_cc.h:27
void set_phase(float phase)
Definition fix_cc.h:34
void set_mag(float mag)
Definition fix_cc.h:33
Definition fix_cc.h:16