Package org.yamcs.pus

Class Pus1Verifier

All Implemented Interfaces:
AlgorithmExecutor

public class Pus1Verifier extends AbstractAlgorithmExecutor
PUS1 verifier.

The algorithm verifies one stage which is given as verificationStage in the constructor. For exmaple verificationStage=3 works for the stage Start - i.e. verifies reports PUS(1,3) and PUS(1,4).

The algorithm requires at least 5 inputs, which must be defined in this exact order in the algorithm input list:

  • sentApid - the APID of the sent command.
  • sentSeqCount - the Sequence Count of the command sent, usually obtained from the command history.
  • rcvdApid - the APID present in the PUS1 report.
  • rcvdSeqCount - the Sequence Count in the PUS1 report.
  • reportSubType - the PUS1 sub-type of the incoming PUS1 report.
The sentApid, rcvdApid, rcvdSeqCount and reportSubType are expected to have a raw type as unsigned integer. The sentSeqCount is filled in by the post-processor and is expected to be signed 32 bit integer (the reason for that is becuase it is converted from a command history attribute)

In addition to these 5, other inputs may be used to get values in case of failure.

The algorithm checks the following conditions:

  • sentApid == rcvdApid
  • sentSeqCount == rcvdSeqCount
  • The reportSubType=verificationStage or reportSubType=verificationStage+1

If these conditions are met:

  • If reportSubType == verificationStage, the verifier returns success.
  • If reportSubType == verificationStage + 1, the verifier returns failure, using the provided template to construct the failure message. The template can use the inputs of the algorithm for message formatting.
  • Field Details

  • Constructor Details

  • Method Details

    • execute

      public AlgorithmExecutionResult execute(long acqTime, long genTime, ProcessingData pdata)
      Description copied from interface: AlgorithmExecutor
      Runs the associated algorithm with the latest InputParameters.

      Should throw an exception if there is an error within the algorithm.

      The error message and error count will be remembered and available to external clients via the API.

      The processing data parameter is passed if required to calibrate the output values. It shall not be updated by the executor as it is done in the ActiveAlgorithm

      Returns:
      the output parameters, if any