GNU Radio's LTE Package
sync_frequency_c_impl.h
Go to the documentation of this file.
1/* -*- c++ -*- */
2/*
3 * Copyright 2013 Communications Engineering Lab (CEL) / Karlsruhe Institute of Technology (KIT)
4 *
5 * This 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 * This software 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 this software; 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
21#ifndef INCLUDED_LTE_SYNC_FREQUENCY_C_IMPL_H
22#define INCLUDED_LTE_SYNC_FREQUENCY_C_IMPL_H
23
25
26namespace gr {
27 namespace lte {
28
30 {
31 private:
32 // basic attributes
33 boost::shared_ptr<gr::analog::sig_source_c> d_sig;
34 int d_fftl;
35 int d_cpl;
36 int d_cpl0;
37 int d_slotl;
38 int d_samp_rate;
39 int d_offset;
40 gr_complex* d_buffer;
41
42 float d_f_av;
43 int d_samp_num;
44 int d_work_call;
45
46 //methods for further calculations
47 void calc_f_off_av();
48
49 gr_complex corr(gr_complex *res, gr_complex *x, gr_complex *y, int len);
50
51 public:
52 sync_frequency_c_impl(boost::shared_ptr<gr::analog::sig_source_c> &sig, int fftl, std::string& name);
54
55 // Where all the action really happens
56 int work(int noutput_items,
57 gr_vector_const_void_star &input_items,
58 gr_vector_void_star &output_items);
59 };
60
61 } // namespace lte
62} // namespace gr
63
64#endif /* INCLUDED_LTE_SYNC_FREQUENCY_C_IMPL_H */
65
Definition: sync_frequency_c_impl.h:30
sync_frequency_c_impl(boost::shared_ptr< gr::analog::sig_source_c > &sig, int fftl, std::string &name)
int work(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
Calculate fractional frequency offset.
Definition: sync_frequency_c.h:40
Definition: bch_crc_check_ant_chooser_bb.h:28