GNU Radio C++ API Reference: ctcss_squelch_ff.h Source File

| GNU Radio C++ API Reference 3.10.12.0 The Free & Open Software Radio Ecosystem |

Loading...
Searching...
No Matches
ctcss_squelch_ff.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_CTCSS_SQUELCH_FF_H
12#define INCLUDED_ANALOG_CTCSS_SQUELCH_FF_H
13
14#include <gnuradio/analog/api.h>
15#include <gnuradio/analog/squelch_base_ff.h>
16#include <gnuradio/block.h>
17
18namespace gr {
19namespace analog {
20
21/*!
22 * \brief gate or zero output if CTCSS tone not present
23 * \ingroup level_controllers_blk
24 */
25 class ANALOG_API ctcss_squelch_ff : public squelch_base_ff, virtual public block
26{
27protected:
28 void update_state(const float& in) override = 0;
29 bool mute() const override = 0;
30
31public:
32 // gr::analog::ctcss_squelch_ff::sptr
33 typedef std::shared_ptr<ctcss_squelch_ff> sptr;
34
35 /*!
36 * \brief Make CTCSS tone squelch block.
37 *
38 * \param rate gain of the internal frequency filters.
39 * \param freq frequency value to use as the squelch tone.
40 * \param level threshold level for the squelch tone.
41 * \param len length of the frequency filters.
42 * \param ramp attack / release time in samples; a sinusodial ramp
43 * is used. set to 0 to disable.
44 * \param gate if true, no output if no squelch tone.
45 * if false, output 0's if no squelch tone.
46 */
47 static sptr make(int rate, float freq, float level, int len, int ramp, bool gate);
48
49 std::vector<float> squelch_range() const override = 0;
50 virtual float level() const = 0;
51 virtual void set_level(float level) = 0;
52 virtual int len() const = 0;
53 virtual float frequency() const = 0;
54 virtual void set_frequency(float frequency) = 0;
55
56 int ramp() const override = 0;
57 void set_ramp(int ramp) override = 0;
58 bool gate() const override = 0;
59 void set_gate(bool gate) override = 0;
60 bool unmuted() const override = 0;
61};
62
63} /* namespace analog */
64} /* namespace gr */
65
66#endif /* INCLUDED_ANALOG_CTCSS_SQUELCH_FF_H */
gr::analog::ctcss_squelch_ff
gate or zero output if CTCSS tone not present
Definition ctcss_squelch_ff.h:26
gr::analog::ctcss_squelch_ff::gate
bool gate() const override=0
gr::analog::ctcss_squelch_ff::set_frequency
virtual void set_frequency(float frequency)=0
gr::analog::ctcss_squelch_ff::mute
bool mute() const override=0
gr::analog::ctcss_squelch_ff::set_gate
void set_gate(bool gate) override=0
gr::analog::ctcss_squelch_ff::unmuted
bool unmuted() const override=0
gr::analog::ctcss_squelch_ff::len
virtual int len() const =0
gr::analog::ctcss_squelch_ff::frequency
virtual float frequency() const =0
gr::analog::ctcss_squelch_ff::ramp
int ramp() const override=0
gr::analog::ctcss_squelch_ff::sptr
std::shared_ptr< ctcss_squelch_ff > sptr
Definition ctcss_squelch_ff.h:33
gr::analog::ctcss_squelch_ff::set_ramp
void set_ramp(int ramp) override=0
gr::analog::ctcss_squelch_ff::update_state
void update_state(const float &in) override=0
gr::analog::ctcss_squelch_ff::set_level
virtual void set_level(float level)=0
gr::analog::ctcss_squelch_ff::level
virtual float level() const =0
gr::analog::ctcss_squelch_ff::squelch_range
std::vector< float > squelch_range() const override=0
gr::analog::ctcss_squelch_ff::make
static sptr make(int rate, float freq, float level, int len, int ramp, bool gate)
Make CTCSS tone squelch block.
gr::analog::squelch_base_ff::squelch_base_ff
squelch_base_ff()
Definition squelch_base_ff.h:31
gr::block::block
block(void)
Definition gnuradio-runtime/include/gnuradio/block.h:806
block.h
api.h
ANALOG_API
#define ANALOG_API
Definition gr-analog/include/gnuradio/analog/api.h:18
gr::analog
Definition agc.h:19
gr
GNU Radio logging wrapper.
Definition basic_block.h:29
squelch_base_ff.h