da9249446c22f1fdf2620294945696ab7be141ea
cargo-fuzz defaults to x86_64-unknown-linux-musl on Linux so ASAN can statically link, but dtolnay/rust-toolchain@nightly doesn't ship a musl std and GH runners don't have it preinstalled — build failed with 'can't find crate for core' on byteorder. Pinning both fuzz build and fuzz run to the gnu target uses the std that comes with the toolchain and works out of the box.
donglora-protocol
Wire protocol types and COBS framing for DongLoRa, shared between the
firmware and host crates (client-rs, mux-rs, bridge). no_std,
zero-alloc, fixed-width little-endian — see the firmware repo's
PROTOCOL.md for the full spec.
Install
# Embedded / firmware (defmt::Format derives on by default):
donglora-protocol = "0.1"
# Host (no defmt):
donglora-protocol = { version = "0.1", default-features = false }
Layout
src/lib.rs—Command,Response,RadioConfig,Bandwidth,ErrorCodeplus constants and validation/resolve helpers.src/framing.rs—CobsDecoder(streaming) andcobs_encode_response.
Features
| Feature | Default | What it does |
|---|---|---|
defmt |
yes | Derive defmt::Format on public enums. |
std |
no | Enable Debug-based niceties for host-side fuzz / proptest. |
Testing
The crate ships its own quality gate via just test:
| Gate | What runs |
|---|---|
test-unit |
nextest across all feature permutations + doc tests |
test-clippy |
-D warnings across all feature permutations |
test-fmt |
cargo fmt -- --check |
test-doc |
cargo doc --no-deps --all-features |
test-deny |
cargo deny check |
test-fuzz |
60 s on each of 7 cargo-fuzz targets (nightly) |
test-miri |
miri on lib + vector tests, both feature shapes (nightly) |
test-mutants |
cargo-mutants under both feature configurations |
The proptest suite alone exercises ~1.13M test cases per run.
License
MIT — see LICENSE.
Languages
Rust
98.6%
Just
1.4%