23 #ifndef _ATSC_SLIDING_CORRELATOR_H_
24 #define _ATSC_SLIDING_CORRELATOR_H_
46 int input_bit(
int bit);
52 int input_int(
int sample) {
return input_bit(sample < 0 ? 0 : 1); }
58 int input_float(
float sample) {
return input_bit(sample < 0 ? 0 : 1); }
63 typedef unsigned long srblock;
64 static const int bits_per_char = 8;
65 static const int srblock_bitsize =
sizeof(srblock) * bits_per_char;
66 static const int NSRBLOCKS = (511 + srblock_bitsize - 1) / srblock_bitsize;
71 shift_reg() { reset(); }
72 void reset() { memset(d, 0,
sizeof(d)); }
73 void shift_in(
int bit);
#define ATSC_API
Definition: gr-atsc/include/gnuradio/atsc/api.h:30
~atsci_sliding_correlator()
Definition: sliding_correlator_impl.h:40
int input_int(int sample)
input sample, return correlation (0,511)
Definition: sliding_correlator_impl.h:52
int input_float(float sample)
input sample, return correlation (0,511)
Definition: sliding_correlator_impl.h:58
look for the PN 511 field sync pattern
Definition: sliding_correlator_impl.h:36
void reset()
Definition: sliding_correlator_impl.h:60