GNU Radio 3.7.1 C++ API
chunks_to_symbols_bf.h
Go to the documentation of this file.
00001 /* -*- c++ -*- */
00002 /*
00003  * Copyright 2004,2012 Free Software Foundation, Inc.
00004  *
00005  * This file is part of GNU Radio
00006  *
00007  * GNU Radio is free software; you can redistribute it and/or modify
00008  * it under the terms of the GNU General Public License as published by
00009  * the Free Software Foundation; either version 3, or (at your option)
00010  * any later version.
00011  *
00012  * GNU Radio is distributed in the hope that it will be useful,
00013  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00014  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00015  * GNU General Public License for more details.
00016  *
00017  * You should have received a copy of the GNU General Public License
00018  * along with GNU Radio; see the file COPYING.  If not, write to
00019  * the Free Software Foundation, Inc., 51 Franklin Street,
00020  * Boston, MA 02110-1301, USA.
00021  */
00022 
00023 /* WARNING: this file is machine generated. Edits will be overwritten */
00024 
00025 #ifndef INCLUDED_DIGITAL_CHUNKS_TO_SYMBOLS_BF_H
00026 #define INCLUDED_DIGITAL_CHUNKS_TO_SYMBOLS_BF_H
00027 
00028 #include <gnuradio/digital/api.h>
00029 #include <gnuradio/sync_interpolator.h>
00030 
00031 namespace gr {
00032   namespace digital {
00033     
00034     /*!
00035      * \brief Map a stream of symbol indexes (unpacked bytes or
00036      * shorts) to stream of float or complex constellation points in D
00037      * dimensions (D = 1 by default)
00038      * \ingroup converter_blk
00039      *
00040      * input: stream of unsigned char; output: stream of float
00041      *
00042      * out[n D + k] = symbol_table[in[n] D + k], k=0,1,...,D-1
00043      *
00044      * The combination of gr::blocks::packed_to_unpacked_XX followed by
00045      * digital_chunks_to_symbols_XY handles the general case of mapping
00046      * from a stream of bytes or shorts into arbitrary float
00047      * or complex symbols.
00048      *
00049      * \sa gr::blocks::packed_to_unpacked_bb, gr::blocks::unpacked_to_packed_bb,
00050      * \sa gr::blocks::packed_to_unpacked_ss, gr::blocks::unpacked_to_packed_ss,
00051      * \sa gr::digital::chunks_to_symbols_bf, gr::digital::chunks_to_symbols_bc.
00052      * \sa gr::digital::chunks_to_symbols_sf, gr::digital::chunks_to_symbols_sc.
00053      */
00054     class DIGITAL_API chunks_to_symbols_bf : virtual public sync_interpolator
00055     {
00056     public:
00057       // gr::digital::chunks_to_symbols_bf::sptr
00058       typedef boost::shared_ptr<chunks_to_symbols_bf> sptr;
00059 
00060       /*!
00061        * Make a chunks-to-symbols block.
00062        *
00063        * \param symbol_table: list that maps chunks to symbols.
00064        * \param D: dimension of table.
00065        */
00066       static sptr make(const std::vector<float> &symbol_table, const int D = 1);
00067 
00068       virtual int D() const = 0;
00069       virtual std::vector<float> symbol_table() const = 0;
00070     };
00071 
00072   } /* namespace digital */
00073 } /* namespace gr */
00074 
00075 #endif /* INCLUDED_DIGITAL_CHUNKS_TO_SYMBOLS_BF_H */