ATLAS Offline Software
PadReadOutStructure.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2022 CERN for the benefit of the ATLAS collaboration
3 */
4 
5 #ifndef TrigT1RPChardware_PadReadOutStructure_H
6 #define TrigT1RPChardware_PadReadOutStructure_H
7 
12 
14 public:
16  PadReadOutStructure(ubit16 inputData);
17  ~PadReadOutStructure() = default;
18 
19  void setInit();
20  //
21  ubit16 makeHeader(ubit16 *inputData);
22  ubit16 makeBody(ubit16 *inputData) { return *inputData; };
23  // ubit16 makeFooter_new(ubit16* errorCode);
24  ubit16 makeSubHeader() { return 0; };
27 
28  //**************************************************//
29  // general user methods to decode ReadOut stream //
30  //**************************************************//
31  ubit16 decodeFragment(ubit16 inputWord, char &field);
32  ubit16 padid() const { return m_padid; };
33  ubit16 status() const { return m_status; };
34  ubit16 errorCode() const { return m_errorCode; };
35  ubit16 l1id() const { return m_l1id; };
36  ubit16 bcid() const { return m_bcid; };
37  ubit16 fifoCM() const { return m_fifoCM; };
38  ubit16 fifoOR() const { return m_fifoOR; };
39  ubit16 fifoL1() const { return m_fifoL1; };
40  ubit16 fifoPAD() const { return m_fifoPAD; };
41  ubit16 errorSH() const { return m_errorSH; };
42  ubit16 errorL1() const { return m_errorL1; };
43  ubit16 errorH() const { return m_errorH; };
44  ubit16 errorCM() const { return m_errorCM; };
45  ubit16 errorCMID() const { return m_errorCMID; };
46 
47  bool isHeader();
48  bool isBody();
49  bool isFooter();
50 
51  bool isPreFooter();
52  bool isSubHeader();
53 
54  //
55 private:
56  //
57  // header
60  // subheader
62 
63  // prefooter
64  ubit16 m_fifoCM; // busy status (fifo on CMs) OR
65  ubit16 m_fifoOR; // busy status (fifo of CMs on pad) OR (fifo L1)
66  ubit16 m_fifoL1; // busy status (fifo on L1)
67  ubit16 m_fifoPAD; // busy status (fifo of CMs on pad)
69 
70  // footer
71  ubit16 m_errorSH; // error in subheader
72  ubit16 m_errorL1; // error in L1ID
73  ubit16 m_errorH; // error in Header
74  ubit16 m_errorCM; // error in CM
75  ubit16 m_errorCMID; // Id of CM with error
77  //
78  // internal objects;
79  //
82 
83  //
84  // some static parameter describing the structure
85  //
86  static const ubit16 s_headerNum = 3;
89  static const ubit16 s_headerVal;
90  static const ubit16 s_subHeaderNum = 2;
93  static const ubit16 s_subHeaderVal;
94  static const ubit16 s_prefooterNum = 5;
97  static const ubit16 s_prefooterVal;
98  static const ubit16 s_footerNum = 6;
101  static const ubit16 s_footerVal;
102  //
103  // pointer to a temporary array
104  //
106  //
107 };
108 
109 #endif
PadReadOutStructure::errorCMID
ubit16 errorCMID() const
Definition: PadReadOutStructure.h:45
PadReadOutStructure::m_l1id
ubit16 m_l1id
Definition: PadReadOutStructure.h:59
PadReadOutStructure::errorCode
ubit16 errorCode() const
Definition: PadReadOutStructure.h:34
PadReadOutStructure::m_errorSH
ubit16 m_errorSH
Definition: PadReadOutStructure.h:71
PadReadOutStructure::s_footerVal
static const ubit16 s_footerVal
Definition: PadReadOutStructure.h:101
PadReadOutStructure::s_subHeaderLen
static const ubit16 s_subHeaderLen[s_subHeaderNum]
Definition: PadReadOutStructure.h:92
PadReadOutStructure::makeHeader
ubit16 makeHeader(ubit16 *inputData)
Definition: PadReadOutStructure.cxx:74
PadReadOutStructure::m_fifoOR
ubit16 m_fifoOR
Definition: PadReadOutStructure.h:65
PadReadOutStructure::s_prefooterPos
static const ubit16 s_prefooterPos[s_prefooterNum]
Definition: PadReadOutStructure.h:95
PadReadOutStructure::m_bcid
ubit16 m_bcid
Definition: PadReadOutStructure.h:61
PadReadOutStructure
Definition: PadReadOutStructure.h:13
RPCReadOut.h
PadReadOutStructure::s_headerPos
static const ubit16 s_headerPos[s_headerNum]
Definition: PadReadOutStructure.h:87
PadReadOutStructure::m_errorH
ubit16 m_errorH
Definition: PadReadOutStructure.h:73
PadReadOutStructure::isPreFooter
bool isPreFooter()
Definition: PadReadOutStructure.cxx:182
PadReadOutStructure::s_footerLen
static const ubit16 s_footerLen[s_footerNum]
Definition: PadReadOutStructure.h:100
PadReadOutStructure::s_headerVal
static const ubit16 s_headerVal
Definition: PadReadOutStructure.h:89
PadReadOutStructure::makeBody
ubit16 makeBody(ubit16 *inputData)
Definition: PadReadOutStructure.h:22
PadReadOutStructure::fifoCM
ubit16 fifoCM() const
Definition: PadReadOutStructure.h:37
PadReadOutStructure::errorH
ubit16 errorH() const
Definition: PadReadOutStructure.h:43
PadReadOutStructure::PadReadOutStructure
PadReadOutStructure()
Definition: PadReadOutStructure.cxx:33
MatrixReadOut
Definition: MatrixReadOut.h:18
PadReadOutStructure::m_MRS
MatrixReadOutStructure m_MRS
Definition: PadReadOutStructure.h:80
PadReadOutStructure::m_errorCMID
ubit16 m_errorCMID
Definition: PadReadOutStructure.h:75
PadReadOutStructure::status
ubit16 status() const
Definition: PadReadOutStructure.h:33
PadReadOutStructure::s_prefooterNum
static const ubit16 s_prefooterNum
Definition: PadReadOutStructure.h:94
PadReadOutStructure::s_headerLen
static const ubit16 s_headerLen[s_headerNum]
Definition: PadReadOutStructure.h:88
PadReadOutStructure::m_errorCM
ubit16 m_errorCM
Definition: PadReadOutStructure.h:74
PadReadOutStructure::decodeFragment
ubit16 decodeFragment(ubit16 inputWord, char &field)
Definition: PadReadOutStructure.cxx:118
PadReadOutStructure::m_errorCode
ubit16 m_errorCode
Definition: PadReadOutStructure.h:76
PadReadOutStructure::m_vectorStruct
ubit16 * m_vectorStruct
Definition: PadReadOutStructure.h:105
PadReadOutStructure::s_subHeaderPos
static const ubit16 s_subHeaderPos[s_subHeaderNum]
Definition: PadReadOutStructure.h:91
Lvl1Def.h
PadReadOutStructure::~PadReadOutStructure
~PadReadOutStructure()=default
PadReadOutStructure::makeFooter
ubit16 makeFooter(ubit16 errorCode)
Definition: PadReadOutStructure.h:25
PadReadOutStructure::isHeader
bool isHeader()
Definition: PadReadOutStructure.cxx:166
PadReadOutStructure::s_prefooterVal
static const ubit16 s_prefooterVal
Definition: PadReadOutStructure.h:97
PadReadOutStructure::m_status
ubit16 m_status
Definition: PadReadOutStructure.h:68
RPCReadOut::field
char field() const
Definition: RPCReadOut.h:19
PadReadOutStructure::s_subHeaderVal
static const ubit16 s_subHeaderVal
Definition: PadReadOutStructure.h:93
PadReadOutStructure::setInit
void setInit()
Definition: PadReadOutStructure.cxx:64
PadReadOutStructure::m_errorL1
ubit16 m_errorL1
Definition: PadReadOutStructure.h:72
PadReadOutStructure::m_MR
MatrixReadOut m_MR
Definition: PadReadOutStructure.h:81
PadReadOutStructure::makeSubHeader
ubit16 makeSubHeader()
Definition: PadReadOutStructure.h:24
PadReadOutStructure::l1id
ubit16 l1id() const
Definition: PadReadOutStructure.h:35
MatrixReadOutStructure
Definition: MatrixReadOutStructure.h:13
PadReadOutStructure::fifoOR
ubit16 fifoOR() const
Definition: PadReadOutStructure.h:38
PadReadOutStructure::errorL1
ubit16 errorL1() const
Definition: PadReadOutStructure.h:42
PadReadOutStructure::m_padid
ubit16 m_padid
Definition: PadReadOutStructure.h:58
PadReadOutStructure::m_fifoL1
ubit16 m_fifoL1
Definition: PadReadOutStructure.h:66
PadReadOutStructure::padid
ubit16 padid() const
Definition: PadReadOutStructure.h:32
PadReadOutStructure::isSubHeader
bool isSubHeader()
Definition: PadReadOutStructure.cxx:174
MatrixReadOutStructure.h
PadReadOutStructure::fifoPAD
ubit16 fifoPAD() const
Definition: PadReadOutStructure.h:40
PadReadOutStructure::s_headerNum
static const ubit16 s_headerNum
Definition: PadReadOutStructure.h:86
PadReadOutStructure::s_footerPos
static const ubit16 s_footerPos[s_footerNum]
Definition: PadReadOutStructure.h:99
PadReadOutStructure::fifoL1
ubit16 fifoL1() const
Definition: PadReadOutStructure.h:39
PadReadOutStructure::isFooter
bool isFooter()
Definition: PadReadOutStructure.cxx:190
ubit16
unsigned short int ubit16
Definition: RpcByteStreamEncoder.h:20
RPCReadOut
Definition: RPCReadOut.h:13
PadReadOutStructure::m_fifoCM
ubit16 m_fifoCM
Definition: PadReadOutStructure.h:64
MatrixReadOut.h
PadReadOutStructure::s_footerNum
static const ubit16 s_footerNum
Definition: PadReadOutStructure.h:98
PadReadOutStructure::s_subHeaderNum
static const ubit16 s_subHeaderNum
Definition: PadReadOutStructure.h:90
PadReadOutStructure::s_prefooterLen
static const ubit16 s_prefooterLen[s_prefooterNum]
Definition: PadReadOutStructure.h:96
PadReadOutStructure::isBody
bool isBody()
Definition: PadReadOutStructure.cxx:160
PadReadOutStructure::bcid
ubit16 bcid() const
Definition: PadReadOutStructure.h:36
PadReadOutStructure::errorSH
ubit16 errorSH() const
Definition: PadReadOutStructure.h:41
PadReadOutStructure::m_fifoPAD
ubit16 m_fifoPAD
Definition: PadReadOutStructure.h:67
PadReadOutStructure::errorCM
ubit16 errorCM() const
Definition: PadReadOutStructure.h:44