GNU Radio 3.6.5.1 C++ API
gr_cpfsk_bc.h
Go to the documentation of this file.
1
/* -*- c++ -*- */
2
/*
3
* Copyright 2008 Free Software Foundation, Inc.
4
*
5
* GNU Radio is free software; you can redistribute it and/or modify
6
* it under the terms of the GNU General Public License as published by
7
* the Free Software Foundation; either version 3, or (at your option)
8
* any later version.
9
*
10
* GNU Radio is distributed in the hope that it will be useful,
11
* but WITHOUT ANY WARRANTY; without even the implied warranty of
12
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13
* GNU General Public License for more details.
14
*
15
* You should have received a copy of the GNU General Public License
16
* along with GNU Radio; see the file COPYING. If not, write to
17
* the Free Software Foundation, Inc., 51 Franklin Street,
18
* Boston, MA 02110-1301, USA.
19
*/
20
#ifndef INCLUDED_GR_CPFSK_BC_H
21
#define INCLUDED_GR_CPFSK_BC_H
22
23
#include <
gr_core_api.h
>
24
#include <
gr_sync_interpolator.h
>
25
26
class
gr_cpfsk_bc
;
27
28
typedef
boost::shared_ptr<gr_cpfsk_bc>
gr_cpfsk_bc_sptr
;
29
30
GR_CORE_API
gr_cpfsk_bc_sptr
gr_make_cpfsk_bc
(
float
k,
float
ampl,
int
samples_per_sym);
31
32
/*!
33
* \brief Perform continuous phase 2-level frequency shift keying modulation
34
* on an input stream of unpacked bits.
35
*
36
* \param k modulation index
37
* \param ampl output amplitude
38
* \param samples_per_sym number of output samples per input bit
39
*/
40
41
class
GR_CORE_API
gr_cpfsk_bc
:
public
gr_sync_interpolator
42
{
43
private
:
44
friend
GR_CORE_API
gr_cpfsk_bc_sptr
gr_make_cpfsk_bc
(
float
k,
float
ampl,
int
samples_per_sym);
45
46
gr_cpfsk_bc
(
float
k,
float
ampl,
int
samples_per_sym);
47
48
int
d_samples_per_sym;
// Samples per symbol, square pulse
49
float
d_freq;
// Modulation index*pi/samples_per_sym
50
float
d_ampl;
// Output amplitude
51
float
d_phase;
// Current phase
52
53
public
:
54
~
gr_cpfsk_bc
();
55
56
void
set_amplitude
(
float
amplitude) { d_ampl = amplitude; }
57
58
int
work
(
int
noutput_items,
59
gr_vector_const_void_star
&input_items,
60
gr_vector_void_star
&output_items);
61
};
62
63
#endif
/* INCLUDED_GR_CPFSK_BC_H */
gnuradio-core
src
lib
general
gr_cpfsk_bc.h
Generated on Mon Aug 19 2013 15:37:30 for GNU Radio 3.6.5.1 C++ API by
1.8.1.2