Skip to content
Snippets Groups Projects
Commit ff01cc62 authored by Pierre-Alain Loizeau's avatar Pierre-Alain Loizeau
Browse files

In raw StsXyter message class, adapt the error flags width and add enum class describing them

parent 7fbadd4f
No related branches found
No related tags found
1 merge request!10First part of mCBM changes to data to monitors, tasks and unpackers
......@@ -55,6 +55,14 @@ namespace stsxyter {
msg_print_Human = (0x1 << 3)
};
ENABLE_BITMASK_OPERATORS( stsxyter::MessagePrintMask ) // Preproc macro!
/// MS error flags
enum class MsErrorFlags : uint16_t
{
MsErrOutFifoAlmostFull = (0x1 << 0),
MsErrOutFifoOverflow = (0x1 << 1),
MsErrTimeoutBinReadout = (0x1 << 2),
MsErrBinOverflow = (0x1 << 3)
};
/// Fields position (Start bit index)
static const uint16_t kusPosNotHitFlag = 31;
......@@ -79,8 +87,8 @@ namespace stsxyter {
static const uint16_t kusPosStatCpFlag = 0;
// Empty/End of MS
static const uint16_t kusPosEmptyFlag = 28;
static const uint16_t kusPosMsErrFlag = 2;
static const uint16_t kusPosMsErrType = 0;
static const uint16_t kusPosMsErrType = 1;
static const uint16_t kusPosMsErrFlag = 0;
/// Fields length (bits)
static const uint16_t kusLenNotHitFlag = 1;
......@@ -107,8 +115,8 @@ namespace stsxyter {
static const uint16_t kusLenStatCpFlag = 1;
// Empty/End of MS
static const uint16_t kusLenEmptyFlag = 1;
static const uint16_t kusLenMsErrType = 4;
static const uint16_t kusLenMsErrFlag = 1;
static const uint16_t kusLenMsErrType = 2;
/// Fields Info
static const MessField kFieldLinkIndex( kusPosLinkIndex, kusLenLinkIndex );
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment