Struct wfm_stage_t¶
One transform, and — the whole point — the fields it covers. More...
#include <wfm_frame.h>
Public Attributes¶
| Type | Name |
|---|---|
| unsigned | depth |
| unsigned | emit_den |
| unsigned | emit_num |
| unsigned | first_field |
| uint32_t | kind |
| unsigned | n_fields |
| unsigned | unit_bits |
Detailed Description¶
n_fields is load-bearing, not a refinement. ccsds_tm_frame.h states the failure this prevents: *"any chain of optional transforms
applied to 'the frame' is right at three stage boundaries and wrong at
the fourth, and wrong in the direction that still encodes, still decodes
against itself, and syncs to nothing."* A stage that inherited "whatever
ran before me" would be that chain. CCSDS is the case that proves it — the marker is covered by the inner code and by neither the outer code nor the randomiser — and any frame with a sync word has the same shape.
The cover is what the stage OCCUPIES on the wire, so for a code it is the information and the check symbols it derives. What the stage reads is the cover minus the fields it derives, which is why both are one declaration rather than two that can disagree.
Public Attributes Documentation¶
variable depth¶
RS / INTERLEAVE: interleaving depth
variable emit_den¶
variable emit_num¶
A stage that consumes the assembled frame and emits a DIFFERENT stream sets these: the output is n * emit_num / emit_den bits. emit_num == 0 means the stage stays inside the frame. Only the inner code does the former today, and it is exactly why wfm_frame_desc_layout_t reports frame_bits and out_bits as two numbers rather than one.
An emitting stage covers the WHOLE frame, and a description may hold at most one. Both are properties of wfm_frame_assemble rather than rules invented for their own sake: it hands emit the whole assembled frame and requires exactly out_bits back, so a cover narrower than the frame describes something no kernel is ever asked to do, and a second emitting stage would have to consume the first one's output, which nothing passes it. wfm_frame_desc_layout refuses both — see there for why that is the right place to say so. A stage that rewrites part of the frame in place is what a partial cover is FOR; that stage sets emit_num = 0 and an in_unit kernel.
variable first_field¶
first field covered
variable kind¶
The stage's kind: a wfm_stage_kind_t value, or a caller's own from WFM_STAGE_USER up. Open on purpose — see the enum.
variable n_fields¶
fields covered; 0 = does not run
variable unit_bits¶
INTERLEAVE: bits per interleaved unit; 0 reads as 1. Not folded into depth, because the two are independent — depth 8 over octets and depth 8 over bits are different permutations of the same span, and only one of them protects an octet-oriented outer code.
The documentation for this class was generated from the following file native/inc/wfm/wfm_frame.h