Next: Bibliography
Up: Event Decoding and I/O
Previous: Readout Configuration
  Contents
  Index
class Converter {
public: // data structures
enum ErrorSeverity { OK, WARNING, FATAL, IGNORE };
enum ErrorType {
// General errors
// (usually HW fatal errors: No way to decode data)
GEN_HBITSET=0, GEN_HBITNOTSET, GEN_ERRFLAG, GEN_HBIT2,
GEN_SMALLSIZE, GEN_SIZE, GEN_SUMLENGTH,
// Controller errors
CTRLR_ERRFLAG, CTRLR_SIZE, CTRLR_SIZEPARITY,
CTRLR_UNKNOWN, CTRLR_MULTIPLE, CTRLR_ABSENT,
CTRLR_EVTNUM, CTRLR_MODULESEQ, CTRLR_TIMESEQ,
// Module errors
MOD_UNEXPECTED, MOD_CHANNELSEQ,
// Data conversion errors
MAP_DET_ABSENT, MAP_SE_ABSENT, MAP_SE_MULTIPLE,
////
LAST_ERRORTYPE
};
struct ErrorDesc {
ErrorType type_;
Crate crate_;
CrateChannel channel_;
Detector detector_;
std::vector<uint16> data_;
ErrorDesc();
explicit ErrorDesc(ErrorType et);
};
public: // functions
// ...
void UseReadoutDB(ReadoutDB * db);
void SetSeverity(ErrorType, ErrorSeverity);
void SetCheckDepth(EventStage d);
ErrorSeverity Check ( const RawEvent & );
ErrorSeverity Convert ( const RawEvent &, ModEvent & );
ErrorSeverity QuickConvert ( const ModEvent &, DetEvent & );
ErrorSeverity QuickConvert ( const RawEvent &, DetEvent & );
const std::vector<ErrorDesc> & GetErrors() const;
std::string StrError() const;
};
Table 11:
Error types defined in class Converter.
HW fatal errors: No way to decode data |
GEN_HBITSET |
highest bit is set in the first word |
GEN_HBITNOTSET |
highest bit is NOT set in the last word |
GEN_ERRFLAG |
error flag in the last word |
GEN_HBIT2 |
two consequitive words with the highest bit |
GEN_SMALLSIZE |
data length less than 2 |
GEN_SIZE |
contradiction in data sizes: (read) vs (readout) |
GEN_SUMLENGTH |
contradiction in lengths: (read) vs (sum by controllers) |
Controller errors |
CTRLR_ERRFLAG |
controller error flag set |
CTRLR_SIZE |
real length is not equal the length from controller |
CTRLR_SIZEPARITY |
length is not even |
CTRLR_UNKNOWN |
unknown crate |
CTRLR_MULTIPLE |
multiple crate (already encountered) |
CTRLR_ABSENT |
expected crate is NOT present |
CTRLR_EVTNUM |
different event numbers |
CTRLR_MODULESEQ |
wrong module sequence |
CTRLR_TIMESEQ |
wrong time sequence |
Module errors |
MOD_UNEXPECTED |
unexpected module number |
MOD_CHANNELSEQ |
wrong channel sequence |
data conversion errors |
MAP_DET_ABSENT |
no detector for (crate, module) |
MAP_SE_ABSENT |
no sensitive element for (detector,module,channel) |
MAP_SE_MULTIPLE |
ambiguous (detector,module,channel)
sensitive element |
|
Next: Bibliography
Up: Event Decoding and I/O
Previous: Readout Configuration
  Contents
  Index
Alexander V.Inyakin
2002-04-05