ccsds #
The CCSDS protocol suite for OCaml, as one package.
A spacecraft and its ground station talk through a stack of standards from the
Consultative Committee for Space Data Systems (CCSDS): channel codes that
survive a noisy radio link, transfer frames that multiplex virtual channels,
space packets, file delivery, and navigation messages exchanged between
operators. Each layer lives in its own OCaml package in this suite, so an
application depends only on what it uses. ccsds depends on 34 of them and
re-exports their libraries, for a ground-segment tool that wants the whole
link stack with one dependency. It adds no code of its own. With the related
packages below, the suite covers the full stack, from RF signal processing and
channel coding through data link, space packet, file delivery and navigation
data messages to mission operations.
The layers stack as follows, from the radio up (the CCSDS report 130.2-G-3,
in docs/, draws the same stack). The physical layer carries symbols.
Synchronisation and channel coding (131.0, 231.0) wraps each transfer frame
in a sync marker and an error-correcting code. A transfer frame (TM, TC, AOS
or USLP) carries data for one virtual channel, a logical stream that shares
the link with others. Space packets (133.0) travel inside the frames: they
are variable-length application messages addressed by an 11-bit application
process identifier (APID). File delivery (CFDP) and the Bundle Protocol run
on top of packets.
The odoc page of the package (index.mld) lists the same packages by CCSDS
document number, with links into their documentation.
Installation #
Install with opam:
$ opam install ccsds
If opam cannot find the package, it may not yet be released in the public
opam-repository. Add the overlay repository, then install it:
$ opam repo add samoht https://tangled.org/gazagnaire.org/opam-overlay.git
$ opam update
$ opam install ccsds
Packages included #
These packages are dependencies of ccsds, and their libraries are
re-exported by it.
Data compression (121 series) #
| Package | Standard | Description |
|---|---|---|
rice |
121.0-B | Rice/Golomb adaptive entropy coding |
Channel coding (131 and 142 series) #
The Attached Sync Marker (ASM, 0x1ACFFC1D) is a fixed 32-bit pattern
placed before each downlink frame so that the receiver can find frame
boundaries in a stream of bits. Randomisation XORs the frame with a fixed
pseudo-random sequence, so that long runs of equal bits do not make the
receiver lose its bit clock. A CLTU (Communications Link Transmission Unit)
is the uplink counterpart: a start sequence, the coded telecommand frame and
a tail sequence. RS(255,223) is a Reed-Solomon code over bytes that adds 32
check bytes to 223 data bytes and corrects up to 16 wrong bytes (RS(255,239)
adds 16 and corrects 8). K=7 is the constraint length of the convolutional
code: each output bit depends on the current input bit and the six before
it.
| Package | Standard | Description |
|---|---|---|
scc |
131.0-B, 231.0-B | Synchronisation and channel coding (ASM, randomisation, CLTU) |
viterbi |
131.0-B | Convolutional decoder (rate 1/2, K=7) |
turbo |
131.0-B | Turbo codes (QPP interleaver) |
ldpc |
131.0-B, 231.0-B | LDPC codes: AR4JA and short block-length, belief propagation |
reed-solomon |
131.0-B | RS(255,223) and RS(255,239) |
erasure |
131.5-B | Erasure codes (GF(2^8) Cauchy matrix) |
flexacm |
131.2-B | Flexible Advanced Coding and Modulation |
occs |
142.0-B | Optical coding and synchronisation (HPE, O3K) |
Data link (132, 211, 232 and 732 series) #
| Package | Standard | Description |
|---|---|---|
tm |
132.0-B | TM transfer frames, VCDU multiplexing |
tc |
232.0-B | TC transfer frames |
cop1 |
232.1-B | Communications Operation Procedure-1 |
clcw |
232.0-B | Command Link Control Word |
aos |
732.0-B | AOS transfer frames |
uslp |
732.1-B | Unified Space Link Protocol |
proximity1 |
211.0-B | Proximity-1 space link |
Space packets and security (133 and 355 series) #
| Package | Standard | Description |
|---|---|---|
space-packet |
133.0-B | Space Packet Protocol |
sdls |
355.0-B | Space Data Link Security |
fsr |
355.1-B | Frame Security Report |
File delivery and networking (727 and 734 series) #
| Package | Standard | Description |
|---|---|---|
cfdp |
727.0-B | CCSDS File Delivery Protocol |
ltp |
734.1-B | Licklider Transmission Protocol |
bundle |
RFC 9171 | Bundle Protocol version 7 |
tcpcl |
RFC 9174 | TCP Convergence-Layer Protocol version 4 |
udpcl |
RFC 7122 | UDP Convergence Layer |
CCSDS 734.2-B-1 specifies BPv6
(RFC 5050). The CCSDS profile of BPv7 is the experimental
734.20-O-1; the bundle entry above
names the IETF protocol it implements, and does not claim conformance to that
profile. 734.3-B-1 specifies
Schedule-Aware Bundle Routing, not TCPCL.
Navigation data messages (500 series) #
| Package | Standard | Description |
|---|---|---|
odm |
502.0-B | Orbit data messages (OEM, OPM) |
tdm |
503.0-B | Tracking Data Message |
aem |
504.0-B | Attitude Data Messages (AEM) |
ocm |
505.0-B | Orbit data with covariance and manoeuvres (OCM) |
cdm |
508.0-B | Conjunction Data Message |
rdm |
508.1-B | Re-entry Data Message |
Ground segment (900 series) #
| Package | Standard | Description |
|---|---|---|
sle |
913.1-B | Space Link Extension (RAF, RCF, FCLTU) |
Signal processing #
| Package | Description |
|---|---|
dsp |
FIR and RRC filters, decimation, AGC, IQ reader |
demod |
BPSK and QPSK demodulation (Costas loop, timing recovery) |
rtlsdr |
RTL-SDR IQ sample reader and synthetic signals |
Related packages #
These packages belong to the same suite but are not dependencies of ccsds;
install them separately. ECSS, the European Cooperation for Space
Standardization, publishes the engineering standards European missions
follow. Its Packet Utilisation Standard (ECSS-E-ST-70-41C) fixes the content
of space packets as numbered services, for example service 1 (telecommand
verification reports) or service 17 (connection test), so that ground and
spacecraft agree on what each command and report means.
| Package | Standard | Description |
|---|---|---|
idc |
CCSDS 122.0-B | Image Data Compression: the 9/7 Float and Integer DWT followed by the Bit Plane Encoder, with segment headers, byte and quality limits |
hcomp |
CCSDS 123.0-B | Lossless and near-lossless multispectral and hyperspectral image compression: the adaptive linear predictor, the sample-adaptive, hybrid and block-adaptive entropy coders, and the header |
tcf |
CCSDS 301.0-B | Time code formats (CUC, CDS) |
mal |
CCSDS 521.0-B | Mission Operations Abstraction Layer |
xtce |
CCSDS 660.1-B | XML Telemetric and Command Exchange |
csts |
CCSDS 922.x-B | Cross Support Transfer Services |
bpsec |
RFC 9172 | Bundle Protocol Security |
pus |
ECSS-E-ST-70-41C | Packet Utilisation Standard |
spacewire |
ECSS-E-ST-50-12C | SpaceWire and RMAP |
spacefibre |
ECSS-E-ST-50-11C | SpaceFibre data frames |
kvn |
Key-Value Notation, the text form of navigation messages | |
sgp4, kepler |
Orbit propagation | |
collision, cam |
Collision probability and avoidance manoeuvres |
Licence #
ISC. See LICENSE.md.