Telemetry Recorder

Overview

The Telemetry Recorder is a component that needs to be customized for a RTC system. A tutorial on how to implement a specific recorder is provided in the Telemetry Recorder Tutorial.

Basic Operation

The Business Logic that is provided as a default (and should be enough for most use cases) start a RecordingThread. This RecordingThread waits for topics over a ipcq and sends them to a FitsRecorder. The FitsRecorder has to be implemented for each topic.

TelemetryRecorderBusinessLogic

The Business Logic controls the RecordingThread when reaching certain states. When “Enabling” the recording thread is instructed to open the FITS file and the ipc queue. When Disabling the processing (if it was running) is stopped and the FITS file and ipc queue get closed. When GoingRunning the processing in the thread is started and stops when the BusinessLogic switches to GoingIdle. When Updating, the sub-sample rate, output directory and telemetry subset can be changed. It is sufficient to instantiate a TelemetryRecorderBusinessLogic with the type of the Recorder. The Business Logic will then instantiate a RecordingThread that waits on the matching topic type for this recorder.

RecordingThread

The RecordingThread does not need to be modified as well. It is controlled from the BusinessLogic and holds the FitsRecorder and ipcq objects. This is basically the actual telemetry recorder. It will try to read for up to 100 milliseconds from the ipc queue. After processing the messages (if there where any) it will check for state changes from the BusinessLogic. If it is still in running state it will return to reading from the ipc queue. This means it might take up to 100 microseconds or an earlier message on the ipc queue to change the state of the recorder.

RecorderIf

This class is an abstract class that can be used to implement a recorder. It does not do any FITS related operations so it could be used to record into other formats if needed.

FitsRecorder

This base class is intended to be used when implementing a Telemetry Recorder that writes to FITS files. It implements the open and close operations for the RecorderIf, so a FitsRecorder for a specific Topic only needs to implement the Write and SetTelemetrySubSet functions.