GNU Radio's SATELLITES Package
pdu_scrambler.h
Go to the documentation of this file.
1 /* -*- c++ -*- */
2 /*
3  * Copyright 2022 Daniel Estevez <daniel@destevez.net>
4  *
5  * This file is part of gr-satellites
6  *
7  * SPDX-License-Identifier: GPL-3.0-or-later
8  *
9  */
10 
11 #ifndef INCLUDED_SATELLITES_PDU_SCRAMBLER_H
12 #define INCLUDED_SATELLITES_PDU_SCRAMBLER_H
13 
14 #include <gnuradio/block.h>
15 #include <satellites/api.h>
16 #include <vector>
17 
18 namespace gr {
19 namespace satellites {
20 
21 /*!
22  * \brief PDU Scrambler
23  * \ingroup satellites
24  *
25  * \details
26  * Uses a predefined sequence to implement a synchronous scrambler that acts
27  * on PDUs. The scrambling sequence needs to be longer than the PDUs that the
28  * block will process. PDUs which are longer than the sequence are dropped.
29  */
30 class SATELLITES_API pdu_scrambler : virtual public gr::block
31 {
32 public:
33  typedef boost::shared_ptr<pdu_scrambler> sptr;
34 
35  /*!
36  * \brief Build the PDU Scrambler block.
37  *
38  * \param sequence The scrambling sequence to use.
39  */
40  static sptr make(const std::vector<uint8_t>& sequence);
41 };
42 
43 } // namespace satellites
44 } // namespace gr
45 
46 #endif /* INCLUDED_SATELLITES_PDU_SCRAMBLER_H */
#define SATELLITES_API
Definition: api.h:31
PDU Scrambler.
Definition: pdu_scrambler.h:31
boost::shared_ptr< pdu_scrambler > sptr
Definition: pdu_scrambler.h:33
static sptr make(const std::vector< uint8_t > &sequence)
Build the PDU Scrambler block.
Definition: ax100_decode.h:17