ATLAS Offline Software
Public Member Functions | Static Public Member Functions | Protected Member Functions | Private Attributes | Static Private Attributes | Friends | List of all members
TileDQstatus Class Reference

Class that holds Data Quality fragment information and provides functions to extract the data quality status for channels Checks for the following types of errors stored in the Data Quality fragment: More...

#include <TileDQstatus.h>

Collaboration diagram for TileDQstatus:

Public Member Functions

 TileDQstatus ()
 Default constructor. More...
 
bool isFilled () const
 returns whether TileDQStatus has been filled with data from TileDQ fragment More...
 
bool isBiGain () const
 returns gain mode of run More...
 
bool nonZeroCounter () const
 returns True if there are any errors in event More...
 
bool isAdcDQgood (int partition, int drawer, int ch, int gain) const
 returns status of single ADC returns False if there are any errors More...
 
bool isChanDQgood (int partition, int drawer, int ch) const
 returns status of single channel (if bigain, returns AND of ADCs' status More...
 
int checkEmptyEvent (int partition, int drawer, int dmu) const
 returns 0 if event is ok, 1 if empty LG event, 2 if empty HG event, 3 if empty event in both gains More...
 
int checkGlobalErr (int partition, int drawer, int gain) const
 returns 1 if adc channel has any global error More...
 
int checkGlobalCRCErr (int partition, int drawer, int gain) const
 returns 1 if adc channel has global CRC error More...
 
int checkROD_CRCErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has CRC error originating in ROD More...
 
int checkFE_CRCErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has CRC error originating in FE electronics More...
 
int checkBCIDErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has BCID mismatch between DMU and ROD
Since BCID errors in the DQ fragment are determined by comparison of each DMU to DMU1, if DMU1 is bad and DMUX is also bad, we must compare the individual DMU's BCID to the actual (ROD) BCID. More...
 
int checkBCIDErrDetail (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has BCID mismatch between DMU and ROD This method accesses the TileDigitsContainer in order to explicitly check the DMU BCID with the ROD BCID. More...
 
int checkHeaderFormatErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has header word format error More...
 
int checkHeaderParityErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has header word parity error More...
 
int checkSampleFormatErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has data word format error More...
 
int checkSampleParityErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has data word parity error More...
 
int checkMemoryParityErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has memory parity error More...
 
int checkSingleStrobeErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has single strobe error More...
 
int checkDoubleStrobeErr (int partition, int drawer, int dmu, int gain) const
 returns 1 if DMU has double strobe error More...
 
bool incompleteDigits () const
 A few extra items (from TileBeamInfoProvider). More...
 
void setIncompleteDigits (bool incomplete)
 
uint32_t calibMode () const
 Calibration mode. More...
 
void setCalibMode (uint32_t calibMode)
 
const uint32_t * cispar () const
 CIS parameters. More...
 
uint32_t * cispar ()
 
int trigType () const
 Trigger type. More...
 
void setTrigType (int trigType)
 
uint32_t RODBCID () const
 

Static Public Member Functions

static int isChEmpty (int partition, int drawer, int ch)
 True if channel is not fully implemented. More...
 

Protected Member Functions

void setFilled (bool filled)
 sets flag that DQ status instance has been filled for this event More...
 
void setBiGain (bool biGain)
 sets flag of gain mode of run More...
 
void setAllGood ()
 mark all channels/ADC's as DQ good More...
 
void setRODBCID (uint32_t BCID)
 sets the ROD BCID stored and used in DQStatus
More...
 
void setEmptyEvent (int partition, int drawer, int dmu, int gain, int isEmpty)
 sets flag that DMU sent an empty event (0xFFFFFFFF) More...
 
void fillArrays (const TileRawChannelCollection *coll, const TileDigitsContainer *digitsCnt, int gain, unsigned short fragBCID)
 parses DQ fragments and fill error arrays for event More...
 
void fillBCIDErrDetail (const TileDigitsContainer *digitsCnt, int frag, int gain)
 
void fillTrips (unsigned int partition, const std::vector< float > &trips, double *rndmVec, MsgStream &msg)
 

Private Attributes

bool m_isFilled
 Boolean storing if DQ fragment has been parsed already. More...
 
bool m_isBiGain
 Boolean storing gain mode of run. More...
 
bool m_checkDigi
 Boolean flag to control TileDigitsContainer access
More...
 
uint32_t m_BCID
 Event bunch crossing identification. More...
 
int m_counter
 Counter of non-zero elements in all error arrays. More...
 
short m_EmptyEventArray [5][64][16][2]
 Array storing whether event is empty. More...
 
short m_GlobalCRCErrArray [5][64][2]
 Array of bit masks storing CRC errors for all DMUs. More...
 
short m_FE_DMUmaskArray [5][64][2]
 Array of bit masks storing CRC errors for all DMUs. More...
 
short m_ROD_DMUmaskArray [5][64][2]
 Array of bit masks storing CRC errors for all DMUs. More...
 
short m_BCIDErrArray [5][64][2]
 Array of bit masks storing BCID errors for all DMUs (from comparison with DMU1) More...
 
short m_BCIDErrArrayDetail [5][64][2]
 Array of bit masks storing BCID errors for all DMUs (from comparison with Digits) More...
 
short m_HeaderFormatErrArray [5][64][2]
 Array of bit masks storing Header Format errors for all DMUs. More...
 
short m_HeaderParityErrArray [5][64][2]
 Array of bit masks storing Header Parity errors for all DMUs. More...
 
short m_SampleFormatErrArray [5][64][2]
 Array of bit masks storing Sample Format errors for all DMUs. More...
 
short m_SampleParityErrArray [5][64][2]
 Array of bit masks storing Sample Parity errors for all DMUs. More...
 
short m_MemoryParityErrArray [5][64][2]
 Array of bit masks storing Memory Parity errors for all DMUs. More...
 
short m_SingleStrobeErrArray [5][64][2]
 Array of bit masks storing Single Strobe errors for all DMUs. More...
 
short m_DoubleStrobeErrArray [5][64][2]
 Array of bit masks storing Double Strobe errors for all DMUs. More...
 
bool m_incompleteDigits
 True if not all digits are available. More...
 
uint32_t m_calibMode
 Calibration mode. More...
 
uint32_t m_cispar [110]
 CIS parameters. More...
 
int m_trigType
 Trigger type. More...
 

Static Private Attributes

static const int s_ch2dmuLB [48]
 
static const int s_ch2dmuEB [48]
 
static const int s_ch2dmuEBspecial [48]
 

Friends

class TileDQstatusTool
 

Detailed Description

Class that holds Data Quality fragment information and provides functions to extract the data quality status for channels Checks for the following types of errors stored in the Data Quality fragment:

Also holds a few other pieces of information, such as trigger type, calibration mode, and CIS parameters.

Definition at line 48 of file TileDQstatus.h.

Constructor & Destructor Documentation

◆ TileDQstatus()

TileDQstatus::TileDQstatus ( )

Default constructor.

Definition at line 37 of file TileDQstatus.cxx.

38  : m_isBiGain(false),
39  m_checkDigi(false),
40  m_BCID(0),
41  m_incompleteDigits(true),
43  m_cispar{0},
44  m_trigType(0)
45 {
46  setAllGood();
47 }

Member Function Documentation

◆ calibMode()

uint32_t TileDQstatus::calibMode ( ) const
inline

Calibration mode.

Definition at line 148 of file TileDQstatus.h.

148 { return m_calibMode; }

◆ checkBCIDErr()

int TileDQstatus::checkBCIDErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has BCID mismatch between DMU and ROD
Since BCID errors in the DQ fragment are determined by comparison of each DMU to DMU1, if DMU1 is bad and DMUX is also bad, we must compare the individual DMU's BCID to the actual (ROD) BCID.

This is due to the fact that DMU1 is checked against the ROD, while the others DMUs are checked against DMU1. This requires access to the digits in the function checkBCIDErrDetail. If this behavior is undesired set m_checkDigi to false in TileBeamInfoProvider. Setting m_checkDigi=false would cause any BCID errors simultaneous with DMU1 to be flagged as BAD (conservative approach)

Definition at line 100 of file TileDQstatus.h.

100  {
101  return ((m_BCIDErrArray[partition][drawer][gain] & 0x2) && m_checkDigi)
102  ? this->checkBCIDErrDetail(partition,drawer,dmu,gain) :
103  ((m_BCIDErrArray[partition][drawer][gain] >> dmu) & 1);
104  }

◆ checkBCIDErrDetail()

int TileDQstatus::checkBCIDErrDetail ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has BCID mismatch between DMU and ROD This method accesses the TileDigitsContainer in order to explicitly check the DMU BCID with the ROD BCID.

Definition at line 109 of file TileDQstatus.h.

109  {
110  return (m_BCIDErrArrayDetail[partition][drawer][gain] >> dmu) & 1;
111  }

◆ checkDoubleStrobeErr()

int TileDQstatus::checkDoubleStrobeErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has double strobe error

Definition at line 137 of file TileDQstatus.h.

137  {
138  return (m_DoubleStrobeErrArray[partition][drawer][gain] >> dmu) & 1;
139  }

◆ checkEmptyEvent()

int TileDQstatus::checkEmptyEvent ( int  partition,
int  drawer,
int  dmu 
) const
inline

returns 0 if event is ok, 1 if empty LG event, 2 if empty HG event, 3 if empty event in both gains

Definition at line 71 of file TileDQstatus.h.

71  {
72  return (m_EmptyEventArray[partition][drawer][dmu][0]+((m_EmptyEventArray[partition][drawer][dmu][1]) << 1));
73  }

◆ checkFE_CRCErr()

int TileDQstatus::checkFE_CRCErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has CRC error originating in FE electronics

Definition at line 88 of file TileDQstatus.h.

88  {
89  return (1 - ((m_FE_DMUmaskArray[partition][drawer][gain] >> dmu) & 1));
90  }

◆ checkGlobalCRCErr()

int TileDQstatus::checkGlobalCRCErr ( int  partition,
int  drawer,
int  gain 
) const
inline

returns 1 if adc channel has global CRC error

Definition at line 80 of file TileDQstatus.h.

80  {
82  }

◆ checkGlobalErr()

int TileDQstatus::checkGlobalErr ( int  partition,
int  drawer,
int  gain 
) const
inline

returns 1 if adc channel has any global error

Definition at line 76 of file TileDQstatus.h.

76  {
78  }

◆ checkHeaderFormatErr()

int TileDQstatus::checkHeaderFormatErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has header word format error

Definition at line 113 of file TileDQstatus.h.

113  {
114  return (m_HeaderFormatErrArray[partition][drawer][gain] >> dmu) & 1;
115  }

◆ checkHeaderParityErr()

int TileDQstatus::checkHeaderParityErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has header word parity error

Definition at line 117 of file TileDQstatus.h.

117  {
118  return (m_HeaderParityErrArray[partition][drawer][gain] >> dmu) & 1;
119  }

◆ checkMemoryParityErr()

int TileDQstatus::checkMemoryParityErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has memory parity error

Definition at line 129 of file TileDQstatus.h.

129  {
130  return (m_MemoryParityErrArray[partition][drawer][gain] >> dmu) & 1;
131  }

◆ checkROD_CRCErr()

int TileDQstatus::checkROD_CRCErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has CRC error originating in ROD

Definition at line 84 of file TileDQstatus.h.

84  {
85  return (1 - ((m_ROD_DMUmaskArray[partition][drawer][gain] >> dmu) & 1));
86  }

◆ checkSampleFormatErr()

int TileDQstatus::checkSampleFormatErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has data word format error

Definition at line 121 of file TileDQstatus.h.

121  {
122  return (m_SampleFormatErrArray[partition][drawer][gain] >> dmu) & 1;
123  }

◆ checkSampleParityErr()

int TileDQstatus::checkSampleParityErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has data word parity error

Definition at line 125 of file TileDQstatus.h.

125  {
126  return (m_SampleParityErrArray[partition][drawer][gain] >> dmu) & 1;
127  }

◆ checkSingleStrobeErr()

int TileDQstatus::checkSingleStrobeErr ( int  partition,
int  drawer,
int  dmu,
int  gain 
) const
inline

returns 1 if DMU has single strobe error

Definition at line 133 of file TileDQstatus.h.

133  {
134  return (m_SingleStrobeErrArray[partition][drawer][gain] >> dmu) & 1;
135  }

◆ cispar() [1/2]

uint32_t * TileDQstatus::cispar ( )

Definition at line 321 of file TileDQstatus.cxx.

322 {
323  return m_cispar;
324 }

◆ cispar() [2/2]

const uint32_t* TileDQstatus::cispar ( ) const
inline

CIS parameters.

Definition at line 152 of file TileDQstatus.h.

152 { return m_cispar; }

◆ fillArrays()

void TileDQstatus::fillArrays ( const TileRawChannelCollection coll,
const TileDigitsContainer digitsCnt,
int  gain,
unsigned short  fragBCID 
)
protected

parses DQ fragments and fill error arrays for event

Definition at line 72 of file TileDQstatus.cxx.

75 {
76  if (digitsCnt) {
77  m_checkDigi = true;
78  }
79 
80  int frag = coll->identify();
81  int partition = (frag >> 8); // 0=AUX,1=LBA,2=LBC,3=EBA,4=EBC
82  int drawer = (frag & 0x3F); // 0-63
83  bool eb = (frag > 0x2ff); // true if ext.barrel
84  bool ebsp = (frag == 0x30e || frag == 0x411);// EBA15 or EBC18
85 
86  m_isBiGain |= (coll->size() > 48);
87  // attention! it's assignment below, i.e. only single "=", not "=="
88  // LF: ... which is something very dangerous. Does it provide any speed advantage?
90  if ((m_BCIDErrArray[partition][drawer][gain] = fragBCID)) ++m_counter;
99 // special treatment of FE DMU mask - take into account that some DMUs in Ext.barrel do not exist
100  if(uint32_t FE_DMUmask = coll->getFragFEChipMask()) {
101  if (eb) { // EBA or EBC
102  if (ebsp) FE_DMUmask <<= 1; // shift by one DMU in EBA15 EBC18
103  FE_DMUmask = (FE_DMUmask & 0xFF) | ((FE_DMUmask & 0xF00) << 2); // shift upper half by two DMUs
104  }
105  m_FE_DMUmaskArray[partition][drawer][gain] = FE_DMUmask;
106  ++m_counter;
107  }
108 
109  unsigned short BCIDerr = fragBCID;
110 
111  if (BCIDerr & 0x2) { // DMU1 (second DMU) is bad - can not trust others
113  } else {
114  // additional check if DQ frag BCID is the same as event BCID
115  uint32_t DSPBCID = coll->getFragDSPBCID();
116  if (DSPBCID != 0xDEAD && DSPBCID != m_BCID) { // DSP BCID doesn't match! all wrong
117  m_BCIDErrArray[partition][drawer][gain] = -1; // I preferred 0xFFFF; but variable is decleared as signed!
118  ++m_counter;
119  } else {
120  int n_badMB = 0;
121  if (eb) { // do not count non-existing DMUs in EB
122  if (ebsp) {
123  BCIDerr &= 0x3cfe;
124  } else {
125  BCIDerr &= 0x3cff;
126  }
127  }
128  while (BCIDerr) {
129  if (BCIDerr & 0xF)
130  ++n_badMB;
131  BCIDerr >>= 4;
132  }
133  if (n_badMB == 4) { // BCID errors in all 4 motherboards - assume that all DMUs are bad
135 #ifdef TILECELL_DEBUG
136  std::cout << "masking whole drawer " << drawer << " in partition " << partition << " because all 4 MB have BCID errors"
137  << std::endl;
138 #endif
139  }
140  }
141  }
142 
143  if ((m_BCIDErrArray[partition][drawer][gain] & 0x2) && digitsCnt) {
144  fillBCIDErrDetail(digitsCnt, frag, gain);
145  } else {
147  }
148 
153  // can not trust FE mask, assume that FE is good
155  }
156 
157 #ifdef TILECELL_DEBUG
158  std::cout << std::hex
159  << " " << coll->getFragGlobalCRC()
160  << " " << coll->getFragFEChipMask()
161  << " " << coll->getFragRODChipMask()
162  << " " << coll->getFragDSPBCID()
163  << " " << coll->getFragBCID()
164  << " " << coll->getFragMemoryPar()
165  << " " << coll->getFragSstrobe()
166  << " " << coll->getFragDstrobe()
167  << " " << coll->getFragHeaderBit()
168  << " " << coll->getFragHeaderPar()
169  << " " << coll->getFragSampleBit()
170  << " " << coll->getFragSamplePar()
171  << " counter is " << std::dec << m_counter << std::endl;
172 #endif
173 
174 }

◆ fillBCIDErrDetail()

void TileDQstatus::fillBCIDErrDetail ( const TileDigitsContainer digitsCnt,
int  frag,
int  gain 
)
protected

Definition at line 249 of file TileDQstatus.cxx.

251 {
252  int partition = (frag >> 8);
253  int drawer = (frag & 0x3F);
255  m_BCIDErrArray[partition][drawer][gain]; //initialize
256  if (digitsCnt == NULL)
257  // by default a conservative return value of 1 (channel Mask)
259  else {
260  TileDigitsContainer::const_iterator collItr = digitsCnt->begin();
261  TileDigitsContainer::const_iterator lastColl = digitsCnt->end();
262 
263  for (; collItr != lastColl; ++collItr) { // Loop over TileModules
264  if ((*collItr)->identify() != frag)
265  continue;
266 
267  std::vector < uint32_t > data;
268  if ( isBiGain() && gain ) //high Gain in bigain run
269  data = (*collItr)->getFragChipHeaderWordsHigh();
270  else
271  data = (*collItr)->getFragChipHeaderWords();
272 
273  unsigned int dataSize = std::min(16u, (unsigned int) data.size());
274  short bcidCheck = 0x0;
275  uint32_t rodbcid = (*collItr)->getRODBCID();
276  for (unsigned int dmu = 0; dmu < dataSize; ++dmu) {
277  bcidCheck |= ((data[dmu] & 0xFFF) != rodbcid) << dmu;
278 #ifdef TILECELL_DEBUG
279  std::cout << "Part: " << partition << " Drawer: " << drawer << " DMU: " << dmu << (gain?"HG":"LG")
280  << " DMU BCID: " << (data[dmu] & 0xFFF) << " ROD BCID: " << rodbcid << std::endl;
281 #endif
282  }
283  if (dataSize > 0)
284  m_BCIDErrArrayDetail[partition][drawer][gain] = bcidCheck;
285  break; // break after the digit is found
286  }
287  }
288 }

◆ fillTrips()

void TileDQstatus::fillTrips ( unsigned int  partition,
const std::vector< float > &  trips,
double *  rndmVec,
MsgStream &  msg 
)
protected

Definition at line 291 of file TileDQstatus.cxx.

295 {
296  for (unsigned int drawer = 0; drawer < TileCalibUtils::MAX_DRAWER; ++drawer) {
297  if (trips[drawer] > rndmVec[drawer]) {
298  msg << MSG::DEBUG
299  << "The drawer has been tripped (simulation): "
303  m_counter += 2;
304  }
305  }
306 }

◆ incompleteDigits()

bool TileDQstatus::incompleteDigits ( ) const
inline

A few extra items (from TileBeamInfoProvider).

True if not all digits are available.

Definition at line 144 of file TileDQstatus.h.

144 { return m_incompleteDigits;}

◆ isAdcDQgood()

bool TileDQstatus::isAdcDQgood ( int  partition,
int  drawer,
int  ch,
int  gain 
) const

returns status of single ADC returns False if there are any errors

Definition at line 178 of file TileDQstatus.cxx.

178  {
179 
180  int dmu = ch/3;
181 
182 #ifdef TILECELL_DEBUG
183 
184  int errorArray[11];
185  errorArray[0] = checkGlobalCRCErr (partition,drawer,gain);
186  errorArray[1] = checkROD_CRCErr (partition,drawer,dmu,gain);
187  errorArray[2] = (m_isBiGain) ? 0 : checkFE_CRCErr(partition,drawer,dmu,gain); // Skip FE CRC for bigain runs
188  errorArray[3] = checkBCIDErr (partition,drawer,dmu,gain);
189  errorArray[4] = checkHeaderFormatErr (partition,drawer,dmu,gain);
190  errorArray[5] = checkHeaderParityErr (partition,drawer,dmu,gain);
191  errorArray[6] = checkSampleFormatErr (partition,drawer,dmu,gain);
192  errorArray[7] = checkSampleParityErr (partition,drawer,dmu,gain);
193  errorArray[8] = checkMemoryParityErr (partition,drawer,dmu,gain);
194  errorArray[9] = checkSingleStrobeErr (partition,drawer,dmu,gain);
195  errorArray[10]= checkDoubleStrobeErr (partition,drawer,dmu,gain);
196 
197  int nError=0;
198  for(int i=0;i<9;++i){ // exclude Strobe errors from decision
199  nError += errorArray[i];
200  }
201  std::cout << std::dec <<"Part: " << partition << " Drawer: " << drawer+1 << " DMU: " << dmu << " ch: " << ch << std::endl;
202  std::cout << "IsBigain " << m_isBiGain << std::endl;
203  std::cout << "EmptyEvent (LG) " << m_EmptyEventArray[partition][drawer][dmu][0] << std::endl;
204  std::cout << "EmptyEvent (HG) " << m_EmptyEventArray[partition][drawer][dmu][1] << std::endl;
205  std::cout << "GlobalCRCErr " << errorArray[0] << std::endl;
206  std::cout << "ROD_CRCmask (LG) " << std::hex << m_ROD_DMUmaskArray[partition][drawer][0] << std::endl;
207  std::cout << "ROD_CRCmask (HG) " << std::hex << m_ROD_DMUmaskArray[partition][drawer][1] << std::endl;
208  std::cout << "ROD_CRCErr " << std::dec << errorArray[1] << std::endl;
209  std::cout << "FE_CRCmask (LG) " << std::hex << m_FE_DMUmaskArray[partition][drawer][0] << std::endl;
210  std::cout << "FE_CRCmask (HG) " << std::hex << m_FE_DMUmaskArray[partition][drawer][1] << std::endl;
211  std::cout << "FE_CRCErr " << std::dec << errorArray[2] << std::endl;
212  std::cout << "BCIDErr " << std::dec << errorArray[3] << std::endl;
213  std::cout << "HeaderFormatErr " << std::dec << errorArray[4] << std::endl;
214  std::cout << "HeaderParityErr " << std::dec << errorArray[5] << std::endl;
215  std::cout << "SampleFormatErr " << std::dec << errorArray[6] << std::endl;
216  std::cout << "SampleParityErr " << std::dec << errorArray[7] << std::endl;
217  std::cout << "MemoryParityErr " << std::dec << errorArray[8] << std::endl;
218  std::cout << "SingleStrobeErr " << std::dec << errorArray[9] << std::endl;
219  std::cout << "DoubleStrobeErr " << std::dec << errorArray[10] << std::endl;
220  std::cout << "Total number of errors: " << std::dec << nError << std::endl;
221 
222 #endif
223 
226  || ((m_isBiGain) ? 0 : checkFE_CRCErr(partition, drawer, dmu, gain)) // Skip FE CRC for bigain runs
227  || checkBCIDErr(partition, drawer, dmu, gain)
233  return false;
234  }
235 
236  return true;
237 }

