GNU Radio 3.6.4.1 C++ API
dc_blocker_ff.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
* GNU Radio is free software; you can redistribute it and/or modify
8
* it under the terms of the GNU General Public License as published by
9
* the Free Software Foundation; either version 3, or (at your option)
10
* any later version.
11
*
12
* GNU Radio is distributed in the hope that it will be useful,
13
* but WITHOUT ANY WARRANTY; without even the implied warranty of
14
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15
* GNU General Public License for more details.
16
*
17
* You should have received a copy of the GNU General Public License
18
* along with GNU Radio; see the file COPYING. If not, write to
19
* the Free Software Foundation, Inc., 51 Franklin Street,
20
* Boston, MA 02110-1301, USA.
21
*/
22
23
#ifndef INCLUDED_FILTER_DC_BLOCKER_FF_H
24
#define INCLUDED_FILTER_DC_BLOCKER_FF_H
25
26
#include <
filter/api.h
>
27
#include <
gr_sync_block.h
>
28
29
namespace
gr {
30
namespace
filter {
31
32
class
FILTER_API
dc_blocker_ff
:
virtual
public
gr_sync_block
33
{
34
public
:
35
36
// gr::filter::dc_blocker_ff::sptr
37
typedef
boost::shared_ptr<dc_blocker_ff>
sptr
;
38
39
/*!
40
* \class dc_blocker_ff
41
* \brief a computationally efficient controllable DC blocker
42
*
43
* \ingroup filter_blk
44
*
45
* This block implements a computationally efficient DC blocker that produces
46
* a tighter notch filter around DC for a smaller group delay than an
47
* equivalent FIR filter or using a single pole IIR filter (though the IIR
48
* filter is computationally cheaper).
49
*
50
* The block defaults to using a delay line of length 32 and the long form
51
* of the filter. Optionally, the delay line length can be changed to alter
52
* the width of the DC notch (longer lines will decrease the width).
53
*
54
* The long form of the filter produces a nearly flat response outside of
55
* the notch but at the cost of a group delay of 2D-2.
56
*
57
* The short form of the filter does not have as flat a response in the
58
* passband but has a group delay of only D-1 and is cheaper to compute.
59
*
60
* The theory behind this block can be found in the paper:
61
*
62
* <B><EM>R. Yates, "DC Blocker Algorithms," IEEE Signal Processing Magazine,
63
* Mar. 2008, pp 132-134.</EM></B>
64
*
65
* \param D (int) the length of the delay line
66
* \param long_form (bool) whether to use long (true, default) or short form
67
*/
68
static
sptr
make(
int
D,
bool
long_form=
true
);
69
70
virtual
int
group_delay() = 0;
71
};
72
73
}
/* namespace filter */
74
}
/* namespace gr */
75
76
#endif
/* INCLUDED_FILTER_DC_BLOCKER_FF_H */
gr-filter
include
filter
dc_blocker_ff.h
Generated on Sun Apr 28 2013 20:26:34 for GNU Radio 3.6.4.1 C++ API by
1.8.3.1