dstar_gateway_core/slowdata/mod.rs
1//! D-STAR slow data sub-codec.
2//!
3//! Slow data is the 3 bytes-per-voice-frame side channel that
4//! carries text status messages, GPS NMEA passthrough, fast data,
5//! and header retransmissions for late joiners. Per JARL spec.
6//!
7//! On the wire, slow data bytes are XOR-scrambled with a 3-byte
8//! key (`0x70 0x4F 0x93`). The `scrambler` submodule handles
9//! scramble/descramble; the [`scramble`] and [`descramble`] functions
10//! are re-exported here. The `assembler` submodule accumulates
11//! 3-byte fragments across consecutive frames into complete blocks
12//! of type [`SlowDataBlockKind`]; use [`SlowDataAssembler`] to
13//! drive it.
14//!
15//! Reference: `ircDDBGateway/Common/SlowDataEncoder.cpp`,
16//! `ircDDBGateway/Common/DStarDefines.h:85-92, 111-113`.
17
18mod assembler;
19mod block;
20mod encoder;
21mod error;
22mod scrambler;
23mod text_collector;
24
25pub use assembler::SlowDataAssembler;
26pub use block::{SlowDataBlock, SlowDataBlockKind, SlowDataText};
27pub use encoder::encode_text_message;
28pub use error::SlowDataError;
29pub use scrambler::{descramble, scramble};
30pub use text_collector::{MAX_MESSAGE_LEN, SlowDataTextCollector};