◆ isBiGain()

bool TileDQstatus::isBiGain ( ) const
inline

returns gain mode of run

Definition at line 60 of file TileDQstatus.h.

60 { return m_isBiGain; }

◆ isChanDQgood()

bool TileDQstatus::isChanDQgood ( int  partition,
int  drawer,
int  ch 
) const

returns status of single channel (if bigain, returns AND of ADCs' status

Definition at line 240 of file TileDQstatus.cxx.

240  {
241  bool isGood = isAdcDQgood(partition, drawer, ch, 0);
242 
243  if (m_isBiGain)
244  isGood &= isAdcDQgood(partition, drawer, ch, 1);
245 
246  return isGood;
247 }

◆ isChEmpty()

static int TileDQstatus::isChEmpty ( int  partition,
int  drawer,
int  ch 
)
static

True if channel is not fully implemented.

◆ isFilled()

bool TileDQstatus::isFilled ( ) const
inline

returns whether TileDQStatus has been filled with data from TileDQ fragment

Definition at line 58 of file TileDQstatus.h.

58 { return m_isFilled; }

◆ nonZeroCounter()

bool TileDQstatus::nonZeroCounter ( ) const
inline

returns True if there are any errors in event

Definition at line 62 of file TileDQstatus.h.

62 { return m_counter; }

◆ RODBCID()

uint32_t TileDQstatus::RODBCID ( ) const
inline

Definition at line 159 of file TileDQstatus.h.

159 {return m_BCID;}

◆ setAllGood()

void TileDQstatus::setAllGood ( )
protected

mark all channels/ADC's as DQ good

Definition at line 49 of file TileDQstatus.cxx.

49  {
50  // Intitalize all arrays to no errors
51  m_isFilled = false;
52  //m_isBiGain = false; //BAD!
53  m_counter = 0;
54  memset(m_EmptyEventArray, 0, sizeof(m_EmptyEventArray));
55  memset(m_GlobalCRCErrArray, 0, sizeof(m_GlobalCRCErrArray));
56  memset(m_FE_DMUmaskArray, -1, sizeof(m_FE_DMUmaskArray));
57  memset(m_ROD_DMUmaskArray, -1, sizeof(m_ROD_DMUmaskArray));
58  memset(m_BCIDErrArray, 0, sizeof(m_BCIDErrArray));
59  memset(m_BCIDErrArrayDetail, 0, sizeof(m_BCIDErrArrayDetail));
67 }

◆ setBiGain()

void TileDQstatus::setBiGain ( bool  biGain)
inlineprotected

sets flag of gain mode of run

Definition at line 167 of file TileDQstatus.h.

167 {m_isBiGain=biGain;}

◆ setCalibMode()

void TileDQstatus::setCalibMode ( uint32_t  calibMode)

Definition at line 315 of file TileDQstatus.cxx.

316 {
318 }

◆ setEmptyEvent()

void TileDQstatus::setEmptyEvent ( int  partition,
int  drawer,
int  dmu,
int  gain,
int  isEmpty 
)
inlineprotected

sets flag that DMU sent an empty event (0xFFFFFFFF)

Definition at line 173 of file TileDQstatus.h.

173  {
174  m_EmptyEventArray[partition][drawer][dmu][gain]=isEmpty;
175  m_counter+=isEmpty;
176  }

◆ setFilled()

void TileDQstatus::setFilled ( bool  filled)
inlineprotected

sets flag that DQ status instance has been filled for this event

Definition at line 165 of file TileDQstatus.h.

165 {m_isFilled=filled;}

◆ setIncompleteDigits()

void TileDQstatus::setIncompleteDigits ( bool  incomplete)

Definition at line 309 of file TileDQstatus.cxx.

310 {
312 }

◆ setRODBCID()

void TileDQstatus::setRODBCID ( uint32_t  BCID)
inlineprotected

sets the ROD BCID stored and used in DQStatus

Definition at line 171 of file TileDQstatus.h.

171 {m_BCID=BCID;}

◆ setTrigType()

void TileDQstatus::setTrigType ( int  trigType)

Definition at line 327 of file TileDQstatus.cxx.

328 {
330 }

◆ trigType()

int TileDQstatus::trigType ( ) const
inline

Trigger type.

Definition at line 156 of file TileDQstatus.h.

156 { return m_trigType; }

Friends And Related Function Documentation

◆ TileDQstatusTool

friend class TileDQstatusTool
friend

Definition at line 50 of file TileDQstatus.h.

Member Data Documentation

◆ m_BCID

uint32_t TileDQstatus::m_BCID
private

Event bunch crossing identification.

Definition at line 193 of file TileDQstatus.h.

◆ m_BCIDErrArray

short TileDQstatus::m_BCIDErrArray[5][64][2]
private

Array of bit masks storing BCID errors for all DMUs (from comparison with DMU1)

Definition at line 205 of file TileDQstatus.h.

◆ m_BCIDErrArrayDetail

short TileDQstatus::m_BCIDErrArrayDetail[5][64][2]
private

Array of bit masks storing BCID errors for all DMUs (from comparison with Digits)

Definition at line 207 of file TileDQstatus.h.

◆ m_calibMode

uint32_t TileDQstatus::m_calibMode
private

Calibration mode.

Definition at line 227 of file TileDQstatus.h.

◆ m_checkDigi

bool TileDQstatus::m_checkDigi
private

Boolean flag to control TileDigitsContainer access

Definition at line 191 of file TileDQstatus.h.

◆ m_cispar

uint32_t TileDQstatus::m_cispar[110]
private

CIS parameters.

Definition at line 230 of file TileDQstatus.h.

◆ m_counter

int TileDQstatus::m_counter
private

Counter of non-zero elements in all error arrays.

Definition at line 195 of file TileDQstatus.h.

◆ m_DoubleStrobeErrArray

short TileDQstatus::m_DoubleStrobeErrArray[5][64][2]
private

Array of bit masks storing Double Strobe errors for all DMUs.

Definition at line 221 of file TileDQstatus.h.

◆ m_EmptyEventArray

short TileDQstatus::m_EmptyEventArray[5][64][16][2]
private

Array storing whether event is empty.

Definition at line 197 of file TileDQstatus.h.

◆ m_FE_DMUmaskArray

short TileDQstatus::m_FE_DMUmaskArray[5][64][2]
private

Array of bit masks storing CRC errors for all DMUs.

Definition at line 201 of file TileDQstatus.h.

◆ m_GlobalCRCErrArray

short TileDQstatus::m_GlobalCRCErrArray[5][64][2]
private

Array of bit masks storing CRC errors for all DMUs.

Definition at line 199 of file TileDQstatus.h.

◆ m_HeaderFormatErrArray

short TileDQstatus::m_HeaderFormatErrArray[5][64][2]
private

Array of bit masks storing Header Format errors for all DMUs.

Definition at line 209 of file TileDQstatus.h.

◆ m_HeaderParityErrArray

short TileDQstatus::m_HeaderParityErrArray[5][64][2]
private

Array of bit masks storing Header Parity errors for all DMUs.

Definition at line 211 of file TileDQstatus.h.

◆ m_incompleteDigits

bool TileDQstatus::m_incompleteDigits
private

True if not all digits are available.

Definition at line 224 of file TileDQstatus.h.

◆ m_isBiGain

bool TileDQstatus::m_isBiGain
private

Boolean storing gain mode of run.

Definition at line 189 of file TileDQstatus.h.

◆ m_isFilled

bool TileDQstatus::m_isFilled
private

Boolean storing if DQ fragment has been parsed already.

Definition at line 187 of file TileDQstatus.h.

◆ m_MemoryParityErrArray

short TileDQstatus::m_MemoryParityErrArray[5][64][2]
private

Array of bit masks storing Memory Parity errors for all DMUs.

Definition at line 217 of file TileDQstatus.h.

◆ m_ROD_DMUmaskArray

short TileDQstatus::m_ROD_DMUmaskArray[5][64][2]
private

Array of bit masks storing CRC errors for all DMUs.

Definition at line 203 of file TileDQstatus.h.

◆ m_SampleFormatErrArray

short TileDQstatus::m_SampleFormatErrArray[5][64][2]
private

Array of bit masks storing Sample Format errors for all DMUs.

Definition at line 213 of file TileDQstatus.h.

◆ m_SampleParityErrArray

short TileDQstatus::m_SampleParityErrArray[5][64][2]
private

Array of bit masks storing Sample Parity errors for all DMUs.

Definition at line 215 of file TileDQstatus.h.

◆ m_SingleStrobeErrArray

short TileDQstatus::m_SingleStrobeErrArray[5][64][2]
private

Array of bit masks storing Single Strobe errors for all DMUs.

Definition at line 219 of file TileDQstatus.h.

◆ m_trigType

int TileDQstatus::m_trigType
private

Trigger type.

Definition at line 233 of file TileDQstatus.h.

◆ s_ch2dmuEB

const int TileDQstatus::s_ch2dmuEB
staticprivate
Initial value:
= { 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 2,
2, 2, 2, 2, 2, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 2, 2,
2, 2, 2, 2 }

Definition at line 236 of file TileDQstatus.h.

◆ s_ch2dmuEBspecial

const int TileDQstatus::s_ch2dmuEBspecial
staticprivate
Initial value:
= { 2, 2, 2, 1,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 2, 2, 2, 2, 2, 2, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0,
2, 2, 2, 2, 2, 2 }

Definition at line 237 of file TileDQstatus.h.

◆ s_ch2dmuLB

const int TileDQstatus::s_ch2dmuLB
staticprivate
Initial value:
= { 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0, 0, 0, 0, 1, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 1,
0, 0, 0, 0 }

Definition at line 235 of file TileDQstatus.h.


The documentation for this class was generated from the following files:
TileDQstatus::m_isFilled
bool m_isFilled
Boolean storing if DQ fragment has been parsed already.
Definition: TileDQstatus.h:187
TileDQstatus::m_GlobalCRCErrArray
short m_GlobalCRCErrArray[5][64][2]
Array of bit masks storing CRC errors for all DMUs.
Definition: TileDQstatus.h:199
data
char data[hepevt_bytes_allocation_ATLAS]
Definition: HepEvt.cxx:11
TileDQstatus::m_BCIDErrArrayDetail
short m_BCIDErrArrayDetail[5][64][2]
Array of bit masks storing BCID errors for all DMUs (from comparison with Digits)
Definition: TileDQstatus.h:207
TileDQstatus::checkBCIDErr
int checkBCIDErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has BCID mismatch between DMU and ROD Since BCID errors in the DQ fragment are det...
Definition: TileDQstatus.h:100
sendEI_SPB.ch
ch
Definition: sendEI_SPB.py:35
xAOD::short
short
Definition: Vertex_v1.cxx:165
TileRawChannelCollection::getFragSampleBit
uint32_t getFragSampleBit() const
Definition: TileRawChannelCollection.h:105
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
TileDQstatus::checkBCIDErrDetail
int checkBCIDErrDetail(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has BCID mismatch between DMU and ROD This method accesses the TileDigitsContainer i...
Definition: TileDQstatus.h:109
TileRawChannelCollection::getFragHeaderPar
uint32_t getFragHeaderPar() const
Definition: TileRawChannelCollection.h:104
plotBeamSpotCompare.x2
x2
Definition: plotBeamSpotCompare.py:218
TileDQstatus::calibMode
uint32_t calibMode() const
Calibration mode.
Definition: TileDQstatus.h:148
CaloCondBlobAlgs_fillNoiseFromASCII.gain
gain
Definition: CaloCondBlobAlgs_fillNoiseFromASCII.py:110
TileDQstatus::isBiGain
bool isBiGain() const
returns gain mode of run
Definition: TileDQstatus.h:60
TileRawChannelCollection::getFragDstrobe
uint32_t getFragDstrobe() const
Definition: TileRawChannelCollection.h:102
TileDQstatus::m_SampleParityErrArray
short m_SampleParityErrArray[5][64][2]
Array of bit masks storing Sample Parity errors for all DMUs.
Definition: TileDQstatus.h:215
TileDQstatus::m_trigType
int m_trigType
Trigger type.
Definition: TileDQstatus.h:233
TileDQstatus::m_FE_DMUmaskArray
short m_FE_DMUmaskArray[5][64][2]
Array of bit masks storing CRC errors for all DMUs.
Definition: TileDQstatus.h:201
TileDQstatus::m_HeaderFormatErrArray
short m_HeaderFormatErrArray[5][64][2]
Array of bit masks storing Header Format errors for all DMUs.
Definition: TileDQstatus.h:209
TileDQstatus::m_MemoryParityErrArray
short m_MemoryParityErrArray[5][64][2]
Array of bit masks storing Memory Parity errors for all DMUs.
Definition: TileDQstatus.h:217
TileRawChannelCollection::getFragBCID
uint32_t getFragBCID() const
Definition: TileRawChannelCollection.h:99
Trk::u
@ u
Enums for curvilinear frames.
Definition: ParamDefs.h:83
Example_ReadSampleNoise.drawer
drawer
Definition: Example_ReadSampleNoise.py:39
TileDQstatus::m_calibMode
uint32_t m_calibMode
Calibration mode.
Definition: TileDQstatus.h:227
TileDQstatus::checkGlobalCRCErr
int checkGlobalCRCErr(int partition, int drawer, int gain) const
returns 1 if adc channel has global CRC error
Definition: TileDQstatus.h:80
TileDQstatus::m_HeaderParityErrArray
short m_HeaderParityErrArray[5][64][2]
Array of bit masks storing Header Parity errors for all DMUs.
Definition: TileDQstatus.h:211
TileDQstatus::checkROD_CRCErr
int checkROD_CRCErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has CRC error originating in ROD
Definition: TileDQstatus.h:84
TileCalibUtils::MAX_DRAWER
static const unsigned int MAX_DRAWER
Number of drawers in ROS 1-4.
Definition: TileCalibUtils.h:139
PixelByteStreamErrors::BCID
@ BCID
Definition: PixelByteStreamErrors.h:13
TileDQstatus::trigType
int trigType() const
Trigger type.
Definition: TileDQstatus.h:156
TileRawChannelCollection::getFragMemoryPar
uint32_t getFragMemoryPar() const
Definition: TileRawChannelCollection.h:100
TileDQstatus::m_isBiGain
bool m_isBiGain
Boolean storing gain mode of run.
Definition: TileDQstatus.h:189
TileDQstatus::fillBCIDErrDetail
void fillBCIDErrDetail(const TileDigitsContainer *digitsCnt, int frag, int gain)
Definition: TileDQstatus.cxx:249
TileDQstatus::m_EmptyEventArray
short m_EmptyEventArray[5][64][16][2]
Array storing whether event is empty.
Definition: TileDQstatus.h:197
TileDQstatus::m_incompleteDigits
bool m_incompleteDigits
True if not all digits are available.
Definition: TileDQstatus.h:224
TileDQstatus::m_checkDigi
bool m_checkDigi
Boolean flag to control TileDigitsContainer access
Definition: TileDQstatus.h:191
lumiFormat.i
int i
Definition: lumiFormat.py:92
python.LArBadChannelDBAlg.xFFFFFFFF
xFFFFFFFF
Definition: LArBadChannelDBAlg.py:73
endmsg
#define endmsg
Definition: AnalysisConfig_Ntuple.cxx:63
TileDQstatus::m_BCID
uint32_t m_BCID
Event bunch crossing identification.
Definition: TileDQstatus.h:193
TileDQstatus::checkHeaderFormatErr
int checkHeaderFormatErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has header word format error
Definition: TileDQstatus.h:113
IdentifiableContainerMT::end
const_iterator end() const
return const_iterator for end of container
Definition: IdentifiableContainerMT.h:242
IdentifiableContainerMT::const_iterator
Definition: IdentifiableContainerMT.h:82
IdentifiableContainerMT::begin
const_iterator begin() const
return const_iterator for first entry
Definition: IdentifiableContainerMT.h:236
TileDQstatus::m_counter
int m_counter
Counter of non-zero elements in all error arrays.
Definition: TileDQstatus.h:195
TileDQstatus::isAdcDQgood
bool isAdcDQgood(int partition, int drawer, int ch, int gain) const
returns status of single ADC returns False if there are any errors
Definition: TileDQstatus.cxx:178
TileDQstatus::m_cispar
uint32_t m_cispar[110]
CIS parameters.
Definition: TileDQstatus.h:230
min
#define min(a, b)
Definition: cfImp.cxx:40
TileRawDataCollection::identify
ID identify() const
Definition: TileRawDataCollection.h:71
TileDQstatus::m_BCIDErrArray
short m_BCIDErrArray[5][64][2]
Array of bit masks storing BCID errors for all DMUs (from comparison with DMU1)
Definition: TileDQstatus.h:205
TileRawChannelCollection::getFragSstrobe
uint32_t getFragSstrobe() const
Definition: TileRawChannelCollection.h:101
Muon::nsw::incomplete
@ incomplete
Definition: NSWTriggerElink.h:37
TileDQstatus::checkSampleParityErr
int checkSampleParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has data word parity error
Definition: TileDQstatus.h:125
PayloadHelpers::dataSize
size_t dataSize(TDA::PayloadIterator start)
Size in bytes of the buffer that is needed to decode next fragment data content.
Definition: TriggerEDMDeserialiserAlg.cxx:188
TileDQstatus::checkHeaderParityErr
int checkHeaderParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has header word parity error
Definition: TileDQstatus.h:117
TileRawChannelCollection::getFragRODChipMask
uint32_t getFragRODChipMask() const
Definition: TileRawChannelCollection.h:108
TileDQstatus::checkSampleFormatErr
int checkSampleFormatErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has data word format error
Definition: TileDQstatus.h:121
TileRawChannelCollection::getFragHeaderBit
uint32_t getFragHeaderBit() const
Definition: TileRawChannelCollection.h:103
TileCalibUtils::getDrawerString
static std::string getDrawerString(unsigned int ros, unsigned int drawer)
Return the drawer name, e.g.
Definition: TileCalibUtils.cxx:145
TileDQstatus::setAllGood
void setAllGood()
mark all channels/ADC's as DQ good
Definition: TileDQstatus.cxx:49
DEBUG
#define DEBUG
Definition: page_access.h:11
StateLessPT_NewConfig.partition
partition
Definition: StateLessPT_NewConfig.py:49
TileDQstatus::m_DoubleStrobeErrArray
short m_DoubleStrobeErrArray[5][64][2]
Array of bit masks storing Double Strobe errors for all DMUs.
Definition: TileDQstatus.h:221
TileRawChannelCollection::getFragSamplePar
uint32_t getFragSamplePar() const
Definition: TileRawChannelCollection.h:106
TileRawChannelCollection::getFragFEChipMask
uint32_t getFragFEChipMask() const
Definition: TileRawChannelCollection.h:107
TileDQstatus::checkSingleStrobeErr
int checkSingleStrobeErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has single strobe error
Definition: TileDQstatus.h:133
TileDQstatus::m_ROD_DMUmaskArray
short m_ROD_DMUmaskArray[5][64][2]
Array of bit masks storing CRC errors for all DMUs.
Definition: TileDQstatus.h:203
TileRawChannelCollection::getFragGlobalCRC
uint32_t getFragGlobalCRC() const
Various get methods.
Definition: TileRawChannelCollection.h:97
TileDQstatus::checkDoubleStrobeErr
int checkDoubleStrobeErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has double strobe error
Definition: TileDQstatus.h:137
TileDQstatus::checkMemoryParityErr
int checkMemoryParityErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has memory parity error
Definition: TileDQstatus.h:129
TileDQstatus::checkFE_CRCErr
int checkFE_CRCErr(int partition, int drawer, int dmu, int gain) const
returns 1 if DMU has CRC error originating in FE electronics
Definition: TileDQstatus.h:88
TileRawChannelCollection::getFragDSPBCID
uint32_t getFragDSPBCID() const
Definition: TileRawChannelCollection.h:98
DataVector::size
size_type size() const noexcept
Returns the number of elements in the collection.
TileDQstatus::m_SingleStrobeErrArray
short m_SingleStrobeErrArray[5][64][2]
Array of bit masks storing Single Strobe errors for all DMUs.
Definition: TileDQstatus.h:219
python.AutoConfigFlags.msg
msg
Definition: AutoConfigFlags.py:7
TileDQstatus::m_SampleFormatErrArray
short m_SampleFormatErrArray[5][64][2]
Array of bit masks storing Sample Format errors for all DMUs.
Definition: TileDQstatus.h:213