GNU Radio Manual and C++ API Reference  3.10.9.1
The Free & Open Software Radio Ecosystem
squelch_base_cc.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2006,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_ANALOG_SQUELCH_BASE_CC_H
12 #define INCLUDED_ANALOG_SQUELCH_BASE_CC_H
13 
14 #include <gnuradio/analog/api.h>
15 #include <gnuradio/block.h>
16 
17 namespace gr {
18 namespace analog {
19 
20 /*!
21  * \brief basic squelch block; to be subclassed for other squelches.
22  * \ingroup level_blk
23  */
24 class ANALOG_API squelch_base_cc : virtual public block
25 {
26 protected:
27  virtual void update_state(const gr_complex& sample) = 0;
28  virtual bool mute() const = 0;
29 
30 public:
32  virtual int ramp() const = 0;
33  virtual void set_ramp(int ramp) = 0;
34  virtual bool gate() const = 0;
35  virtual void set_gate(bool gate) = 0;
36  virtual bool unmuted() const = 0;
37 
38  virtual std::vector<float> squelch_range() const = 0;
39 };
40 
41 } /* namespace analog */
42 } /* namespace gr */
43 
44 #endif /* INCLUDED_ANALOG_SQUELCH_BASE_CC_H */
basic squelch block; to be subclassed for other squelches.
Definition: squelch_base_cc.h:25
virtual int ramp() const =0
virtual void update_state(const gr_complex &sample)=0
virtual void set_gate(bool gate)=0
virtual bool unmuted() const =0
squelch_base_cc()
Definition: squelch_base_cc.h:31
virtual void set_ramp(int ramp)=0
virtual std::vector< float > squelch_range() const =0
virtual bool mute() const =0
virtual bool gate() const =0
The abstract base class for all 'terminal' processing blocks.
Definition: gnuradio-runtime/include/gnuradio/block.h:63
#define ANALOG_API
Definition: gr-analog/include/gnuradio/analog/api.h:18
std::complex< float > gr_complex
Definition: gr_complex.h:15
GNU Radio logging wrapper.
Definition: basic_block.h:29