GNU Radio's SATNOGS Package
|
A IEEE 802.15.4 like decoder. More...
#include <ieee802_15_4_variant_decoder.h>
Public Member Functions | |
ieee802_15_4_variant_decoder (const std::vector< uint8_t > &preamble, size_t preamble_threshold, const std::vector< uint8_t > &sync, size_t sync_threshold, crc::crc_t crc, whitening::whitening_sptr descrambler, bool var_len=true, size_t max_len=1024, bool drop_invalid=true, bool rs=false) | |
~ieee802_15_4_variant_decoder () | |
decoder_status_t | decode (const void *in, int len) |
void | reset () |
size_t | input_multiple () const |
![]() | |
int | unique_id () const |
decoder (const std::string &name, const std::string &version, int input_item_size, size_t max_frame_len=8192) | |
virtual | ~decoder () |
size_t | max_frame_len () const |
int | sizeof_input_item () const |
std::string | name () const |
std::string | version () const |
Static Public Member Functions | |
static decoder::decoder_sptr | make (const std::vector< uint8_t > &preamble, size_t preamble_threshold, const std::vector< uint8_t > &sync, size_t sync_threshold, crc::crc_t crc, whitening::whitening_sptr descrambler, bool var_len=true, size_t max_len=1024, bool drop_invalid=true, bool rs=false) |
Additional Inherited Members | |
![]() | |
static int | base_unique_id |
![]() | |
void | incr_nitems_read (size_t nitems) |
uint64_t | nitems_read () const |
A IEEE 802.15.4 like decoder.
The IEEE 802.15.4 uses the well known preamble + sync word synchronization scheme. Many popular on Cubesats ICs like the Texas Instruments CC1xxx family or the AXxxxx of On Semiconductors follow this scheme. This decoder class provides a generic way to decode signals following this framing scheme.
gr::satnogs::ieee802_15_4_variant_decoder::ieee802_15_4_variant_decoder | ( | const std::vector< uint8_t > & | preamble, |
size_t | preamble_threshold, | ||
const std::vector< uint8_t > & | sync, | ||
size_t | sync_threshold, | ||
crc::crc_t | crc, | ||
whitening::whitening_sptr | descrambler, | ||
bool | var_len = true , |
||
size_t | max_len = 1024 , |
||
bool | drop_invalid = true , |
||
bool | rs = false |
||
) |
gr::satnogs::ieee802_15_4_variant_decoder::~ieee802_15_4_variant_decoder | ( | ) |
|
virtual |
Decodes a buffer of input items contained in the in buffer. This method is called continuously by the frame_decoder. Based on the returned status data, the frame_decoder() instructs properly the GNU Radio scheduler and/or propagates decoded data.
As the number of input items may not enough to decode a frame, each decoder should keep internal state, so decoding can be accomplished after an arbitrary number of calls to this method
in | the input items |
nitems | the number of input items contained in the in buffer |
Implements gr::satnogs::decoder.
|
virtual |
Reimplemented from gr::satnogs::decoder.
|
static |
preamble | the preamble should be a repeated word. Note that due to AGC settling, the receiver may not receive the whole preamble. If the preamble is indeed a repeated pattern, a portion of it can be given as parameter. The block should be able to deal with this. However, a quite small subset may lead to a larger number of false alarms |
preamble_threshold | the maximum number of bits that are allowed to be wrong at the preamble |
sync | the synchronization work following the preamble |
sync_threshold | the maximum number of bits that are allowed to be wrong at the synchronization word |
crc | the CRC scheme to use |
descrambler | if set, data will be first descrambled by this descrambling method |
var_len | if set to true, variable length decoding is used. Otherwise, the max_len parameter indicates the fixed frame size |
max_len | the maximum allowed decode-able frame length |
rs | if set, the decoder will perform RS(255,223) decoding prior the descrambling and the CRC |
|
virtual |
Resets the internal state of the decoder to the initial defaults
Implements gr::satnogs::decoder.