CMS 3D CMS Logo

List of all members | Public Member Functions | Private Attributes
SiPixelRawDataError Class Reference

Pixel error – collection of errors and error information. More...

#include <SiPixelRawDataError.h>

Public Member Functions

int getFedId () const
 
std::string getMessage () const
 
int getType () const
 
cms_uint32_t getWord32 () const
 
cms_uint64_t getWord64 () const
 
void setFedId (int fedId)
 
void setMessage ()
 
void setType (int errorType)
 
void setWord32 (cms_uint32_t errorWord32)
 
void setWord64 (cms_uint64_t errorWord64)
 
 SiPixelRawDataError ()
 Default constructor. More...
 
 SiPixelRawDataError (cms_uint32_t errorWord32, const int errorType, int fedId)
 Constructor for 32-bit error word. More...
 
 SiPixelRawDataError (cms_uint64_t errorWord64, const int errorType, int fedId)
 Constructor with 64-bit error word and type included (header or trailer word) More...
 
 ~SiPixelRawDataError ()
 Destructor. More...
 

Private Attributes

std::string errorMessage_
 
int errorType_
 
cms_uint32_t errorWord32_
 
cms_uint64_t errorWord64_
 
int fedId_
 

Detailed Description

Pixel error – collection of errors and error information.

Class to contain and store all information about errors

Author
Andrew York, University of Tennessee

Definition at line 19 of file SiPixelRawDataError.h.

Constructor & Destructor Documentation

SiPixelRawDataError::SiPixelRawDataError ( )

Default constructor.

Definition at line 15 of file SiPixelRawDataError.cc.

15 {}
SiPixelRawDataError::SiPixelRawDataError ( cms_uint32_t  errorWord32,
const int  errorType,
int  fedId 
)

Constructor for 32-bit error word.

Definition at line 17 of file SiPixelRawDataError.cc.

References setMessage().

17  :
18  errorWord32_(errorWord32),
19  errorType_(errorType),
20  fedId_(fedId)
21  {
22  setMessage();
23  }
SiPixelRawDataError::SiPixelRawDataError ( cms_uint64_t  errorWord64,
const int  errorType,
int  fedId 
)

Constructor with 64-bit error word and type included (header or trailer word)

Definition at line 25 of file SiPixelRawDataError.cc.

References setMessage().

25  :
26  errorWord64_(errorWord64),
27  errorType_(errorType),
28  fedId_(fedId)
29  {
30  setMessage();
31  }
SiPixelRawDataError::~SiPixelRawDataError ( )

Destructor.

Definition at line 35 of file SiPixelRawDataError.cc.

35 {}

Member Function Documentation

int SiPixelRawDataError::getFedId ( ) const
inline

Definition at line 40 of file SiPixelRawDataError.h.

References fedId_.

Referenced by operator<().

40 {return fedId_;} // the fedId where the error occured
std::string SiPixelRawDataError::getMessage ( ) const
inline

Definition at line 41 of file SiPixelRawDataError.h.

References errorMessage_.

41 {return errorMessage_;} // the error message to be displayed with the error
int SiPixelRawDataError::getType ( ) const
inline
cms_uint32_t SiPixelRawDataError::getWord32 ( ) const
inline

Definition at line 37 of file SiPixelRawDataError.h.

References errorWord32_.

37 {return errorWord32_;} // the 32-bit word that contains the error information
cms_uint64_t SiPixelRawDataError::getWord64 ( ) const
inline

Definition at line 38 of file SiPixelRawDataError.h.

References errorWord64_.

38 {return errorWord64_;} // the 64-bit word that contains the error information
void SiPixelRawDataError::setFedId ( int  fedId)

Definition at line 52 of file SiPixelRawDataError.cc.

References l1t::stage2::layer2::fedId, and fedId_.

void SiPixelRawDataError::setMessage ( )

Definition at line 56 of file SiPixelRawDataError.cc.

References errorMessage_, and errorType_.

Referenced by setType(), and SiPixelRawDataError().

56  {
57  switch (errorType_) {
58  case(25) : {
59  errorMessage_ = "Error: Disabled FED channel (ROC=25)";
60  break;
61  }
62  case(26) : {
63  errorMessage_ = "Error: Gap word";
64  break;
65  }
66  case(27) : {
67  errorMessage_ = "Error: Dummy word";
68  break;
69  }
70  case(28) : {
71  errorMessage_ = "Error: FIFO nearly full";
72  break;
73  }
74  case(29) : {
75  errorMessage_ = "Error: Timeout";
76  break;
77  }
78  case(30) : {
79  errorMessage_ = "Error: Trailer";
80  break;
81  }
82  case(31) : {
83  errorMessage_ = "Error: Event number mismatch";
84  break;
85  }
86  case(32) : {
87  errorMessage_ = "Error: Invalid or missing header";
88  break;
89  }
90  case(33) : {
91  errorMessage_ = "Error: Invalid or missing trailer";
92  break;
93  }
94  case(34) : {
95  errorMessage_ = "Error: Size mismatch";
96  break;
97  }
98  case(35) : {
99  errorMessage_ = "Error: Invalid channel";
100  break;
101  }
102  case(36) : {
103  errorMessage_ = "Error: Invalid ROC number";
104  break;
105  }
106  case(37) : {
107  errorMessage_ = "Error: Invalid dcol/pixel address";
108  break;
109  }
110  default: errorMessage_ = "Error: Unknown error type";
111  };
112 }
void SiPixelRawDataError::setType ( int  errorType)

Definition at line 47 of file SiPixelRawDataError.cc.

References errorType_, and setMessage().

47  {
48 errorType_ = errorType;
49 setMessage();
50 }
void SiPixelRawDataError::setWord32 ( cms_uint32_t  errorWord32)

Definition at line 39 of file SiPixelRawDataError.cc.

References errorWord32_.

39  {
40  errorWord32_ = errorWord32;
41 }
void SiPixelRawDataError::setWord64 ( cms_uint64_t  errorWord64)

Definition at line 43 of file SiPixelRawDataError.cc.

References errorWord64_.

43  {
44  errorWord64_ = errorWord64;
45 }

Member Data Documentation

std::string SiPixelRawDataError::errorMessage_
private

Definition at line 49 of file SiPixelRawDataError.h.

Referenced by getMessage(), and setMessage().

int SiPixelRawDataError::errorType_
private

Definition at line 47 of file SiPixelRawDataError.h.

Referenced by getType(), setMessage(), and setType().

cms_uint32_t SiPixelRawDataError::errorWord32_
private

Definition at line 45 of file SiPixelRawDataError.h.

Referenced by getWord32(), and setWord32().

cms_uint64_t SiPixelRawDataError::errorWord64_
private

Definition at line 46 of file SiPixelRawDataError.h.

Referenced by getWord64(), and setWord64().

int SiPixelRawDataError::fedId_
private

Definition at line 48 of file SiPixelRawDataError.h.

Referenced by getFedId(), and setFedId().