![]() |
Project
|
Decoder of the ALTRO data in the raw page. More...
#include <AltroDecoder.h>
Public Member Functions | |
AltroDecoder (RawReaderMemory &reader) | |
Constructor. | |
~AltroDecoder ()=default | |
Destructor. | |
void | setMaxBunchLength (int maxBunchLength) |
Set the max. allowed bunch length. | |
void | decode () |
Decode the ALTRO stream. | |
const RCUTrailer & | getRCUTrailer () const |
Get reference to the RCU trailer object. | |
const std::vector< Channel > & | getChannels () const |
Get the reference to the channel container. | |
void | readRCUTrailer () |
Read RCU trailer for the current event in the raw buffer. | |
void | readChannels () |
Read channels for the current event in the raw buffer. | |
const std::vector< MinorAltroDecodingError > & | getMinorDecodingErrors () const |
Get list of minor decoding errors. | |
Decoder of the ALTRO data in the raw page.
This is a base class for reading raw data digits in Altro format. The class is able to read the RCU v3 and above formats. The main difference between the format V3 and older ones is in the coding of the 10-bit Altro payload words. In V3 3 10-bit words are coded in one 32-bit word. The bits 30 and 31 are used to identify the payload, altro header and RCU trailer contents.
Based on AliAltroRawStreamV3 and AliCaloRawStreamV3 by C. Cheshkov
Definition at line 300 of file AltroDecoder.h.
AltroDecoder::AltroDecoder | ( | RawReaderMemory & | reader | ) |
Constructor.
reader | Raw reader instance to be decoded |
Definition at line 23 of file AltroDecoder.cxx.
|
default |
Destructor.
void AltroDecoder::decode | ( | ) |
Decode the ALTRO stream.
AltroDecoderError | if the RCUTrailer or ALTRO payload cannot be decoded |
Decoding and checking the RCUTtrailer and all channels and bunches in the ALTRO stream. After successfull decoding the Decoder can provide a reference to the RCU trailer and a vector with the decoded chanenels, each containing its bunches.
Definition at line 30 of file AltroDecoder.cxx.
const std::vector< Channel > & AltroDecoder::getChannels | ( | ) | const |
Get the reference to the channel container.
AltroDecoderError | with CHANNEL_ERROR if the channel container was not initialized for the current event |
Definition at line 197 of file AltroDecoder.cxx.
|
inline |
Get list of minor decoding errors.
Definition at line 346 of file AltroDecoder.h.
const RCUTrailer & AltroDecoder::getRCUTrailer | ( | ) | const |
Get reference to the RCU trailer object.
AltroDecoderError | with type RCU_TRAILER_ERROR if the RCU trailer was not initialized |
Definition at line 189 of file AltroDecoder.cxx.
void AltroDecoder::readChannels | ( | ) |
Read channels for the current event in the raw buffer.
decode all words for channel
Definition at line 58 of file AltroDecoder.cxx.
void AltroDecoder::readRCUTrailer | ( | ) |
Read RCU trailer for the current event in the raw buffer.
Definition at line 38 of file AltroDecoder.cxx.
Set the max. allowed bunch length.
maxBunchLength | Max. allowed bunch lengths |
Rejects bunches in case the decoded bunch length or the decoded start time exceeds the maximum allowed bunch length.
Definition at line 315 of file AltroDecoder.h.