2 #ifndef INCLUDED_LORA_SDR_FRAME_SYNC_IMPL_H 3 #define INCLUDED_LORA_SDR_FRAME_SYNC_IMPL_H 7 #define GRLORA_MEASUREMENTS 13 #include <volk/volk.h> 15 #include <gnuradio/io_signature.h> 46 uint8_t m_invalid_header;
48 std::vector<uint16_t> m_sync_words;
52 uint32_t m_number_of_bins;
53 uint32_t m_samples_per_symbol;
57 std::vector<gr_complex> in_down;
58 std::vector<gr_complex> m_downchirp;
59 std::vector<gr_complex> m_upchirp;
66 uint8_t symbols_to_skip;
73 std::vector<gr_complex> preamble_raw;
74 std::vector<gr_complex> preamble_up;
83 std::vector<gr_complex> CFO_frac_correc;
86 std::vector<gr_complex> symb_corr;
91 #ifdef GRLORA_MEASUREMENTS 93 std::ofstream sync_log;
96 int numb_symbol_to_save;
97 std::vector<gr_complex> last_frame;
98 std::ofstream samples_file;
99 std::ofstream preamb_file;
100 std::ofstream payload_file;
105 void frame_info_handler(pmt::pmt_t frame_info);
113 void estimate_CFO(gr_complex* samples);
117 void estimate_CFO_Bernier();
130 uint32_t get_symbol_val(
const gr_complex *samples,gr_complex *ref_chirp);
138 float determine_energy(
const gr_complex *samples);
143 void header_err_handler(pmt::pmt_t payload_len);
146 frame_sync_impl(
float samp_rate, uint32_t bandwidth, uint8_t sf,
bool impl_head, std::vector<uint16_t> sync_word);
150 void forecast (
int noutput_items, gr_vector_int &ninput_items_required);
153 gr_vector_int &ninput_items,
154 gr_vector_const_void_star &input_items,
155 gr_vector_void_star &output_items);
int general_work(int noutput_items, gr_vector_int &ninput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
void forecast(int noutput_items, gr_vector_int &ninput_items_required)
Definition: frame_sync_impl.h:23
Definition: kiss_fft.h:67
<+description of block+>
Definition: frame_sync.h:36
frame_sync_impl(float samp_rate, uint32_t bandwidth, uint8_t sf, bool impl_head, std::vector< uint16_t > sync_word)