diff --git a/CHANGELOG.md b/CHANGELOG.md index 8016c3fe..c51e71e8 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -10,7 +10,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/). ### Added - Transparent LoRa radio over USB CDC-ACM (VID `1209`, PID `5741`) -- COBS-framed postcard binary protocol (8 commands, 6 responses) +- COBS-framed fixed-size LE binary protocol (8 commands, 6 responses) - Radio configuration: frequency, bandwidth, spreading factor, coding rate, TX power - Continuous RX mode with RSSI/SNR per packet - Single-shot TX with optional per-packet config override diff --git a/DESIGN.md b/DESIGN.md index 574f4825..172511f9 100644 --- a/DESIGN.md +++ b/DESIGN.md @@ -97,8 +97,8 @@ keep, but never prematurely. | Decision | Choice | Why | |---|---|---| -| USB framing | COBS + postcard | Compact, `no_std` native, battle-tested | -| Serialization | postcard + serde | Zero-alloc binary codec, perfect for embedded | +| USB framing | COBS | Compact, `no_std`, zero-overhead frame delimiting | +| Serialization | Fixed-size LE | Every field at a known offset. No varints, no surprises | | Async runtime | Embassy | De facto standard for async embedded Rust | | Display | Radio status dashboard | Freq, BW, SF, packet counts, RSSI/SNR | | Boot behavior | Idle until host commands | Host-driven principle | diff --git a/README.md b/README.md index e7d013c0..fdebc329 100644 --- a/README.md +++ b/README.md @@ -23,10 +23,9 @@ and gets out of the way. No mesh logic, no protocol opinions, no config files. ## Protocol -DongLoRa speaks a binary protocol over USB CDC-ACM: COBS-framed -[postcard](https://postcard.jamesmunns.com/) messages. 8 commands, -6 response types — everything you need to configure the radio, -transmit, and receive. +DongLoRa speaks a binary protocol over USB CDC-ACM: COBS-framed, +fixed-size little-endian messages. 8 commands, 6 response types — +everything you need to configure the radio, transmit, and receive. See **[docs/PROTOCOL.md](docs/PROTOCOL.md)** for the complete wire format specification with worked examples. diff --git a/examples/donglora.py b/examples/donglora.py index 04888915..8ca43d73 100644 --- a/examples/donglora.py +++ b/examples/donglora.py @@ -1,7 +1,7 @@ """DongLoRa host library — connect, configure, send/receive LoRa packets. This is a minimal helper for the example scripts. It implements the -DongLoRa USB protocol (COBS-framed postcard) just enough to be useful. +DongLoRa USB protocol (COBS-framed fixed-size LE) just enough to be useful. See docs/PROTOCOL.md for the full specification. """ # /// script