GNU Radio's LORA_SDR Package
hamming_enc_impl.h
Go to the documentation of this file.
1#ifndef INCLUDED_LORA_HAMMING_ENC_IMPL_H
2#define INCLUDED_LORA_HAMMING_ENC_IMPL_H
3
5
6namespace gr {
7namespace lora_sdr {
8
10private:
11 /**
12 * @brief Transmission coding rate
13 *
14 */
15 uint8_t m_cr;
16
17 /**
18 * @brief Transmission spreading factor
19 *
20 */
21 uint8_t m_sf;
22
23 /**
24 * @brief count the number of processed items in the current frame
25 *
26 */
27 int m_cnt;
28
29public:
30 /**
31 * @brief Construct a new hamming enc impl object
32 *
33 * @param cr : coding rate
34 * @param sf : spreading factor
35 */
36 hamming_enc_impl(uint8_t cr, uint8_t sf);
37
38 /**
39 * @brief Destroy the hamming enc impl object
40 *
41 */
43
44 /**
45 * @brief Main function that does the actual hamming encoding.
46 * With cr : coding rate, and sf : spreading factor
47 *
48 * @param noutput_items : number of output items
49 * @param input_items : number of input items
50 * @param output_items : number of output items
51 * @return int
52 */
53 int work(int noutput_items, gr_vector_const_void_star &input_items,
54 gr_vector_void_star &output_items);
55};
56
57} // namespace lora_sdr
58} // namespace gr
59
60#endif /* INCLUDED_LORA_HAMMING_ENC_IMPL_H */
Definition: hamming_enc_impl.h:9
hamming_enc_impl(uint8_t cr, uint8_t sf)
Construct a new hamming enc impl object.
~hamming_enc_impl()
Destroy the hamming enc impl object.
int work(int noutput_items, gr_vector_const_void_star &input_items, gr_vector_void_star &output_items)
Main function that does the actual hamming encoding. With cr : coding rate, and sf : spreading factor...
Add hamming code to the to be sent playload. This means extra party bits are added to the payload to ...
Definition: hamming_enc.h:39
Definition: add_crc.h:28