GNU Radio 3.4.2 C++ API
|
00001 /* 00002 * Copyright 2008 Free Software Foundation, Inc. 00003 * 00004 * This file is part of GNU Radio 00005 * 00006 * GNU Radio is free software; you can redistribute it and/or modify 00007 * it under the terms of the GNU General Public License as published by 00008 * the Free Software Foundation; either version 3, or (at your option) 00009 * any later version. 00010 * 00011 * GNU Radio is distributed in the hope that it will be useful, 00012 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00013 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00014 * GNU General Public License for more details. 00015 * 00016 * You should have received a copy of the GNU General Public License 00017 * along with GNU Radio; see the file COPYING. If not, write to 00018 * the Free Software Foundation, Inc., 51 Franklin Street, 00019 * Boston, MA 02110-1301, USA. 00020 */ 00021 00022 #include <gr_top_block.h> 00023 #include <usrp_sink_c.h> 00024 #include <gr_sig_source_c.h> 00025 #include <gr_noise_source_c.h> 00026 00027 usrp_subdev_spec str_to_subdev(std::string spec_str); 00028 00029 class usrp_siggen; 00030 typedef boost::shared_ptr<usrp_siggen> usrp_siggen_sptr; 00031 usrp_siggen_sptr make_usrp_siggen(int which, usrp_subdev_spec spec, 00032 double rf_freq, int interp, double wfreq, 00033 int waveform, float amp, float gain, 00034 float offset, long long nsamples); 00035 00036 class usrp_siggen : public gr_top_block 00037 { 00038 private: 00039 usrp_siggen(int which, usrp_subdev_spec spec, 00040 double rf_freq, int interp, double wfreq, 00041 int waveform, float amp, float gain, 00042 float offset, long long nsamples); 00043 friend usrp_siggen_sptr make_usrp_siggen(int which, usrp_subdev_spec spec, 00044 double rf_freq, int interp, double wfreq, 00045 int waveform, float amp, float gain, 00046 float offset, 00047 long long nsamples); 00048 00049 public: 00050 gr_block_sptr source; 00051 gr_sig_source_c_sptr siggen; 00052 gr_noise_source_c_sptr noisegen; 00053 };