libSDRForge
Loading...
Searching...
No Matches
sdrforge.protocols.spectrum_zmq Namespace Reference

Optional ZeroMQ PUB transport for binary spectrum frames. More...

Classes

class  SpectrumZmqPublisher
 PUB adapter; caller owns its thread and invokes send_frame there. More...

Functions

bytes encode_spectrum (SpectrumFrame frame)
 Encode a versioned little-endian float32 spectrum frame.
SpectrumFrame decode_spectrum (bytes payload)
 Decode a complete frame without retaining the network buffer.

Variables

str TOPIC = b"sdrforge.v1.spectrum"
 _HEADER = struct.Struct("<4sBQQQI")

Detailed Description

Optional ZeroMQ PUB transport for binary spectrum frames.

Function Documentation

◆ decode_spectrum()

SpectrumFrame sdrforge.protocols.spectrum_zmq.decode_spectrum ( bytes payload)

Decode a complete frame without retaining the network buffer.

Parameters
payloadThe telemetry payload.
Returns
The operation result.

◆ encode_spectrum()

bytes sdrforge.protocols.spectrum_zmq.encode_spectrum ( SpectrumFrame frame)

Encode a versioned little-endian float32 spectrum frame.

Parameters
frameThe frame value.
Returns
The operation result.

Variable Documentation

◆ _HEADER

sdrforge.protocols.spectrum_zmq._HEADER = struct.Struct("<4sBQQQI")
protected

◆ TOPIC

str sdrforge.protocols.spectrum_zmq.TOPIC = b"sdrforge.v1.spectrum"