GNU Radio's FOO Package: channel_model_impl.h Source File

GNU Radio's FOO Package

channel_model_impl.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2017 Bastian Bloessl <mail@bastibl.net>
3 *
4 * This program is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
8 *
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
16 */
17#ifndef INCLUDED_FOO_CHANNEL_MODEL_IMPL_H
18#define INCLUDED_FOO_CHANNEL_MODEL_IMPL_H
19
20#include <foo/channel_model.h>
21
22#include <gnuradio/top_block.h>
23#include <gnuradio/blocks/add_blk.h>
24#include <gnuradio/blocks/multiply.h>
25#include <gnuradio/analog/sig_source.h>
26#include <gnuradio/analog/noise_source.h>
27#include <gnuradio/filter/mmse_resampler_cc.h>
28#include <gnuradio/filter/fir_filter_blk.h>
29
30namespace gr {
31namespace foo {
32
33 class FOO_API channel_model_impl : public foo::channel_model
34{
35private:
36 blocks::add_cc::sptr d_noise_adder;
37 blocks::multiply_cc::sptr d_mixer_offset;
38
39 analog::sig_source_c::sptr d_freq_offset;
40 analog::noise_source_c::sptr d_noise;
41
42 filter::mmse_resampler_cc::sptr d_timing_offset;
43 filter::fir_filter_ccc::sptr d_multipath;
44
45 std::vector<gr_complex> d_taps;
46
47public:
48 channel_model_impl(double noise_voltage,
49 double frequency_offset,
50 double epsilon,
51 const std::vector<gr_complex> &taps,
52 double noise_seed,
53 bool block_tags);
54
55 ~channel_model_impl();
56
57 void set_noise_voltage(double noise_voltage);
58 void set_frequency_offset(double frequency_offset);
59 void set_taps(const std::vector<gr_complex> &taps);
60 void set_timing_offset(double epsilon);
61
62 double noise_voltage() const;
63 double frequency_offset() const;
64 std::vector<gr_complex> taps() const;
65 double timing_offset() const;
66};
67
68} // namespace foo
69} // namespace gr
70
71#endif /* INCLUDED_FOO_CHANNEL_MODEL_IMPL_H */
FOO_API
#define FOO_API
Definition api.h:19
channel_model.h
gr::foo::channel_model_impl::set_frequency_offset
void set_frequency_offset(double frequency_offset)
gr::foo::channel_model_impl::set_taps
void set_taps(const std::vector< gr_complex > &taps)
gr::foo::channel_model_impl::channel_model_impl
channel_model_impl(double noise_voltage, double frequency_offset, double epsilon, const std::vector< gr_complex > &taps, double noise_seed, bool block_tags)
gr::foo::channel_model_impl::set_noise_voltage
void set_noise_voltage(double noise_voltage)
gr::foo::channel_model_impl::set_timing_offset
void set_timing_offset(double epsilon)
gr::foo::channel_model_impl::noise_voltage
double noise_voltage() const
gr::foo::channel_model_impl::timing_offset
double timing_offset() const
gr::foo::channel_model_impl::~channel_model_impl
~channel_model_impl()
gr::foo::channel_model_impl::frequency_offset
double frequency_offset() const
gr::foo::channel_model_impl::taps
std::vector< gr_complex > taps() const
gr::foo::channel_model
Definition channel_model.h:28
gr::foo
Definition burst_tagger.h:28
gr
Definition burst_tagger.h:27