GNU Radio 3.7.0 C++ API
cpfsk_bc.h
Go to the documentation of this file.
00001 /* -*- c++ -*- */
00002 /*
00003  * Copyright 2008,2012 Free Software Foundation, Inc.
00004  *
00005  * GNU Radio is free software; you can redistribute it and/or modify
00006  * it under the terms of the GNU General Public License as published by
00007  * the Free Software Foundation; either version 3, or (at your option)
00008  * any later version.
00009  *
00010  * GNU Radio is distributed in the hope that it will be useful,
00011  * but WITHOUT ANY WARRANTY; without even the implied warranty of
00012  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00013  * GNU General Public License for more details.
00014  *
00015  * You should have received a copy of the GNU General Public License
00016  * along with GNU Radio; see the file COPYING.  If not, write to
00017  * the Free Software Foundation, Inc., 51 Franklin Street,
00018  * Boston, MA 02110-1301, USA.
00019  */
00020 
00021 #ifndef INCLUDED_ANALOG_CPFSK_BC_H
00022 #define INCLUDED_ANALOG_CPFSK_BC_H
00023 
00024 #include <gnuradio/analog/api.h>
00025 #include <gnuradio/sync_interpolator.h>
00026 
00027 namespace gr {
00028   namespace analog {
00029     
00030     /*!
00031      * \brief Perform continuous phase 2-level frequency shift keying modulation
00032      * on an input stream of unpacked bits.
00033      * \ingroup modulators_blk
00034      */
00035     class ANALOG_API cpfsk_bc : virtual public sync_interpolator
00036     {
00037     public:
00038       // gr::analog::cpfsk_bc::sptr
00039       typedef boost::shared_ptr<cpfsk_bc> sptr;
00040             
00041       /*!
00042        * \brief Make a CPFSK block.
00043        *
00044        * \param k modulation index
00045        * \param ampl output amplitude
00046        * \param samples_per_sym number of output samples per input bit
00047        */
00048       static sptr make(float k, float ampl, int samples_per_sym);
00049 
00050       virtual void set_amplitude(float amplitude) = 0;
00051       virtual float amplitude() = 0;
00052       virtual float freq() = 0;
00053       virtual float phase() = 0;
00054     };
00055 
00056   } /* namespace analog */
00057 } /* namespace gr */
00058 
00059 #endif /* INCLUDED_ANALOG_CPFSK_BC_H */