The license is now changed. This project will be dual licensed under the PolyForm Non-commercial license and a separate commercial license to be determined later. A new contributing section was added so that there will be no ambiguity about how the license will be applied in that domain.
75 lines
1.9 KiB
Markdown
75 lines
1.9 KiB
Markdown
# ccsds_spp
|
|
|
|
A `no_std`, heapless Rust implementation of the
|
|
[CCSDS Space Packet Protocol][SPP], suitable for embedded and real-time
|
|
systems.
|
|
|
|
This library is intended for use in satellite software, space simulation,
|
|
and telemetry/telecommand tooling. It is designed to be robust, portable,
|
|
and usable in constrained environments. No allocator required.
|
|
|
|
---
|
|
|
|
## Features
|
|
|
|
* `no_std` compatible
|
|
* Heapless: works in memory-constrained environments
|
|
* Bit-accurate parsing and encoding
|
|
* `FromBits` / `IntoBits` traits for masked operations
|
|
* CCSDS-compliant `Version`, `PacketType`, `APID` support
|
|
* Designed for integration into embedded systems or FFI-safe libraries
|
|
|
|
---
|
|
|
|
|
|
## Example
|
|
|
|
```rust
|
|
use ccsds_space_packet::{PacketHeader, PacketType, Version, ApId};
|
|
|
|
let mut header = PacketHeader { data: [0u8; 6] };
|
|
|
|
header.set_version(Version::One);
|
|
header.set_packet_type(PacketType::Telemetry);
|
|
header.set_ap_id(ApId::from(42));
|
|
|
|
assert_eq!(header.get_version(), Version::One);
|
|
assert_eq!(header.get_packet_type(), PacketType::Telemetry);
|
|
assert_eq!(u16::from(header.get_ap_id()), 42);
|
|
```
|
|
|
|
## Design Notes
|
|
|
|
This is a work in progress.
|
|
|
|
Focus is on correctness and portability over performance for now.
|
|
|
|
Library avoids panics where possible and returns Result<T, &str> for error handling.
|
|
|
|
|
|
## References
|
|
[SPP]: https://ccsds.org/wp-content/uploads/gravity_forms/5-448e85c647331d9cbaf66c096458bdd5/2025/01//133x0b2e2.pdf "CCSDS Space Packet Protocol PDF"
|
|
|
|
|
|
---
|
|
|
|
|
|
## Contributing
|
|
|
|
Contributions are welcome. Please see CONTRIBUTING.md for terms and details.
|
|
|
|
|
|
## Copyright & License
|
|
|
|
Copyright © 2025 CyberMages LLC
|
|
|
|
This project is licensed under the PolyForm Noncommercial License 1.0.0.
|
|
|
|
You may use, modify, and redistribute this software for non-commercial purposes
|
|
only.
|
|
|
|
The full license text is available in the LICENSE.md file.
|
|
|
|
Commercial use requires a separate commercial license.
|
|
Contact: jason@cybermagesllc.com
|