GNU Radio Manual and C++ API Reference  3.7.7
The Free & Open Software Radio Ecosystem
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
dvb_bbheader_bb_impl.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2015 Free Software Foundation, Inc.
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_DTV_DVB_BBHEADER_BB_IMPL_H
22 #define INCLUDED_DTV_DVB_BBHEADER_BB_IMPL_H
23 
25 #include "dvb_defines.h"
26 
27 typedef struct{
28  int ts_gs;
29  int sis_mis;
30  int ccm_acm;
31  int issyi;
32  int npd;
33  int ro;
34  int isi;
35  int upl;
36  int dfl;
37  int sync;
38  int syncd;
39 }BBHeader;
40 
41 typedef struct{
44 
45 namespace gr {
46  namespace dtv {
47 
49  {
50  private:
51  unsigned int kbch;
52  unsigned int count;
53  unsigned char crc;
54  unsigned int input_mode;
55  unsigned int extra;
56  int inband_type_b;
57  int fec_blocks;
58  int fec_block;
59  int ts_rate;
60  bool dvbs2x;
61  bool alternate;
62  FrameFormat m_format[1];
63  unsigned char crc_tab[256];
64  void add_bbheader(unsigned char *, int, int);
65  void build_crc8_table(void);
66  int add_crc8_bits(unsigned char *, int);
67  void add_inband_type_b(unsigned char *, int);
68 
69  public:
70  dvb_bbheader_bb_impl(dvb_standard_t standard, dvb_framesize_t framesize, dvb_code_rate_t rate, dvbs2_rolloff_factor_t rolloff, dvbt2_inputmode_t mode, dvbt2_inband_t inband, int fecblocks, int tsrate);
72 
73  void forecast (int noutput_items, gr_vector_int &ninput_items_required);
74 
75  int general_work(int noutput_items,
76  gr_vector_int &ninput_items,
77  gr_vector_const_void_star &input_items,
78  gr_vector_void_star &output_items);
79  };
80 
81  } // namespace dtv
82 } // namespace gr
83 
84 #endif /* INCLUDED_DTV_DVB_BBHEADER_BB_IMPL_H */
85 
Definition: dvb_bbheader_bb_impl.h:27
Definition: dvb_bbheader_bb_impl.h:41
dvbt2_inputmode_t
Definition: dvbt2_config.h:37
int dfl
Definition: dvb_bbheader_bb_impl.h:36
int general_work(int noutput_items, gr_vector_int &ninput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
compute output items from input items
dvb_bbheader_bb_impl(dvb_standard_t standard, dvb_framesize_t framesize, dvb_code_rate_t rate, dvbs2_rolloff_factor_t rolloff, dvbt2_inputmode_t mode, dvbt2_inband_t inband, int fecblocks, int tsrate)
std::vector< const void * > gr_vector_const_void_star
Definition: gnuradio-runtime/include/gnuradio/types.h:38
int ccm_acm
Definition: dvb_bbheader_bb_impl.h:30
int issyi
Definition: dvb_bbheader_bb_impl.h:31
int upl
Definition: dvb_bbheader_bb_impl.h:35
int npd
Definition: dvb_bbheader_bb_impl.h:32
std::vector< void * > gr_vector_void_star
Definition: gnuradio-runtime/include/gnuradio/types.h:37
std::vector< int > gr_vector_int
Definition: gnuradio-runtime/include/gnuradio/types.h:33
Include this header to use the message passing features.
Definition: logger.h:129
int ts_gs
Definition: dvb_bbheader_bb_impl.h:28
int sync
Definition: dvb_bbheader_bb_impl.h:37
BBHeader bb_header
Definition: dvb_bbheader_bb_impl.h:42
dvb_standard_t
Definition: dvb_config.h:26
Formats MPEG-2 Transport Stream packets into FEC baseband frames and adds a 10-byte header...
Definition: dvb_bbheader_bb.h:43
void forecast(int noutput_items, gr_vector_int &ninput_items_required)
Estimate input requirements given output request.
dvbt2_inband_t
Definition: dvbt2_config.h:128
int sis_mis
Definition: dvb_bbheader_bb_impl.h:29
dvbs2_rolloff_factor_t
Definition: dvbs2_config.h:26
int isi
Definition: dvb_bbheader_bb_impl.h:34
int syncd
Definition: dvb_bbheader_bb_impl.h:38
int ro
Definition: dvb_bbheader_bb_impl.h:33
dvb_framesize_t
Definition: dvb_config.h:75
Definition: dvb_bbheader_bb_impl.h:48
dvb_code_rate_t
Definition: dvb_config.h:31