Back to Fprime

Svc::ComAggregator

Svc/ComAggregator/docs/sdd.md

4.3.03.2 KB
Original Source

Svc::ComAggregator

Aggregates buffers in the downlink chain. This is for use with systems that have fixed size frames (e.g. CCSDS TM) that needed internal aggregation.

[!CAUTION] Svc::ComAggregator does not preserve context.

Requirements

IDDescriptionVerification
Svc-ComAggregator-001ComAggregator shall accept incoming downlink data as Fw::Buffer, ComCfg::FrameContext pairs and append the buffer into the aggregate space permittingUnit-Test
Svc-ComAggregator-002ComAggregator shall hold the incoming buffer when there is insufficient space in the aggregate buffer.Unit-Test
Svc-ComAggregator-003ComAggregator shall send the current aggregate buffer when the incoming buffer is held due to overflow.Unit-Test
Svc-ComAggregator-004ComAggregator shall send the current aggregate buffer when it receives a timeout trigger if and only if the aggregate is non-empty.Unit-Test
Svc-ComAggregator-005ComAggregator shall clear aggregation state when a Fw::Success::SUCCESS communication status is received back.Unit-Test
Svc-ComAggregator-006ComAggregator shall preserve the order of received buffers when forming each aggregate and across aggregate sends.Unit-Test
Svc-ComAggregator-007ComAggregator shall interoperate with the Communication Adapter Interface protocol. Specifically, it shall pass through Fw::Success::SUCCESS and Fw::Success::FAILURE statuses per the Framer Status Protocol, including the initial start-up SUCCESS and any recovery SUCCESS following a FAILURE.Unit-Test

Design

Svc.ComAggregator implements Svc.Framer. Additionally, it has a Svc.Sched timeout port enabling timeout to be driven via a rate group.

Threading Model

Svc.ComAggregator is an active component whose input ports are all sync: port handlers run on the caller's thread and do no work beyond sending a signal to the AggregationMachine state machine instance. State machine signals are internally enqueued on the component's message queue, so all state machine actions and guards execute serially on the component's own thread. This keeps callers non-blocking while ensuring the aggregation state (frame buffer, held buffer, last context) is only touched from one thread. The only state shared across threads is the buffer ownership flag, which is an atomic exchanged in dataReturnIn_handler (caller thread) and doSend (component thread).