ATLAS Offline Software
Loading...
Searching...
No Matches
SCT_ByteStreamErrors.h File Reference

Define SCT byte stream errors and utility methods. More...

#include <array>
#include <vector>
#include <cstdint>
Include dependency graph for SCT_ByteStreamErrors.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Namespaces

namespace  SCT_ByteStreamErrors

Macros

#define SCT_ERRORTYPELIST(XYZ)
 Specifications of the data format and errors is found in [1] http://www-eng.lbl.gov/~jmjoseph/Atlas-SiROD/Manuals/usersManual-v164.pdf [2] http://cds.cern.ch/record/683741/files/ [3] https://twiki.cern.ch/twiki/bin/view/Atlas/SCTDaqErrors [4] https://twiki.cern.ch/twiki/bin/view/Atlas/ROBINFragmentErrors#Definition_of_the_first_status_e.
#define SCT_DO_ENUM(e)
#define SCT_DO_DESCRIPTION(e)

Enumerations

enum  SCT_ByteStreamErrors::ErrorType
 SCT byte stream error type enums used in SCT_RodDecoder, SCT_ByteStreamErrorsTool, SCTErrMonAlg. More...

Functions

template<ErrorType et>
static constexpr uint64_t SCT_ByteStreamErrors::maskUpTo ()
static constexpr uint64_t SCT_ByteStreamErrors::ABCDErrorMask ()
static constexpr uint64_t SCT_ByteStreamErrors::TempMaskedChipsMask ()
ErrorType SCT_ByteStreamErrors::TempMaskedChipToBit (const int chip)

Variables

static const std::vector< std::string > SCT_ByteStreamErrors::ErrorTypeDescription
 SCT byte stream error type strings used in SCTErrMonAlg.
static const std::vector< ErrorTypeSCT_ByteStreamErrors::BadErrors
 Bad error enums used in SCT_ByteStreamErrorsTool and SCTErrMonAlg.
static const std::vector< ErrorTypeSCT_ByteStreamErrors::LinkLevelBadErrors
 Bad error enums in FE-link level used in SCTErrMonAlg.
static const std::vector< ErrorTypeSCT_ByteStreamErrors::RodLevelBadErrors
 Bad error enums in ROD level used in SCTErrMonAlg.
static const std::vector< ErrorTypeSCT_ByteStreamErrors::LinkLevelErrors
 Error enums in FE-link level used in SCTErrMonAlg (assigned by SCT_RodDecoder::addSingleError)
static const std::vector< ErrorTypeSCT_ByteStreamErrors::RodLevelErrors
 Error enums in ROD level used in SCTErrMonAlg (assigned by SCT_RodDecoder::addRODError)

Detailed Description

Define SCT byte stream errors and utility methods.

Author
Susum.nosp@m.u.Od.nosp@m.a@cer.nosp@m.n.ch

Definition in file SCT_ByteStreamErrors.h.

Macro Definition Documentation

◆ SCT_DO_DESCRIPTION

#define SCT_DO_DESCRIPTION ( e)
Value:
#e,

Definition at line 169 of file SCT_ByteStreamErrors.h.

◆ SCT_DO_ENUM

#define SCT_DO_ENUM ( e)
Value:
e,

Definition at line 165 of file SCT_ByteStreamErrors.h.

◆ SCT_ERRORTYPELIST

#define SCT_ERRORTYPELIST ( XYZ)

Specifications of the data format and errors is found in [1] http://www-eng.lbl.gov/~jmjoseph/Atlas-SiROD/Manuals/usersManual-v164.pdf [2] http://cds.cern.ch/record/683741/files/ [3] https://twiki.cern.ch/twiki/bin/view/Atlas/SCTDaqErrors [4] https://twiki.cern.ch/twiki/bin/view/Atlas/ROBINFragmentErrors#Definition_of_the_first_status_e.

The following is almost a copy of description of https://its.cern.ch/jira/browse/ATLASRECTS-4444

Link header : table 27 of [1] 001ptlbKdMMMMMMM d = link masked by DSP (MaskedLink) t = time out error (TimeOutError) p = Preamble Error (PreambleError) l = L1 error (LVL1IDError) b = BCID error (BCIDError) M = link number (FormatterError if M>11)

Link trailer : table 16 of [1] 010zhvxxxxxxmmmm z = trailer bit error (TrailerError) h = header trailer limit error (HeaderTrailerLimitError) v = data overflow error (HeaderTrailerLimitError) m = dynamically masked chips to reduced data size at high pileup Not written in [1]. (TempMaskedChipX, X=0-5)

