GNU Radio Manual and C++ API Reference  3.8.1.0
The Free & Open Software Radio Ecosystem
modulate_vector.h
Go to the documentation of this file.
1 /*
2  * Copyright 2015 Free Software Foundation, Inc.
3  *
4  * This file is part of GNU Radio
5  *
6  * GNU Radio is free software; you can redistribute it and/or modify
7  * it under the terms of the GNU General Public License as published by
8  * the Free Software Foundation; either version 3, or (at your option)
9  * any later version.
10  *
11  * GNU Radio is distributed in the hope that it will be useful,
12  * but WITHOUT ANY WARRANTY; without even the implied warranty of
13  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14  * GNU General Public License for more details.
15  *
16  * You should have received a copy of the GNU General Public License
17  * along with GNU Radio; see the file COPYING. If not, write to
18  * the Free Software Foundation, Inc., 51 Franklin Street,
19  * Boston, MA 02110-1301, USA.
20  */
21 
22 #ifndef INCLUDED_DIGITAL_MODULATE_VECTOR_H
23 #define INCLUDED_DIGITAL_MODULATE_VECTOR_H
24 
25 #include <gnuradio/digital/api.h>
26 #include <gnuradio/types.h>
27 
28 namespace gr {
29 namespace digital {
30 
31 /*!
32  * \brief Modulate a vector of data and apply a shaping filter.
33  *
34  * \p modulator: Pointer to a byte-to-complex modulator block.
35  * \p data: Vector of bytes to modulate into symbols.
36  * \p taps: Post-modulation symbol shaping filter taps.
37  *
38  * \details
39  * This function modulates the input vector and applies a
40  * symbol shaping filter. It is intended for use with the
41  * corr_est_cc block as the symbol stream to correlate
42  * against.
43  *
44  * Any differential encoding or other data coding must be
45  * performed on the input vector before this modulation
46  * operation.
47  *
48  * Be aware that the format of the incoming data must match
49  * the format the modulator block is expecting. GNURadio
50  * modulator blocks are inconsistent in their data type
51  * expectations. For instance, cpmmod_bc expects unpacked,
52  * signed bytes in (-1, 1), while gmsk_mod expects packed,
53  * unsigned bytes in (0, 1). In other words, the output of
54  * gmsk_mod given the input vector [0xaa, 0x00] is equivalent
55  * to the output of cpmmod_bc given the input vector
56  * [1,255,1,255,1,255,1,255,255,255,255,255,255,255,255,255]
57  *
58  * Please check the documentation or source of the modulator
59  * before using this function.
60  *
61  */
62 DIGITAL_API std::vector<gr_complex> modulate_vector_bc(basic_block_sptr modulator,
63  std::vector<uint8_t> data,
64  std::vector<float> taps);
65 
66 } /* namespace digital */
67 } /* namespace gr */
68 
69 #endif /* INCLUDED_DIGITAL_MODULATE_VECTOR_H */
#define DIGITAL_API
Definition: gr-digital/include/gnuradio/digital/api.h:30
GNU Radio logging wrapper for log4cpp library (C++ port of log4j)
Definition: basic_block.h:43
static const float taps[NSTEPS+1][NTAPS]
Definition: interpolator_taps.h:9
DIGITAL_API std::vector< gr_complex > modulate_vector_bc(basic_block_sptr modulator, std::vector< uint8_t > data, std::vector< float > taps)
Modulate a vector of data and apply a shaping filter.