CMS 3D CMS Logo

SiStripFEDBufferComponents.cc
Go to the documentation of this file.
1 #include <iomanip>
2 #include <ostream>
3 #include <sstream>
4 #include <cstring>
7 
8 namespace sistrip {
9 
10  void printHexValue(const uint8_t value, std::ostream& os) {
11  const std::ios_base::fmtflags originalFormatFlags = os.flags();
12  os << std::hex << std::setfill('0') << std::setw(2);
13  os << uint16_t(value);
14  os.flags(originalFormatFlags);
15  }
16 
17  void printHexWord(const uint8_t* pointer, const size_t lengthInBytes, std::ostream& os) {
18  size_t i = lengthInBytes - 1;
19  do {
20  printHexValue(pointer[i], os);
21  if (i != 0)
22  os << " ";
23  } while (i-- != 0);
24  }
25 
26  void printHex(const void* pointer, const size_t lengthInBytes, std::ostream& os) {
27  const uint8_t* bytePointer = reinterpret_cast<const uint8_t*>(pointer);
28  //if there is one 64 bit word or less, print it out
29  if (lengthInBytes <= 8) {
30  printHexWord(bytePointer, lengthInBytes, os);
31  }
32  //otherwise, print word numbers etc
33  else {
34  //header
35  os << "word\tbyte\t \t\tbyte" << std::endl;
36  ;
37  const size_t words = lengthInBytes / 8;
38  const size_t extraBytes = lengthInBytes - 8 * words;
39  //print full words
40  for (size_t w = 0; w < words; w++) {
41  const size_t startByte = w * 8;
42  os << w << '\t' << startByte + 8 << '\t';
43  printHexWord(bytePointer + startByte, 8, os);
44  os << "\t\t" << startByte << std::endl;
45  }
46  //print part word, if any
47  if (extraBytes) {
48  const size_t startByte = words * 8;
49  os << words << '\t' << startByte + 8 << '\t';
50  //padding
51  size_t p = 8;
52  while (p-- > extraBytes) {
53  os << "00 ";
54  }
55  printHexWord(bytePointer + startByte, extraBytes, os);
56  os << "\t\t" << startByte << std::endl;
57  }
58  os << std::endl;
59  }
60  }
61 
62  uint16_t calculateFEDBufferCRC(const uint8_t* buffer, const size_t lengthInBytes) {
63  uint16_t crc = 0xFFFF;
64  for (size_t i = 0; i < lengthInBytes - 8; i++) {
65  crc = evf::compute_crc_8bit(crc, buffer[i ^ 7]);
66  }
67  for (size_t i = lengthInBytes - 8; i < lengthInBytes; i++) {
68  uint8_t byte;
69  //set CRC bytes to zero since these were not set when CRC was calculated
70  if (i == lengthInBytes - 4 || i == lengthInBytes - 3)
71  byte = 0x00;
72  else
73  byte = buffer[i ^ 7];
74  crc = evf::compute_crc_8bit(crc, byte);
75  }
76  return crc;
77  }
78 
79  std::ostream& operator<<(std::ostream& os, const FEDBufferFormat& value) {
80  switch (value) {
82  os << "Old VME";
83  break;
85  os << "Old S-Link";
86  break;
87  case BUFFER_FORMAT_NEW:
88  os << "New";
89  break;
91  os << "Invalid";
92  break;
93  default:
94  os << "Unrecognized";
95  os << " (";
96  printHexValue(value, os);
97  os << ")";
98  break;
99  }
100  return os;
101  }
102 
103  std::ostream& operator<<(std::ostream& os, const FEDHeaderType& value) {
104  switch (value) {
106  os << "Full debug";
107  break;
109  os << "APV error";
110  break;
111  case HEADER_TYPE_NONE:
112  os << "None";
113  break;
114  case HEADER_TYPE_INVALID:
115  os << "Invalid";
116  break;
117  default:
118  os << "Unrecognized";
119  os << " (";
120  printHexValue(value, os);
121  os << ")";
122  break;
123  }
124  return os;
125  }
126 
127  std::ostream& operator<<(std::ostream& os, const FEDLegacyReadoutMode& value) {
128  switch (value) {
130  os << "(L) Scope mode";
131  break;
133  os << "(L) Virgin raw (real)";
134  break;
136  os << "(L) Virgin raw (fake)";
137  break;
139  os << "(L) Processed raw (real)";
140  break;
142  os << "(L) Processed raw (fake)";
143  break;
145  os << "(L) Zero suppressed (real)";
146  break;
148  os << "(L) Zero suppressed (fake)";
149  break;
151  os << "(L) Zero suppressed lite (real)";
152  break;
154  os << "(L) Zero suppressed lite (fake)";
155  break;
157  os << "(L) Spy channel";
158  break;
160  os << "(L) PreMix raw";
161  break;
163  os << "(L) Invalid";
164  break;
165  default:
166  os << "(L) Unrecognized";
167  os << " (";
168  printHexValue(value, os);
169  os << ")";
170  break;
171  }
172  return os;
173  }
174 
175  std::ostream& operator<<(std::ostream& os, const FEDReadoutMode& value) {
176  switch (value) {
177  case READOUT_MODE_SCOPE:
178  os << "Scope mode";
179  break;
181  os << "Virgin raw";
182  break;
184  os << "Processed raw";
185  break;
187  os << "Zero suppressed";
188  break;
190  os << "Zero suppressed (fake)";
191  break;
193  os << "Zero suppressed lite";
194  break;
195  case READOUT_MODE_SPY:
196  os << "Spy channel";
197  break;
198  /*case READOUT_MODE_ZERO_SUPPRESSED_CMOVERRIDE:
199  os << "Zero suppressed CM Override";
200  break;*/
202  os << "Zero suppressed lite CM Override";
203  break;
205  os << "Zero suppressed lite (8 bit, top-stripped)";
206  break;
208  os << "Zero suppressed lite CM Override (8 bit, top-stripped)";
209  break;
211  os << "Zero suppressed lite (8 bit, bottom-stripped)";
212  break;
214  os << "Zero suppressed lite CM Override (8 bit, bottom-stripped)";
215  break;
217  os << "Zero suppressed lite (8 bit, top/bottom-stripped)";
218  break;
220  os << "Zero suppressed lite CM Override (8 bit, top/bottom-stripped)";
221  break;
223  os << "PreMix raw";
224  break;
226  os << "Invalid";
227  break;
228  default:
229  os << "Unrecognized";
230  os << " (";
231  printHexValue(value, os);
232  os << ")";
233  break;
234  }
235  return os;
236  }
237 
238  std::ostream& operator<<(std::ostream& os, const FEDDAQEventType& value) {
239  switch (value) {
241  os << "Physics trigger";
242  break;
244  os << "Calibration trigger";
245  break;
246  case DAQ_EVENT_TYPE_TEST:
247  os << "Test trigger";
248  break;
250  os << "Technical trigger";
251  break;
253  os << "Simulated event";
254  break;
256  os << "Traced event";
257  break;
259  os << "Error";
260  break;
262  os << "Unknown";
263  break;
264  default:
265  os << "Unrecognized";
266  os << " (";
267  printHexValue(value, os);
268  os << ")";
269  break;
270  }
271  return os;
272  }
273 
274  std::ostream& operator<<(std::ostream& os, const FEDTTSBits& value) {
275  switch (value) {
276  case TTS_DISCONNECTED0:
277  os << "Disconected 0";
278  break;
279  case TTS_WARN_OVERFLOW:
280  os << "Warning overflow";
281  break;
282  case TTS_OUT_OF_SYNC:
283  os << "Out of sync";
284  break;
285  case TTS_BUSY:
286  os << "Busy";
287  break;
288  case TTS_READY:
289  os << "Ready";
290  break;
291  case TTS_ERROR:
292  os << "Error";
293  break;
294  case TTS_INVALID:
295  os << "Invalid";
296  break;
297  case TTS_DISCONNECTED1:
298  os << "Disconected 1";
299  break;
300  default:
301  os << "Unrecognized";
302  os << " (";
303  printHexValue(value, os);
304  os << ")";
305  break;
306  }
307  return os;
308  }
309 
310  std::ostream& operator<<(std::ostream& os, const FEDBufferState& value) {
311  switch (value) {
312  case BUFFER_STATE_UNSET:
313  os << "Unset";
314  break;
315  case BUFFER_STATE_EMPTY:
316  os << "Empty";
317  break;
319  os << "Partial Full";
320  break;
321  case BUFFER_STATE_FULL:
322  os << "Full";
323  break;
324  default:
325  os << "Unrecognized";
326  os << " (";
327  printHexValue(value, os);
328  os << ")";
329  break;
330  }
331  return os;
332  }
333 
334  std::ostream& operator<<(std::ostream& os, const FEDChannelStatus& value) {
335  if (!(value & CHANNEL_STATUS_LOCKED))
336  os << "Unlocked ";
337  if (!(value & CHANNEL_STATUS_IN_SYNC))
338  os << "Out-of-sync ";
340  os << "APV 1 bad address ";
342  os << "APV 1 error ";
344  os << "APV 0 bad address ";
346  os << "APV 0 error ";
348  os << "No errors";
349  return os;
350  }
351 
352  std::ostream& operator<<(std::ostream& os, const FEDBufferStatusCode& value) {
353  switch (value) {
355  os << "SUCCESS";
356  break;
358  os << "Buffer pointer is NULL.";
359  break;
361  os << "Buffer is too small. Min size is 24.";
362  break;
364  os << "Buffer format not recognized. ";
365  break;
367  os << "Unpacking of spy channel data with FEDBuffer is not supported";
368  break;
370  os << "Buffer is not from spy channel";
371  break;
373  os << "No or invalid header type";
374  break;
377  os << "Channel does not fit into buffer";
378  break;
380  os << "Channel is too short";
381  break;
382  }
383  return os;
384  }
385 
387  if ((bufferFormatString == "OLD_VME") || (bufferFormatString == "BUFFER_FORMAT_OLD_VME") ||
388  (bufferFormatString == "Old VME")) {
389  return BUFFER_FORMAT_OLD_VME;
390  }
391  if ((bufferFormatString == "OLD_SLINK") || (bufferFormatString == "BUFFER_FORMAT_OLD_SLINK") ||
392  (bufferFormatString == "Old S-Link")) {
394  }
395  if ((bufferFormatString == "NEW") || (bufferFormatString == "BUFFER_FORMAT_NEW") || (bufferFormatString == "New")) {
396  return BUFFER_FORMAT_NEW;
397  }
398  //if it was none of the above then return invalid
399  return BUFFER_FORMAT_INVALID;
400  }
401 
403  if ((headerTypeString == "FULL_DEBUG") || (headerTypeString == "HEADER_TYPE_FULL_DEBUG") ||
404  (headerTypeString == "Full debug")) {
405  return HEADER_TYPE_FULL_DEBUG;
406  }
407  if ((headerTypeString == "APV_ERROR") || (headerTypeString == "HEADER_TYPE_APV_ERROR") ||
408  (headerTypeString == "APV error")) {
409  return HEADER_TYPE_APV_ERROR;
410  }
411  if ((headerTypeString == "None") || (headerTypeString == "none")) {
412  return HEADER_TYPE_NONE;
413  }
414  //if it was none of the above then return invalid
415  return HEADER_TYPE_INVALID;
416  }
417 
419  if ((readoutModeString == "READOUT_MODE_SCOPE") || (readoutModeString == "SCOPE") ||
420  (readoutModeString == "SCOPE_MODE") || (readoutModeString == "Scope mode")) {
421  return READOUT_MODE_SCOPE;
422  }
423  if ((readoutModeString == "READOUT_MODE_VIRGIN_RAW") || (readoutModeString == "VIRGIN_RAW") ||
424  (readoutModeString == "Virgin raw")) {
426  }
427  if ((readoutModeString == "READOUT_MODE_PROC_RAW") || (readoutModeString == "PROC_RAW") ||
428  (readoutModeString == "PROCESSED_RAW") || (readoutModeString == "Processed raw")) {
429  return READOUT_MODE_PROC_RAW;
430  }
431  if ((readoutModeString == "READOUT_MODE_ZERO_SUPPRESSED") || (readoutModeString == "ZERO_SUPPRESSED") ||
432  (readoutModeString == "Zero suppressed")) {
434  }
435  if ((readoutModeString == "READOUT_MODE_ZERO_SUPPRESSED_LITE8") || (readoutModeString == "ZERO_SUPPRESSED_LITE8") ||
436  (readoutModeString == "Zero suppressed lite8")) {
438  }
439  if ((readoutModeString == "READOUT_MODE_ZERO_SUPPRESSED_LITE8_TOPBOT") ||
440  (readoutModeString == "ZERO_SUPPRESSED_LITE8_TOPBOT") ||
441  (readoutModeString == "Zero suppressed lite8 TopBot")) {
443  }
444  if ((readoutModeString == "READOUT_MODE_ZERO_SUPPRESSED_LITE8_BOTBOT") ||
445  (readoutModeString == "ZERO_SUPPRESSED_LITE8_BOTBOT") ||
446  (readoutModeString == "Zero suppressed lite8 BotBot")) {
448  }
449  if ((readoutModeString == "READOUT_MODE_ZERO_SUPPRESSED_LITE10") ||
450  (readoutModeString == "ZERO_SUPPRESSED_LITE10") || (readoutModeString == "Zero suppressed lite10")) {
452  }
453  if ((readoutModeString == "READOUT_MODE_PREMIX_RAW") || (readoutModeString == "PREMIX_RAW") ||
454  (readoutModeString == "PreMix Raw")) {
456  }
457  if ((readoutModeString == "READOUT_MODE_SPY") || (readoutModeString == "SPY") ||
458  (readoutModeString == "Spy channel")) {
459  return READOUT_MODE_SPY;
460  }
461  //if it was none of the above then return invalid
462  return READOUT_MODE_INVALID;
463  }
464  uint8_t packetCodeFromString(const std::string& packetCode, FEDReadoutMode mode) {
466  if (packetCode == "ZERO_SUPPRESSED" || packetCode == "Zero suppressed") {
468  } else if (packetCode == "ZERO_SUPPRESSED10" || packetCode == "Zero suppressed 10") {
470  } else if (packetCode == "ZERO_SUPPRESSED8_BOTBOT" || packetCode == "Zero suppressed 8 BOTBOT") {
472  } else if (packetCode == "ZERO_SUPPRESSED8_TOPBOT" || packetCode == "Zero suppressed 8 TOPBOT") {
474  } else {
475  throw cms::Exception("FEDBuffer")
476  << "'" << packetCode << "' cannot be converted into a valid packet code for FEDReadoutMode ZERO_SUPPRESSED";
477  }
478  } else if (mode == READOUT_MODE_VIRGIN_RAW) {
479  if (packetCode == "VIRGIN_RAW" || packetCode == "Virgin raw") {
480  return PACKET_CODE_VIRGIN_RAW;
481  } else if (packetCode == "VIRGIN_RAW10" || packetCode == "Virgin raw 10") {
483  } else if (packetCode == "VIRGIN_RAW8_BOTBOT" || packetCode == "Virgin raw 8 BOTBOT") {
485  } else if (packetCode == "VIRGIN_RAW8_TOPBOT" || packetCode == "Virgin raw 8 TOPBOT") {
487  } else {
488  throw cms::Exception("FEDBuffer")
489  << "'" << packetCode << "' cannot be converted into a valid packet code for FEDReadoutMode VIRGIN_RAW";
490  }
491  } else if (mode == READOUT_MODE_PROC_RAW) {
492  if (packetCode == "PROC_RAW" || packetCode == "Processed raw") {
493  return PACKET_CODE_PROC_RAW;
494  } else if (packetCode == "PROC_RAW10" || packetCode == "Processed raw 10") {
495  return PACKET_CODE_PROC_RAW10;
496  } else if (packetCode == "PROC_RAW8_BOTBOT" || packetCode == "Processed raw 8 BOTBOT") {
498  } else if (packetCode == "PROC_RAW8_TOPBOT" || packetCode == "Processed raw 8 TOPBOT") {
500  } else {
501  throw cms::Exception("FEDBuffer")
502  << "'" << packetCode << "' cannot be converted into a valid packet code for FEDReadoutMode PROC_RAW";
503  }
504  } else if (mode == READOUT_MODE_SCOPE) {
505  if (packetCode == "SCOPE" || packetCode == "Scope" || packetCode.empty()) { // default
506  return PACKET_CODE_SCOPE;
507  } else {
508  throw cms::Exception("FEDBuffer")
509  << "'" << packetCode << "' cannot be converted into a valid packet code for FEDReadoutMode SCOPE";
510  }
511  } else {
512  if (!packetCode.empty()) {
513  throw cms::Exception("FEDBuffer") << "Packet codes are only needed for zero-suppressed (non-lite), virgin raw, "
514  "processed raw and spy data. FEDReadoutMode="
515  << mode << " and packetCode='" << packetCode << "'";
516  }
517  return 0;
518  }
519  }
520 
522  if ((daqEventTypeString == "PHYSICS") || (daqEventTypeString == "DAQ_EVENT_TYPE_PHYSICS") ||
523  (daqEventTypeString == "Physics trigger")) {
524  return DAQ_EVENT_TYPE_PHYSICS;
525  }
526  if ((daqEventTypeString == "CALIBRATION") || (daqEventTypeString == "DAQ_EVENT_TYPE_CALIBRATION") ||
527  (daqEventTypeString == "Calibration trigger")) {
529  }
530  if ((daqEventTypeString == "TEST") || (daqEventTypeString == "DAQ_EVENT_TYPE_TEST") ||
531  (daqEventTypeString == "Test trigger")) {
532  return DAQ_EVENT_TYPE_TEST;
533  }
534  if ((daqEventTypeString == "TECHNICAL") || (daqEventTypeString == "DAQ_EVENT_TYPE_TECHNICAL") ||
535  (daqEventTypeString == "Technical trigger")) {
537  }
538  if ((daqEventTypeString == "SIMULATED") || (daqEventTypeString == "DAQ_EVENT_TYPE_SIMULATED") ||
539  (daqEventTypeString == "Simulated trigger")) {
541  }
542  if ((daqEventTypeString == "TRACED") || (daqEventTypeString == "DAQ_EVENT_TYPE_TRACED") ||
543  (daqEventTypeString == "Traced event")) {
544  return DAQ_EVENT_TYPE_TRACED;
545  }
546  if ((daqEventTypeString == "ERROR") || (daqEventTypeString == "DAQ_EVENT_TYPE_ERROR") ||
547  (daqEventTypeString == "Error")) {
548  return DAQ_EVENT_TYPE_ERROR;
549  }
550  //if it was none of the above then return invalid
551  return DAQ_EVENT_TYPE_INVALID;
552  }
553 
554  void FEDStatusRegister::printFlags(std::ostream& os) const {
555  if (slinkFullFlag())
556  os << "SLINK_FULL ";
558  os << "HEADER_MONITOR_READY ";
559  if (qdrMemoryFullFlag())
560  os << "QDR_FULL ";
562  os << "QDR_PARTIAL_FULL ";
563  if (qdrMemoryEmptyFlag())
564  os << "QDR_EMPTY ";
565  if (l1aBxFIFOFullFlag())
566  os << "L1A_FULL ";
568  os << "L1A_PARTIAL_FULL ";
569  if (l1aBxFIFOEmptyFlag())
570  os << "L1A_EMPTY ";
571  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
572  if (feDataMissingFlag(iFE))
573  os << "FEUNIT" << uint16_t(iFE) << "MISSING ";
574  }
575  }
576 
578  uint8_t result(0x00);
579  if (qdrMemoryFullFlag())
583  if (qdrMemoryEmptyFlag())
585  return FEDBufferState(result);
586  }
587 
589  uint8_t result(0x00);
590  if (l1aBxFIFOFullFlag())
594  if (l1aBxFIFOEmptyFlag())
596  return FEDBufferState(result);
597  }
598 
599  void FEDStatusRegister::setBit(const uint8_t num, const bool bitSet) {
600  const uint16_t mask = (0x0001 << num);
601  if (bitSet)
602  data_ |= mask;
603  else
604  data_ &= (~mask);
605  }
606 
608  switch (state) {
609  case BUFFER_STATE_FULL:
611  case BUFFER_STATE_EMPTY:
612  case BUFFER_STATE_UNSET:
613  break;
614  default:
615  std::ostringstream ss;
616  ss << "Invalid buffer state: ";
617  printHex(&state, 1, ss);
618  throw cms::Exception("FEDBuffer") << ss.str();
619  }
623  return *this;
624  }
625 
627  switch (state) {
628  case BUFFER_STATE_FULL:
630  case BUFFER_STATE_EMPTY:
631  case BUFFER_STATE_UNSET:
632  break;
633  default:
634  std::ostringstream ss;
635  ss << "Invalid buffer state: ";
636  printHex(&state, 1, ss);
637  throw cms::Exception("FEDBuffer") << ss.str();
638  }
642  return *this;
643  }
644 
645  void FEDBackendStatusRegister::printFlags(std::ostream& os) const {
646  if (internalFreezeFlag())
647  os << "INTERNAL_FREEZE ";
648  if (slinkDownFlag())
649  os << "SLINK_DOWN ";
650  if (slinkFullFlag())
651  os << "SLINK_FULL ";
652  if (backpressureFlag())
653  os << "BACKPRESSURE ";
654  if (ttcReadyFlag())
655  os << "TTC_READY ";
657  os << "HEADER_MONITOR_READY ";
658  printFlagsForBuffer(qdrMemoryState(), "QDR", os);
659  printFlagsForBuffer(frameAddressFIFOState(), "FRAME_ADDRESS", os);
660  printFlagsForBuffer(totalLengthFIFOState(), "TOTAL_LENGTH", os);
661  printFlagsForBuffer(trackerHeaderFIFOState(), "TRACKER_HEADER", os);
662  printFlagsForBuffer(l1aBxFIFOState(), "L1ABX", os);
663  printFlagsForBuffer(feEventLengthFIFOState(), "FE_LENGTH", os);
665  }
666 
668  const std::string name,
669  std::ostream& os) const {
670  if (bufferState & BUFFER_STATE_EMPTY)
671  os << name << "_EMPTY ";
672  if (bufferState & BUFFER_STATE_PARTIAL_FULL)
673  os << name << "_PARTIAL_FULL ";
674  if (bufferState & BUFFER_STATE_FULL)
675  os << name << "_FULL ";
676  if (bufferState == BUFFER_STATE_UNSET)
677  os << name << "_UNSET ";
678  }
679 
680  FEDBufferState FEDBackendStatusRegister::getBufferState(const uint8_t bufferPosition) const {
681  uint8_t result = 0x00;
682  if (getBit(bufferPosition + STATE_OFFSET_EMPTY))
684  if (getBit(bufferPosition + STATE_OFFSET_PARTIAL_FULL))
686  if (getBit(bufferPosition + STATE_OFFSET_FULL))
688  return FEDBufferState(result);
689  }
690 
691  void FEDBackendStatusRegister::setBufferSate(const uint8_t bufferPosition, const FEDBufferState state) {
692  switch (state) {
693  case BUFFER_STATE_FULL:
695  case BUFFER_STATE_EMPTY:
696  case BUFFER_STATE_UNSET:
697  break;
698  default:
699  std::ostringstream ss;
700  ss << "Invalid buffer state: ";
701  printHex(&state, 1, ss);
702  throw cms::Exception("FEDBuffer") << ss.str();
703  }
704  setBit(bufferPosition + STATE_OFFSET_EMPTY, state & BUFFER_STATE_EMPTY);
706  setBit(bufferPosition + STATE_OFFSET_FULL, state & BUFFER_STATE_FULL);
707  }
708 
709  void FEDBackendStatusRegister::setBit(const uint8_t num, const bool bitSet) {
710  const uint32_t mask = (0x00000001 << num);
711  if (bitSet)
712  data_ |= mask;
713  else
714  data_ &= (~mask);
715  }
716 
718  const FEDBufferState frameAddressFIFOBufferState,
719  const FEDBufferState totalLengthFIFOBufferState,
720  const FEDBufferState trackerHeaderFIFOBufferState,
721  const FEDBufferState l1aBxFIFOBufferState,
722  const FEDBufferState feEventLengthFIFOBufferState,
723  const FEDBufferState feFPGABufferState,
724  const bool backpressure,
725  const bool slinkFull,
726  const bool slinkDown,
727  const bool internalFreeze,
728  const bool trackerHeaderMonitorDataReady,
729  const bool ttcReady)
730  : data_(0) {
731  setInternalFreezeFlag(internalFreeze);
732  setSLinkDownFlag(slinkDown);
733  setSLinkFullFlag(slinkFull);
734  setBackpressureFlag(backpressure);
735  setTTCReadyFlag(ttcReady);
736  setTrackerHeaderMonitorDataReadyFlag(trackerHeaderMonitorDataReady);
737  setQDRMemoryState(qdrMemoryBufferState);
738  setFrameAddressFIFOState(frameAddressFIFOBufferState);
739  setTotalLengthFIFOState(totalLengthFIFOBufferState);
740  setTrackerHeaderFIFOState(trackerHeaderFIFOBufferState);
741  setL1ABXFIFOState(l1aBxFIFOBufferState);
742  setFEEventLengthFIFOState(feEventLengthFIFOBufferState);
744  }
745 
746  TrackerSpecialHeader::TrackerSpecialHeader(const uint8_t* headerPointer) {
747  //the buffer format byte is one of the valid values if we assume the buffer is not swapped
748  const bool validFormatByteWhenNotWordSwapped = ((headerPointer[BUFFERFORMAT] == BUFFER_FORMAT_CODE_NEW) ||
749  (headerPointer[BUFFERFORMAT] == BUFFER_FORMAT_CODE_OLD));
750  //the buffer format byte is the old value if we assume the buffer is swapped
751  const bool validFormatByteWhenWordSwapped = (headerPointer[BUFFERFORMAT ^ 4] == BUFFER_FORMAT_CODE_OLD);
752  //if the buffer format byte is valid if the buffer is not swapped or it is never valid
753  if (validFormatByteWhenNotWordSwapped || (!validFormatByteWhenNotWordSwapped && !validFormatByteWhenWordSwapped)) {
754  memcpy(specialHeader_, headerPointer, 8);
755  wordSwapped_ = false;
756  } else {
757  memcpy(specialHeader_, headerPointer + 4, 4);
758  memcpy(specialHeader_ + 4, headerPointer, 4);
759  wordSwapped_ = true;
760  }
761  }
762 
765  return BUFFER_FORMAT_NEW;
767  if (wordSwapped_)
768  return BUFFER_FORMAT_OLD_VME;
769  else
771  } else
772  return BUFFER_FORMAT_INVALID;
773  }
774 
776  const uint8_t eventTypeNibble = trackerEventTypeNibble();
777  const uint8_t mode = (eventTypeNibble & 0xF);
778  switch (mode) {
787  return FEDLegacyReadoutMode(mode);
788  default:
790  }
791  }
792 
794  //check if order in buffer is different
795  if (((bufferFormat() == BUFFER_FORMAT_OLD_VME) && (newBufferFormat != BUFFER_FORMAT_OLD_VME)) ||
796  ((bufferFormat() != BUFFER_FORMAT_OLD_VME) && (newBufferFormat == BUFFER_FORMAT_OLD_VME))) {
798  }
799  //set appropriate code
800  setBufferFormatByte(newBufferFormat);
801  return *this;
802  }
803 
805  switch (newBufferFormat) {
809  break;
810  case BUFFER_FORMAT_NEW:
812  break;
813  default:
814  std::ostringstream ss;
815  ss << "Invalid buffer format: ";
816  printHex(&newBufferFormat, 1, ss);
817  throw cms::Exception("FEDBuffer") << ss.str();
818  }
819  }
820 
822  switch (headerType) {
825  case HEADER_TYPE_NONE:
827  return *this;
828  default:
829  std::ostringstream ss;
830  ss << "Invalid header type: ";
831  printHex(&headerType, 1, ss);
832  throw cms::Exception("FEDBuffer") << ss.str();
833  }
834  }
835 
837  switch (readoutMode) {
838  case READOUT_MODE_SCOPE:
841  case READOUT_MODE_SPY:
854  break;
855  default:
856  std::ostringstream ss;
857  ss << "Invalid readout mode: ";
858  printHex(&readoutMode, 1, ss);
859  throw cms::Exception("FEDBuffer") << ss.str();
860  }
861  return *this;
862  }
863 
865  const bool error) {
866  const uint8_t mask = 0x1 << internalFEUnitNum;
867  const uint8_t result = ((apvAddressErrorRegister() & (~mask)) | (error ? mask : 0x00));
869  return *this;
870  }
871 
873  const bool enabled) {
874  const uint8_t mask = 0x1 << internalFEUnitNum;
875  const uint8_t result = ((feEnableRegister() & (~mask)) | (enabled ? mask : 0x00));
877  return *this;
878  }
879 
881  const bool overflow) {
882  const uint8_t mask = 0x1 << internalFEUnitNum;
883  const uint8_t result = ((feOverflowRegister() & (~mask)) | (overflow ? mask : 0x00));
885  return *this;
886  }
887 
889  const FEDReadoutMode readoutMode,
890  const FEDHeaderType headerType,
891  const uint8_t address,
892  const uint8_t addressErrorRegister,
893  const uint8_t feEnableRegister,
894  const uint8_t feOverflowRegister,
895  const FEDStatusRegister fedStatusRegister) {
896  memset(specialHeader_, 0x00, 8);
897  //determine if order is swapped in real buffer
899  //set fields
903  setAPVEAddress(address);
904  setAPVEAddressErrorRegister(addressErrorRegister);
908  }
909 
911  switch (eventTypeNibble()) {
914  case DAQ_EVENT_TYPE_TEST:
920  default:
921  return DAQ_EVENT_TYPE_INVALID;
922  }
923  }
924 
926  header_[7] = ((header_[7] & 0xF0) | evtType);
927  return *this;
928  }
929 
930  FEDDAQHeader& FEDDAQHeader::setL1ID(const uint32_t l1ID) {
931  header_[4] = (l1ID & 0x000000FF);
932  header_[5] = ((l1ID & 0x0000FF00) >> 8);
933  header_[6] = ((l1ID & 0x00FF0000) >> 16);
934  return *this;
935  }
936 
937  FEDDAQHeader& FEDDAQHeader::setBXID(const uint16_t bxID) {
938  header_[3] = ((bxID & 0x0FF0) >> 4);
939  header_[2] = ((header_[2] & 0x0F) | ((bxID & 0x000F) << 4));
940  return *this;
941  }
942 
943  FEDDAQHeader& FEDDAQHeader::setSourceID(const uint16_t sourceID) {
944  header_[2] = ((header_[2] & 0xF0) | ((sourceID & 0x0F00) >> 8));
945  header_[1] = (sourceID & 0x00FF);
946  return *this;
947  }
948 
949  FEDDAQHeader::FEDDAQHeader(const uint32_t l1ID,
950  const uint16_t bxID,
951  const uint16_t sourceID,
952  const FEDDAQEventType evtType) {
953  //clear everything (FOV,H,x,$ all set to 0)
954  memset(header_, 0x0, 8);
955  //set the BoE nibble to indicate this is the last fragment
956  header_[7] = 0x50;
957  //set variable fields vith values supplied
958  setEventType(evtType);
959  setL1ID(l1ID);
960  setBXID(bxID);
962  }
963 
965  switch (ttsNibble()) {
966  case TTS_DISCONNECTED0:
967  case TTS_WARN_OVERFLOW:
968  case TTS_OUT_OF_SYNC:
969  case TTS_BUSY:
970  case TTS_READY:
971  case TTS_ERROR:
972  case TTS_DISCONNECTED1:
973  return FEDTTSBits(ttsNibble());
974  default:
975  return TTS_INVALID;
976  }
977  }
978 
979  FEDDAQTrailer::FEDDAQTrailer(const uint32_t eventLengthIn64BitWords,
980  const uint16_t crc,
981  const FEDTTSBits ttsBits,
982  const bool slinkTransmissionError,
983  const bool badFEDID,
984  const bool slinkCRCError,
985  const uint8_t eventStatusNibble) {
986  //clear everything (T,x,$ all set to 0)
987  memset(trailer_, 0x0, 8);
988  //set the EoE nibble to indicate this is the last fragment
989  trailer_[7] = 0xA0;
990  //set variable fields vith values supplied
994  setCRC(crc);
996  setBadSourceIDBit(badFEDID);
998  }
999 
1000  FEDDAQTrailer& FEDDAQTrailer::setEventLengthIn64BitWords(const uint32_t eventLengthIn64BitWords) {
1001  trailer_[4] = (eventLengthIn64BitWords & 0x000000FF);
1002  trailer_[5] = ((eventLengthIn64BitWords & 0x0000FF00) >> 8);
1003  trailer_[6] = ((eventLengthIn64BitWords & 0x00FF0000) >> 16);
1004  return *this;
1005  }
1006 
1007  FEDDAQTrailer& FEDDAQTrailer::setCRC(const uint16_t crc) {
1008  trailer_[2] = (crc & 0x00FF);
1009  trailer_[3] = ((crc >> 8) & 0x00FF);
1010  return *this;
1011  }
1012 
1014  if (bitSet)
1015  trailer_[1] |= 0x80;
1016  else
1017  trailer_[1] &= (~0x80);
1018  return *this;
1019  }
1020 
1022  if (bitSet)
1023  trailer_[1] |= 0x40;
1024  else
1025  trailer_[1] &= (~0x40);
1026  return *this;
1027  }
1028 
1030  if (bitSet)
1031  trailer_[0] |= 0x04;
1032  else
1033  trailer_[0] &= (~0x40);
1034  return *this;
1035  }
1036 
1037  FEDDAQTrailer& FEDDAQTrailer::setEventStatusNibble(const uint8_t eventStatusNibble) {
1038  trailer_[1] = ((trailer_[1] & 0xF0) | (eventStatusNibble & 0x0F));
1039  return *this;
1040  }
1041 
1043  trailer_[0] = ((trailer_[0] & 0x0F) | (ttsBits & 0xF0));
1044  return *this;
1045  }
1046 
1048 
1050 
1052 
1054 
1055  bool FEDAPVErrorHeader::checkStatusBits(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const {
1056  //3 bytes per FE unit, channel order is reversed in FE unit data, 2 bits per channel
1057  const uint16_t bitNumber = (internalFEDChannelNum / FEDCH_PER_FEUNIT) * 24 +
1058  (FEDCH_PER_FEUNIT - 1 - (internalFEDChannelNum % FEDCH_PER_FEUNIT)) * 2 + apvNum;
1059  //bit high means no error
1060  return (header_[bitNumber / 8] & (0x01 << (bitNumber % 8)));
1061  }
1062 
1065  }
1066 
1067  const uint8_t* FEDAPVErrorHeader::data() const { return header_; }
1068 
1069  FEDAPVErrorHeader::FEDAPVErrorHeader(const std::vector<bool>& apvsGood) {
1070  memset(header_, 0x00, APV_ERROR_HEADER_SIZE_IN_BYTES);
1071  for (uint8_t iCh = 0; iCh < FEDCH_PER_FED; iCh++) {
1072  setAPVStatusBit(iCh, 0, apvsGood[iCh * 2]);
1073  setAPVStatusBit(iCh, 1, apvsGood[iCh * 2 + 1]);
1074  }
1075  }
1076 
1078  const uint8_t apvNum,
1079  const bool apvGood) {
1080  //3 bytes per FE unit, channel order is reversed in FE unit data, 2 bits per channel
1081  const uint16_t bitNumber = (internalFEDChannelNum / FEDCH_PER_FED) * 24 +
1082  (FEDCH_PER_FED - 1 - (internalFEDChannelNum % FEDCH_PER_FED)) * 2 + apvNum;
1083  const uint8_t byteNumber = bitNumber / 8;
1084  const uint8_t bitInByte = bitNumber % 8;
1085  const uint8_t mask = (0x01 << bitInByte);
1086  header_[byteNumber] = ((header_[byteNumber] & (~mask)) | (apvGood ? mask : 0x00));
1087  return *this;
1088  }
1089 
1091  //if channel is unlocked then set both APV bits bad
1095  return;
1096  } else {
1099  } else {
1101  }
1104  } else {
1106  }
1107  }
1108  }
1109 
1110  //These methods do nothing as the values in question are in present in the APV Error header.
1111  //The methods exist so that users of the base class can set the values without caring which type of header they have and so if they are needed.
1112  void FEDAPVErrorHeader::setFEUnitMajorityAddress(const uint8_t internalFEUnitNum, const uint8_t address) { return; }
1113  void FEDAPVErrorHeader::setBEStatusRegister(const FEDBackendStatusRegister beStatusRegister) { return; }
1114  void FEDAPVErrorHeader::setDAQRegister(const uint32_t daqRegister) { return; }
1115  void FEDAPVErrorHeader::setDAQRegister2(const uint32_t daqRegister2) { return; }
1116  void FEDAPVErrorHeader::set32BitReservedRegister(const uint8_t internalFEUnitNum, const uint32_t reservedRegister) {
1117  return;
1118  }
1119  void FEDAPVErrorHeader::setFEUnitLength(const uint8_t internalFEUnitNum, const uint16_t length) { return; }
1120 
1122 
1124 
1126 
1128 
1129  bool FEDFullDebugHeader::checkStatusBits(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const {
1132  }
1133 
1135  //return ( !unlockedFromBit(internalFEDChannelNum) &&
1136  // !outOfSyncFromBit(internalFEDChannelNum) &&
1137  // !apvErrorFromBit(internalFEDChannelNum,0) &&
1138  // !apvAddressErrorFromBit(internalFEDChannelNum,0) &&
1139  // !apvErrorFromBit(internalFEDChannelNum,1) &&
1140  // !apvAddressErrorFromBit(internalFEDChannelNum,1) );
1142  }
1143 
1145  const uint8_t* pFEWord = feWord(internalFEDChannelNum / FEDCH_PER_FEUNIT);
1146  const uint8_t feUnitChanNum = internalFEDChannelNum % FEDCH_PER_FEUNIT;
1147  const uint8_t startByteInFEWord = (FEDCH_PER_FEUNIT - 1 - feUnitChanNum) * 6 / 8;
1148  switch ((FEDCH_PER_FEUNIT - 1 - feUnitChanNum) % 4) {
1149  case 0:
1150  return FEDChannelStatus(pFEWord[startByteInFEWord] & 0x3F);
1151  case 1:
1152  return FEDChannelStatus(((pFEWord[startByteInFEWord] & 0xC0) >> 6) |
1153  ((pFEWord[startByteInFEWord + 1] & 0x0F) << 2));
1154  case 2:
1155  return FEDChannelStatus(((pFEWord[startByteInFEWord] & 0xF0) >> 4) |
1156  ((pFEWord[startByteInFEWord + 1] & 0x03) << 4));
1157  case 3:
1158  return FEDChannelStatus((pFEWord[startByteInFEWord] & 0xFC) >> 2);
1159  //stop compiler warning
1160  default:
1161  return FEDChannelStatus(0);
1162  }
1163  /*const uint8_t feUnitChanNum = internalFEDChannelNum / FEDCH_PER_FEUNIT;
1164  const uint8_t* pFEWord = feWord(feUnitChanNum);
1165  const uint8_t startByteInFEWord = feUnitChanNum * 3 / 4;
1166  //const uint8_t shift = ( 6 - ((feUnitChanNum-1)%4) );
1167  //const uint16_t mask = ( 0x003F << shift );
1168  //uint8_t result = ( (pFEWord[startByteInFEWord] & (mask&0x00FF)) >> shift );
1169  //result |= ( (pFEWord[startByteInFEWord+1] & (mask>>8)) << (8-shift) );
1170  switch (feUnitChanNum % 4) {
1171  case 0:
1172  return FEDChannelStatus( pFEWord[startByteInFEWord] & 0x3F );
1173  case 1:
1174  return FEDChannelStatus( ((pFEWord[startByteInFEWord] & 0xC0) >> 6) | ((pFEWord[startByteInFEWord+1] & 0x0F) << 2) );
1175  case 2:
1176  return FEDChannelStatus( ((pFEWord[startByteInFEWord] & 0xF0) >> 4) | ((pFEWord[startByteInFEWord+1] & 0x03) << 4) );
1177  case 3:
1178  return FEDChannelStatus( (pFEWord[startByteInFEWord] & 0xFC) >> 2 );
1179  //stop compiler warning
1180  default:
1181  return FEDChannelStatus(0);
1182  }*/
1183  }
1184 
1185  const uint8_t* FEDFullDebugHeader::data() const { return header_; }
1186 
1187  FEDFullDebugHeader::FEDFullDebugHeader(const std::vector<uint16_t>& feUnitLengths,
1188  const std::vector<uint8_t>& feMajorityAddresses,
1189  const std::vector<FEDChannelStatus>& channelStatus,
1190  const FEDBackendStatusRegister beStatusRegister,
1191  const uint32_t daqRegister,
1192  const uint32_t daqRegister2) {
1197  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
1198  setFEUnitLength(iFE, feUnitLengths[iFE]);
1199  setFEUnitMajorityAddress(iFE, feMajorityAddresses[iFE]);
1200  }
1201  for (uint8_t iCh = 0; iCh < FEDCH_PER_FED; iCh++) {
1202  setChannelStatus(iCh, channelStatus[iCh]);
1203  }
1204  }
1205 
1213  }
1214 
1215  void FEDFullDebugHeader::setFEUnitMajorityAddress(const uint8_t internalFEUnitNum, const uint8_t address) {
1216  feWord(internalFEUnitNum)[9] = address;
1217  }
1218 
1221  }
1222 
1223  void FEDFullDebugHeader::setDAQRegister(const uint32_t daqRegister) { set32BitWordAt(feWord(7) + 10, daqRegister); }
1224 
1225  void FEDFullDebugHeader::setDAQRegister2(const uint32_t daqRegister2) {
1227  }
1228 
1229  //used by DigiToRaw to copy reserved registers in internalFEUnit buffers 1 through 5
1230  void FEDFullDebugHeader::set32BitReservedRegister(const uint8_t internalFEUnitNum, const uint32_t reservedRegister) {
1231  set32BitWordAt(feWord(internalFEUnitNum) + 10, reservedRegister);
1232  }
1233 
1234  void FEDFullDebugHeader::setFEUnitLength(const uint8_t internalFEUnitNum, const uint16_t length) {
1235  feWord(internalFEUnitNum)[15] = ((length & 0xFF00) >> 8);
1236  feWord(internalFEUnitNum)[14] = (length & 0x00FF);
1237  }
1238 
1239  void FEDFullDebugHeader::setBit(const uint8_t internalFEDChannelNum, const uint8_t bit, const bool value) {
1240  const uint8_t bitInFeWord = (FEDCH_PER_FEUNIT - 1 - (internalFEDChannelNum % FEDCH_PER_FEUNIT)) * 6 + bit;
1241  uint8_t& byte = *(feWord(internalFEDChannelNum / FEDCH_PER_FEUNIT) + (bitInFeWord / 8));
1242  const uint8_t mask = (0x1 << bitInFeWord % 8);
1243  byte = ((byte & (~mask)) | (value ? mask : 0x0));
1244  }
1245 
1247 
1249  : channels_(FEDCH_PER_FED, FEDChannel(nullptr, 0, 0)),
1250  originalBuffer_(fedBuffer.data()),
1251  bufferSize_(fedBuffer.size()) {
1252  init();
1253  }
1254 
1255  FEDBufferBase::FEDBufferBase(const FEDRawData& fedBuffer, const bool fillChannelVector)
1256  : originalBuffer_(fedBuffer.data()), bufferSize_(fedBuffer.size()) {
1257  init();
1258  if (fillChannelVector)
1259  channels_.assign(FEDCH_PER_FED, FEDChannel(nullptr, 0, 0));
1260  }
1261 
1263  //construct tracker special header using second 64 bit word
1265 
1266  //check the buffer format
1268  //swap the buffer words so that the whole buffer is in slink ordering
1270  uint8_t* newBuffer = new uint8_t[bufferSize_];
1271  const uint32_t* originalU32 = reinterpret_cast<const uint32_t*>(originalBuffer_);
1272  const size_t sizeU32 = bufferSize_ / 4;
1273  uint32_t* newU32 = reinterpret_cast<uint32_t*>(newBuffer);
1275  //swap whole buffer
1276  for (size_t i = 0; i < sizeU32; i += 2) {
1277  newU32[i] = originalU32[i + 1];
1278  newU32[i + 1] = originalU32[i];
1279  }
1280  }
1282  //copy DAQ header
1283  memcpy(newU32, originalU32, 8);
1284  //copy DAQ trailer
1285  memcpy(newU32 + sizeU32 - 2, originalU32 + sizeU32 - 2, 8);
1286  //swap the payload
1287  for (size_t i = 2; i < sizeU32 - 2; i += 2) {
1288  newU32[i] = originalU32[i + 1];
1289  newU32[i + 1] = originalU32[i];
1290  }
1291  }
1292  orderedBuffer_ = newBuffer;
1293  } //if ( (bufferFormat == BUFFER_FORMAT_OLD_VME) || (bufferFormat == BUFFER_FORMAT_NEW) )
1294  else {
1296  }
1297 
1298  //construct header object at begining of buffer
1300  //construct trailer object using last 64 bit word of buffer
1302  }
1303 
1305  //if the buffer was coppied and swapped then delete the copy
1307  delete[] orderedBuffer_;
1308  }
1309 
1310  void FEDBufferBase::print(std::ostream& os) const {
1311  os << "buffer format: " << bufferFormat() << std::endl;
1312  os << "Buffer size: " << bufferSize() << " bytes" << std::endl;
1313  os << "Event length from DAQ trailer: " << daqEventLengthInBytes() << " bytes" << std::endl;
1314  os << "Source ID: " << daqSourceID() << std::endl;
1315  os << "Header type: " << headerType() << std::endl;
1316  os << "Readout mode: " << readoutMode() << std::endl;
1317  os << "DAQ event type: " << daqEventType() << std::endl;
1318  os << "TTS state: " << daqTTSState() << std::endl;
1319  os << "L1 ID: " << daqLvl1ID() << std::endl;
1320  os << "BX ID: " << daqBXID() << std::endl;
1321  os << "FED status register flags: ";
1323  os << std::endl;
1324  os << "APVe Address: " << uint16_t(apveAddress()) << std::endl;
1325  os << "Enabled FE units: " << uint16_t(nFEUnitsEnabled()) << std::endl;
1326  }
1327 
1329  uint8_t result = 0;
1330  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
1331  if (feEnabled(iFE))
1332  result++;
1333  }
1334  return result;
1335  }
1336 
1338  return ((daqSourceID() >= FED_ID_MIN) && (daqSourceID() <= FED_ID_MAX));
1339  }
1340 
1342  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
1343  if (!feEnabled(iFE))
1344  continue;
1346  return false;
1347  }
1348  return true;
1349  }
1350 
1352  const uint8_t feUnit = internalFEDChannelNum / FEDCH_PER_FEUNIT;
1353  return (!majorityAddressErrorForFEUnit(feUnit) && feEnabled(feUnit) && !feOverflow(feUnit));
1354  }
1355 
1357  std::ostringstream summary;
1358  summary << "Check buffer type valid: " << (checkBufferFormat() ? "passed" : "FAILED") << std::endl;
1359  summary << "Check header format valid: " << (checkHeaderType() ? "passed" : "FAILED") << std::endl;
1360  summary << "Check readout mode valid: " << (checkReadoutMode() ? "passed" : "FAILED") << std::endl;
1361  //summary << "Check APVe address valid: " << ( checkAPVEAddressValid() ? "passed" : "FAILED" ) << std::endl;
1362  summary << "Check FE unit majority addresses: " << (checkMajorityAddresses() ? "passed" : "FAILED") << std::endl;
1363  if (!checkMajorityAddresses()) {
1364  summary << "FEs with majority address error: ";
1365  unsigned int badFEs = 0;
1366  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
1367  if (!feEnabled(iFE))
1368  continue;
1369  if (majorityAddressErrorForFEUnit(iFE)) {
1370  summary << uint16_t(iFE) << " ";
1371  badFEs++;
1372  }
1373  }
1374  summary << std::endl;
1375  summary << "Number of FE Units with bad addresses: " << badFEs << std::endl;
1376  }
1377  summary << "Check for FE unit buffer overflows: " << (checkNoFEOverflows() ? "passed" : "FAILED") << std::endl;
1378  if (!checkNoFEOverflows()) {
1379  summary << "FEs which overflowed: ";
1380  unsigned int badFEs = 0;
1381  for (uint8_t iFE = 0; iFE < FEUNITS_PER_FED; iFE++) {
1382  if (feOverflow(iFE)) {
1383  summary << uint16_t(iFE) << " ";
1384  badFEs++;
1385  }
1386  }
1387  summary << std::endl;
1388  summary << "Number of FE Units which overflowed: " << badFEs << std::endl;
1389  }
1390  summary << "Check for S-Link CRC errors: " << (checkNoSlinkCRCError() ? "passed" : "FAILED") << std::endl;
1391  summary << "Check for S-Link transmission error: " << (checkNoSLinkTransmissionError() ? "passed" : "FAILED")
1392  << std::endl;
1393  summary << "Check CRC: " << (checkCRC() ? "passed" : "FAILED") << std::endl;
1394  summary << "Check source ID is FED ID: " << (checkSourceIDs() ? "passed" : "FAILED") << std::endl;
1395  summary << "Check for unexpected source ID at FRL: " << (checkNoUnexpectedSourceID() ? "passed" : "FAILED")
1396  << std::endl;
1397  summary << "Check there are no extra headers or trailers: "
1398  << (checkNoExtraHeadersOrTrailers() ? "passed" : "FAILED") << std::endl;
1399  summary << "Check length from trailer: " << (checkLengthFromTrailer() ? "passed" : "FAILED") << std::endl;
1400  return summary.str();
1401  }
1402 } // namespace sistrip
sistrip::printHexValue
void printHexValue(const uint8_t value, std::ostream &os)
Definition: SiStripFEDBufferComponents.cc:10
sistrip::FEDBufferBase::daqSourceID
uint16_t daqSourceID() const
Definition: SiStripFEDBufferComponents.h:1415
sistrip::FEDFullDebugHeader::unlockedFromBit
bool unlockedFromBit(const uint8_t internalFEDChannelNum) const
Definition: SiStripFEDBufferComponents.h:1267
sistrip::FEDFullDebugHeader::clone
FEDFullDebugHeader * clone() const override
Definition: SiStripFEDBufferComponents.cc:1127
sistrip::FEDBufferBase::checkLengthFromTrailer
bool checkLengthFromTrailer() const
Definition: SiStripFEDBufferComponents.h:1548
sistrip::TrackerSpecialHeader::setBufferFormat
TrackerSpecialHeader & setBufferFormat(const FEDBufferFormat newBufferFormat)
Definition: SiStripFEDBufferComponents.cc:793
sistrip::TrackerSpecialHeader::specialHeader_
uint8_t specialHeader_[8]
Definition: SiStripFEDBufferComponents.h:389
mps_fire.i
i
Definition: mps_fire.py:428
sistrip::TrackerSpecialHeader::setReadoutModeBits
void setReadoutModeBits(const uint8_t value)
Definition: SiStripFEDBufferComponents.h:925
sistrip::FEDBackendStatusRegister::setBackpressureFlag
FEDBackendStatusRegister & setBackpressureFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1056
sistrip::READOUT_MODE_PREMIX_RAW
Definition: SiStripFEDBufferComponents.h:61
sistrip::FEDFullDebugHeader::~FEDFullDebugHeader
~FEDFullDebugHeader() override
Definition: SiStripFEDBufferComponents.cc:1121
sistrip::FEDFullDebugHeader::setDAQRegister2
void setDAQRegister2(const uint32_t daqRegister2) override
Definition: SiStripFEDBufferComponents.cc:1225
sistrip::FEDDAQTrailer::setSLinkCRCErrorBit
FEDDAQTrailer & setSLinkCRCErrorBit(const bool bitSet)
Definition: SiStripFEDBufferComponents.cc:1029
sistrip::CHANNEL_STATUS_IN_SYNC
Definition: SiStripFEDBufferComponents.h:130
sistrip::FEDFullDebugHeader::setDAQRegister
void setDAQRegister(const uint32_t daqRegister) override
Definition: SiStripFEDBufferComponents.cc:1223
sistrip::CHANNEL_STATUS_APV0_ADDRESS_GOOD
Definition: SiStripFEDBufferComponents.h:133
sistrip::FEDBufferBase::checkNoFEOverflows
bool checkNoFEOverflows() const
Definition: SiStripFEDBufferComponents.h:1536
sistrip::DAQ_EVENT_TYPE_TEST
Definition: SiStripFEDBufferComponents.h:98
sistrip::READOUT_MODE_LEGACY_PREMIX_RAW
Definition: SiStripFEDBufferComponents.h:76
sistrip::fedHeaderTypeFromString
FEDHeaderType fedHeaderTypeFromString(const std::string &headerTypeString)
Definition: SiStripFEDBufferComponents.cc:402
sistrip::FEDBufferBase::fedStatusRegister
FEDStatusRegister fedStatusRegister() const
Definition: SiStripFEDBufferComponents.h:1500
sistrip::DAQ_EVENT_TYPE_SIMULATED
Definition: SiStripFEDBufferComponents.h:100
sistrip::FEDBackendStatusRegister::setFEFPGABufferState
FEDBackendStatusRegister & setFEFPGABufferState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1129
sistrip::READOUT_MODE_LEGACY_SPY
Definition: SiStripFEDBufferComponents.h:75
sistrip::TrackerSpecialHeader::setAPVEAddressErrorRegister
TrackerSpecialHeader & setAPVEAddressErrorRegister(const uint8_t addressErrorRegister)
Definition: SiStripFEDBufferComponents.h:934
sistrip::FEDAPVErrorHeader
Definition: SiStripFEDBufferComponents.h:502
sistrip::FEDBackendStatusRegister::setQDRMemoryState
FEDBackendStatusRegister & setQDRMemoryState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1099
sistrip::TrackerSpecialHeader::setAPVEAddress
TrackerSpecialHeader & setAPVEAddress(const uint8_t address)
Definition: SiStripFEDBufferComponents.h:929
sistrip::FEDFullDebugHeader::setAPVError
void setAPVError(const uint8_t internalFEDChannelNum, const uint8_t apvNum, const bool value)
Definition: SiStripFEDBufferComponents.h:1327
mps_update.status
status
Definition: mps_update.py:68
sistrip::READOUT_MODE_LEGACY_PROC_RAW_FAKE
Definition: SiStripFEDBufferComponents.h:70
sistrip::packetCodeFromString
uint8_t packetCodeFromString(const std::string &packetCodeString, FEDReadoutMode mode)
Definition: SiStripFEDBufferComponents.cc:464
sistrip::READOUT_MODE_SCOPE
Definition: SiStripFEDBufferComponents.h:47
sistrip::FEDBufferBase::daqTTSState
FEDTTSBits daqTTSState() const
Definition: SiStripFEDBufferComponents.h:1423
sistrip::CHANNEL_STATUS_NO_PROBLEMS
Definition: SiStripFEDBufferComponents.h:135
sistrip::FEDStatusRegister::setBit
void setBit(const uint8_t num, const bool bitSet)
Definition: SiStripFEDBufferComponents.cc:599
sistrip::TrackerSpecialHeader::setFEEnableRegister
TrackerSpecialHeader & setFEEnableRegister(const uint8_t feEnableRegister)
Definition: SiStripFEDBufferComponents.h:939
sistrip::FEDDAQTrailer::eventLengthIn64BitWords
uint32_t eventLengthIn64BitWords() const
Definition: SiStripFEDBufferComponents.h:1369
sistrip::operator<<
std::ostream & operator<<(std::ostream &os, const FEDBufferFormat &value)
Definition: SiStripFEDBufferComponents.cc:79
sistrip::FEDBufferBase::daqEventLengthInBytes
uint32_t daqEventLengthInBytes() const
Definition: SiStripFEDBufferComponents.h:1419
sistrip::FEDBackendStatusRegister::ttcReadyFlag
bool ttcReadyFlag() const
Definition: SiStripFEDBufferComponents.h:1037
sistrip::FEDDAQHeader::eventTypeNibble
uint8_t eventTypeNibble() const
Definition: SiStripFEDBufferComponents.h:1345
sistrip::FEDBufferBase::~FEDBufferBase
virtual ~FEDBufferBase()
Definition: SiStripFEDBufferComponents.cc:1304
sistrip::FEDBufferStatusCode::CHANNEL_END_BEYOND_PAYLOAD
sistrip::FEDStatusRegister::l1aBxFIFOPartialFullFlag
bool l1aBxFIFOPartialFullFlag() const
Definition: SiStripFEDBufferComponents.h:975
sistrip::FEDTTSBits
FEDTTSBits
Definition: SiStripFEDBufferComponents.h:108
sistrip::FEDStatusRegister::qdrMemoryPartialFullFlag
bool qdrMemoryPartialFullFlag() const
Definition: SiStripFEDBufferComponents.h:969
ALCARECOPromptCalibProdSiPixelAli0T_cff.mode
mode
Definition: ALCARECOPromptCalibProdSiPixelAli0T_cff.py:96
sistrip::TrackerSpecialHeader::BUFFERFORMAT
Definition: SiStripFEDBufferComponents.h:386
sistrip::FEDStatusRegister::feDataMissingFlag
bool feDataMissingFlag(const uint8_t internalFEUnitNum) const
Definition: SiStripFEDBufferComponents.h:979
sistrip::FEDStatusRegister::setQDRMemoryEmptyFlag
void setQDRMemoryEmptyFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:999
sistrip::FEDBackendStatusRegister::printFlagsForBuffer
void printFlagsForBuffer(const FEDBufferState bufferState, const std::string name, std::ostream &os) const
Definition: SiStripFEDBufferComponents.cc:667
sistrip::FEDFullDebugHeader::set32BitReservedRegister
void set32BitReservedRegister(const uint8_t internalFEUnitNum, const uint32_t reservedRegister) override
Definition: SiStripFEDBufferComponents.cc:1230
sistrip::FEDDAQTrailer::ttsNibble
uint8_t ttsNibble() const
Definition: SiStripFEDBufferComponents.h:1383
sistrip::READOUT_MODE_SPY
Definition: SiStripFEDBufferComponents.h:60
sistrip::FEDStatusRegister::slinkFullFlag
bool slinkFullFlag() const
Definition: SiStripFEDBufferComponents.h:963
sistrip::FEDFullDebugHeader::checkStatusBits
bool checkStatusBits(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const override
Definition: SiStripFEDBufferComponents.cc:1129
sistrip::FEDBufferBase::channelGood
virtual bool channelGood(const uint8_t internalFEDChannelNum) const
Definition: SiStripFEDBufferComponents.cc:1351
sistrip::FEDAPVErrorHeader::checkChannelStatusBits
bool checkChannelStatusBits(const uint8_t internalFEDChannelNum) const override
Definition: SiStripFEDBufferComponents.cc:1063
sistrip::FEDBackendStatusRegister::trackerHeaderMonitorDataReadyFlag
bool trackerHeaderMonitorDataReadyFlag() const
Definition: SiStripFEDBufferComponents.h:1039
sistrip::calculateFEDBufferCRC
uint16_t calculateFEDBufferCRC(const uint8_t *buffer, const size_t lengthInBytes)
Definition: SiStripFEDBufferComponents.cc:62
sistrip::FEDBackendStatusRegister::getBit
bool getBit(const uint8_t num) const
Definition: SiStripFEDBufferComponents.h:1027
sistrip::FEDDAQTrailer::slinkCRCError
bool slinkCRCError() const
Definition: SiStripFEDBufferComponents.h:253
sistrip::FEDAPVErrorHeader::setChannelStatus
void setChannelStatus(const uint8_t internalFEDChannelNum, const FEDChannelStatus status) override
Definition: SiStripFEDBufferComponents.cc:1090
sistrip::FEDBackendStatusRegister::qdrMemoryState
FEDBufferState qdrMemoryState() const
Definition: SiStripFEDBufferComponents.h:1071
sistrip::FEDAPVErrorHeader::checkStatusBits
bool checkStatusBits(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const override
Definition: SiStripFEDBufferComponents.cc:1055
sistrip::fedReadoutModeFromString
FEDReadoutMode fedReadoutModeFromString(const std::string &readoutModeString)
Definition: SiStripFEDBufferComponents.cc:418
sistrip::TrackerSpecialHeader::wordSwapped_
bool wordSwapped_
Definition: SiStripFEDBufferComponents.h:391
sistrip::FEDBackendStatusRegister::setFrameAddressFIFOState
FEDBackendStatusRegister & setFrameAddressFIFOState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1104
sistrip::FEDBufferBase::FEDBufferBase
FEDBufferBase(const FEDRawData &fedBuffer)
Definition: SiStripFEDBufferComponents.cc:1248
sistrip::PACKET_CODE_ZERO_SUPPRESSED8_TOPBOT
static const uint8_t PACKET_CODE_ZERO_SUPPRESSED8_TOPBOT
Definition: SiStripFEDBufferComponents.h:91
sistrip::FED_ID_MIN
static const uint16_t FED_ID_MIN
Definition: ConstantsForHardwareSystems.h:21
sistrip::FEDBackendStatusRegister::setTrackerHeaderFIFOState
FEDBackendStatusRegister & setTrackerHeaderFIFOState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1114
sistrip::FEDBackendStatusRegister::FEDBackendStatusRegister
FEDBackendStatusRegister(const uint32_t backendStatusRegister)
Definition: SiStripFEDBufferComponents.h:1020
sistrip::PACKET_CODE_ZERO_SUPPRESSED
static const uint8_t PACKET_CODE_ZERO_SUPPRESSED
Definition: SiStripFEDBufferComponents.h:88
sistrip::FEDFullDebugHeader::setBEStatusRegister
void setBEStatusRegister(const FEDBackendStatusRegister beStatusRegister) override
Definition: SiStripFEDBufferComponents.cc:1219
sistrip::FEDStatusRegister::l1aBxFIFOState
FEDBufferState l1aBxFIFOState() const
Definition: SiStripFEDBufferComponents.cc:588
sistrip::FEDBufferBase::nFEUnitsEnabled
uint8_t nFEUnitsEnabled() const
Definition: SiStripFEDBufferComponents.cc:1328
sistrip::READOUT_MODE_LEGACY_ZERO_SUPPRESSED_LITE_REAL
Definition: SiStripFEDBufferComponents.h:73
sistrip::FEDDAQHeader::header_
uint8_t header_[8]
Definition: SiStripFEDBufferComponents.h:226
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8_TOPBOT
Definition: SiStripFEDBufferComponents.h:51
relativeConstraints.error
error
Definition: relativeConstraints.py:53
sistrip::FEDFullDebugHeader::lengthInBytes
size_t lengthInBytes() const override
Definition: SiStripFEDBufferComponents.cc:1123
sistrip::TrackerSpecialHeader::setFEDStatusRegister
TrackerSpecialHeader & setFEDStatusRegister(const FEDStatusRegister fedStatusRegister)
Definition: SiStripFEDBufferComponents.h:949
sistrip::FEDBufferBase::checkSummary
virtual std::string checkSummary() const
Definition: SiStripFEDBufferComponents.cc:1356
sistrip::FEDStatusRegister::setL1ABXFIFOBufferState
FEDStatusRegister & setL1ABXFIFOBufferState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.cc:626
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE10_CMOVERRIDE
Definition: SiStripFEDBufferComponents.h:50
sistrip::HEADER_TYPE_INVALID
Definition: SiStripFEDBufferComponents.h:38
sistrip::FEDBufferBase::daqBXID
uint16_t daqBXID() const
Definition: SiStripFEDBufferComponents.h:1413
sistrip::FEDDAQHeader::l1ID
uint32_t l1ID() const
Definition: SiStripFEDBufferComponents.h:1347
FEDRawData
Definition: FEDRawData.h:19
sistrip::FEDBackendStatusRegister::data_
uint32_t data_
Definition: SiStripFEDBufferComponents.h:463
sistrip::TrackerSpecialHeader::apvAddressErrorRegister
uint8_t apvAddressErrorRegister() const
Definition: SiStripFEDBufferComponents.h:887
sistrip::PACKET_CODE_SCOPE
static const uint8_t PACKET_CODE_SCOPE
Definition: SiStripFEDBufferComponents.h:79
sistrip::PACKET_CODE_PROC_RAW10
static const uint8_t PACKET_CODE_PROC_RAW10
Definition: SiStripFEDBufferComponents.h:85
sistrip::FEDReadoutMode
FEDReadoutMode
Definition: SiStripFEDBufferComponents.h:45
edmScanValgrind.buffer
buffer
Definition: edmScanValgrind.py:171
sistrip::FEDDAQHeader::sourceID
uint16_t sourceID() const
Definition: SiStripFEDBufferComponents.h:1351
sistrip::FEDBackendStatusRegister::STATE_OFFSET_PARTIAL_FULL
Definition: SiStripFEDBufferComponents.h:462
sistrip::FEDFEHeader::~FEDFEHeader
virtual ~FEDFEHeader()
Definition: SiStripFEDBufferComponents.cc:1246
sistrip::FEDBufferBase::feEnabled
bool feEnabled(const uint8_t internalFEUnitNum) const
Definition: SiStripFEDBufferComponents.h:1492
contentValuesCheck.ss
ss
Definition: contentValuesCheck.py:33
sistrip::DAQ_EVENT_TYPE_TRACED
Definition: SiStripFEDBufferComponents.h:101
sistrip::internalFEDChannelNum
uint8_t internalFEDChannelNum(const uint8_t internalFEUnitNum, const uint8_t internalFEUnitChannelNum)
Definition: SiStripFEDBufferComponents.h:785
sistrip::READOUT_MODE_LEGACY_VIRGIN_RAW_FAKE
Definition: SiStripFEDBufferComponents.h:68
sistrip::TTS_OUT_OF_SYNC
Definition: SiStripFEDBufferComponents.h:111
sistrip::BUFFER_STATE_EMPTY
Definition: SiStripFEDBufferComponents.h:122
sistrip::FEDBufferBase::readoutMode
FEDReadoutMode readoutMode() const
Definition: SiStripFEDBufferComponents.h:1431
sistrip::FEDDAQTrailer::setSLinkTransmissionErrorBit
FEDDAQTrailer & setSLinkTransmissionErrorBit(const bool bitSet)
Definition: SiStripFEDBufferComponents.cc:1013
sistrip::TTS_INVALID
Definition: SiStripFEDBufferComponents.h:116
sistrip::FEDAPVErrorHeader::setDAQRegister2
void setDAQRegister2(const uint32_t daqRegister2) override
Definition: SiStripFEDBufferComponents.cc:1115
sistrip::HEADER_TYPE_NONE
Definition: SiStripFEDBufferComponents.h:41
sistrip::FEDBufferStatusCode::CHANNEL_BEGIN_BEYOND_PAYLOAD
sistrip::FEDBufferBase::orderedBuffer_
const uint8_t * orderedBuffer_
Definition: SiStripFEDBufferComponents.h:735
sistrip::FEDBufferBase::daqTrailer_
FEDDAQTrailer daqTrailer_
Definition: SiStripFEDBufferComponents.h:738
sistrip::FEDDAQTrailer::ttsBits
FEDTTSBits ttsBits() const
Definition: SiStripFEDBufferComponents.cc:964
sistrip::FEDAPVErrorHeader::~FEDAPVErrorHeader
~FEDAPVErrorHeader() override
Definition: SiStripFEDBufferComponents.cc:1047
w
const double w
Definition: UKUtility.cc:23
sistrip::FEDFullDebugHeader::daqRegister
uint32_t daqRegister() const
Definition: SiStripFEDBufferComponents.h:1210
sistrip::FEDFullDebugHeader::apvError
bool apvError(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const
Definition: SiStripFEDBufferComponents.h:1240
sistrip::FEDDAQEventType
FEDDAQEventType
Definition: SiStripFEDBufferComponents.h:95
sistrip::READOUT_MODE_LEGACY_VIRGIN_RAW_REAL
Definition: SiStripFEDBufferComponents.h:67
sistrip::FEDDAQTrailer::eventStatusNibble
uint8_t eventStatusNibble() const
Definition: SiStripFEDBufferComponents.h:1381
sistrip::FEDFullDebugHeader::feWord
uint8_t * feWord(const uint8_t internalFEUnitNum)
Definition: SiStripFEDBufferComponents.h:1309
sistrip::FEDFullDebugHeader::print
void print(std::ostream &os) const override
Definition: SiStripFEDBufferComponents.cc:1125
sistrip::FEDBackendStatusRegister::slinkFullFlag
bool slinkFullFlag() const
Definition: SiStripFEDBufferComponents.h:1033
sistrip::READOUT_MODE_PROC_RAW
Definition: SiStripFEDBufferComponents.h:52
sistrip::FEDStatusRegister::setQDRMemoryFullFlag
void setQDRMemoryFullFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:995
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8
Definition: SiStripFEDBufferComponents.h:58
sistrip::TTS_READY
Definition: SiStripFEDBufferComponents.h:113
sistrip::PACKET_CODE_VIRGIN_RAW10
static const uint8_t PACKET_CODE_VIRGIN_RAW10
Definition: SiStripFEDBufferComponents.h:81
sistrip::FEDBufferBase::checkMajorityAddresses
bool checkMajorityAddresses() const
Definition: SiStripFEDBufferComponents.cc:1341
sistrip::FEDDAQTrailer::trailer_
uint8_t trailer_[8]
Definition: SiStripFEDBufferComponents.h:273
sistrip::TTS_DISCONNECTED1
Definition: SiStripFEDBufferComponents.h:115
sistrip::PACKET_CODE_ZERO_SUPPRESSED10
static const uint8_t PACKET_CODE_ZERO_SUPPRESSED10
Definition: SiStripFEDBufferComponents.h:89
sistrip::FEDBackendStatusRegister::getBufferState
FEDBufferState getBufferState(const uint8_t bufferPosition) const
Definition: SiStripFEDBufferComponents.cc:680
sistrip::FEDBufferBase::checkReadoutMode
bool checkReadoutMode() const
Definition: SiStripFEDBufferComponents.h:1532
sistrip::DAQ_EVENT_TYPE_PHYSICS
Definition: SiStripFEDBufferComponents.h:96
sistrip::TrackerSpecialHeader::trackerEventTypeNibble
uint8_t trackerEventTypeNibble() const
Definition: SiStripFEDBufferComponents.h:852
sistrip::DAQ_EVENT_TYPE_CALIBRATION
Definition: SiStripFEDBufferComponents.h:97
sistrip::FEDBackendStatusRegister::feFPGABufferState
FEDBufferState feFPGABufferState() const
Definition: SiStripFEDBufferComponents.h:1095
sistrip::TrackerSpecialHeader::fedStatusRegister
FEDStatusRegister fedStatusRegister() const
Definition: SiStripFEDBufferComponents.h:911
sistrip::FEDStatusRegister::data_
uint16_t data_
Definition: SiStripFEDBufferComponents.h:312
sistrip::fedBufferFormatFromString
FEDBufferFormat fedBufferFormatFromString(const std::string &bufferFormatString)
Definition: SiStripFEDBufferComponents.cc:386
sistrip::FEDStatusRegister::qdrMemoryState
FEDBufferState qdrMemoryState() const
Definition: SiStripFEDBufferComponents.cc:577
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8_BOTBOT_CMOVERRIDE
Definition: SiStripFEDBufferComponents.h:59
sistrip::BUFFER_FORMAT_NEW
Definition: SiStripFEDBufferComponents.h:30
sistrip::FEDBufferBase::checkNoExtraHeadersOrTrailers
bool checkNoExtraHeadersOrTrailers() const
Definition: SiStripFEDBufferComponents.h:1544
sistrip::TrackerSpecialHeader
Definition: SiStripFEDBufferComponents.h:315
sistrip::FEDBufferBase::daqEventType
FEDDAQEventType daqEventType() const
Definition: SiStripFEDBufferComponents.h:1409
sistrip::FEDDAQTrailer::slinkTransmissionError
bool slinkTransmissionError() const
Definition: SiStripFEDBufferComponents.h:241
sistrip::FEDBackendStatusRegister::trackerHeaderFIFOState
FEDBufferState trackerHeaderFIFOState() const
Definition: SiStripFEDBufferComponents.h:1083
sistrip::BUFFER_STATE_FULL
Definition: SiStripFEDBufferComponents.h:124
sistrip::TrackerSpecialHeader::feOverflowRegister
uint8_t feOverflowRegister() const
Definition: SiStripFEDBufferComponents.h:899
sistrip::FEDBackendStatusRegister::slinkDownFlag
bool slinkDownFlag() const
Definition: SiStripFEDBufferComponents.h:1031
sistrip::FEDAPVErrorHeader::setDAQRegister
void setDAQRegister(const uint32_t daqRegister) override
Definition: SiStripFEDBufferComponents.cc:1114
sistrip::FEDAPVErrorHeader::setFEUnitMajorityAddress
void setFEUnitMajorityAddress(const uint8_t internalFEUnitNum, const uint8_t address) override
Definition: SiStripFEDBufferComponents.cc:1112
sistrip::FEDAPVErrorHeader::setAPVStatusBit
FEDAPVErrorHeader & setAPVStatusBit(const uint8_t internalFEDChannelNum, const uint8_t apvNum, const bool apvGood)
Definition: SiStripFEDBufferComponents.cc:1077
sistrip::FEDLegacyReadoutMode
FEDLegacyReadoutMode
Definition: SiStripFEDBufferComponents.h:64
sistrip::TrackerSpecialHeader::bufferFormatByte
uint8_t bufferFormatByte() const
Definition: SiStripFEDBufferComponents.h:836
sistrip::FEDDAQTrailer::setEventLengthIn64BitWords
FEDDAQTrailer & setEventLengthIn64BitWords(const uint32_t eventLengthIn64BitWords)
Definition: SiStripFEDBufferComponents.cc:1000
sistrip::FEUNITS_PER_FED
static const uint16_t FEUNITS_PER_FED
Definition: ConstantsForHardwareSystems.h:29
sistrip::FEDDAQTrailer::setTTSBits
FEDDAQTrailer & setTTSBits(const FEDTTSBits ttsBits)
Definition: SiStripFEDBufferComponents.cc:1042
sistrip::FEDBufferBase::daqLvl1ID
uint32_t daqLvl1ID() const
Definition: SiStripFEDBufferComponents.h:1411
sistrip::FEDBufferBase::checkNoSlinkCRCError
bool checkNoSlinkCRCError() const
Definition: SiStripFEDBufferComponents.h:1538
sistrip::FEDBufferBase::bufferSize_
const size_t bufferSize_
Definition: SiStripFEDBufferComponents.h:736
sistrip::BUFFER_STATE_PARTIAL_FULL
Definition: SiStripFEDBufferComponents.h:123
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE10
Definition: SiStripFEDBufferComponents.h:49
sistrip::FEDBackendStatusRegister::STATE_OFFSET_EMPTY
Definition: SiStripFEDBufferComponents.h:462
sistrip::FEDBufferBase::headerType
FEDHeaderType headerType() const
Definition: SiStripFEDBufferComponents.h:1427
sistrip::FEDStatusRegister::setL1ABXFIFOPartialFullFlag
void setL1ABXFIFOPartialFullFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1003
sistrip::FEDBackendStatusRegister::setTTCReadyFlag
FEDBackendStatusRegister & setTTCReadyFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1061
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8_TOPBOT_CMOVERRIDE
Definition: SiStripFEDBufferComponents.h:53
sistrip::FEDBackendStatusRegister::l1aBxFIFOState
FEDBufferState l1aBxFIFOState() const
Definition: SiStripFEDBufferComponents.h:1087
sistrip::FEDDAQTrailer::setEventStatusNibble
FEDDAQTrailer & setEventStatusNibble(const uint8_t eventStatusNibble)
Definition: SiStripFEDBufferComponents.cc:1037
sistrip::FEDFullDebugHeader::setAPVAddressError
void setAPVAddressError(const uint8_t internalFEDChannelNum, const uint8_t apvNum, const bool value)
Definition: SiStripFEDBufferComponents.h:1321
sistrip::DAQ_EVENT_TYPE_TECHNICAL
Definition: SiStripFEDBufferComponents.h:99
sistrip::fedDAQEventTypeFromString
FEDDAQEventType fedDAQEventTypeFromString(const std::string &daqEventTypeString)
Definition: SiStripFEDBufferComponents.cc:521
sistrip::CHANNEL_STATUS_APV1_NO_ERROR_BIT
Definition: SiStripFEDBufferComponents.h:134
sistrip::FEDBackendStatusRegister::setTotalLengthFIFOState
FEDBackendStatusRegister & setTotalLengthFIFOState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1109
sistrip::FEDBufferStatusCode
FEDBufferStatusCode
Definition: SiStripFEDBufferComponents.h:140
sistrip::FEDDAQTrailer::setBadSourceIDBit
FEDDAQTrailer & setBadSourceIDBit(const bool bitSet)
Definition: SiStripFEDBufferComponents.cc:1021
sistrip::FEDHeaderType
FEDHeaderType
Definition: SiStripFEDBufferComponents.h:37
sistrip::FEDBufferBase::specialHeader_
TrackerSpecialHeader specialHeader_
Definition: SiStripFEDBufferComponents.h:739
AlCaHLTBitMon_ParallelJobs.p
def p
Definition: AlCaHLTBitMon_ParallelJobs.py:153
sistrip::FEDAPVErrorHeader::FEDAPVErrorHeader
FEDAPVErrorHeader(const uint8_t *headerBuffer)
Definition: SiStripFEDBufferComponents.h:1187
sistrip::FEDStatusRegister::printFlags
void printFlags(std::ostream &os) const
Definition: SiStripFEDBufferComponents.cc:554
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8_BOTBOT
Definition: SiStripFEDBufferComponents.h:55
sistrip::FEDBufferStatusCode::CHANNEL_TOO_SHORT
sistrip::BUFFER_STATE_UNSET
Definition: SiStripFEDBufferComponents.h:121
sistrip::HEADER_TYPE_FULL_DEBUG
Definition: SiStripFEDBufferComponents.h:39
sistrip::FEDBufferBase::checkCRC
bool checkCRC() const
Definition: SiStripFEDBufferComponents.h:1526
sistrip::BUFFER_FORMAT_CODE_NEW
static const uint8_t BUFFER_FORMAT_CODE_NEW
Definition: SiStripFEDBufferComponents.h:34
sistrip::TrackerSpecialHeader::setReadoutMode
TrackerSpecialHeader & setReadoutMode(const FEDReadoutMode readoutMode)
Definition: SiStripFEDBufferComponents.cc:836
sistrip::FEDStatusRegister
Definition: SiStripFEDBufferComponents.h:276
sistrip::TrackerSpecialHeader::legacyReadoutMode
FEDLegacyReadoutMode legacyReadoutMode() const
Definition: SiStripFEDBufferComponents.cc:775
sistrip::TrackerSpecialHeader::setHeaderTypeNibble
void setHeaderTypeNibble(const uint8_t value)
Definition: SiStripFEDBufferComponents.h:921
SiStripFEDBufferComponents.h
sistrip::FEDBufferBase::majorityAddressErrorForFEUnit
bool majorityAddressErrorForFEUnit(const uint8_t internalFEUnitNum) const
Definition: SiStripFEDBufferComponents.h:1488
sistrip::FEDBufferBase::bufferFormat
FEDBufferFormat bufferFormat() const
Definition: SiStripFEDBufferComponents.h:1425
sistrip::FEDBufferStatusCode::BUFFER_TOO_SHORT
sistrip::FEDBufferBase::checkSourceIDs
bool checkSourceIDs() const
Definition: SiStripFEDBufferComponents.cc:1337
sistrip::FEDStatusRegister::qdrMemoryFullFlag
bool qdrMemoryFullFlag() const
Definition: SiStripFEDBufferComponents.h:967
sistrip::PACKET_CODE_VIRGIN_RAW8_BOTBOT
static const uint8_t PACKET_CODE_VIRGIN_RAW8_BOTBOT
Definition: SiStripFEDBufferComponents.h:82
sistrip::FEDFullDebugHeader::checkChannelStatusBits
bool checkChannelStatusBits(const uint8_t internalFEDChannelNum) const override
Definition: SiStripFEDBufferComponents.cc:1134
sistrip::FEDBufferBase::channels_
std::vector< FEDChannel > channels_
Definition: SiStripFEDBufferComponents.h:730
sistrip::FEDFullDebugHeader::setChannelStatus
void setChannelStatus(const uint8_t internalFEDChannelNum, const FEDChannelStatus status) override
Definition: SiStripFEDBufferComponents.cc:1206
sistrip::FEDFullDebugHeader::header_
uint8_t header_[FULL_DEBUG_HEADER_SIZE_IN_BYTES]
Definition: SiStripFEDBufferComponents.h:612
sistrip::FEDAPVErrorHeader::set32BitReservedRegister
void set32BitReservedRegister(const uint8_t internalFEUnitNum, const uint32_t reservedRegister) override
Definition: SiStripFEDBufferComponents.cc:1116
edmLumisInFiles.summary
summary
Definition: edmLumisInFiles.py:39
sistrip::PACKET_CODE_PROC_RAW
static const uint8_t PACKET_CODE_PROC_RAW
Definition: SiStripFEDBufferComponents.h:84
sistrip::TTS_ERROR
Definition: SiStripFEDBufferComponents.h:114
sistrip::TrackerSpecialHeader::setBufferFormatByte
void setBufferFormatByte(const FEDBufferFormat newBufferFormat)
Definition: SiStripFEDBufferComponents.cc:804
sistrip::FEDBufferStatusCode::SUCCESS
value
Definition: value.py:1
sistrip::FEDBufferStatusCode::WRONG_HEADERTYPE
sistrip::FEDBackendStatusRegister::setTrackerHeaderMonitorDataReadyFlag
FEDBackendStatusRegister & setTrackerHeaderMonitorDataReadyFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1066
sistrip::READOUT_MODE_VIRGIN_RAW
Definition: SiStripFEDBufferComponents.h:48
sistrip::FEDFullDebugHeader::setUnlocked
void setUnlocked(const uint8_t internalFEDChannelNum, const bool value)
Definition: SiStripFEDBufferComponents.h:1313
sistrip::FEDDAQHeader::FEDDAQHeader
FEDDAQHeader()
Definition: SiStripFEDBufferComponents.h:200
sistrip::printHex
void printHex(const void *pointer, const size_t length, std::ostream &os)
Definition: SiStripFEDBufferComponents.cc:26
sistrip::TrackerSpecialHeader::bufferFormat
FEDBufferFormat bufferFormat() const
Definition: SiStripFEDBufferComponents.cc:763
sistrip::TrackerSpecialHeader::setAPVAddressErrorForFEUnit
TrackerSpecialHeader & setAPVAddressErrorForFEUnit(const uint8_t internalFEUnitNum, const bool error)
Definition: SiStripFEDBufferComponents.cc:864
sistrip::FEDStatusRegister::setQDRMemoryBufferState
FEDStatusRegister & setQDRMemoryBufferState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.cc:607
sistrip::FEDBufferBase::print
virtual void print(std::ostream &os) const
Definition: SiStripFEDBufferComponents.cc:1310
sistrip::FEDBufferBase::bufferSize
size_t bufferSize() const
Definition: SiStripFEDBufferComponents.h:1405
sistrip::FEDFullDebugHeader
Definition: SiStripFEDBufferComponents.h:535
sistrip::PACKET_CODE_VIRGIN_RAW8_TOPBOT
static const uint8_t PACKET_CODE_VIRGIN_RAW8_TOPBOT
Definition: SiStripFEDBufferComponents.h:83
sistrip::FEDBackendStatusRegister::feEventLengthFIFOState
FEDBufferState feEventLengthFIFOState() const
Definition: SiStripFEDBufferComponents.h:1091
sistrip::READOUT_MODE_LEGACY_ZERO_SUPPRESSED_LITE_FAKE
Definition: SiStripFEDBufferComponents.h:74
sistrip::FEDAPVErrorHeader::clone
FEDAPVErrorHeader * clone() const override
Definition: SiStripFEDBufferComponents.cc:1053
sistrip::FEDAPVErrorHeader::data
const uint8_t * data() const override
Definition: SiStripFEDBufferComponents.cc:1067
sistrip::DAQ_EVENT_TYPE_INVALID
Definition: SiStripFEDBufferComponents.h:103
sistrip::READOUT_MODE_INVALID
Definition: SiStripFEDBufferComponents.h:46
sistrip::FEDStatusRegister::qdrMemoryEmptyFlag
bool qdrMemoryEmptyFlag() const
Definition: SiStripFEDBufferComponents.h:971
sistrip::FEDStatusRegister::setL1ABXFIFOFullFlag
void setL1ABXFIFOFullFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1001
AlCaHLTBitMon_QueryRunRegistry.string
string string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
sistrip::FEDBackendStatusRegister::frameAddressFIFOState
FEDBufferState frameAddressFIFOState() const
Definition: SiStripFEDBufferComponents.h:1075
sistrip::READOUT_MODE_LEGACY_ZERO_SUPPRESSED_FAKE
Definition: SiStripFEDBufferComponents.h:72
sistrip::FED_ID_MAX
static const uint16_t FED_ID_MAX
Definition: ConstantsForHardwareSystems.h:22
EgammaValidation_cff.num
num
Definition: EgammaValidation_cff.py:33
sistrip::FEDBufferBase::checkNoUnexpectedSourceID
bool checkNoUnexpectedSourceID() const
Definition: SiStripFEDBufferComponents.h:1542
sistrip::FEDBackendStatusRegister::setFEEventLengthFIFOState
FEDBackendStatusRegister & setFEEventLengthFIFOState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1124
sistrip::FEDBackendStatusRegister
Definition: SiStripFEDBufferComponents.h:394
sistrip::FEDFullDebugHeader::FULL_DEBUG_HEADER_SIZE_IN_BYTES
static const size_t FULL_DEBUG_HEADER_SIZE_IN_BYTES
Definition: SiStripFEDBufferComponents.h:611
sistrip::FEDDAQHeader::setL1ID
FEDDAQHeader & setL1ID(const uint32_t l1ID)
Definition: SiStripFEDBufferComponents.cc:930
sistrip::CHANNEL_STATUS_APV1_ADDRESS_GOOD
Definition: SiStripFEDBufferComponents.h:131
sistrip::FEDAPVErrorHeader::setFEUnitLength
void setFEUnitLength(const uint8_t internalFEUnitNum, const uint16_t length) override
Definition: SiStripFEDBufferComponents.cc:1119
sistrip::FEDBackendStatusRegister::totalLengthFIFOState
FEDBufferState totalLengthFIFOState() const
Definition: SiStripFEDBufferComponents.h:1079
sistrip::FEDBackendStatusRegister::setBufferSate
void setBufferSate(const uint8_t bufferPosition, const FEDBufferState state)
Definition: SiStripFEDBufferComponents.cc:691
sistrip::FEDDAQHeader::setSourceID
FEDDAQHeader & setSourceID(const uint16_t sourceID)
Definition: SiStripFEDBufferComponents.cc:943
sistrip::FEDBufferFormat
FEDBufferFormat
Definition: SiStripFEDBufferComponents.h:26
sistrip::BUFFER_FORMAT_OLD_SLINK
Definition: SiStripFEDBufferComponents.h:29
sistrip::TTS_WARN_OVERFLOW
Definition: SiStripFEDBufferComponents.h:110
sistrip::FEDBufferBase::checkHeaderType
bool checkHeaderType() const
Definition: SiStripFEDBufferComponents.h:1530
sistrip::FEDAPVErrorHeader::setBEStatusRegister
void setBEStatusRegister(const FEDBackendStatusRegister beStatusRegister) override
Definition: SiStripFEDBufferComponents.cc:1113
sistrip::TrackerSpecialHeader::feEnableRegister
uint8_t feEnableRegister() const
Definition: SiStripFEDBufferComponents.h:893
sistrip::FEDDAQHeader::setEventType
FEDDAQHeader & setEventType(const FEDDAQEventType evtType)
Definition: SiStripFEDBufferComponents.cc:925
sistrip::FEDBufferBase::originalBuffer_
const uint8_t * originalBuffer_
Definition: SiStripFEDBufferComponents.h:734
sistrip::READOUT_MODE_LEGACY_INVALID
Definition: SiStripFEDBufferComponents.h:65
sistrip::TrackerSpecialHeader::setFEOverflowRegister
TrackerSpecialHeader & setFEOverflowRegister(const uint8_t feOverflowRegister)
Definition: SiStripFEDBufferComponents.h:944
RunInfoPI::state
state
Definition: RunInfoPayloadInspectoHelper.h:16
sistrip::FEDChannelStatus
FEDChannelStatus
Definition: SiStripFEDBufferComponents.h:128
sistrip::FEDBackendStatusRegister::STATE_OFFSET_FULL
Definition: SiStripFEDBufferComponents.h:462
sistrip::READOUT_MODE_LEGACY_ZERO_SUPPRESSED_REAL
Definition: SiStripFEDBufferComponents.h:71
sistrip::FEDDAQHeader::eventType
FEDDAQEventType eventType() const
Definition: SiStripFEDBufferComponents.cc:910
sistrip::TrackerSpecialHeader::TrackerSpecialHeader
TrackerSpecialHeader()
Definition: SiStripFEDBufferComponents.h:834
sistrip::FEDBufferBase::feOverflow
bool feOverflow(const uint8_t internalFEUnitNum) const
Definition: SiStripFEDBufferComponents.h:1496
sistrip::FEDBackendStatusRegister::backpressureFlag
bool backpressureFlag() const
Definition: SiStripFEDBufferComponents.h:1035
Exception
Definition: hltDiff.cc:245
sistrip::TrackerSpecialHeader::setFEOverflowForFEUnit
TrackerSpecialHeader & setFEOverflowForFEUnit(const uint8_t internalFEUnitNum, const bool overflow)
Definition: SiStripFEDBufferComponents.cc:880
sistrip::FEDBufferBase::checkNoSLinkTransmissionError
bool checkNoSLinkTransmissionError() const
Definition: SiStripFEDBufferComponents.h:1540
sistrip::DAQ_EVENT_TYPE_ERROR
Definition: SiStripFEDBufferComponents.h:102
sistrip::FEDFullDebugHeader::setBit
void setBit(const uint8_t internalFEDChannelNum, const uint8_t bit, const bool value)
Definition: SiStripFEDBufferComponents.cc:1239
sistrip::BUFFER_FORMAT_OLD_VME
Definition: SiStripFEDBufferComponents.h:28
sistrip::FEDDAQTrailer
Definition: SiStripFEDBufferComponents.h:230
sistrip::FEDBufferStatusCode::EXPECT_SPY
sistrip::FEDBackendStatusRegister::internalFreezeFlag
bool internalFreezeFlag() const
Definition: SiStripFEDBufferComponents.h:1029
sistrip::FEDFullDebugHeader::set32BitWordAt
static void set32BitWordAt(uint8_t *startOfWord, const uint32_t value)
Definition: SiStripFEDBufferComponents.h:1300
Skims_PA_cff.name
name
Definition: Skims_PA_cff.py:17
sistrip::FEDBackendStatusRegister::setSLinkFullFlag
FEDBackendStatusRegister & setSLinkFullFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1051
sistrip::FEDFullDebugHeader::data
const uint8_t * data() const override
Definition: SiStripFEDBufferComponents.cc:1185
sistrip::TrackerSpecialHeader::headerType
FEDHeaderType headerType() const
Definition: SiStripFEDBufferComponents.h:840
sistrip::FEDFullDebugHeader::apvAddressError
bool apvAddressError(const uint8_t internalFEDChannelNum, const uint8_t apvNum) const
Definition: SiStripFEDBufferComponents.h:1251
data
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:79
sistrip::TrackerSpecialHeader::readoutMode
FEDReadoutMode readoutMode() const
Definition: SiStripFEDBufferComponents.h:854
sistrip::TrackerSpecialHeader::setFEEnableForFEUnit
TrackerSpecialHeader & setFEEnableForFEUnit(const uint8_t internalFEUnitNum, const bool enabled)
Definition: SiStripFEDBufferComponents.cc:872
sistrip::FEDCH_PER_FED
static const uint16_t FEDCH_PER_FED
Definition: ConstantsForHardwareSystems.h:30
sistrip::FEDBackendStatusRegister::printFlags
void printFlags(std::ostream &os) const
Definition: SiStripFEDBufferComponents.cc:645
sistrip::FEDBufferStatusCode::BUFFER_NULL
sistrip::FEDCH_PER_FEUNIT
static const uint16_t FEDCH_PER_FEUNIT
Definition: ConstantsForHardwareSystems.h:28
sistrip::TTS_BUSY
Definition: SiStripFEDBufferComponents.h:112
sistrip::FEDAPVErrorHeader::print
void print(std::ostream &os) const override
Definition: SiStripFEDBufferComponents.cc:1051
sistrip::FEDBufferBase::checkBufferFormat
bool checkBufferFormat() const
Definition: SiStripFEDBufferComponents.h:1528
sistrip::FEDBackendStatusRegister::setInternalFreezeFlag
FEDBackendStatusRegister & setInternalFreezeFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1041
L1TBPTX_cfi.bitNumber
bitNumber
Definition: L1TBPTX_cfi.py:26
mps_fire.result
result
Definition: mps_fire.py:311
sistrip::CHANNEL_STATUS_LOCKED
Definition: SiStripFEDBufferComponents.h:129
sistrip::FEDStatusRegister::setL1ABXFIFOEmptyFlag
void setL1ABXFIFOEmptyFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1005
sistrip::FEDDAQTrailer::setCRC
FEDDAQTrailer & setCRC(const uint16_t crc)
Definition: SiStripFEDBufferComponents.cc:1007
sistrip::READOUT_MODE_LEGACY_PROC_RAW_REAL
Definition: SiStripFEDBufferComponents.h:69
sistrip::FEDBackendStatusRegister::setL1ABXFIFOState
FEDBackendStatusRegister & setL1ABXFIFOState(const FEDBufferState state)
Definition: SiStripFEDBufferComponents.h:1119
sistrip::FEDFullDebugHeader::daqRegister2
uint32_t daqRegister2() const
Definition: SiStripFEDBufferComponents.h:1212
sistrip
sistrip classes
Definition: EnsembleCalibrationLA.cc:10
sistrip::FEDBackendStatusRegister::setSLinkDownFlag
FEDBackendStatusRegister & setSLinkDownFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:1046
sistrip::PACKET_CODE_PROC_RAW8_TOPBOT
static const uint8_t PACKET_CODE_PROC_RAW8_TOPBOT
Definition: SiStripFEDBufferComponents.h:87
sistrip::FEDDAQHeader::setBXID
FEDDAQHeader & setBXID(const uint16_t bxID)
Definition: SiStripFEDBufferComponents.cc:937
sistrip::FEDBufferBase::init
void init()
Definition: SiStripFEDBufferComponents.cc:1262
sistrip::FEDBufferStatusCode::EXPECT_NOT_SPY
sistrip::PACKET_CODE_VIRGIN_RAW
static const uint8_t PACKET_CODE_VIRGIN_RAW
Definition: SiStripFEDBufferComponents.h:80
sistrip::FEDBufferBase::apveAddress
uint8_t apveAddress() const
Definition: SiStripFEDBufferComponents.h:1486
sistrip::FEDBufferStatusCode::UNRECOGNIZED_FORMAT
sistrip::FEDStatusRegister::l1aBxFIFOFullFlag
bool l1aBxFIFOFullFlag() const
Definition: SiStripFEDBufferComponents.h:973
sistrip::FEDDAQHeader
Definition: SiStripFEDBufferComponents.h:198
sistrip::FEDAPVErrorHeader::lengthInBytes
size_t lengthInBytes() const override
Definition: SiStripFEDBufferComponents.cc:1049
sistrip::BUFFER_FORMAT_CODE_OLD
static const uint8_t BUFFER_FORMAT_CODE_OLD
Definition: SiStripFEDBufferComponents.h:33
sistrip::FEDChannel
Definition: SiStripFEDBufferComponents.h:616
sistrip::FEDBackendStatusRegister::setBit
void setBit(const uint8_t num, const bool bitSet)
Definition: SiStripFEDBufferComponents.cc:709
sistrip::FEDFullDebugHeader::outOfSyncFromBit
bool outOfSyncFromBit(const uint8_t internalFEDChannelNum) const
Definition: SiStripFEDBufferComponents.h:1271
sistrip::FEDBufferState
FEDBufferState
Definition: SiStripFEDBufferComponents.h:120
sistrip::READOUT_MODE_ZERO_SUPPRESSED_LITE8_CMOVERRIDE
Definition: SiStripFEDBufferComponents.h:54
sistrip::FEDFullDebugHeader::beStatusRegister
FEDBackendStatusRegister beStatusRegister() const
Definition: SiStripFEDBufferComponents.h:1206
sistrip::FEDFullDebugHeader::setOutOfSync
void setOutOfSync(const uint8_t internalFEDChannelNum, const bool value)
Definition: SiStripFEDBufferComponents.h:1317
sistrip::FEDStatusRegister::l1aBxFIFOEmptyFlag
bool l1aBxFIFOEmptyFlag() const
Definition: SiStripFEDBufferComponents.h:977
evf::compute_crc_8bit
unsigned short compute_crc_8bit(unsigned short crc, unsigned char data)
Definition: CRC16.h:56
sistrip::FEDAPVErrorHeader::header_
uint8_t header_[APV_ERROR_HEADER_SIZE_IN_BYTES]
Definition: SiStripFEDBufferComponents.h:532
sistrip::BUFFER_FORMAT_INVALID
Definition: SiStripFEDBufferComponents.h:27
sistrip::FEDDAQTrailer::crc
uint16_t crc() const
Definition: SiStripFEDBufferComponents.h:1375
sistrip::READOUT_MODE_LEGACY_SCOPE
Definition: SiStripFEDBufferComponents.h:66
sistrip::FEDDAQTrailer::FEDDAQTrailer
FEDDAQTrailer()
Definition: SiStripFEDBufferComponents.h:232
sistrip::READOUT_MODE_ZERO_SUPPRESSED_FAKE
Definition: SiStripFEDBufferComponents.h:57
sistrip::CHANNEL_STATUS_APV0_NO_ERROR_BIT
Definition: SiStripFEDBufferComponents.h:132
sistrip::FEDStatusRegister::setQDRMemoryPartialFullFlag
void setQDRMemoryPartialFullFlag(const bool bitSet)
Definition: SiStripFEDBufferComponents.h:997
sistrip::FEDBufferBase::daqHeader_
FEDDAQHeader daqHeader_
Definition: SiStripFEDBufferComponents.h:737
sistrip::FEDFullDebugHeader::FEDFullDebugHeader
FEDFullDebugHeader(const uint8_t *headerBuffer)
Definition: SiStripFEDBufferComponents.h:1198
sistrip::PACKET_CODE_ZERO_SUPPRESSED8_BOTBOT
static const uint8_t PACKET_CODE_ZERO_SUPPRESSED8_BOTBOT
Definition: SiStripFEDBufferComponents.h:90
sistrip::FEDDAQHeader::bxID
uint16_t bxID() const
Definition: SiStripFEDBufferComponents.h:1349
sistrip::HEADER_TYPE_APV_ERROR
Definition: SiStripFEDBufferComponents.h:40
sistrip::PACKET_CODE_PROC_RAW8_BOTBOT
static const uint8_t PACKET_CODE_PROC_RAW8_BOTBOT
Definition: SiStripFEDBufferComponents.h:86
sistrip::TrackerSpecialHeader::setHeaderType
TrackerSpecialHeader & setHeaderType(const FEDHeaderType headerType)
Definition: SiStripFEDBufferComponents.cc:821
sistrip::FEDFullDebugHeader::setFEUnitLength
void setFEUnitLength(const uint8_t internalFEUnitNum, const uint16_t length) override
Definition: SiStripFEDBufferComponents.cc:1234
sistrip::FEDFullDebugHeader::setFEUnitMajorityAddress
void setFEUnitMajorityAddress(const uint8_t internalFEUnitNum, const uint8_t address) override
Definition: SiStripFEDBufferComponents.cc:1215
CRC16.h
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
sistrip::READOUT_MODE_ZERO_SUPPRESSED
Definition: SiStripFEDBufferComponents.h:56
sistrip::TTS_DISCONNECTED0
Definition: SiStripFEDBufferComponents.h:109
pixel_dqm_sourceclient-live_cfg.enabled
enabled
Definition: pixel_dqm_sourceclient-live_cfg.py:139
sistrip::FEDFullDebugHeader::getChannelStatus
FEDChannelStatus getChannelStatus(const uint8_t internalFEDChannelNum) const
Definition: SiStripFEDBufferComponents.cc:1144
sistrip::FEDAPVErrorHeader::APV_ERROR_HEADER_SIZE_IN_BYTES
static const size_t APV_ERROR_HEADER_SIZE_IN_BYTES
Definition: SiStripFEDBufferComponents.h:531
sistrip::FEDStatusRegister::trackerHeaderMonitorDataReadyFlag
bool trackerHeaderMonitorDataReadyFlag() const
Definition: SiStripFEDBufferComponents.h:965
sistrip::printHexWord
void printHexWord(const uint8_t *pointer, const size_t lengthInBytes, std::ostream &os)
Definition: SiStripFEDBufferComponents.cc:17