0 means no masked chip (always has been 0 until April 2017)

If Rx redundacy is not used, 1 means chips 0-5 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in link-0) 6 means chip 5 is temporarily masked. (TempMaskedChip5 in link-0) 7 means chips 6-11 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in link-1) 12 means chip 11 is temporarily masked. (TempMaskedChip5 in link-1)

If Rx redundacy is used and link-1 is not used, 1 means chips 0-11 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in both link-0 and link-1) 6 means chips 5-11 are temporarily masked. (TempMaskedChip5 in link-0 and TempMaskedChip0-TempMaskedChip5 in link-1) 7 means chips 6-11 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in link-1) 12 means chip 11 is temporarily masked. (TempMaskedChip5 in link-1)

If Rx redundacy is used and link-0 is not used, 1 means chips 0-5 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in link-0) 6 means chip 5 is temporarily masked. (TempMaskedChip5 in link-0) 7 means chips 6-11, 0-5 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in both link-0 and -1) 12 means chips 11, 0-5 are temporarily masked. (TempMaskedChip0-TempMaskedChip5 in link-0 and TempMaskedChip5 in link-1)

ABCD error : table 16 of [1] 000xxxxxxFFFFEEE F = FE number (ABCDError_ChipX, ABCDError_Invalid) E = ABC error code (ABCDError_ErrorX, ABCDError_Invalid)

Raw data : table 16 of [1] 011nnnxxWWWWWWWW n = count of raw data bits + 1 W = raw data (RawError)

ByteStreamParseError When invalid data word is found, this BS error is assigned.

MissingLinkHeaderError When hit, ABCD error or raw data appear earlier than header, this BS error is assigned. Since we cannot know which FE-link does not have header, we assign this error to all the FE-links without hit, ABCD error or raw data of the ROD.

ROD status words : table 32 of [1] Bit 16 TIM Clock Error (RODClockError) Bit 17 BOC Clock Error (RODClockError) Bit 20-23 DCS HV bits (Expanded. Not written in [1])

ROB status word : [4] Non-zero status word (ROBFragmentError) Bit 31 Discard: the ROBIN did not have a fragment for the requested L1ID because it is in "discard" mode. It therefore generated an empty fragment Bit 29 Lost: the ROBIN did not have a fragment for the requested L1ID. It therefore generated an empty fragment (MaskedROD) Bit 27 Truncation: the amount of data sent across S-Link for this fragment was larger than the maximum fragment size the ROBIN was configured to handle. Therefore this fragment has been truncated (TruncatedROD)

The detector event type of ROB (do not know where these are documented) Bit 20 : RODSimulatedData Bit 21 : Super-condensed mode (not BS error)

For enum to string conversion http://stackoverflow.com/questions/21456262/enum-to-string-in-c11

Definition at line 125 of file SCT_ByteStreamErrors.h.

125#define SCT_ERRORTYPELIST(XYZ) \
126 XYZ(ByteStreamParseError) \
127 XYZ(TimeOutError) \
128 XYZ(BCIDError) \
129 XYZ(LVL1IDError) \
130 XYZ(PreambleError) \
131 XYZ(FormatterError) \
132 XYZ(TrailerError) \
133 XYZ(TrailerOverflowError) \
134 XYZ(HeaderTrailerLimitError) \
135 XYZ(ABCDError) \
136 XYZ(RawError) \
137 XYZ(MaskedLink) \
138 XYZ(RODClockError) \
139 XYZ(TruncatedROD) \
140 XYZ(ROBFragmentError) \
141 XYZ(MissingLinkHeaderError) \
142 XYZ(MaskedROD) \
143 XYZ(ABCDError_Chip0) \
144 XYZ(ABCDError_Chip1) \
145 XYZ(ABCDError_Chip2) \
146 XYZ(ABCDError_Chip3) \
147 XYZ(ABCDError_Chip4) \
148 XYZ(ABCDError_Chip5) \
149 XYZ(ABCDError_Error1) \
150 XYZ(ABCDError_Error2) \
151 XYZ(ABCDError_Error4) \
152 XYZ(TempMaskedChip0) \
153 XYZ(TempMaskedChip1) \
154 XYZ(TempMaskedChip2) \
155 XYZ(TempMaskedChip3) \
156 XYZ(TempMaskedChip4) \
157 XYZ(TempMaskedChip5) \
158 XYZ(ABCDError_Error7) \
159 XYZ(ABCDError_Invalid) \
160 XYZ(RODSimulatedData) \
161 XYZ(NUM_ERROR_TYPES) // always have this one last, so we can use it as a loop index