libsdr
0.1.0
A simple SDR library
|
Implements a POCSAG decoder. More...
#include <pocsag.hh>
Classes | |
class | Message |
A pocsag message. More... | |
Public Member Functions | |
POCSAG () | |
Constructor. More... | |
void | config (const Config &src_cfg) |
Needs to be implemented by any sub-type to check and perform the configuration of the node. More... | |
void | process (const Buffer< uint8_t > &buffer, bool allow_overwrite) |
Needs to be implemented by any sub-type to process the received data. More... | |
virtual void | handleMessages () |
Can be overwritten by any other implementation to process the received messages stored in _queue . More... | |
Public Member Functions inherited from sdr::Sink< uint8_t > | |
Sink () | |
Constructor. More... | |
virtual | ~Sink () |
Drestructor. More... | |
virtual void | handleBuffer (const RawBuffer &buffer, bool allow_overwrite) |
Re-implemented from SinkBase . More... | |
Public Member Functions inherited from sdr::SinkBase | |
SinkBase () | |
Constructor. More... | |
virtual | ~SinkBase () |
Destructor. More... | |
Protected Types | |
enum | State { WAIT, RECEIVE, CHECK_CONTINUE } |
The possible states of the POGSAC receiver. More... | |
Protected Member Functions | |
void | _process_word (uint32_t word) |
Process a POGSAC word. More... | |
void | _reset_message () |
Clear the message. More... | |
void | _finish_message () |
Add the (non-empty) message to the queue. More... | |
Protected Attributes | |
State | _state |
The current state. More... | |
uint64_t | _bits |
The last received bits. More... | |
uint8_t | _bitcount |
The number of received bits. More... | |
uint8_t | _slot |
The current slot. More... | |
Message | _message |
The current message. More... | |
std::list< Message > | _queue |
The completed messages. More... | |
Implements a POCSAG decoder.
In conjecture with the FSKDetector
or AFSDetector
and the BitStream
nodes, this node can be used to receive and process POCSAG (pages) messages.
The POCSAG protocol is defined as followig:
1) at least 576 bits of alternating value (1 0 1 0 ...) 2) a 32-bit sync word (0x7CD215D8) 3) 2x8 data words (each 32 bit) 4) If data left to send -> continue with step 2
Unused data words are send as 0x7A89C197. Each dataword is either a address word (bit 31 = 0) or message word (bit 31 = 1).
POCSAG::POCSAG | ( | ) |
Constructor.
|
protected |
Add the (non-empty) message to the queue.
|
protected |
Process a POGSAC word.
|
protected |
Clear the message.
|
virtual |
Needs to be implemented by any sub-type to check and perform the configuration of the node.
Implements sdr::SinkBase.
|
virtual |
Can be overwritten by any other implementation to process the received messages stored in _queue
.
Reimplemented in sdr::POCSAGDump.
|
virtual |
Needs to be implemented by any sub-type to process the received data.
Implements sdr::Sink< uint8_t >.
|
protected |
The number of received bits.
|
protected |
The last received bits.
|
protected |
The current message.
|
protected |
The completed messages.
|
protected |
The current slot.
|
protected |
The current state.