24#ifndef INCLUDED_SATNOGS_ARGOS_LDR_DECODER_H
25#define INCLUDED_SATNOGS_ARGOS_LDR_DECODER_H
53 using sptr = std::shared_ptr<argos_ldr_decoder>;
54 static sptr make(
bool crc_check =
true,
size_t max_frame_len = 64);
74 typedef enum { NO_SYNC, IN_SYNC, DECODING } decoding_state_t;
76 const bool d_crc_check;
77 const size_t d_max_frame_len;
78 decoding_state_t d_state;
81 size_t d_received_bytes;
82 size_t d_decoded_bits;
83 uint8_t* d_frame_buffer;
84 std::deque<uint8_t> d_bitstream;
86 uint64_t d_frame_start;
87 uint64_t d_sample_cnt;
90 void enter_sync_state();
91 void enter_decoding_state();
96 inline void decode_1b(uint8_t in);
#define SATNOGS_API
Definition: api.h:19
ARGOS Low Data Rate HDLC decoder.
Definition: argos_ldr_decoder.h:42
std::shared_ptr< argos_ldr_decoder > sptr
Definition: argos_ldr_decoder.h:53
static sptr make(bool crc_check=true, size_t max_frame_len=64)
argos_ldr_decoder(bool crc_check=true, size_t max_frame_len=64)
decoder_status_t decode(const void *in, int len)
Abstract class that provided the API for the c decoders.
Definition: decoder.h:71
class decoder_status decoder_status_t
Definition: decoder.h:56
Definition: amsat_duv_decoder.h:29