CbmRoot
CbmStar2019MonitorAlgo.cxx
Go to the documentation of this file.
1 // -----------------------------------------------------------------------------
2 // ----- -----
3 // ----- CbmStar2019MonitorAlgo -----
4 // ----- Created 12.10.2019 by P.-A. Loizeau -----
5 // ----- -----
6 // -----------------------------------------------------------------------------
7 
9 
11 #include "CbmStar2019TofPar.h"
12 #include "CbmTofAddress.h"
13 #include "CbmTofDetectorId_v14a.h" // in cbmdata/tof
14 
15 #include "FairLogger.h"
16 #include "FairRootManager.h"
17 #include "FairRun.h"
18 #include "FairRunOnline.h"
19 #include "FairRuntimeDb.h"
20 
21 #include <TCanvas.h>
22 #include <TFile.h>
23 #include <TH1.h>
24 #include <TH2.h>
25 #include <TList.h>
26 #include <TPaveStats.h>
27 #include <TProfile.h>
28 #include <TROOT.h>
29 #include <TString.h>
30 
31 #include <fstream>
32 #include <iomanip>
33 #include <iostream>
34 #include <stdint.h>
35 
36 // -------------------------------------------------------------------------
38  : CbmStar2019Algo()
39  ,
41  fbDebugMonitorMode(kFALSE)
42  , fbIgnoreCriticalErrors(kFALSE)
43  , fvbMaskedComponents()
44  , fiSectorIndex(-1)
45  , fUnpackPar(nullptr)
46  , fuNrOfGdpbs(0)
47  , fGdpbIdIndexMap()
48  , fuNrOfFeePerGdpb(0)
49  , fuNrOfGet4PerFee(0)
50  , fuNrOfChannelsPerGet4(0)
51  , fuNrOfChannelsPerFee(0)
52  , fuNrOfGet4(0)
53  , fuNrOfGet4PerGdpb(0)
54  , fuNrOfChannelsPerGdpb(0)
55  , fuMinTotPulser(90)
56  , fuMaxTotPulser(100)
57  , fulCurrentTsIdx(0)
58  , fulCurrentMsIdx(0)
59  , fdTsStartTime(-1.0)
60  , fdTsStopTimeCore(-1.0)
61  , fdMsTime(-1.0)
62  , fuMsIndex(0)
63  , fmMsgCounter()
64  , fuCurrentEquipmentId(0)
65  , fuCurrDpbId(0)
66  , fuCurrDpbIdx(0)
67  , fuCurrSector(0)
68  , fiRunStartDateTimeSec(-1)
69  , fiBinSizeDatePlots(-1)
70  , fuGet4Id(0)
71  , fuGet4Nr(0)
72  , fvulCurrentEpoch()
73  , fvulCurrentEpochCycle()
74  , fvulCurrentEpochFull()
75  , fvmEpSupprBuffer()
76  , fulStartTs(0)
77  , fdStartTime(-1.0)
78  , fdStartTimeMsSz(0.0)
79  , ftStartTimeUnix(std::chrono::steady_clock::now())
80  , fvulGdpbTsMsb()
81  , fvulGdpbTsLsb()
82  , fvulStarTsMsb()
83  , fvulStarTsMid()
84  , fvulGdpbTsFullLast()
85  , fvulStarTsFullLast()
86  , fvuStarTokenLast()
87  , fvuStarDaqCmdLast()
88  , fvuStarTrigCmdLast()
89  , fbEpochSinceLastHit(kTRUE)
90  , fuDuplicatesCount(0)
91  , fmLastHit(0)
92  , fuHistoryHistoSize(3600)
93  , fhMessType(nullptr)
94  , fhSysMessType(nullptr)
95  , fhGet4MessType(nullptr)
96  , fhGet4ChanScm(nullptr)
97  , fhGet4ChanErrors(nullptr)
98  , fhGet4EpochFlags(nullptr)
99  , fhGdpbAsicSpiCounts(nullptr)
100  , fhGdpbMessType(nullptr)
101  , fhGdpbSysMessType(nullptr)
102  , fhGdpbSysMessPattType(nullptr)
103  , fhGdpbEpochFlags(nullptr)
104  , fhGdpbEpochSyncEvo(nullptr)
105  , fhGdpbEpochMissEvo(nullptr)
106  , fhGdpbEndMsBufferNotEmpty(nullptr)
107  , fhGdpbEndMsDataLost(nullptr)
108  , fvhGdpbGet4MessType()
109  , fvhGdpbGet4ChanScm()
110  , fvhGdpbGet4ChanErrors()
111  , fhMsgCntEvo(nullptr)
112  , fhHitCntEvo(nullptr)
113  , fhErrorCntEvo(nullptr)
114  , fhLostEvtCntEvo(nullptr)
115  , fhErrorFractEvo(nullptr)
116  , fhLostEvtFractEvo(nullptr)
117  , fhMsgCntPerMsEvo(nullptr)
118  , fhHitCntPerMsEvo(nullptr)
119  , fhErrorCntPerMsEvo(nullptr)
120  , fhLostEvtCntPerMsEvo(nullptr)
121  , fhErrorFractPerMsEvo(nullptr)
122  , fhLostEvtFractPerMsEvo(nullptr)
123  , fvhRawFt_gDPB()
124  , fvhRawCt_gDPB()
125  , fvhRemapTot_gDPB()
126  , fvhRemapChCount_gDPB()
127  , fvhRemapChRate_gDPB()
128  , fuNbMissmatchPattern()
129  , fhNbMissPatternPerMs(nullptr)
130  , fhPatternMissmatch(nullptr)
131  , fhPatternEnable(nullptr)
132  , fhPatternResync(nullptr)
133  , fvhGdpbPatternMissmatchEvo()
134  , fvhGdpbPatternEnableEvo()
135  , fvhGdpbPatternResyncEvo()
136  , fvvbGdpbLastMissmatchPattern()
137  , fvvbGdpbLastEnablePattern()
138  , fvvbGdpbLastResyncPattern()
139  , fvhGdpbMissmatchEvoPerTs()
140  , fvhGdpbMissmatchEnaEvoPerTs()
141  , fvhGdpbEnableEvoPerTs()
142  , fvhGdpbResyncEvoPerTs()
143  , fvhGdpbResyncEnaEvoPerTs()
144  , fvhGdpbStateEvoPerTs()
145  , fvhTokenMsgType()
146  , fvhTriggerRate()
147  , fvhCmdDaqVsTrig()
148  , fvhStarTokenEvo()
149  , fvhStarTrigGdpbTsEvo()
150  , fvhStarTrigStarTsEvo()
151  , fcSummary(nullptr)
152  , fcSummaryGdpb(nullptr)
153  , fvcSumGdpbGet4()
154  , fcStarTrigTokenType(nullptr)
155  , fcStarTriggerRate(nullptr)
156  , fcStarTrigCmdDaqVsTrig(nullptr)
157  , fcStarTrigStarTokenEvo(nullptr)
158  , fcStarTrigGdpbTsEvo(nullptr)
159  , fcStarTrigStarTsEvo(nullptr) {}
162  fvmEpSupprBuffer.clear();
163 }
164 
165 // -------------------------------------------------------------------------
167  LOG(info) << "Initializing mCBM T0 2019 monitor algo";
168 
169  return kTRUE;
170 }
174 
176 }
177 
178 // -------------------------------------------------------------------------
180  LOG(info) << "Init parameter containers for CbmStar2019MonitorAlgo";
181  Bool_t initOK = ReInitContainers();
182 
183  return initOK;
184 }
186  LOG(info) << "**********************************************";
187  LOG(info) << "ReInit parameter containers for CbmStar2019MonitorAlgo";
188 
189  fUnpackPar = (CbmStar2019TofPar*) fParCList->FindObject("CbmStar2019TofPar");
190  if (nullptr == fUnpackPar) return kFALSE;
191 
192  Bool_t initOK = InitParameters();
193 
194  return initOK;
195 }
197  if (nullptr == fParCList) fParCList = new TList();
198  fUnpackPar = new CbmStar2019TofPar("CbmStar2019TofPar");
199  fParCList->Add(fUnpackPar);
200 
201  return fParCList;
202 }
204  LOG(info) << "Debug Monitor mode: " << (fbDebugMonitorMode ? "ON" : "OFF");
205 
206  if (kTRUE == fbIgnoreCriticalErrors)
207  LOG(warning) << "Monitor set to ignore critical GET4 errors!!! No printout "
208  "will be delivered for those!!!!";
209 
211  LOG(info) << "Nr. of Tof GDPBs: " << fuNrOfGdpbs;
212 
214  LOG(info) << "Nr. of FEES per Tof GDPB: " << fuNrOfFeePerGdpb;
215 
217  LOG(info) << "Nr. of GET4 per Tof FEE: " << fuNrOfGet4PerFee;
218 
220  LOG(info) << "Nr. of channels per GET4: " << fuNrOfChannelsPerGet4;
221 
223  LOG(info) << "Nr. of channels per FEE: " << fuNrOfChannelsPerFee;
224 
226  LOG(info) << "Nr. of GET4s: " << fuNrOfGet4;
227 
229  LOG(info) << "Nr. of GET4s per GDPB: " << fuNrOfGet4PerGdpb;
230 
232  LOG(info) << "Nr. of channels per GDPB: " << fuNrOfChannelsPerGdpb;
233 
234  fGdpbIdIndexMap.clear();
235  for (UInt_t i = 0; i < fuNrOfGdpbs; ++i) {
237  LOG(info) << "GDPB Id of TOF " << i << " : " << std::hex
238  << fUnpackPar->GetGdpbId(i) << std::dec;
239  } // for( UInt_t i = 0; i < fuNrOfGdpbs; ++i )
240 
243  LOG(info) << "Timeslice parameters: each MS is " << fdMsSizeInNs << " ns";
244 
246  if (-1 < fiSectorIndex) {
248  if (fuNrOfGdpbs <= static_cast<UInt_t>(fiSectorIndex))
249  LOG(fatal) << "Selected sector out of bounds relative to parameter file: "
250  << fiSectorIndex << " VS " << fuNrOfGdpbs;
251  else
252  LOG(info) << "Selected sector "
254  << " for single sector analysis";
255 
256  fuNrOfGdpbs = 1;
257  fGdpbIdIndexMap.clear();
259  } // if( -1 < fiSectorIndex )
260 
262  fvulCurrentEpoch.resize(fuNrOfGdpbs, 0);
265 
272  fvulGdpbTsMsb.resize(fuNrOfGdpbs);
273  fvulGdpbTsLsb.resize(fuNrOfGdpbs);
274  fvulStarTsMsb.resize(fuNrOfGdpbs);
275  fvulStarTsMid.resize(fuNrOfGdpbs);
281  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
283  fvvbGdpbLastMissmatchPattern[uGdpb].resize(fuNrOfGet4PerGdpb, kFALSE);
284  fvvbGdpbLastEnablePattern[uGdpb].resize(fuNrOfGet4PerGdpb, kTRUE);
285  fvvbGdpbLastResyncPattern[uGdpb].resize(fuNrOfGet4PerGdpb, kFALSE);
287  fvulGdpbTsMsb[uGdpb] = 0;
288  fvulGdpbTsLsb[uGdpb] = 0;
289  fvulStarTsMsb[uGdpb] = 0;
290  fvulStarTsMid[uGdpb] = 0;
291  fvulGdpbTsFullLast[uGdpb] = 0;
292  fvulStarTsFullLast[uGdpb] = 0;
293  fvuStarTokenLast[uGdpb] = 0;
294  fvuStarDaqCmdLast[uGdpb] = 0;
295  fvuStarTrigCmdLast[uGdpb] = 0;
296  } // for (Int_t iGdpb = 0; iGdpb < fuNrOfGdpbs; ++iGdpb)
297 
298  if (kTRUE == fbDebugMonitorMode) fuNbMissmatchPattern.resize(fuNrOfGdpbs, 0);
299 
300  return kTRUE;
301 }
302 // -------------------------------------------------------------------------
303 
305  UShort_t usDetectorId) {
307  for (UInt_t uCompIdx = 0; uCompIdx < fvMsComponentsList.size(); ++uCompIdx)
308  if (component == fvMsComponentsList[uCompIdx]) return;
309 
311  fvMsComponentsList.push_back(component);
312 
313  LOG(info) << "CbmStar2019MonitorAlgo::AddMsComponentToList => Component "
314  << component << " with detector ID 0x" << std::hex << usDetectorId
315  << std::dec << " added to list";
316 }
317 // -------------------------------------------------------------------------
318 
319 Bool_t CbmStar2019MonitorAlgo::ProcessTs(const fles::Timeslice& ts) {
320  fulCurrentTsIdx = ts.index();
321  fdTsStartTime = static_cast<Double_t>(ts.descriptor(0, 0).idx);
322 
324  if (0 == fulCurrentTsIdx) return kTRUE;
325 
327  if (-1.0 == fdTsCoreSizeInNs) {
328  fuNbCoreMsPerTs = ts.num_core_microslices();
329  fuNbOverMsPerTs = ts.num_microslices(0) - ts.num_core_microslices();
332  LOG(info) << "Timeslice parameters: each TS has " << fuNbCoreMsPerTs
333  << " Core MS and " << fuNbOverMsPerTs
334  << " Overlap MS, for a core duration of " << fdTsCoreSizeInNs
335  << " ns and a full duration of " << fdTsFullSizeInNs << " ns";
336 
339  if (kFALSE == fbIgnoreOverlapMs) fuNbMsLoop += fuNbOverMsPerTs;
340  LOG(info) << "In each TS " << fuNbMsLoop << " MS will be looped over";
341 
344  } // if( -1.0 == fdTsCoreSizeInNs )
345 
348  // LOG(info) << Form( "TS %5d Start %12f Stop %12f", fulCurrentTsIdx, fdTsStartTime, fdTsStopTimeCore );
349 
351  for (fuMsIndex = 0; fuMsIndex < fuNbMsLoop; fuMsIndex++) {
353  for (UInt_t uMsCompIdx = 0; uMsCompIdx < fvMsComponentsList.size();
354  ++uMsCompIdx) {
355  UInt_t uMsComp = fvMsComponentsList[uMsCompIdx];
356 
357  if (kFALSE == ProcessMs(ts, uMsComp, fuMsIndex)) {
358  LOG(error) << "Failed to process ts " << fulCurrentTsIdx << " MS "
359  << fuMsIndex << " for component " << uMsComp;
360  return kFALSE;
361  } // if( kFALSE == ProcessMs( ts, uMsCompIdx, fuMsIndex ) )
362  } // for( UInt_t uMsCompIdx = 0; uMsCompIdx < fvMsComponentsList.size(); ++uMsCompIdx )
363 
364  if (kTRUE == fbDebugMonitorMode) {
365  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
367  uGdpb + fUnpackPar->GetGdpbToSectorOffset());
368  fuNbMissmatchPattern[uGdpb] = 0;
369  } // for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb)
370  } // if( kTRUE == fbDebugMonitorMode )
371  } // for( fuMsIndex = 0; fuMsIndex < uNbMsLoop; fuMsIndex ++ )
372 
374  if (kFALSE == FillHistograms()) {
375  LOG(error) << "Failed to fill histos in ts " << fulCurrentTsIdx;
376  return kFALSE;
377  } // if( kFALSE == FillHistograms() )
378 
379  return kTRUE;
380 }
381 
382 Bool_t CbmStar2019MonitorAlgo::ProcessMs(const fles::Timeslice& ts,
383  size_t uMsCompIdx,
384  size_t uMsIdx) {
385  auto msDescriptor = ts.descriptor(uMsCompIdx, uMsIdx);
386  fuCurrentEquipmentId = msDescriptor.eq_id;
387  const uint8_t* msContent =
388  reinterpret_cast<const uint8_t*>(ts.content(uMsCompIdx, uMsIdx));
389 
390  uint32_t uSize = msDescriptor.size;
391  fulCurrentMsIdx = msDescriptor.idx;
392  fdMsTime = (1e-9) * static_cast<double>(fulCurrentMsIdx);
393  LOG(debug) << "Microslice: " << fulCurrentMsIdx << " from EqId " << std::hex
394  << fuCurrentEquipmentId << std::dec << " has size: " << uSize;
395 
396  if (0 == fvbMaskedComponents.size())
397  fvbMaskedComponents.resize(ts.num_components(), kFALSE);
398 
399  fuCurrDpbId = static_cast<uint32_t>(fuCurrentEquipmentId & 0xFFFF);
400  // fuCurrDpbIdx = fDpbIdIndexMap[ fuCurrDpbId ];
401 
403  auto it = fGdpbIdIndexMap.find(fuCurrDpbId);
404  if (it == fGdpbIdIndexMap.end()) {
405  if (kFALSE == fvbMaskedComponents[uMsCompIdx]) {
406  LOG(info)
407  << "---------------------------------------------------------------";
408  LOG(info) << FormatMsHeaderPrintout(msDescriptor);
409  LOG(warning) << "Could not find the gDPB index for AFCK id 0x" << std::hex
410  << fuCurrDpbId << std::dec << " in timeslice "
411  << fulCurrentTsIdx << " in microslice " << uMsIdx
412  << " component " << uMsCompIdx << "\n"
413  << "If valid this index has to be added in the TOF "
414  "parameter file in the DbpIdArray field";
415  fvbMaskedComponents[uMsCompIdx] = kTRUE;
416  } // if( kFALSE == fvbMaskedComponents[ uMsComp ] )
417  else
418  return kTRUE;
419 
422 
423  return kFALSE;
424  } // if( it == fGdpbIdIndexMap.end() )
425  else
427 
429 
431  if (fdStartTime < 0) fdStartTime = fdMsTime;
433  else if (fuHistoryHistoSize < fdMsTime - fdStartTime) {
436  } // else if( fuHistoryHistoSize < fdMsTime - fdStartTime )
437  /*
439  if (fdStartTimeLong < 0)
440  fdStartTimeLong = fdMsTime;
442  if( fuHistoryHistoSizeLong < 1e-9 * (fdMsTime - fdStartTimeLong) / 60.0 )
443  {
444  ResetLongEvolutionHistograms();
445  fdStartTimeLong = dHitTime;
446  } // if( fuHistoryHistoSize < 1e-9 * (fdMsTime - fdStartTimeLong) / 60.0 )
447 */
448 
449  // If not integer number of message in input buffer, print warning/error
450  if (0 != (uSize % kuBytesPerMessage))
451  LOG(error) << "The input microslice buffer does NOT "
452  << "contain only complete nDPB messages!";
453 
454  // Compute the number of complete messages in the input microslice buffer
455  uint32_t uNbMessages =
456  (uSize - (uSize % kuBytesPerMessage)) / kuBytesPerMessage;
457 
458  // Prepare variables for the loop on contents
459  Int_t messageType = -111;
460  const uint64_t* pInBuff = reinterpret_cast<const uint64_t*>(msContent);
461  for (uint32_t uIdx = 0; uIdx < uNbMessages; uIdx++) {
462  // Fill message
463  uint64_t ulData = static_cast<uint64_t>(pInBuff[uIdx]);
464 
466  if (0 == uIdx) {
467  ProcessEpochCycle(ulData);
468  continue;
469  } // if( 0 == uIdx )
470 
471  gdpbv100::Message mess(ulData);
473  messageType = mess.getMessageType();
474  fhMessType->Fill(messageType);
475  fhGdpbMessType->Fill(messageType, fuCurrSector);
476 
479 
480  if (fuNrOfGet4PerGdpb <= fuGet4Id && !mess.isStarTrigger()
482  LOG(warning) << "Message with Get4 ID too high: " << fuGet4Id << " VS "
483  << fuNrOfGet4PerGdpb << " set in parameters.";
484 
485  switch (messageType) {
486  case gdpbv100::MSG_HIT: {
487  if (mess.getGdpbHitIs24b()) {
489  LOG(fatal) << "This monitor does not support 24b hit messages!!!.";
490  continue;
491  } // if( getGdpbHitIs24b() )
492  else {
494  fhGet4MessType->Fill(fuGet4Nr, 0);
496 
497  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
498  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
499 
502  /*
503  if( kFALSE == fbEpochSinceLastHit )
504  {
505  if( fmLastHit != mess )
506  {
507  if( 0 < fuDuplicatesCount )
508  {
509  LOG(warning) << "Detected duplicate hits in sector " << fuCurrSector
510  << ": " << fuDuplicatesCount << " times "
511  << Form( "0x%16lx", fmLastHit.getData() );
512  } // if( 0 < fuDuplicatesCount )
513  fmLastHit = mess;
514  fuDuplicatesCount = 0;
515  }
516  else fuDuplicatesCount++;
517  } // if( kFALSE == fbEpochSinceLastHit )
518  else
519  {
520  fmLastHit = mess;
521  fbEpochSinceLastHit = kFALSE;
522  } // else of if( kFALSE == fbEpochSinceLastHit )
523 */
524  fvmEpSupprBuffer.push_back(mess);
525  } // else of if( getGdpbHitIs24b() )
526  break;
527  } // case gdpbv100::MSG_HIT:
528  case gdpbv100::MSG_EPOCH: {
530  ProcessEpoch(mess);
531  } // if this epoch message is a merged one valid for all chips
532  else {
534  LOG(fatal) << "This event builder does not support unmerged epoch "
535  "messages!!!.";
536  continue;
537  } // if single chip epoch message
538  break;
539  } // case gdpbv100::MSG_EPOCH:
540  case gdpbv100::MSG_SLOWC: {
541  ProcessSlowCtrl(mess);
542  break;
543  } // case gdpbv100::MSG_SLOWC:
544  case gdpbv100::MSG_SYST: {
545  ProcessSysMess(mess);
546  break;
547  } // case gdpbv100::MSG_SYST:
552  ProcessStarTrig(mess);
553  break;
554  } // case gdpbv100::MSG_STAR_TRI_A-D
555  default:
556  LOG(fatal) << "Message type " << std::hex << std::setw(2)
557  << static_cast<uint16_t>(messageType)
558  << " not included in Get4 data format.";
559  } // switch( mess.getMessageType() )
560  } // for (uint32_t uIdx = 0; uIdx < uNbMessages; uIdx ++)
561 
564  if (0 < fvmEpSupprBuffer.size()) {
567  } // if( 0 < fvmEpSupprBuffer.size() )
568 
570  fvmEpSupprBuffer.clear();
571 
573  FillHistograms();
574 
575  return kTRUE;
576 }
577 
578 // -------------------------------------------------------------------------
579 void CbmStar2019MonitorAlgo::ProcessEpochCycle(uint64_t ulCycleData) {
580  ULong64_t ulEpochCycleVal = ulCycleData & gdpbv100::kulEpochCycleFieldSz;
581 
582  if (!(ulEpochCycleVal == fvulCurrentEpochCycle[fuCurrDpbIdx]
583  || ulEpochCycleVal == fvulCurrentEpochCycle[fuCurrDpbIdx] + 1)
584  && 0 < fulCurrentMsIdx) {
585  LOG(warning) << "CbmStar2019MonitorAlgo::ProcessEpochCycle => "
586  << " Missmatch in epoch cycles detected for Gdpb "
587  << fuCurrDpbIdx
588  << ", probably fake cycles due to epoch index corruption! "
589  << Form(" Current cycle 0x%09llX New cycle 0x%09llX",
591  ulEpochCycleVal);
592  } // if epoch cycle did not stay constant or increase by exactly 1, except if first MS of the TS
593  if (ulEpochCycleVal != fvulCurrentEpochCycle[fuCurrDpbIdx]) {
594  LOG(info) << "CbmStar2019EventBuilderEtofAlgo::ProcessEpochCycle => "
595  << " New epoch cycle for Gdpb " << fuCurrDpbIdx
596  << Form(": Current cycle 0x%09llX New cycle 0x%09llX",
598  ulEpochCycleVal);
599  } // if( ulEpochCycleVal != fvulCurrentEpochCycle[fuCurrDpbIdx] )
600  fvulCurrentEpochCycle[fuCurrDpbIdx] = ulEpochCycleVal;
601 
602  return;
603 }
605  ULong64_t ulEpochNr = mess.getGdpbEpEpochNb();
606  Bool_t bSyncFlag = (1 == mess.getGdpbEpSync());
607  Bool_t bDataLoss = (1 == mess.getGdpbEpDataLoss());
608  Bool_t bEpochLoss = (1 == mess.getGdpbEpEpochLoss());
609  Bool_t bMissmMatch = (1 == mess.getGdpbEpMissmatch());
610 
611  fvulCurrentEpoch[fuCurrDpbIdx] = ulEpochNr;
613  ulEpochNr
615 
617  if (bSyncFlag) {
618  fhGdpbEpochFlags->Fill(fuCurrSector, 0);
620  } // if( bSyncFlag )
621 
622  if (bDataLoss) fhGdpbEpochFlags->Fill(fuCurrSector, 1);
623 
624  if (bEpochLoss) fhGdpbEpochFlags->Fill(fuCurrSector, 2);
625 
626  if (bMissmMatch) {
627  fhGdpbEpochFlags->Fill(fuCurrSector, 3);
629  } // if( bMissmMatch )
630 
631  for (uint32_t uGet4Index = 0; uGet4Index < fuNrOfGet4PerGdpb; uGet4Index++) {
632  fuGet4Id = uGet4Index;
634 
635  fhGet4MessType->Fill(fuGet4Nr, 1);
637 
638  if (bSyncFlag) fhGet4EpochFlags->Fill(fuGet4Nr, 0);
639  if (bDataLoss) fhGet4EpochFlags->Fill(fuGet4Nr, 1);
640  if (bEpochLoss) fhGet4EpochFlags->Fill(fuGet4Nr, 2);
641  if (bMissmMatch) fhGet4EpochFlags->Fill(fuGet4Nr, 3);
642  } // for( uint32_t uGet4Index = 0; uGet4Index < fuNrOfGet4PerGdpb; uGet4Index ++ )
643 
644  if (0 < fuDuplicatesCount)
645  LOG(warning) << "Detected duplicate hits: " << fuDuplicatesCount
646  << " times "
647  << Form("0x%16lx",
648  static_cast<unsigned long>(fmLastHit.getData()));
649  fbEpochSinceLastHit = kTRUE;
650  fuDuplicatesCount = 0;
651 
654 }
655 // -------------------------------------------------------------------------
657  Int_t iBufferSize = fvmEpSupprBuffer.size();
658 
659  if (0 == iBufferSize) return;
660 
661  LOG(debug) << "Now processing stored messages for for gDPB " << fuCurrDpbIdx
662  << " with epoch number " << (fvulCurrentEpoch[fuCurrDpbIdx] - 1);
663 
666  std::stable_sort(fvmEpSupprBuffer.begin(), fvmEpSupprBuffer.end());
667 
669  ULong64_t ulCurEpochGdpbGet4 = fvulCurrentEpochFull[fuCurrDpbIdx];
670 
672  if (0 == ulCurEpochGdpbGet4) return;
673 
675  ulCurEpochGdpbGet4--;
676 
677  Int_t messageType = -111;
678  for (Int_t iMsgIdx = 0; iMsgIdx < iBufferSize; iMsgIdx++) {
679  messageType = fvmEpSupprBuffer[iMsgIdx].getMessageType();
680 
682  fvmEpSupprBuffer[iMsgIdx].getGdpbGenChipId());
684 
686  gdpbv100::FullMessage fullMess(fvmEpSupprBuffer[iMsgIdx],
687  ulCurEpochGdpbGet4);
688 
690  switch (messageType) {
691  case gdpbv100::MSG_HIT: {
692  ProcessHit(fullMess);
693  break;
694  } // case gdpbv100::MSG_HIT:
695  case gdpbv100::MSG_SLOWC:
697  break;
698  case gdpbv100::MSG_SYST: {
701  ProcessError(fullMess);
702  break;
703  } // case gdpbv100::MSG_SYST:
704  case gdpbv100::MSG_EPOCH:
710  break;
711  default:
712  LOG(error) << "Message type " << std::hex << std::setw(2)
713  << static_cast<uint16_t>(messageType)
714  << " not included in Get4 unpacker.";
715  } // switch( mess.getMessageType() )
716  } // for( Int_t iMsgIdx = 0; iMsgIdx < iBufferSize; iMsgIdx++ )
717 
718  fvmEpSupprBuffer.clear();
719 }
720 // -------------------------------------------------------------------------
722  UInt_t uChannel = mess.getGdpbHitChanId();
723  UInt_t uTot = mess.getGdpbHit32Tot();
724 
728  UInt_t uFts = mess.getGdpbHitFullTs() % 112;
729  UInt_t uCts = mess.getGdpbHitFullTs() / 112;
730 
731  UInt_t uChannelNr = fuGet4Id * fuNrOfChannelsPerGet4 + uChannel;
732  UInt_t uChannelNrInFee =
734  UInt_t uFeeNr = (fuGet4Id / fuNrOfGet4PerFee);
735  // UInt_t uFeeNrInSys = fuCurrDpbIdx * fuNrOfFeePerGdpb + uFeeNr;
736  UInt_t uRemappedChannelNr = uFeeNr * fuNrOfChannelsPerFee
737  + fUnpackPar->Get4ChanToPadiChan(uChannelNrInFee);
738  // UInt_t uGbtxNr = (uFeeNr / fUnpackPar->GetNrOfFeePerGbtx());
739  // UInt_t uFeeInGbtx = (uFeeNr % fUnpackPar->GetNrOfFeePerGbtx());
740  // UInt_t uGbtxNrInSys = fuCurrDpbIdx * fUnpackPar->GetNrOfGbtxPerGdpb() + uGbtxNr;
741 
742  // UInt_t uChanInSyst = fuCurrDpbIdx * fuNrOfChannelsPerGdpb + uChannelNr;
743  // UInt_t uRemappedChannelNrInSys = fuCurrDpbIdx * fuNrOfChannelsPerGdpb
744  // + uFeeNr * fuNrOfChannelsPerFee
745  // + fUnpackPar->Get4ChanToPadiChan( uChannelNrInFee );
746 
747  // ULong_t ulHitTime = mess.getMsgFullTime( mess.getExtendedEpoch() );
748  Double_t dHitTime = mess.GetFullTimeNs();
749  // Double_t dHitTot = uTot; // in bins
750 
752  if (kTRUE == fbDebugMonitorMode) {
753  fvhRawFt_gDPB[fuCurrDpbIdx]->Fill(uChannelNr, uFts);
754  fvhRawCt_gDPB[fuCurrDpbIdx]->Fill(uChannelNr, uCts);
755  } // if( kTRUE == fbDebugMonitorMode )
756 
758  if (4096 <= uCts) {
759  LOG(debug) << "CbmStar2019MonitorAlgo::ProcessHit => Coarse time above "
760  "4096 detected."
761  << Form(" sector %02u GET4 %03u Channel %u, TS %8llu MS %3u (MS "
762  "time %12llu)",
764  fuGet4Id,
765  uChannel,
767  fuMsIndex,
769  } // if( 4096 <= uCts )
770 
772  fvhRemapChCount_gDPB[fuCurrDpbIdx]->Fill(uRemappedChannelNr);
773  fvhRemapTot_gDPB[fuCurrDpbIdx]->Fill(uRemappedChannelNr, uTot);
774 
777  if (0 <= fdStartTime) {
778  fvhRemapChRate_gDPB[fuCurrDpbIdx]->Fill(1e-9 * dHitTime - fdStartTime,
779  uRemappedChannelNr);
780  // fvhFeeRate_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill( 1e-9 * (dHitTime - fdStartTime));
781  // fvhFeeErrorRatio_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill( 1e-9 * (dHitTime - fdStartTime), 0, 1);
782  } // if (0 <= fdStartTime)
783  /*
784  if (0 <= fdStartTimeLong)
785  {
786  fvhFeeRateLong_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
787  1e-9 / 60.0 * (dHitTime - fdStartTimeLong), 1 / 60.0 );
788  fvhFeeErrorRatioLong_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
789  1e-9 / 60.0 * (dHitTime - fdStartTimeLong), 0, 1 / 60.0 );
790  } // if (0 <= fdStartTimeLong)
791 */
792 }
793 // -------------------------------------------------------------------------
795  UInt_t uSubType = mess.getGdpbSysSubType();
796  fhSysMessType->Fill(uSubType);
797  fhGdpbSysMessType->Fill(uSubType, fuCurrSector);
798 
799  switch (mess.getGdpbSysSubType()) {
802  fhGet4MessType->Fill(fuGet4Nr, 3);
804 
806  fvmEpSupprBuffer.push_back(mess);
807  // ProcessError( mess );
808  break;
809  } // case gdpbv100::SYSMSG_GET4_EVENT
811  LOG(debug) << "Unknown GET4 message, data: " << std::hex << std::setw(8)
812  << mess.getGdpbSysUnkwData() << std::dec
813  << " Full message: " << std::hex << std::setw(16)
814  << mess.getData() << std::dec;
815  break;
816  } // case gdpbv100::SYS_GDPB_UNKWN:
818  if (mess.getGdpbSysFwErrResync())
819  LOG(info) << Form("GET4 Resynchronization: Get4:0x%04x ",
820  mess.getGdpbGenChipId())
821  << fuCurrDpbIdx;
822  else
823  LOG(info) << "GET4 synchronization pulse missing in gDPB "
824  << fuCurrDpbIdx;
825  break;
826  } // case gdpbv100::SYS_GET4_SYNC_MISS:
827  case gdpbv100::SYS_PATTERN: {
828  ProcessPattern(mess);
829  break;
830  } // case gdpbv100::SYS_PATTERN:
831  default: {
832  LOG(info) << "Crazy system message, subtype " << mess.getGdpbSysSubType();
833  break;
834  } // default
835  } // switch( mess.getGdpbSysSubType() )
836 }
837 // -------------------------------------------------------------------------
839  uint32_t uErrorType = mess.getGdpbSysErrData();
840 
841  fhGet4MessType->Fill(fuGet4Nr, 3);
843 
844  // UInt_t uFeeNr = (fuGet4Id / fuNrOfGet4PerFee);
845 
847  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
848  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 0.0);
849 
852  fhErrorFractEvo->Fill(fdMsTime - fdStartTime, 1.0);
853 
854  if (gdpbv100::GET4_V2X_ERR_LOST_EVT == uErrorType) {
856  fhLostEvtFractEvo->Fill(fdMsTime - fdStartTime, 1.0);
857  } // if( gdpbv100::GET4_V2X_ERR_LOST_EVT == mess.getGdpbSysErrData() )
858  /*
860  if (0 <= fdStartTime)
861  {
862  fvhFeeErrorRate_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
863  1e-9 * (mess.getMsgFullTimeD(fvulCurrentEpoch[fuGet4Nr]) - fdStartTime));
864  fvhFeeErrorRatio_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
865  1e-9 * (mess.getMsgFullTimeD(fvulCurrentEpoch[fuGet4Nr]) - fdStartTime), 1, 1 );
866  } // if (0 <= fdStartTime)
867  if (0 <= fdStartTimeLong)
868  {
869  fvhFeeErrorRateLong_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
870  1e-9 / 60.0 * (mess.getMsgFullTimeD(fvulCurrentEpoch[fuGet4Nr]) - fdStartTimeLong), 1 / 60.0);
871  fvhFeeErrorRatioLong_gDPB[(fuCurrDpbIdx * fuNrOfFeePerGdpb) + uFeeNr]->Fill(
872  1e-9 / 60.0 * (mess.getMsgFullTimeD(fvulCurrentEpoch[fuGet4Nr]) - fdStartTimeLong), 1, 1 / 60.0);
873  } // if (0 <= fdStartTime)
874 */
875  Int_t dGdpbChId =
877  Int_t dFullChId =
879 
880  switch (uErrorType) {
882  fhGet4ChanErrors->Fill(dFullChId, 0);
883  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 0);
884  break;
885  } // case gdpbv100::GET4_V2X_ERR_READ_INIT:
887  fhGet4ChanErrors->Fill(dFullChId, 1);
888  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 1);
889  break;
890  } // case gdpbv100::GET4_V2X_ERR_SYNC:
892  fhGet4ChanErrors->Fill(dFullChId, 2);
893  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 2);
894  break;
895  } // case gdpbv100::GET4_V2X_ERR_EP_CNT_SYNC:
897  fhGet4ChanErrors->Fill(dFullChId, 3);
898  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 3);
899  break;
900  } // case gdpbv100::GET4_V2X_ERR_EP:
902  fhGet4ChanErrors->Fill(dFullChId, 4);
903  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 4);
904  break;
905  } // case gdpbv100::GET4_V2X_ERR_FIFO_WRITE:
907  fhGet4ChanErrors->Fill(dFullChId, 5);
908  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 5);
909  break;
910  } // case gdpbv100::GET4_V2X_ERR_LOST_EVT:
912  fhGet4ChanErrors->Fill(dFullChId, 6);
913  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 6);
914  break;
915  } // case gdpbv100::GET4_V2X_ERR_CHAN_STATE:
917  fhGet4ChanErrors->Fill(dFullChId, 7);
918  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 7);
919  break;
920  } // case gdpbv100::GET4_V2X_ERR_TOK_RING_ST:
922  fhGet4ChanErrors->Fill(dFullChId, 8);
923  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 8);
924  break;
925  } // case gdpbv100::GET4_V2X_ERR_TOKEN:
927  fhGet4ChanErrors->Fill(dFullChId, 9);
928  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 9);
929  break;
930  } // case gdpbv100::GET4_V2X_ERR_READOUT_ERR:
932  fhGet4ChanErrors->Fill(dFullChId, 10);
933  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 10);
934  break;
935  } // case gdpbv100::GET4_V2X_ERR_SPI:
937  fhGet4ChanErrors->Fill(dFullChId, 11);
938  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 11);
939  break;
940  } // case gdpbv100::GET4_V2X_ERR_DLL_LOCK:
942  fhGet4ChanErrors->Fill(dFullChId, 12);
943  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 12);
944  break;
945  } // case gdpbv100::GET4_V2X_ERR_DLL_RESET:
947  fhGet4ChanErrors->Fill(dFullChId, 13);
948  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 13);
949  break;
950  } // case gdpbv100::GET4_V2X_ERR_TOT_OVERWRT:
952  fhGet4ChanErrors->Fill(dFullChId, 14);
953  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 14);
954  break;
955  } // case gdpbv100::GET4_V2X_ERR_TOT_RANGE:
957  fhGet4ChanErrors->Fill(dFullChId, 15);
958  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 15);
959  break;
960  } // case gdpbv100::GET4_V2X_ERR_EVT_DISCARD:
962  fhGet4ChanErrors->Fill(dFullChId, 16);
963  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 16);
964  break;
965  } // case gdpbv100::GET4_V2X_ERR_ADD_RIS_EDG:
967  fhGet4ChanErrors->Fill(dFullChId, 17);
968  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 17);
969  break;
970  } // case gdpbv100::GET4_V2X_ERR_UNPAIR_FALL:
972  fhGet4ChanErrors->Fill(dFullChId, 18);
973  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 18);
974  break;
975  } // case gdpbv100::GET4_V2X_ERR_SEQUENCE_ER:
977  fhGet4ChanErrors->Fill(dFullChId, 19);
978  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 19);
979  break;
980  } // case gdpbv100::GET4_V2X_ERR_EPOCH_OVERF:
982  fhGet4ChanErrors->Fill(dFullChId, 20);
983  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 20);
984  break;
985  } // case gdpbv100::GET4_V2X_ERR_UNKNOWN:
986  default: // Corrupt error or not yet supported error
987  {
988  fhGet4ChanErrors->Fill(dFullChId, 21);
989  fvhGdpbGet4ChanErrors[fuCurrDpbIdx]->Fill(dGdpbChId, 21);
990  break;
991  } //
992  } // Switch( mess.getGdpbSysErrData() )
993 
994  switch (uErrorType) {
1007  if (kFALSE == fbIgnoreCriticalErrors)
1008  LOG(info) << " +++++++ > gDPB: " << std::hex << std::setw(4)
1009  << fuCurrDpbIdx << std::dec << ", Chip = " << std::setw(2)
1010  << mess.getGdpbGenChipId() << ", Chan = " << std::setw(1)
1011  << mess.getGdpbSysErrChanId() << ", Edge = " << std::setw(1)
1012  << mess.getGdpbSysErrEdge() << ", Empt = " << std::setw(1)
1013  << mess.getGdpbSysErrUnused() << ", Data = " << std::hex
1014  << std::setw(2) << uErrorType << std::dec
1015  << " -- GET4 V1 Error Event";
1016  break;
1017  } // critical errors
1020  break;
1029  LOG(debug) << " +++++++ >gDPB: " << std::hex << std::setw(4)
1030  << fuCurrDpbIdx << std::dec << ", Chip = " << std::setw(2)
1031  << mess.getGdpbGenChipId() << ", Chan = " << std::setw(1)
1032  << mess.getGdpbSysErrChanId() << ", Edge = " << std::setw(1)
1033  << mess.getGdpbSysErrEdge() << ", Empt = " << std::setw(1)
1034  << mess.getGdpbSysErrUnused() << ", Data = " << std::hex
1035  << std::setw(2) << uErrorType << std::dec
1036  << " -- GET4 V1 Error Event ";
1037  break;
1038  } // Input channel related errors (TOT, shaky signals, etc...)
1042  break;
1043  default:
1045  break;
1046  } // switch( uErrorType )
1047 
1048  return;
1049 }
1050 // -------------------------------------------------------------------------
1052  uint16_t usType = mess.getGdpbSysPattType();
1053  uint16_t usIndex = mess.getGdpbSysPattIndex();
1054  uint32_t uPattern = mess.getGdpbSysPattPattern();
1055  UInt_t uNbBits = (7 == usIndex ? 16 : 32);
1056  fhGdpbSysMessPattType->Fill(usType, fuCurrSector);
1057 
1058 
1059  switch (usType) {
1060  case gdpbv100::PATT_MISSMATCH: {
1061 
1062  if (kTRUE == fbDebugMonitorMode && 0 == usIndex) {
1064 
1065  LOG(debug) << Form("Missmatch pattern message => Type %d, Index %2d, "
1066  "Pattern 0x%08X TS %12llu MS %3u Epoch %12llu",
1067  usType,
1068  usIndex,
1069  uPattern,
1071  fuMsIndex,
1073  } // if( 0 == usIndex )
1074 
1075  LOG(debug) << Form(
1076  "Missmatch pattern message => Type %d, Index %2d, Pattern 0x%08X",
1077  usType,
1078  usIndex,
1079  uPattern);
1080  if (kTRUE == fbDebugMonitorMode)
1081  for (UInt_t uBit = 0; uBit < uNbBits; ++uBit) {
1082  UInt_t uBadAsic = fUnpackPar->ElinkIdxToGet4Idx(32 * usIndex + uBit);
1083 
1084  if ((uPattern >> uBit) & 0x1) {
1085  fhPatternMissmatch->Fill(uBadAsic, fuCurrSector);
1087  fulCurrentTsIdx - fulStartTs, uBadAsic);
1088  fvvbGdpbLastMissmatchPattern[fuCurrDpbIdx][uBadAsic] = kTRUE;
1089  } // if( ( uPattern >> uBit ) & 0x1 )
1090  else
1091  fvvbGdpbLastMissmatchPattern[fuCurrDpbIdx][uBadAsic] = kFALSE;
1092 
1093  } // for( UInt_t uBit = 0; uBit < uNbBits; ++uBit )
1094  break;
1095  } // case gdpbv100::PATT_MISSMATCH:
1096  case gdpbv100::PATT_ENABLE: {
1097  LOG(debug) << Form(
1098  "ENABLE pattern message => Type %d, Index %2d, Pattern 0x%08X",
1099  usType,
1100  usIndex,
1101  uPattern);
1102 
1103  if (kTRUE == fbDebugMonitorMode)
1104  for (UInt_t uBit = 0; uBit < uNbBits; ++uBit) {
1105  UInt_t uAsic = fUnpackPar->ElinkIdxToGet4Idx(32 * usIndex + uBit);
1106 
1107  if ((uPattern >> uBit) & 0x1) {
1108  fhPatternEnable->Fill(uAsic, fuCurrSector);
1110  fvvbGdpbLastEnablePattern[fuCurrDpbIdx][uAsic] = kFALSE;
1111  } // if( ( uPattern >> uBit ) & 0x1 )
1112  else
1113  fvvbGdpbLastEnablePattern[fuCurrDpbIdx][uAsic] = kTRUE;
1114 
1115  } // for( UInt_t uBit = 0; uBit < uNbBits; ++uBit )
1116  break;
1117  } // case gdpbv100::PATT_ENABLE:
1118  case gdpbv100::PATT_RESYNC: {
1119  LOG(debug) << Form(
1120  "RESYNC pattern message => Type %d, Index %2d, Pattern 0x%08X",
1121  usType,
1122  usIndex,
1123  uPattern);
1124 
1125  if (kTRUE == fbDebugMonitorMode)
1126  for (UInt_t uBit = 0; uBit < uNbBits; ++uBit) {
1127  UInt_t uBadAsic = fUnpackPar->ElinkIdxToGet4Idx(32 * usIndex + uBit);
1128 
1129  if ((uPattern >> uBit) & 0x1) {
1130  fhPatternResync->Fill(uBadAsic, fuCurrSector);
1132  uBadAsic);
1133  fvvbGdpbLastResyncPattern[fuCurrDpbIdx][uBadAsic] = kTRUE;
1134  } // if( ( uPattern >> uBit ) & 0x1 )
1135  else
1136  fvvbGdpbLastResyncPattern[fuCurrDpbIdx][uBadAsic] = kFALSE;
1137 
1138  } // for( UInt_t uBit = 0; uBit < uNbBits; ++uBit )
1139  break;
1140  } // case gdpbv100::PATT_RESYNC:
1141  default: {
1142  LOG(debug) << "Crazy pattern message, subtype " << usType;
1143  break;
1144  } // default
1145  } // switch( usType )
1146 
1147  return;
1148 }
1149 // -------------------------------------------------------------------------
1151  UInt_t uChan = mess.getGdpbSlcChan();
1152  UInt_t uEdge = mess.getGdpbSlcEdge();
1153  UInt_t uData = mess.getGdpbSlcData();
1154  UInt_t uType = mess.getGdpbSlcType();
1155 
1156  Double_t dGdpbChId = fuGet4Id * fuNrOfChannelsPerGet4 + mess.getGdpbSlcChan()
1157  + 0.5 * mess.getGdpbSlcEdge();
1158  Double_t dFullChId = fuGet4Nr * fuNrOfChannelsPerGet4 + mess.getGdpbSlcChan()
1159  + 0.5 * mess.getGdpbSlcEdge();
1160  Double_t dMessTime = fulCurrentMsIdx * 1e-9;
1161 
1162 
1163  switch (uType) {
1165  fhGet4ChanScm->Fill(dFullChId, uType);
1166  fvhGdpbGet4ChanScm[fuCurrDpbIdx]->Fill(dGdpbChId, uType);
1167  break;
1168  } // case gdpbv100::GET4_32B_SLC_SCALER:
1170  fhGet4ChanScm->Fill(dFullChId, uType);
1171  fvhGdpbGet4ChanScm[fuCurrDpbIdx]->Fill(dGdpbChId, uType);
1172  break;
1173  } // case gdpbv100::GET4_32B_SLC_DEADT:
1175  fhGet4ChanScm->Fill(dFullChId, uType);
1176  fvhGdpbGet4ChanScm[fuCurrDpbIdx]->Fill(dGdpbChId, uType);
1177 
1180  LOG(info) << "GET4 Slow Control SPI message, time "
1181  << Form("%3.3f", dMessTime) << " s "
1182  << " for board ID " << std::hex << std::setw(4) << fuCurrDpbIdx
1183  << std::dec << "\n"
1184  << " +++++++ > Chip = " << std::setw(3) << fuGet4Id
1185  << ", Chan = " << std::setw(1) << uChan
1186  << ", Edge = " << std::setw(1) << uEdge
1187  << ", Type = " << std::setw(1) << mess.getGdpbSlcType() << ", "
1188  << Form("channel %1u,", (uData >> 10) & 0xF)
1189  << Form("value 0x%03x ", uData & 0x3FF)
1190  << Form("level %4.1f ",
1191  fUnpackPar->GetPadiThresholdVal(uData & 0x3FF))
1192  << Form("(Data = 0x%06x) ", uData);
1193  break;
1194  } // if( gdpbv100::GET4_32B_SLC_SPIREAD == uType )
1196  if (0 == mess.getGdpbSlcChan()
1197  && 0 == mess.getGdpbSlcEdge()) // START message
1198  {
1199  fhGet4ChanScm->Fill(dFullChId, uType + 1);
1200  fvhGdpbGet4ChanScm[fuCurrDpbIdx]->Fill(dGdpbChId, uType + 1);
1201  } // if( 0 == mess.getGdpbSlcChan() && 0 == mess.getGdpbSlcEdge() )
1202  else if (0 == mess.getGdpbSlcChan()
1203  && 1 == mess.getGdpbSlcEdge()) // SEU counter message
1204  {
1205  fhGet4ChanScm->Fill(dFullChId, uType);
1206  fvhGdpbGet4ChanScm[fuCurrDpbIdx]->Fill(dGdpbChId, uType);
1207  } // else if( 0 == mess.getGdpbSlcChan() && 1 == mess.getGdpbSlcEdge() )
1208  break;
1209  } // case gdpbv100::GET4_32B_SLC_START_SEU:
1210  default: break;
1211  } // switch( uType )
1212 
1214  fhGet4MessType->Fill(fuGet4Nr, 2);
1216 }
1217 // -------------------------------------------------------------------------
1219  Int_t iMsgIndex = mess.getStarTrigMsgIndex();
1220 
1221  switch (iMsgIndex) {
1222  case 0:
1223  fvhTokenMsgType[fuCurrDpbIdx]->Fill(0);
1225  break;
1226  case 1:
1227  fvhTokenMsgType[fuCurrDpbIdx]->Fill(1);
1230  break;
1231  case 2:
1232  fvhTokenMsgType[fuCurrDpbIdx]->Fill(2);
1234  break;
1235  case 3: {
1236  fvhTokenMsgType[fuCurrDpbIdx]->Fill(3);
1237 
1238  ULong64_t ulNewGdpbTsFull =
1240  ULong64_t ulNewStarTsFull = (fvulStarTsMsb[fuCurrDpbIdx] << 48)
1241  + (fvulStarTsMid[fuCurrDpbIdx] << 8)
1242  + mess.getStarTsLsbStarD();
1243  UInt_t uNewToken = mess.getStarTokenStarD();
1244  UInt_t uNewDaqCmd = mess.getStarDaqCmdStarD();
1245  UInt_t uNewTrigCmd = mess.getStarTrigCmdStarD();
1246 
1247  if ((uNewToken == fvuStarTokenLast[fuCurrDpbIdx])
1248  && (ulNewGdpbTsFull == fvulGdpbTsFullLast[fuCurrDpbIdx])
1249  && (ulNewStarTsFull == fvulStarTsFullLast[fuCurrDpbIdx])
1250  && (uNewDaqCmd == fvuStarDaqCmdLast[fuCurrDpbIdx])
1251  && (uNewTrigCmd == fvuStarTrigCmdLast[fuCurrDpbIdx])) {
1252  UInt_t uTrigWord = ((fvuStarTrigCmdLast[fuCurrDpbIdx] & 0x00F) << 16)
1253  + ((fvuStarDaqCmdLast[fuCurrDpbIdx] & 0x00F) << 12)
1254  + ((fvuStarTokenLast[fuCurrDpbIdx] & 0xFFF));
1255  LOG(warning) << "Possible error: identical STAR tokens found twice in "
1256  "a row => ignore 2nd! "
1257  << " TS " << fulCurrentTsIdx << " gDBB #" << fuCurrDpbIdx
1258  << " "
1259  << Form("token = %5u ", fvuStarTokenLast[fuCurrDpbIdx])
1260  << Form("gDPB ts = %12llu ",
1262  << Form("STAR ts = %12llu ",
1264  << Form("DAQ cmd = %2u ", fvuStarDaqCmdLast[fuCurrDpbIdx])
1265  << Form("TRG cmd = %2u ", fvuStarTrigCmdLast[fuCurrDpbIdx])
1266  << Form("TRG Wrd = %5x ", uTrigWord);
1267  return;
1268  } // if exactly same message repeated
1269 
1270  // STAR TS counter reset detection
1271  if (ulNewStarTsFull < fvulStarTsFullLast[fuCurrDpbIdx])
1272  LOG(info) << "Probable reset of the STAR TS: old = "
1273  << Form("%16llu", fvulStarTsFullLast[fuCurrDpbIdx])
1274  << " new = " << Form("%16llu", ulNewStarTsFull) << " Diff = -"
1275  << Form("%8llu",
1276  fvulStarTsFullLast[fuCurrDpbIdx] - ulNewStarTsFull);
1277 
1278  // ULong64_t ulGdpbTsDiff = ulNewGdpbTsFull - fvulGdpbTsFullLast[ fuCurrDpbIdx ];
1279  fvulGdpbTsFullLast[fuCurrDpbIdx] = ulNewGdpbTsFull;
1280  fvulStarTsFullLast[fuCurrDpbIdx] = ulNewStarTsFull;
1281  fvuStarTokenLast[fuCurrDpbIdx] = uNewToken;
1282  fvuStarDaqCmdLast[fuCurrDpbIdx] = uNewDaqCmd;
1283  fvuStarTrigCmdLast[fuCurrDpbIdx] = uNewTrigCmd;
1284 
1286  if (fuMsIndex < fuNbCoreMsPerTs) {
1288  if (0 <= fdStartTime) {
1296  } // if( 0 < fdStartTime )
1299  } // if( fuMsIndex < fuNbCoreMsPerTs )
1300 
1301  break;
1302  } // case 3
1303  default: LOG(error) << "Unknown Star Trigger messageindex: " << iMsgIndex;
1304  } // switch( iMsgIndex )
1305 }
1306 // -------------------------------------------------------------------------
1307 
1309  std::string sFolder = "eTofMoni";
1310 
1311  LOG(info) << "create Histos for eTOF monitoring ";
1312 
1314  // Number of log bins =
1315  // 9 for the sub-unit decade
1316  // + 9 for each unit of each decade * 10 for the subdecade range
1317  // + 1 for the closing bin top edge
1318  const Int_t iNbDecadesLog = 4;
1319  const Int_t iNbStepsDecade = 9;
1320  const Int_t iNbSubStepsInStep = 1;
1321  const Int_t iNbBinsLog =
1322  iNbStepsDecade + iNbStepsDecade * iNbSubStepsInStep * iNbDecadesLog + 1;
1323  Double_t dBinsLog[iNbBinsLog];
1324  // First fill sub-unit decade
1325  for (Int_t iSubU = 0; iSubU < iNbStepsDecade; iSubU++)
1326  dBinsLog[iSubU] = 0.1 * (1 + iSubU);
1327  std::cout << std::endl;
1328  // Then fill the main decades
1329  Double_t dSubstepSize = 1.0 / iNbSubStepsInStep;
1330  for (Int_t iDecade = 0; iDecade < iNbDecadesLog; iDecade++) {
1331  Double_t dBase = std::pow(10, iDecade);
1332  Int_t iDecadeIdx =
1333  iNbStepsDecade + iDecade * iNbStepsDecade * iNbSubStepsInStep;
1334  for (Int_t iStep = 0; iStep < iNbStepsDecade; iStep++) {
1335  Int_t iStepIdx = iDecadeIdx + iStep * iNbSubStepsInStep;
1336  for (Int_t iSubStep = 0; iSubStep < iNbSubStepsInStep; iSubStep++) {
1337  dBinsLog[iStepIdx + iSubStep] =
1338  dBase * (1 + iStep) + dBase * dSubstepSize * iSubStep;
1339  } // for( Int_t iSubStep = 0; iSubStep < iNbSubStepsInStep; iSubStep++ )
1340  } // for( Int_t iStep = 0; iStep < iNbStepsDecade; iStep++ )
1341  } // for( Int_t iDecade = 0; iDecade < iNbDecadesLog; iDecade ++)
1342  dBinsLog[iNbBinsLog - 1] = std::pow(10, iNbDecadesLog);
1343 
1344  /*******************************************************************/
1345  fhMessType = new TH1I("hMessageType",
1346  "Nb of message for each type; Type",
1348  0.,
1350  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_HIT, "HIT");
1351  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_EPOCH, "EPOCH");
1352  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_SLOWC, "SLOWC");
1353  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_SYST, "SYST");
1354  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_A, "TRI_A");
1355  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_B, "TRI_B");
1356  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_C, "TRI_C");
1357  fhMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_D, "TRI_D");
1358 
1359  fhSysMessType = new TH1I("hSysMessType",
1360  "Nb of system message for each type; System Type",
1362  0.,
1363  1 + gdpbv100::SYS_PATTERN);
1364  fhSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GET4_ERROR,
1365  "GET4 ERROR");
1366  fhSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GDPB_UNKWN,
1367  "UNKW GET4 MSG");
1368  fhSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GET4_SYNC_MISS,
1369  "SYS_GET4_SYNC_MISS");
1370  fhSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_PATTERN,
1371  "SYS_PATTERN");
1372 
1373  fhGet4MessType =
1374  new TH2I("hGet4MessType",
1375  "Nb of message for each type per GET4; GET4 chip # ; Type",
1376  fuNrOfGet4,
1377  0.,
1378  fuNrOfGet4,
1379  4,
1380  0.,
1381  4.);
1382  fhGet4MessType->GetYaxis()->SetBinLabel(1, "DATA 32b");
1383  fhGet4MessType->GetYaxis()->SetBinLabel(2, "EPOCH");
1384  fhGet4MessType->GetYaxis()->SetBinLabel(3, "S.C. M");
1385  fhGet4MessType->GetYaxis()->SetBinLabel(4, "ERROR");
1386  // fhGet4MessType->GetYaxis()->SetBinLabel( 5, "DATA 24b");
1387  // fhGet4MessType->GetYaxis()->SetBinLabel( 6, "STAR Trigger");
1388 
1389  fhGet4ChanScm =
1390  new TH2I("hGet4ChanScm",
1391  "SC messages per GET4 channel; GET4 channel # ; SC type",
1393  0.,
1395  5,
1396  0.,
1397  5.);
1398  fhGet4ChanScm->GetYaxis()->SetBinLabel(1, "Hit Scal");
1399  fhGet4ChanScm->GetYaxis()->SetBinLabel(2, "Deadtime");
1400  fhGet4ChanScm->GetYaxis()->SetBinLabel(3, "SPI");
1401  fhGet4ChanScm->GetYaxis()->SetBinLabel(4, "SEU Scal");
1402  fhGet4ChanScm->GetYaxis()->SetBinLabel(5, "START");
1403 
1405  new TH2I("hGet4ChanErrors",
1406  "Error messages per GET4 channel; GET4 channel # ; Error",
1408  0.,
1410  21,
1411  0.,
1412  21.);
1413  fhGet4ChanErrors->GetYaxis()->SetBinLabel(1, "0x00: Readout Init ");
1414  fhGet4ChanErrors->GetYaxis()->SetBinLabel(2, "0x01: Sync ");
1415  fhGet4ChanErrors->GetYaxis()->SetBinLabel(3, "0x02: Epoch count sync");
1416  fhGet4ChanErrors->GetYaxis()->SetBinLabel(4, "0x03: Epoch ");
1417  fhGet4ChanErrors->GetYaxis()->SetBinLabel(5, "0x04: FIFO Write ");
1418  fhGet4ChanErrors->GetYaxis()->SetBinLabel(6, "0x05: Lost event ");
1419  fhGet4ChanErrors->GetYaxis()->SetBinLabel(7, "0x06: Channel state ");
1420  fhGet4ChanErrors->GetYaxis()->SetBinLabel(8, "0x07: Token Ring state");
1421  fhGet4ChanErrors->GetYaxis()->SetBinLabel(9, "0x08: Token ");
1422  fhGet4ChanErrors->GetYaxis()->SetBinLabel(10, "0x09: Error Readout ");
1423  fhGet4ChanErrors->GetYaxis()->SetBinLabel(11, "0x0a: SPI ");
1424  fhGet4ChanErrors->GetYaxis()->SetBinLabel(
1425  12, "0x0b: DLL Lock error "); // <- From GET4 v1.2
1426  fhGet4ChanErrors->GetYaxis()->SetBinLabel(
1427  13, "0x0c: DLL Reset invoc."); // <- From GET4 v1.2
1428  fhGet4ChanErrors->GetYaxis()->SetBinLabel(14, "0x11: Overwrite ");
1429  fhGet4ChanErrors->GetYaxis()->SetBinLabel(15, "0x12: ToT out of range");
1430  fhGet4ChanErrors->GetYaxis()->SetBinLabel(16, "0x13: Event Discarded ");
1431  fhGet4ChanErrors->GetYaxis()->SetBinLabel(
1432  17, "0x14: Add. Rising edge"); // <- From GET4 v1.3
1433  fhGet4ChanErrors->GetYaxis()->SetBinLabel(
1434  18, "0x15: Unpaired Falling"); // <- From GET4 v1.3
1435  fhGet4ChanErrors->GetYaxis()->SetBinLabel(
1436  19, "0x16: Sequence error "); // <- From GET4 v1.3
1437  fhGet4ChanErrors->GetYaxis()->SetBinLabel(20, "0x7f: Unknown ");
1438  fhGet4ChanErrors->GetYaxis()->SetBinLabel(21, "Corrupt/unsuprtd error");
1439 
1440  fhGet4EpochFlags = new TH2I("hGet4EpochFlags",
1441  "Epoch flags per GET4; GET4 chip # ; Type",
1442  fuNrOfGet4,
1443  0.,
1444  fuNrOfGet4,
1445  4,
1446  0.,
1447  4.);
1448  fhGet4EpochFlags->GetYaxis()->SetBinLabel(1, "SYNC");
1449  fhGet4EpochFlags->GetYaxis()->SetBinLabel(2, "Ep LOSS");
1450  fhGet4EpochFlags->GetYaxis()->SetBinLabel(3, "Da LOSS");
1451  fhGet4EpochFlags->GetYaxis()->SetBinLabel(4, "MISSMAT");
1452 
1453  Double_t dSectorMin = -0.5 + fUnpackPar->GetGdpbToSectorOffset();
1454  Double_t dSectorMax = fuNrOfGdpbs + dSectorMin;
1455  fhGdpbAsicSpiCounts = new TH2I(
1456  "hGdpbAsicSpiCounts",
1457  "SPI messages count per Sector and ASIC; ASIC Idx []; Sector []; SPI msg[]",
1459  -0.5,
1460  fuNrOfGet4PerGdpb - 0.5,
1461  fuNrOfGdpbs,
1462  dSectorMin,
1463  dSectorMax);
1464 
1465  fhGdpbMessType =
1466  new TH2I("hGdpbMessageType",
1467  "Nb of message for each type per Sector; Type; Sector []",
1469  0.,
1471  fuNrOfGdpbs,
1472  dSectorMin,
1473  dSectorMax);
1474  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_HIT, "HIT");
1475  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_EPOCH, "EPOCH");
1476  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_SLOWC, "SLOWC");
1477  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_SYST, "SYST");
1478  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_A,
1479  "TRI_A");
1480  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_B,
1481  "TRI_B");
1482  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_C,
1483  "TRI_C");
1484  fhGdpbMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::MSG_STAR_TRI_D,
1485  "TRI_D");
1486 
1487  fhGdpbSysMessType = new TH2I(
1488  "hGdpbSysMessType",
1489  "Nb of system message for each type per Sector; System Type; Sector []",
1491  0.,
1493  fuNrOfGdpbs,
1494  dSectorMin,
1495  dSectorMax);
1496  fhGdpbSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GET4_ERROR,
1497  "GET4 ERROR");
1498  fhGdpbSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GDPB_UNKWN,
1499  "UNKW GET4 MSG");
1500  fhGdpbSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_GET4_SYNC_MISS,
1501  "SYS_GET4_SYNC_MISS");
1502  fhGdpbSysMessType->GetXaxis()->SetBinLabel(1 + gdpbv100::SYS_PATTERN,
1503  "SYS_PATTERN");
1504 
1505  fhGdpbSysMessPattType = new TH2I(
1506  "hGdpbSysMessPattType",
1507  "Nb of pattern message for each type per Sector; Pattern Type; Sector []",
1509  0.,
1511  fuNrOfGdpbs,
1512  dSectorMin,
1513  dSectorMax);
1514  fhGdpbSysMessPattType->GetXaxis()->SetBinLabel(1 + gdpbv100::PATT_MISSMATCH,
1515  "PATT_MISSMATCH");
1516  fhGdpbSysMessPattType->GetXaxis()->SetBinLabel(1 + gdpbv100::PATT_ENABLE,
1517  "PATT_ENABLE");
1518  fhGdpbSysMessPattType->GetXaxis()->SetBinLabel(1 + gdpbv100::PATT_RESYNC,
1519  "PATT_RESYNC");
1520 
1521  fhGdpbEpochFlags = new TH2I("hGdpbEpochFlags",
1522  "Epoch flags per Sector; Sector # ; Type",
1523  fuNrOfGdpbs,
1524  dSectorMin,
1525  dSectorMax,
1526  4,
1527  0.,
1528  4.);
1529  fhGdpbEpochFlags->GetYaxis()->SetBinLabel(1, "SYNC");
1530  fhGdpbEpochFlags->GetYaxis()->SetBinLabel(2, "Ep LOSS");
1531  fhGdpbEpochFlags->GetYaxis()->SetBinLabel(3, "Da LOSS");
1532  fhGdpbEpochFlags->GetYaxis()->SetBinLabel(4, "MISSMAT");
1533 
1535  new TH2D("hGdpbEpochSyncEvo",
1536  "Epoch SYNC per second and Sector; Time[s]; Sector #; SYNC Nb",
1538  0,
1540  fuNrOfGdpbs,
1541  dSectorMin,
1542  dSectorMax);
1543 
1544  fhGdpbEpochMissEvo = new TH2D(
1545  "hGdpbEpochMissEvo",
1546  "Epoch Missmatch per second and Sector; Time[s]; Sector #; Missmatch Nb",
1548  0,
1550  fuNrOfGdpbs,
1551  dSectorMin,
1552  dSectorMax);
1553 
1554  fhGdpbEndMsBufferNotEmpty = new TH1D(
1555  "hGdpbEndMsBufferNotEmpty",
1556  "MS where buffer is not empty at end, per Sector; Sector #; Bad MS",
1557  fuNrOfGdpbs,
1558  dSectorMin,
1559  dSectorMax);
1560 
1562  new TH2D("hGdpbEndMsDataLost",
1563  "Amount of lost data when buffer not empty at end, per MS and "
1564  "Sector; Sector #; Lost Data per bad MS []; Bad MS",
1565  fuNrOfGdpbs,
1566  dSectorMin,
1567  dSectorMax,
1568  iNbBinsLog - 1,
1569  dBinsLog);
1570 
1571  if (kTRUE == fbDebugMonitorMode) {
1573  new TH2I("hNbMissPatternPerMs",
1574  "Nb of missmatch pattern per MS for each sector; Number of "
1575  "pattern messages []; sector []; MS",
1576  1000,
1577  -0.5,
1578  999.5,
1579  fuNrOfGdpbs,
1580  dSectorMin,
1581  dSectorMax);
1582 
1583  fhPatternMissmatch = new TH2I(
1584  "hPatternMissmatch",
1585  "Missmatch pattern integral per Sector; ASIC Pattern []; Sector []",
1587  0.,
1589  fuNrOfGdpbs,
1590  dSectorMin,
1591  dSectorMax);
1592 
1593  fhPatternEnable =
1594  new TH2I("hPatternEnable",
1595  "Enable pattern integral per Sector; ASIC Pattern []; Sector []",
1597  0.,
1599  fuNrOfGdpbs,
1600  dSectorMin,
1601  dSectorMax);
1602 
1603  fhPatternResync =
1604  new TH2I("hPatternResync",
1605  "Resync pattern integral per Sector; ASIC Pattern []; Sector []",
1607  0.,
1609  fuNrOfGdpbs,
1610  dSectorMin,
1611  dSectorMax);
1612  } // if( kTRUE == fbDebugMonitorMode )
1613 
1615  AddHistoToVector(fhMessType, sFolder);
1616  AddHistoToVector(fhSysMessType, sFolder);
1618  AddHistoToVector(fhGet4MessType, sFolder);
1619  AddHistoToVector(fhGet4ChanScm, sFolder);
1624  AddHistoToVector(fhGdpbMessType, sFolder);
1634  if (kTRUE == fbDebugMonitorMode) {
1639  } // if( kTRUE == fbDebugMonitorMode )
1640 
1641  /*******************************************************************/
1642  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
1643  UInt_t uSectorIndex = uGdpb + fUnpackPar->GetGdpbToSectorOffset();
1644  if (-1 < fiSectorIndex) uSectorIndex += fiSectorIndex;
1645 
1646  std::string sFolderSector = Form("sector%02u", uSectorIndex);
1647  std::string sFolderSectorPatt = Form("sector%02u/Pattern", uSectorIndex);
1648  std::string sFolderSectorTrig = Form("sector%02u/Trigger", uSectorIndex);
1649 
1650  fvhGdpbGet4MessType.push_back(
1651  new TH2I(Form("hGdpbGet4MessType_%02u", uGdpb),
1652  Form("Nb of message for each type per GET4 in Sector %02u; GET4 "
1653  "chip # ; Type",
1654  uSectorIndex),
1656  0.,
1658  4,
1659  0.,
1660  4.));
1661  fvhGdpbGet4MessType[uGdpb]->GetYaxis()->SetBinLabel(1, "DATA 32b");
1662  fvhGdpbGet4MessType[uGdpb]->GetYaxis()->SetBinLabel(2, "EPOCH");
1663  fvhGdpbGet4MessType[uGdpb]->GetYaxis()->SetBinLabel(3, "S.C. M");
1664  fvhGdpbGet4MessType[uGdpb]->GetYaxis()->SetBinLabel(4, "ERROR");
1665 
1666  fvhGdpbGet4ChanScm.push_back(new TH2I(
1667  Form("hGdpbGet4ChanScm_%02u", uGdpb),
1668  Form(
1669  "SC messages per GET4 channel in Sector %02u; GET4 channel # ; SC type",
1670  uSectorIndex),
1672  0.,
1674  5,
1675  0.,
1676  5.));
1677  fvhGdpbGet4ChanScm[uGdpb]->GetYaxis()->SetBinLabel(1, "Hit Scal");
1678  fvhGdpbGet4ChanScm[uGdpb]->GetYaxis()->SetBinLabel(2, "Deadtime");
1679  fvhGdpbGet4ChanScm[uGdpb]->GetYaxis()->SetBinLabel(3, "SPI");
1680  fvhGdpbGet4ChanScm[uGdpb]->GetYaxis()->SetBinLabel(4, "SEU Scal");
1681  fvhGdpbGet4ChanScm[uGdpb]->GetYaxis()->SetBinLabel(5, "START");
1682 
1683  fvhGdpbGet4ChanErrors.push_back(
1684  new TH2I(Form("hGdpbGet4ChanErrors_%02u", uGdpb),
1685  Form("Error messages per GET4 channel in Sector %02u; GET4 "
1686  "channel # ; Error",
1687  uSectorIndex),
1689  0.,
1691  22,
1692  0.,
1693  22.));
1694  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1695  1, "0x00: Readout Init ");
1696  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1697  2, "0x01: Sync ");
1698  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1699  3, "0x02: Epoch count sync");
1700  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1701  4, "0x03: Epoch ");
1702  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1703  5, "0x04: FIFO Write ");
1704  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1705  6, "0x05: Lost event ");
1706  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1707  7, "0x06: Channel state ");
1708  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1709  8, "0x07: Token Ring state");
1710  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1711  9, "0x08: Token ");
1712  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1713  10, "0x09: Error Readout ");
1714  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1715  11, "0x0a: SPI ");
1716  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1717  12, "0x0b: DLL Lock error "); // <- From GET4 v1.2
1718  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1719  13, "0x0c: DLL Reset invoc."); // <- From GET4 v1.2
1720  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1721  14, "0x11: Overwrite "); // <- From GET4 v1.0 to 1.3
1722  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1723  15, "0x12: ToT out of range");
1724  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1725  16, "0x13: Event Discarded ");
1726  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1727  17, "0x14: Add. Rising edge"); // <- From GET4 v1.3
1728  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1729  18, "0x15: Unpaired Falling"); // <- From GET4 v1.3
1730  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1731  19, "0x16: Sequence error "); // <- From GET4 v1.3
1732  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1733  20, "0x17: Epoch Overflow "); // <- From GET4 v2.0
1734  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1735  21, "0x7f: Unknown ");
1736  fvhGdpbGet4ChanErrors[uGdpb]->GetYaxis()->SetBinLabel(
1737  22, "Corrupt/unsuprtd error");
1738 
1740  if (kTRUE == fbDebugMonitorMode) {
1741  fvhRawFt_gDPB.push_back(new TH2I(
1742  Form("RawFt_gDPB_%02u", uSectorIndex),
1743  Form("Raw FineTime Sector %02u Plot 0; channel; FineTime [bin]",
1744  uSectorIndex),
1746  0,
1748  128,
1749  0,
1750  128));
1751 
1752  fvhRawCt_gDPB.push_back(new TH2I(
1753  Form("RawCt_gDPB_%02u", uSectorIndex),
1754  Form("Raw CoarseTime Sector %02u Plot 0; channel; CoarseTime [bin]",
1755  uSectorIndex),
1757  0,
1759  4096,
1760  0,
1761  4096));
1762  } // if( kTRUE == fbDebugMonitorMode )
1763 
1764  fvhRemapTot_gDPB.push_back(
1765  new TH2I(Form("RemapTot_gDPB_%02u", uSectorIndex),
1766  Form("Raw TOT Sector %02u remapped; PADI channel; TOT [bin]",
1767  uSectorIndex),
1769  0,
1771  256,
1772  0,
1773  256));
1774 
1775  fvhRemapChCount_gDPB.push_back(
1776  new TH1I(Form("RemapChCount_gDPB_%02u", uSectorIndex),
1777  Form("Channel counts Sector %02u remapped; PADI channel; Hits",
1778  uSectorIndex),
1780  0,
1782 
1783  fvhRemapChRate_gDPB.push_back(
1784  new TH2D(Form("RemapChRate_gDPB_%02u", uSectorIndex),
1785  Form("PADI channel rate Sector %02u; Time in run [s]; PADI "
1786  "channel; Rate [1/s]",
1787  uSectorIndex),
1789  0,
1792  0,
1794 
1796  if (kTRUE == fbDebugMonitorMode) {
1797  fvhGdpbPatternMissmatchEvo.push_back(
1798  new TH2I(Form("hGdpbPatternMissmatchEvo_%02u", uSectorIndex),
1799  Form("Missmatch pattern vs TS index in Sector %02u; TS # ; "
1800  "ASIC Pattern []",
1801  uSectorIndex),
1802  10000,
1803  0.,
1804  100000,
1806  0.,
1808 
1809  fvhGdpbPatternEnableEvo.push_back(new TH2I(
1810  Form("hGdpbPatternEnableEvo_%02u", uSectorIndex),
1811  Form(
1812  "Enable pattern vs TS index in Sector %02u; TS # ; ASIC Pattern []",
1813  uSectorIndex),
1814  10000,
1815  0.,
1816  100000,
1818  0.,
1820 
1821  fvhGdpbPatternResyncEvo.push_back(new TH2I(
1822  Form("hGdpbPatternResyncEvo%02u", uSectorIndex),
1823  Form(
1824  "Resync pattern vs TS index in Sector %02u; TS # ; ASIC Pattern []",
1825  uSectorIndex),
1826  10000,
1827  0.,
1828  100000,
1830  0.,
1832 
1833  fvhGdpbMissmatchEvoPerTs.push_back(new TH2I(
1834  Form("hGdpbMissmatchEvoPerTs%02u", uSectorIndex),
1835  Form(
1836  "Missmatch vs TS index in Sector %02u; TS # ; Asic []; Missmatch? []",
1837  uSectorIndex),
1838  10000,
1839  0.,
1840  100000,
1842  0.,
1844 
1845  fvhGdpbMissmatchEnaEvoPerTs.push_back(
1846  new TH2I(Form("hGdpbMissmatchEnaEvoPerTs%02u", uSectorIndex),
1847  Form("Enable+Missmatch vs TS index in Sector %02u; TS # ; "
1848  "Asic []; Enabled & Missmatch? []",
1849  uSectorIndex),
1850  10000,
1851  0.,
1852  100000,
1854  0.,
1856 
1857  fvhGdpbEnableEvoPerTs.push_back(new TH2I(
1858  Form("hGdpbEnableEvoPerTs%02u", uSectorIndex),
1859  Form("Enable vs TS index in Sector %02u; TS # ; Asic []; Enabled? []",
1860  uSectorIndex),
1861  100000,
1862  0.,
1863  100000,
1865  0.,
1867 
1868  fvhGdpbResyncEvoPerTs.push_back(new TH2I(
1869  Form("hGdpbResyncEvoPerTs%02u", uSectorIndex),
1870  Form("Resync vs TS index in Sector %02u; TS # ; Asic []; Resync? []",
1871  uSectorIndex),
1872  10000,
1873  0.,
1874  100000,
1876  0.,
1878 
1879  fvhGdpbResyncEnaEvoPerTs.push_back(
1880  new TH2I(Form("hGdpbResyncEnaEvoPerTs%02u", uSectorIndex),
1881  Form("Enable+Resync vs TS index in Sector %02u; TS # ; Asic "
1882  "[]; Enabled & Resync? []",
1883  uSectorIndex),
1884  10000,
1885  0.,
1886  100000,
1888  0.,
1890 
1891  fvhGdpbStateEvoPerTs.push_back(new TH2I(
1892  Form("hGdpbStateEvoPerTs%02u", uSectorIndex),
1893  Form("ASIC State vs TS index in Sector %02u; TS # ; Asic []; 0 = Off, "
1894  "1 = OK, 2 = Miss, 3 = Resync, 4 = Miss + Resync []",
1895  uSectorIndex),
1896  100000,
1897  0.,
1898  100000,
1900  0.,
1902  } // if( kTRUE == fbDebugMonitorMode )
1903 
1906  fvhTokenMsgType.push_back(
1907  new TH1F(Form("hTokenMsgType_gDPB_%02u", uSectorIndex),
1908  Form("STAR trigger Messages type Sector %02u; Type ; Counts",
1909  uSectorIndex),
1910  4,
1911  0,
1912  4));
1913  fvhTokenMsgType[uGdpb]->GetXaxis()->SetBinLabel(1, "A"); // gDPB TS high
1914  fvhTokenMsgType[uGdpb]->GetXaxis()->SetBinLabel(
1915  2, "B"); // gDPB TS low, STAR TS high
1916  fvhTokenMsgType[uGdpb]->GetXaxis()->SetBinLabel(3, "C"); // STAR TS mid
1917  fvhTokenMsgType[uGdpb]->GetXaxis()->SetBinLabel(
1918  4, "D"); // STAR TS low, token, CMDs
1919 
1920  fvhTriggerRate.push_back(new TH1F(
1921  Form("hTriggerRate_gDPB_%02u", uSectorIndex),
1922  Form("STAR trigger signals per second Sector %02u; Time[s] ; Counts",
1923  uSectorIndex),
1925  0,
1927 
1928  fvhCmdDaqVsTrig.push_back(new TH2I(
1929  Form("hCmdDaqVsTrig_gDPB_%02u", uSectorIndex),
1930  Form(
1931  "STAR daq command VS STAR trigger command Sector %02u; DAQ ; TRIGGER",
1932  uSectorIndex),
1933  16,
1934  0,
1935  16,
1936  16,
1937  0,
1938  16));
1939  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1940  1, "0x0: no-trig "); // idle link
1941  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1942  2, "0x1: clear "); // clears redundancy counters on the readout boards
1943  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1944  3, "0x2: mast-rst"); // general reset of the whole front-end logic
1945  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1946  4, "0x3: spare "); // reserved
1947  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1948  5, "0x4: trigg. 0"); // Default physics readout, all det support required
1949  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(6, "0x5: trigg. 1"); //
1950  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(7, "0x6: trigg. 2"); //
1951  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(8, "0x7: trigg. 3"); //
1952  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(9, "0x8: puls. 0"); //
1953  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(10, "0x9: puls. 1"); //
1954  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(11, "0xA: puls. 2"); //
1955  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(12, "0xB: puls. 3"); //
1956  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1957  13,
1958  "0xC: config "); // housekeeping trigger: return geographic info of FE
1959  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(
1960  14, "0xD: abort "); // aborts and clears an active event
1961  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(15, "0xE: L1accept"); //
1962  fvhCmdDaqVsTrig[uGdpb]->GetXaxis()->SetBinLabel(16, "0xF: L2accept"); //
1963  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1964  1, "0x0: 0"); // To be filled at STAR
1965  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1966  2, "0x1: 1"); // To be filled at STAR
1967  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1968  3, "0x2: 2"); // To be filled at STAR
1969  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1970  4, "0x3: 3"); // To be filled at STAR
1971  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1972  5, "0x4: 4"); // To be filled at STAR
1973  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1974  6, "0x5: 5"); // To be filled at STAR
1975  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1976  7, "0x6: 6"); // To be filled at STAR
1977  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1978  8, "0x7: 7"); // To be filled at STAR
1979  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1980  9, "0x8: 8"); // To be filled at STAR
1981  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1982  10, "0x9: 9"); // To be filled at STAR
1983  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1984  11, "0xA: 10"); // To be filled at STAR
1985  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1986  12, "0xB: 11"); // To be filled at STAR
1987  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1988  13, "0xC: 12"); // To be filled at STAR
1989  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1990  14, "0xD: 13"); // To be filled at STAR
1991  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1992  15, "0xE: 14"); // To be filled at STAR
1993  fvhCmdDaqVsTrig[uGdpb]->GetYaxis()->SetBinLabel(
1994  16, "0xF: 15"); // To be filled at STAR
1995 
1996  fvhStarTokenEvo.push_back(
1997  new TH2I(Form("hStarTokenEvo_gDPB_%02u", uSectorIndex),
1998  Form("STAR token value VS time Sector %02u; Time in Run [s] ; "
1999  "STAR Token; Counts",
2000  uSectorIndex),
2002  0,
2004  410,
2005  0,
2006  4100));
2007 
2008  fvhStarTrigGdpbTsEvo.push_back(
2009  new TProfile(Form("hStarTrigGdpbTsEvo_gDPB_%02u", uSectorIndex),
2010  Form("gDPB TS in STAR triger tokens for Sector %02u; Time "
2011  "in Run [s] ; gDPB TS;",
2012  uSectorIndex),
2014  0,
2016 
2017  fvhStarTrigStarTsEvo.push_back(
2018  new TProfile(Form("hStarTrigStarTsEvo_gDPB_%02u", uSectorIndex),
2019  Form("STAR TS in STAR triger tokens for Sector %02u; Time "
2020  "in Run [s] ; STAR TS;",
2021  uSectorIndex),
2023  0,
2025 
2026 
2029  AddHistoToVector(fvhGdpbGet4MessType[uGdpb], sFolderSector);
2030  AddHistoToVector(fvhGdpbGet4ChanScm[uGdpb], sFolderSector);
2031  AddHistoToVector(fvhGdpbGet4ChanErrors[uGdpb], sFolderSector);
2033  if (kTRUE == fbDebugMonitorMode) {
2034  AddHistoToVector(fvhRawFt_gDPB[uGdpb], sFolderSector);
2035  AddHistoToVector(fvhRawCt_gDPB[uGdpb], sFolderSector);
2036  } // if( kTRUE == fbDebugMonitorMode )
2037  AddHistoToVector(fvhRemapTot_gDPB[uGdpb], sFolderSector);
2038  AddHistoToVector(fvhRemapChCount_gDPB[uGdpb], sFolderSector);
2039  AddHistoToVector(fvhRemapChRate_gDPB[uGdpb], sFolderSector);
2040  if (kTRUE == fbDebugMonitorMode) {
2042  AddHistoToVector(fvhGdpbPatternMissmatchEvo[uGdpb], sFolderSectorPatt);
2043  AddHistoToVector(fvhGdpbPatternEnableEvo[uGdpb], sFolderSectorPatt);
2044  AddHistoToVector(fvhGdpbPatternResyncEvo[uGdpb], sFolderSectorPatt);
2046  AddHistoToVector(fvhGdpbMissmatchEvoPerTs[uGdpb], sFolderSectorPatt);
2047  AddHistoToVector(fvhGdpbMissmatchEnaEvoPerTs[uGdpb], sFolderSectorPatt);
2048  AddHistoToVector(fvhGdpbEnableEvoPerTs[uGdpb], sFolderSectorPatt);
2049  AddHistoToVector(fvhGdpbResyncEvoPerTs[uGdpb], sFolderSectorPatt);
2050  AddHistoToVector(fvhGdpbResyncEnaEvoPerTs[uGdpb], sFolderSectorPatt);
2051  AddHistoToVector(fvhGdpbStateEvoPerTs[uGdpb], sFolderSectorPatt);
2052  } // if( kTRUE == fbDebugMonitorMode )
2054  AddHistoToVector(fvhTokenMsgType[uGdpb], sFolderSectorTrig);
2055  AddHistoToVector(fvhTriggerRate[uGdpb], sFolderSectorTrig);
2056  AddHistoToVector(fvhCmdDaqVsTrig[uGdpb], sFolderSectorTrig);
2057  AddHistoToVector(fvhStarTokenEvo[uGdpb], sFolderSectorTrig);
2058  AddHistoToVector(fvhStarTrigGdpbTsEvo[uGdpb], sFolderSectorTrig);
2059  AddHistoToVector(fvhStarTrigStarTsEvo[uGdpb], sFolderSectorTrig);
2060  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
2061 
2062  /*******************************************************************/
2063  fhMsgCntEvo = new TH1I("hMsgCntEvo",
2064  "Evolution of Hit & error msgs counts vs time in run; "
2065  "Time in run [s]; Msgs Count []",
2067  0,
2069  fhHitCntEvo = new TH1I(
2070  "hHitCntEvo",
2071  "Evolution of Hit counts vs time in run; Time in run [s]; Hits Count []",
2073  0,
2075  fhErrorCntEvo = new TH1I(
2076  "hErrorCntEvo",
2077  "Evolution of Error counts vs time in run; Time in run [s]; Error Count []",
2079  0,
2081  fhLostEvtCntEvo = new TH1I("hLostEvtCntEvo",
2082  "Evolution of LostEvent counts vs time in run; "
2083  "Time in run [s]; LostEvent Count []",
2085  0,
2087 
2088  fhErrorFractEvo = new TProfile("hErrorFractEvo",
2089  "Evolution of Error Fraction vs time in run; "
2090  "Time in run [s]; Error Fract []",
2092  0,
2094  fhLostEvtFractEvo = new TProfile("hLostEvtFractEvo",
2095  "Evolution of LostEvent Fraction vs time in "
2096  "run; Time in run [s]; LostEvent Fract []",
2098  0,
2100 
2102  new TH2I("hMsgCntPerMsEvo",
2103  "Evolution of Hit & error msgs counts, per MS vs time in run; "
2104  "Time in run [s]; Hits Count/MS []; MS",
2106  0,
2108  iNbBinsLog - 1,
2109  dBinsLog);
2110  fhHitCntPerMsEvo = new TH2I("hHitCntPerMsEvo",
2111  "Evolution of Hit counts, per MS vs time in run; "
2112  "Time in run [s]; Hits Count/MS []; MS",
2114  0,
2116  iNbBinsLog - 1,
2117  dBinsLog);
2118  fhErrorCntPerMsEvo = new TH2I("hErrorCntPerMsEvo",
2119  "Evolution of Error counts, per MS vs time in "
2120  "run; Time in run [s]; Error Count/MS []; MS",
2122  0,
2124  iNbBinsLog - 1,
2125  dBinsLog);
2127  new TH2I("hLostEvtCntPerMsEvo",
2128  "Evolution of LostEvent, per MS counts vs time in run; Time in "
2129  "run [s]; LostEvent Count/MS []; MS",
2131  0,
2133  iNbBinsLog - 1,
2134  dBinsLog);
2135 
2137  new TH2I("hErrorFractPerMsEvo",
2138  "Evolution of Error Fraction, per MS vs time in run; Time in run "
2139  "[s]; Error Fract/MS []; MS",
2141  0,
2143  1000,
2144  0,
2145  1);
2147  new TH2I("hLostEvtFractPerMsEvo",
2148  "Evolution of LostEvent Fraction, per MS vs time in run; Time in "
2149  "run [s]; LostEvent Fract/MS []; MS",
2151  0,
2153  1000,
2154  0,
2155  1);
2156 
2158  AddHistoToVector(fhMsgCntEvo, sFolder);
2159  AddHistoToVector(fhHitCntEvo, sFolder);
2160  AddHistoToVector(fhErrorCntEvo, sFolder);
2162 
2165 
2171 
2172  /*******************************************************************/
2173 
2174  /*******************************************************************/
2177  fcSummary = new TCanvas("cSummary", "gDPB Monitoring Summary");
2178  fcSummary->Divide(2, 3);
2179 
2180  // 1st Column: Messages types
2181  fcSummary->cd(1);
2182  gPad->SetGridx();
2183  gPad->SetGridy();
2184  gPad->SetLogy();
2185  fhMessType->Draw();
2186 
2187  fcSummary->cd(2);
2188  gPad->SetGridx();
2189  gPad->SetGridy();
2190  gPad->SetLogy();
2191  fhSysMessType->Draw();
2192 
2193  fcSummary->cd(3);
2194  gPad->SetGridx();
2195  gPad->SetGridy();
2196  gPad->SetLogz();
2197  fhGet4MessType->Draw("colz");
2198 
2199  // 2nd Column: GET4 Errors + Epoch flags + SCm
2200  fcSummary->cd(4);
2201  gPad->SetGridx();
2202  gPad->SetGridy();
2203  gPad->SetLogz();
2204  fhGet4ChanErrors->Draw("colz");
2205 
2206  fcSummary->cd(5);
2207  gPad->SetGridx();
2208  gPad->SetGridy();
2209  gPad->SetLogz();
2210  fhGet4EpochFlags->Draw("colz");
2211 
2212  fcSummary->cd(6);
2213  gPad->SetGridx();
2214  gPad->SetGridy();
2215  fhGet4ChanScm->Draw("colz");
2216 
2217  AddCanvasToVector(fcSummary, "canvases");
2219 
2221  fcSummaryGdpb = new TCanvas("cSummaryGdpb", "gDPB Monitoring Summary");
2222  fcSummaryGdpb->Divide(2, 3);
2223 
2224  fcSummaryGdpb->cd(1);
2225  gPad->SetGridx();
2226  gPad->SetGridy();
2227  gPad->SetLogz();
2228  fhGdpbMessType->Draw("colz");
2229 
2230  fcSummaryGdpb->cd(2);
2231  gPad->SetGridx();
2232  gPad->SetGridy();
2233  gPad->SetLogz();
2234  fhGdpbSysMessPattType->Draw("text colz");
2235 
2236  fcSummaryGdpb->cd(3);
2237  gPad->SetGridx();
2238  gPad->SetGridy();
2239  gPad->SetLogz();
2240  fhGdpbSysMessType->Draw("colz");
2241 
2242  fcSummaryGdpb->cd(5);
2243  gPad->SetGridx();
2244  gPad->SetGridy();
2245  gPad->SetLogz();
2246  fhGdpbEpochFlags->Draw("text colz");
2247 
2248  fcSummaryGdpb->cd(4);
2249  gPad->SetGridx();
2250  gPad->SetGridy();
2251  fhGdpbEpochSyncEvo->Draw("colz");
2252 
2253  fcSummaryGdpb->cd(6);
2254  gPad->SetGridx();
2255  gPad->SetGridy();
2256  gPad->SetLogz();
2257  fhGdpbEpochMissEvo->Draw("colz");
2258 
2259  AddCanvasToVector(fcSummaryGdpb, "canvases");
2261  fcStarTrigTokenType = new TCanvas(
2262  "cStarTrigTokenType", "STAR trigger token message type per sector");
2264  new TCanvas("cStarTriggerRate", "STAR trigger rate per sector");
2265  fcStarTrigCmdDaqVsTrig = new TCanvas("cStarTrigCmdDaqVsTrig",
2266  "STAR trigger command types per sector");
2267  fcStarTrigStarTokenEvo = new TCanvas(
2268  "cStarTrigStarTokenEvo", "STAR trigger token evolution per sector");
2270  new TCanvas("cStarTrigGdpbTsEvo", "STAR trigger gDPB TS evo per sector");
2272  new TCanvas("cStarTrigStarTsEvo", "STAR trigger STAR TS evo per sector");
2273 
2274  fcStarTrigTokenType->Divide(4, 3);
2275  fcStarTriggerRate->Divide(4, 3);
2276  fcStarTrigCmdDaqVsTrig->Divide(4, 3);
2277  fcStarTrigStarTokenEvo->Divide(4, 3);
2278  fcStarTrigGdpbTsEvo->Divide(4, 3);
2279  fcStarTrigStarTsEvo->Divide(4, 3);
2280 
2282  AddCanvasToVector(fcStarTriggerRate, "canvases");
2287 
2288  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
2289  UInt_t uSectorIndex = uGdpb + fUnpackPar->GetGdpbToSectorOffset();
2290  if (-1 < fiSectorIndex) uSectorIndex += fiSectorIndex;
2291 
2292  fvcSumGdpbGet4.push_back(new TCanvas(
2293  Form("cSumSector%02u", uSectorIndex),
2294  Form("Summary per GET4 or channel for sector %02u", uSectorIndex)));
2295  fvcSumGdpbGet4[uGdpb]->Divide(2, 2);
2296 
2297  fvcSumGdpbGet4[uGdpb]->cd(1);
2298  gPad->SetGridx();
2299  gPad->SetGridy();
2300  gPad->SetLogz();
2301  fvhGdpbGet4MessType[uGdpb]->Draw("colz");
2302 
2303  fvcSumGdpbGet4[uGdpb]->cd(2);
2304  gPad->SetGridx();
2305  gPad->SetGridy();
2306  gPad->SetLogz();
2307  fvhGdpbGet4ChanScm[uGdpb]->Draw("colz");
2308 
2309  fvcSumGdpbGet4[uGdpb]->cd(3);
2310  gPad->SetGridx();
2311  gPad->SetGridy();
2312  gPad->SetLogz();
2313  fvhGdpbGet4ChanErrors[uGdpb]->Draw("colz");
2314 
2315  fvcSumGdpbGet4[uGdpb]->cd(4);
2316  gPad->SetGridx();
2317  gPad->SetGridy();
2318  gPad->SetLogz();
2319  fvhRemapTot_gDPB[uGdpb]->Draw("colz");
2320 
2321 
2322  AddCanvasToVector(fvcSumGdpbGet4[uGdpb], "canvases");
2323 
2324  fcStarTrigTokenType->cd(1 + uGdpb);
2325  gPad->SetGridx();
2326  gPad->SetGridy();
2327  fvhTokenMsgType[uGdpb]->Draw("hist");
2328 
2329  fcStarTriggerRate->cd(1 + uGdpb);
2330  gPad->SetGridx();
2331  gPad->SetGridy();
2332  gPad->SetLogy();
2333  fvhTriggerRate[uGdpb]->Draw("hist");
2334 
2335  fcStarTrigCmdDaqVsTrig->cd(1 + uGdpb);
2336  gPad->SetGridx();
2337  gPad->SetGridy();
2338  gPad->SetLogz();
2339  fvhCmdDaqVsTrig[uGdpb]->Draw("colz");
2340 
2341  fcStarTrigStarTokenEvo->cd(1 + uGdpb);
2342  gPad->SetGridx();
2343  gPad->SetGridy();
2344  gPad->SetLogz();
2345  fvhStarTokenEvo[uGdpb]->Draw("colz");
2346 
2347  fcStarTrigGdpbTsEvo->cd(1 + uGdpb);
2348  gPad->SetGridx();
2349  gPad->SetGridy();
2350  fvhStarTrigGdpbTsEvo[uGdpb]->Draw("hist");
2351 
2352  fcStarTrigStarTsEvo->cd(1 + uGdpb);
2353  gPad->SetGridx();
2354  gPad->SetGridy();
2355  fvhStarTrigStarTsEvo[uGdpb]->Draw("hist");
2356  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
2357  /*******************************************************************/
2358 
2359  return kTRUE;
2360 }
2362  if (kTRUE == fbDebugMonitorMode) {
2364  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb)
2365  for (UInt_t uAsic = 0; uAsic < fuNrOfGet4PerGdpb; ++uAsic) {
2366  if (fvvbGdpbLastMissmatchPattern[uGdpb][uAsic]) {
2367  fvhGdpbMissmatchEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic);
2368  } // if( fvvbGdpbLastMissmatchPattern[ uGdpb ][ uAsic ] )
2369 
2370  if (fvvbGdpbLastEnablePattern[uGdpb][uAsic]) {
2371  fvhGdpbEnableEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic);
2372 
2373  if (fvvbGdpbLastMissmatchPattern[uGdpb][uAsic]) {
2374  fvhGdpbMissmatchEnaEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic);
2375  } // if( fvvbGdpbLastMissmatchPattern[ uGdpb ][ uAsic ] )
2376 
2377  if (fvvbGdpbLastResyncPattern[uGdpb][uAsic]) {
2378  fvhGdpbResyncEnaEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic);
2379  } // if( fvvbGdpbLastResyncPattern[ uGdpb ][ uAsic ] )
2380 
2382  if (fvvbGdpbLastMissmatchPattern[uGdpb][uAsic]) {
2383  if (fvvbGdpbLastResyncPattern[uGdpb][uAsic]) {
2384  fvhGdpbStateEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic, 4);
2385  } // if( fvvbGdpbLastResyncPattern[ uGdpb ][ uAsic ] )
2386  else
2387  fvhGdpbStateEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic, 2);
2388  } // if( fvvbGdpbLastMissmatchPattern[ uGdpb ][ uAsic ] )
2389  else if (fvvbGdpbLastResyncPattern[uGdpb][uAsic]) {
2390  fvhGdpbStateEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic, 3);
2391  } // else if( fvvbGdpbLastResyncPattern[ uGdpb ][ uAsic ] )
2392  else
2393  fvhGdpbStateEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic, 1);
2394  } // if( fvvbGdpbLastEnablePattern[ uGdpb ][ uAsic ] )
2395  else
2396  fvhGdpbStateEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic, 0);
2397 
2398  if (fvvbGdpbLastResyncPattern[uGdpb][uAsic]) {
2399  fvhGdpbResyncEvoPerTs[uGdpb]->Fill(fulCurrentTsIdx, uAsic);
2400  } // if( fvvbGdpbLastResyncPattern[ uGdpb ][ uAsic ] )
2401  } // Loop on gDPB and ASICs
2402  } // if( kTRUE == fbDebugMonitorMode )
2403  /*
2404  UInt_t uCountHitsInMs = 0;
2405  UInt_t uCountErrorsInMs = 0;
2406  UInt_t uCountLostEvtInMs = 0;
2407 
2408  Double_t dFractErrorsInMs = uCountErrorsInMs;
2409  Double_t dFractLostEvtInMs = uCountLostEvtInMs;
2410  dFractErrorsInMs /= ( uCountHitsInMs + uCountErrorsInMs );
2411  dFractLostEvtInMs /= ( uCountHitsInMs + uCountErrorsInMs );
2412 
2413  fhMsgCntPerMsEvo->Fill( fdMsTime - fdStartTime, uCountHitsInMs + uCountErrorsInMs );
2414  fhHitCntPerMsEvo->Fill( fdMsTime - fdStartTime, uCountHitsInMs );
2415  fhErrorCntPerMsEvo->Fill( fdMsTime - fdStartTime, uCountErrorsInMs );
2416  fhLostEvtCntPerMsEvo->Fill( fdMsTime - fdStartTime, uCountLostEvtInMs );
2417  fhErrorFractPerMsEvo->Fill( fdMsTime - fdStartTime, dFractErrorsInMs );
2418  fhLostEvtFractPerMsEvo->Fill( fdMsTime - fdStartTime, dFractLostEvtInMs );
2419 */
2420  return kTRUE;
2421 }
2423  fhMessType->Reset();
2424  fhSysMessType->Reset();
2425  fhGet4MessType->Reset();
2426  fhGet4ChanScm->Reset();
2427  fhGet4ChanErrors->Reset();
2428  fhGet4EpochFlags->Reset();
2429  fhGdpbAsicSpiCounts->Reset();
2430  fhGdpbMessType->Reset();
2431  fhGdpbSysMessType->Reset();
2432  fhGdpbSysMessPattType->Reset();
2433  fhGdpbEpochFlags->Reset();
2434  fhGdpbEpochSyncEvo->Reset();
2435  fhGdpbEpochMissEvo->Reset();
2436  fhGdpbEndMsBufferNotEmpty->Reset();
2437  fhGdpbEndMsDataLost->Reset();
2438  if (kTRUE == fbDebugMonitorMode) {
2439  fhNbMissPatternPerMs->Reset();
2440  fhPatternMissmatch->Reset();
2441  fhPatternEnable->Reset();
2442  fhPatternResync->Reset();
2443  } // if( kTRUE == fbDebugMonitorMode )
2444 
2445  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
2446  fvhGdpbGet4MessType[uGdpb]->Reset();
2447  fvhGdpbGet4ChanScm[uGdpb]->Reset();
2448  fvhGdpbGet4ChanErrors[uGdpb]->Reset();
2449  if (kTRUE == fbDebugMonitorMode) {
2450  fvhRawFt_gDPB[uGdpb]->Reset();
2451  fvhRawCt_gDPB[uGdpb]->Reset();
2452  } // if( kTRUE == fbDebugMonitorMode )
2453  fvhRemapTot_gDPB[uGdpb]->Reset();
2454  fvhRemapChCount_gDPB[uGdpb]->Reset();
2455  fvhRemapChRate_gDPB[uGdpb]->Reset();
2456  if (kTRUE == fbDebugMonitorMode) {
2457  fvhGdpbPatternMissmatchEvo[uGdpb]->Reset();
2458  fvhGdpbPatternEnableEvo[uGdpb]->Reset();
2459  fvhGdpbPatternResyncEvo[uGdpb]->Reset();
2460  fvhGdpbMissmatchEvoPerTs[uGdpb]->Reset();
2461  fvhGdpbMissmatchEnaEvoPerTs[uGdpb]->Reset();
2462  fvhGdpbEnableEvoPerTs[uGdpb]->Reset();
2463  fvhGdpbResyncEvoPerTs[uGdpb]->Reset();
2464  fvhGdpbResyncEnaEvoPerTs[uGdpb]->Reset();
2465  fvhGdpbStateEvoPerTs[uGdpb]->Reset();
2466  } // if( kTRUE == fbDebugMonitorMode )
2467  fvhTokenMsgType[uGdpb]->Reset();
2468  fvhTriggerRate[uGdpb]->Reset();
2469  fvhCmdDaqVsTrig[uGdpb]->Reset();
2470  fvhStarTokenEvo[uGdpb]->Reset();
2471  fvhStarTrigGdpbTsEvo[uGdpb]->Reset();
2472  fvhStarTrigStarTsEvo[uGdpb]->Reset();
2473  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
2474 
2475  fhMsgCntEvo->Reset();
2476  fhHitCntEvo->Reset();
2477  fhErrorCntEvo->Reset();
2478  fhLostEvtCntEvo->Reset();
2479  fhErrorFractEvo->Reset();
2480  fhLostEvtFractEvo->Reset();
2481  fhHitCntPerMsEvo->Reset();
2482  fhErrorCntPerMsEvo->Reset();
2483  fhLostEvtCntPerMsEvo->Reset();
2484  fhErrorFractPerMsEvo->Reset();
2485  fhLostEvtFractPerMsEvo->Reset();
2486 
2487 
2490  fdStartTime = -1.0;
2491 
2492  return kTRUE;
2493 }
2495  fhGdpbEpochSyncEvo->Reset();
2496  fhGdpbEpochMissEvo->Reset();
2497 
2498  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
2499  fvhRemapChRate_gDPB[uGdpb]->Reset();
2500  if (kTRUE == fbDebugMonitorMode) {
2501  // fvhGdpbPatternMissmatchEvo[ uGdpb ] ->Reset();
2502  // fvhGdpbPatternEnableEvo[ uGdpb ] ->Reset();
2503  // fvhGdpbPatternResyncEvo[ uGdpb ] ->Reset();
2504  fvhGdpbMissmatchEvoPerTs[uGdpb]->Reset();
2505  fvhGdpbMissmatchEnaEvoPerTs[uGdpb]->Reset();
2506  fvhGdpbEnableEvoPerTs[uGdpb]->Reset();
2507  fvhGdpbResyncEvoPerTs[uGdpb]->Reset();
2508  fvhGdpbResyncEnaEvoPerTs[uGdpb]->Reset();
2509  fvhGdpbStateEvoPerTs[uGdpb]->Reset();
2510  } // if( kTRUE == fbDebugMonitorMode )
2511  fvhTriggerRate[uGdpb]->Reset();
2512  fvhStarTokenEvo[uGdpb]->Reset();
2513  fvhStarTrigGdpbTsEvo[uGdpb]->Reset();
2514  fvhStarTrigStarTsEvo[uGdpb]->Reset();
2515  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
2516 
2517  fhMsgCntEvo->Reset();
2518  fhHitCntEvo->Reset();
2519  fhErrorCntEvo->Reset();
2520  fhLostEvtCntEvo->Reset();
2521  fhErrorFractEvo->Reset();
2522  fhLostEvtFractEvo->Reset();
2523  fhHitCntPerMsEvo->Reset();
2524  fhErrorCntPerMsEvo->Reset();
2525  fhLostEvtCntPerMsEvo->Reset();
2526  fhErrorFractPerMsEvo->Reset();
2527  fhLostEvtFractPerMsEvo->Reset();
2528 
2529  fdStartTime = -1;
2530 }
2531 // -------------------------------------------------------------------------
2532 Bool_t CbmStar2019MonitorAlgo::SaveLatencyHistograms(TString fsHistoFileName) {
2534  TDirectory* oldDir = NULL;
2535  TFile* histoFile = NULL;
2536  // Store current directory position to allow restore later
2537  oldDir = gDirectory;
2538  // open separate histo file in recreate mode
2539  histoFile = new TFile(fsHistoFileName, "RECREATE");
2540 
2541  if (nullptr == histoFile) return kFALSE;
2542 
2545  /*
2546  TString sFolder = "";
2547  if( nullptr == gDirectory->Get( sFolder ) )
2548  gDirectory->mkdir( sFolder );
2549  gDirectory->cd( sFolder );
2550 */
2551  fhGdpbEpochFlags->Write();
2552  if (kTRUE == fbDebugMonitorMode) {
2553  fhPatternMissmatch->Write();
2554  fhPatternEnable->Write();
2555  } // if( kTRUE == fbDebugMonitorMode )
2556 
2557  for (UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb) {
2560  /*
2561  TString sFolder = "";
2562  if( nullptr == gDirectory->Get( sFolder ) )
2563  gDirectory->mkdir( sFolder );
2564  gDirectory->cd( sFolder );
2565 */
2566  fvhGdpbGet4MessType[uGdpb]->Write();
2567  /*
2568  if( kTRUE == fbDebugMonitorMode )
2569  {
2570  fvhGdpbPatternMissmatchEvo[ uGdpb ]->Write();
2571  } // if( kTRUE == fbDebugMonitorMode )
2572 */
2573  } // for( UInt_t uGdpb = 0; uGdpb < fuNrOfGdpbs; ++uGdpb )
2574 
2576  oldDir->cd();
2577  histoFile->Close();
2578 
2579  return kTRUE;
2580 }
2581 // -------------------------------------------------------------------------
gdpbv100::Message::getStarTrigCmdStarD
uint32_t getStarTrigCmdStarD() const
Definition: gDpbMessv100.h:278
gdpbv100::MSG_STAR_TRI_A
@ MSG_STAR_TRI_A
Definition: gDpbMessv100.h:63
CbmStar2019MonitorAlgo::fvhRemapChRate_gDPB
std::vector< TH2 * > fvhRemapChRate_gDPB
Definition: CbmStar2019MonitorAlgo.h:215
gdpbv100::Message
Definition: gDpbMessv100.h:133
CbmStar2019MonitorAlgo::fcStarTriggerRate
TCanvas * fcStarTriggerRate
Definition: CbmStar2019MonitorAlgo.h:263
CbmStar2019MonitorAlgo::fulCurrentTsIdx
ULong64_t fulCurrentTsIdx
Definition: CbmStar2019MonitorAlgo.h:109
gdpbv100::Message::getGdpbSlcType
uint32_t getGdpbSlcType() const
Definition: gDpbMessv100.h:241
CbmStar2019MonitorAlgo::fhSysMessType
TH1 * fhSysMessType
Definition: CbmStar2019MonitorAlgo.h:177
CbmStar2019MonitorAlgo::fhErrorFractEvo
TProfile * fhErrorFractEvo
Definition: CbmStar2019MonitorAlgo.h:202
CbmStar2019MonitorAlgo::GetParList
TList * GetParList()
Definition: CbmStar2019MonitorAlgo.cxx:196
CbmStar2019MonitorAlgo::fuNbMissmatchPattern
std::vector< UInt_t > fuNbMissmatchPattern
Definition: CbmStar2019MonitorAlgo.h:218
gdpbv100::Message::getGdpbSysErrChanId
uint16_t getGdpbSysErrChanId() const
Definition: gDpbMessv100.h:251
CbmStar2019MonitorAlgo::fvhGdpbResyncEvoPerTs
std::vector< TH2 * > fvhGdpbResyncEvoPerTs
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:244
CbmStar2019MonitorAlgo::fhMessType
TH1 * fhMessType
Size in seconds of the evolution histograms.
Definition: CbmStar2019MonitorAlgo.h:176
gdpbv100::Message::getGdpbTsMsbStarA
uint64_t getGdpbTsMsbStarA() const
Definition: gDpbMessv100.h:266
gdpbv100::Message::getGdpbEpEpochNb
uint32_t getGdpbEpEpochNb() const
Definition: gDpbMessv100.h:231
CbmStar2019Algo< CbmTofDigi >::fdMsSizeInNs
Double_t fdMsSizeInNs
/‍** Ignore Overlap Ms: all fuOverlapMsNb MS at the end of timeslice **‍/
Definition: CbmStar2019Algo.h:117
gdpbv100::FullMessage::GetFullTimeNs
double GetFullTimeNs() const
Definition: gDpbMessv100.h:395
CbmStar2019MonitorAlgo::ResetHistograms
Bool_t ResetHistograms()
Definition: CbmStar2019MonitorAlgo.cxx:2422
CbmStar2019MonitorAlgo::ProcessEpochCycle
void ProcessEpochCycle(uint64_t ulCycleData)
Definition: CbmStar2019MonitorAlgo.cxx:579
CbmStar2019MonitorAlgo::ProcessHit
void ProcessHit(gdpbv100::FullMessage mess)
Definition: CbmStar2019MonitorAlgo.cxx:721
CbmStar2019MonitorAlgo::fvhGdpbGet4MessType
std::vector< TH2 * > fvhGdpbGet4MessType
Definition: CbmStar2019MonitorAlgo.h:194
gdpbv100::GET4_V2X_ERR_TOT_OVERWRT
@ GET4_V2X_ERR_TOT_OVERWRT
Definition: gDpbMessv100.h:121
CbmStar2019TofPar::GetNrOfChannelsPerGet4
static constexpr UInt_t GetNrOfChannelsPerGet4()
Definition: CbmStar2019TofPar.h:45
CbmStar2019MonitorAlgo::ProcessSlowCtrl
void ProcessSlowCtrl(gdpbv100::Message mess)
Definition: CbmStar2019MonitorAlgo.cxx:1150
CbmStar2019Algo< CbmTofDigi >::fuNbMsLoop
size_t fuNbMsLoop
Definition: CbmStar2019Algo.h:114
CbmStar2019MonitorAlgo::fuDuplicatesCount
UInt_t fuDuplicatesCount
Definition: CbmStar2019MonitorAlgo.h:167
gdpbv100::Message::getGdpbSlcChan
uint32_t getGdpbSlcChan() const
Definition: gDpbMessv100.h:239
gdpbv100::Message::getGdpbEpSync
bool getGdpbEpSync() const
Definition: gDpbMessv100.h:232
CbmStar2019MonitorAlgo::ProcessMs
Bool_t ProcessMs(const fles::Timeslice &ts, size_t uMsCompIdx, size_t uMsIdx)
Definition: CbmStar2019MonitorAlgo.cxx:382
gdpbv100::SYS_GET4_ERROR
@ SYS_GET4_ERROR
Definition: gDpbMessv100.h:70
gdpbv100::MSG_HIT
@ MSG_HIT
Definition: gDpbMessv100.h:59
i
int i
Definition: L1/vectors/P4_F32vec4.h:25
CbmStar2019MonitorAlgo::fhLostEvtFractEvo
TProfile * fhLostEvtFractEvo
Definition: CbmStar2019MonitorAlgo.h:203
CbmStar2019MonitorAlgo::fvhStarTrigGdpbTsEvo
std::vector< TProfile * > fvhStarTrigGdpbTsEvo
Definition: CbmStar2019MonitorAlgo.h:254
CbmStar2019MonitorAlgo::fhGdpbEpochSyncEvo
TH2 * fhGdpbEpochSyncEvo
Definition: CbmStar2019MonitorAlgo.h:189
gdpbv100::Message::getGdpbSysPattType
uint16_t getGdpbSysPattType() const
Definition: gDpbMessv100.h:259
gdpbv100::MSG_SLOWC
@ MSG_SLOWC
Definition: gDpbMessv100.h:61
CbmStar2019MonitorAlgo::fcSummary
TCanvas * fcSummary
Canvases.
Definition: CbmStar2019MonitorAlgo.h:259
CbmStar2019MonitorAlgo::fvhRawFt_gDPB
std::vector< TH2 * > fvhRawFt_gDPB
Definition: CbmStar2019MonitorAlgo.h:211
CbmStar2019MonitorAlgo::fuNrOfChannelsPerFee
UInt_t fuNrOfChannelsPerFee
Number of channels in each GET4.
Definition: CbmStar2019MonitorAlgo.h:93
CbmStar2019MonitorAlgo::CbmStar2019MonitorAlgo
CbmStar2019MonitorAlgo()
Definition: CbmStar2019MonitorAlgo.cxx:37
CbmStar2019MonitorAlgo::fdStartTime
Double_t fdStartTime
Definition: CbmStar2019MonitorAlgo.h:148
CbmStar2019MonitorAlgo::fhPatternMissmatch
TH2 * fhPatternMissmatch
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:220
CbmStar2019Algo< CbmTofDigi >::fuNbOverMsPerTs
size_t fuNbOverMsPerTs
Definition: CbmStar2019Algo.h:113
gdpbv100::MSG_STAR_TRI_D
@ MSG_STAR_TRI_D
Definition: gDpbMessv100.h:66
gdpbv100::Message::getMessageType
uint8_t getMessageType() const
Returns the message type. Valid for all message types. 4 bit.
Definition: gDpbMessv100.h:206
CbmStar2019MonitorAlgo::fvhStarTokenEvo
std::vector< TH2 * > fvhStarTokenEvo
Definition: CbmStar2019MonitorAlgo.h:253
CbmStar2019MonitorAlgo::fvhGdpbPatternResyncEvo
std::vector< TH2 * > fvhGdpbPatternResyncEvo
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:229
CbmStar2019Algo< CbmTofDigi >::AddHistoToVector
void AddHistoToVector(TNamed *pointer, std::string sFolder="")
For monitor algos.
Definition: CbmStar2019Algo.h:80
CbmStar2019MonitorAlgo::fvhGdpbGet4ChanErrors
std::vector< TH2 * > fvhGdpbGet4ChanErrors
Definition: CbmStar2019MonitorAlgo.h:196
CbmStar2019MonitorAlgo::fuNrOfGdpbs
UInt_t fuNrOfGdpbs
Definition: CbmStar2019MonitorAlgo.h:88
gdpbv100::GET4_32B_SLC_START_SEU
@ GET4_32B_SLC_START_SEU
Definition: gDpbMessv100.h:104
gdpbv100::Message::getGdpbSysSubType
uint16_t getGdpbSysSubType() const
Definition: gDpbMessv100.h:245
CbmStar2019MonitorAlgo::fhErrorCntPerMsEvo
TH2 * fhErrorCntPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:206
CbmStar2019MonitorAlgo::ProcessSysMess
void ProcessSysMess(gdpbv100::FullMessage mess)
Definition: CbmStar2019MonitorAlgo.cxx:794
CbmStar2019Algo< CbmTofDigi >::fuNbCoreMsPerTs
size_t fuNbCoreMsPerTs
Definition: CbmStar2019Algo.h:112
gdpbv100::GET4_V2X_ERR_TOKEN
@ GET4_V2X_ERR_TOKEN
Definition: gDpbMessv100.h:116
CbmStar2019MonitorAlgo::fuGet4Id
UInt_t fuGet4Id
Bin size in s for the plots with date as X axis.
Definition: CbmStar2019MonitorAlgo.h:132
gdpbv100::GET4_V2X_ERR_CHAN_STATE
@ GET4_V2X_ERR_CHAN_STATE
Definition: gDpbMessv100.h:114
gdpbv100::kuEpochCounterSz
const uint32_t kuEpochCounterSz
Definition: gDpbMessv100.h:40
CbmStar2019MonitorAlgo::Finish
virtual void Finish()
Definition: CbmStar2019MonitorAlgo.cxx:172
CbmStar2019MonitorAlgo::fhGdpbSysMessPattType
TH2 * fhGdpbSysMessPattType
Definition: CbmStar2019MonitorAlgo.h:187
gdpbv100::Message::isStarTrigger
bool isStarTrigger() const
Returns true is message type is MSG_STAR_TRI_A, _B, _C, _D (STAR Trigger message)
Definition: gDpbMessv100.h:329
CbmStar2019MonitorAlgo::fuNrOfGet4
UInt_t fuNrOfGet4
Number of channels in each FEE.
Definition: CbmStar2019MonitorAlgo.h:94
CbmStar2019Algo< CbmTofDigi >::fdTsFullSizeInNs
Double_t fdTsFullSizeInNs
Total size of the core MS in a TS, [nanoseconds].
Definition: CbmStar2019Algo.h:121
gdpbv100::Message::getGdpbSysErrData
uint16_t getGdpbSysErrData() const
Definition: gDpbMessv100.h:253
CbmStar2019Algo< CbmTofDigi >::fParCList
TList * fParCList
Parameter management.
Definition: CbmStar2019Algo.h:108
gdpbv100::Message::getGdpbSysPattIndex
uint16_t getGdpbSysPattIndex() const
Definition: gDpbMessv100.h:260
CbmStar2019MonitorAlgo::fuCurrSector
UInt_t fuCurrSector
Index of the DPB from which the MS currently unpacked is coming.
Definition: CbmStar2019MonitorAlgo.h:127
CbmStar2019MonitorAlgo::fhLostEvtCntPerMsEvo
TH2 * fhLostEvtCntPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:207
CbmStar2019MonitorAlgo::fUnpackPar
CbmStar2019TofPar * fUnpackPar
Settings from parameter file.
Definition: CbmStar2019MonitorAlgo.h:86
CbmStar2019TofPar::GetGdpbId
Int_t GetGdpbId(Int_t i)
Definition: CbmStar2019TofPar.h:39
CbmStar2019MonitorAlgo::fvhGdpbMissmatchEnaEvoPerTs
std::vector< TH2 * > fvhGdpbMissmatchEnaEvoPerTs
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:240
CbmStar2019MonitorAlgo::fhPatternEnable
TH2 * fhPatternEnable
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:221
CbmStar2019MonitorAlgo::fulCurrentMsIdx
ULong64_t fulCurrentMsIdx
Definition: CbmStar2019MonitorAlgo.h:110
CbmStar2019Algo< CbmTofDigi >::fvMsComponentsList
std::vector< size_t > fvMsComponentsList
Parameters related to FLES containers.
Definition: CbmStar2019Algo.h:111
CbmStar2019MonitorAlgo::fvhRemapTot_gDPB
std::vector< TH2 * > fvhRemapTot_gDPB
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:213
CbmStar2019MonitorAlgo::fvhCmdDaqVsTrig
std::vector< TH2 * > fvhCmdDaqVsTrig
Definition: CbmStar2019MonitorAlgo.h:252
CbmStar2019MonitorAlgo::fvulCurrentEpoch
std::vector< ULong64_t > fvulCurrentEpoch
Data format control: Current time references for each GDPB: merged epoch marker, epoch cycle,...
Definition: CbmStar2019MonitorAlgo.h:136
CbmStar2019MonitorAlgo::fuNrOfChannelsPerGet4
UInt_t fuNrOfChannelsPerGet4
Number of GET4s per FEE.
Definition: CbmStar2019MonitorAlgo.h:92
CbmStar2019MonitorAlgo::SaveLatencyHistograms
Bool_t SaveLatencyHistograms(TString fsHistoFileName)
Definition: CbmStar2019MonitorAlgo.cxx:2532
CbmStar2019MonitorAlgo::fdMsTime
Double_t fdMsTime
End Time in ns of current TS Core from the index of the first MS first component.
Definition: CbmStar2019MonitorAlgo.h:116
CbmStar2019MonitorAlgo::fcStarTrigCmdDaqVsTrig
TCanvas * fcStarTrigCmdDaqVsTrig
Definition: CbmStar2019MonitorAlgo.h:264
CbmStar2019MonitorAlgo::fhGdpbSysMessType
TH2 * fhGdpbSysMessType
Definition: CbmStar2019MonitorAlgo.h:186
gdpbv100::GET4_V2X_ERR_DLL_LOCK
@ GET4_V2X_ERR_DLL_LOCK
Definition: gDpbMessv100.h:119
CbmStar2019MonitorAlgo::fbIgnoreCriticalErrors
Bool_t fbIgnoreCriticalErrors
Switch ON the filling of a additional set of histograms.
Definition: CbmStar2019MonitorAlgo.h:81
gdpbv100::GET4_V2X_ERR_FIFO_WRITE
@ GET4_V2X_ERR_FIFO_WRITE
Definition: gDpbMessv100.h:112
CbmStar2019MonitorAlgo::fvulStarTsMid
std::vector< ULong64_t > fvulStarTsMid
Definition: CbmStar2019MonitorAlgo.h:158
CbmStar2019MonitorAlgo::fvuStarDaqCmdLast
std::vector< UInt_t > fvuStarDaqCmdLast
Definition: CbmStar2019MonitorAlgo.h:162
CbmTofDetectorId_v14a.h
CbmStar2019MonitorAlgo::fdTsStartTime
Double_t fdTsStartTime
Definition: CbmStar2019MonitorAlgo.h:112
CbmStar2019MonitorAlgo::fuGet4Nr
UInt_t fuGet4Nr
running number (0 to fuNrOfGet4PerGdpb) of the Get4 chip of a unique GDPB for current message
Definition: CbmStar2019MonitorAlgo.h:134
gdpbv100::Message::getStarTsLsbStarD
uint64_t getStarTsLsbStarD() const
Definition: gDpbMessv100.h:273
CbmStar2019MonitorAlgo::fhGdpbEpochMissEvo
TH2 * fhGdpbEpochMissEvo
Definition: CbmStar2019MonitorAlgo.h:190
gdpbv100::PATT_MISSMATCH
@ PATT_MISSMATCH
Definition: gDpbMessv100.h:81
CbmStar2019MonitorAlgo::InitContainers
Bool_t InitContainers()
Definition: CbmStar2019MonitorAlgo.cxx:179
gdpbv100::GET4_V2X_ERR_UNKNOWN
@ GET4_V2X_ERR_UNKNOWN
Definition: gDpbMessv100.h:130
CbmStar2019MonitorAlgo::fhPatternResync
TH2 * fhPatternResync
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:222
CbmStar2019MonitorAlgo::FillHistograms
Bool_t FillHistograms()
Definition: CbmStar2019MonitorAlgo.cxx:2361
gdpbv100::MSG_STAR_TRI_C
@ MSG_STAR_TRI_C
Definition: gDpbMessv100.h:65
CbmStar2019TofPar::ElinkIdxToGet4Idx
Int_t ElinkIdxToGet4Idx(UInt_t uElink)
Definition: CbmStar2019TofPar.cxx:169
gdpbv100::GET4_32B_SLC_SCALER
@ GET4_32B_SLC_SCALER
Definition: gDpbMessv100.h:101
CbmStar2019MonitorAlgo::fvhGdpbResyncEnaEvoPerTs
std::vector< TH2 * > fvhGdpbResyncEnaEvoPerTs
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:246
gdpbv100::Message::getGdpbSysFwErrResync
uint32_t getGdpbSysFwErrResync() const
Definition: gDpbMessv100.h:257
gdpbv100::PATT_RESYNC
@ PATT_RESYNC
Definition: gDpbMessv100.h:83
CbmStar2019MonitorAlgo::fcStarTrigTokenType
TCanvas * fcStarTrigTokenType
Definition: CbmStar2019MonitorAlgo.h:262
CbmStar2019MonitorAlgo::fhGet4MessType
TH2 * fhGet4MessType
Definition: CbmStar2019MonitorAlgo.h:179
gdpbv100::GET4_V2X_ERR_EP
@ GET4_V2X_ERR_EP
Definition: gDpbMessv100.h:111
gdpbv100::Message::getData
uint64_t getData() const
Definition: gDpbMessv100.h:156
CbmStar2019MonitorAlgo::fvulGdpbTsMsb
std::vector< ULong64_t > fvulGdpbTsMsb
STAR TRIGGER detection.
Definition: CbmStar2019MonitorAlgo.h:155
CbmStar2019MonitorAlgo::Init
virtual Bool_t Init()
Definition: CbmStar2019MonitorAlgo.cxx:166
CbmStar2019MonitorAlgo::fuCurrDpbId
UInt_t fuCurrDpbId
Current equipment ID, tells from which DPB the current MS is originating.
Definition: CbmStar2019MonitorAlgo.h:123
gdpbv100::GET4_V2X_ERR_SYNC
@ GET4_V2X_ERR_SYNC
Definition: gDpbMessv100.h:109
CbmStar2019MonitorAlgo::fvhRawCt_gDPB
std::vector< TH2 * > fvhRawCt_gDPB
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:212
gdpbv100::GET4_V2X_ERR_EP_CNT_SYNC
@ GET4_V2X_ERR_EP_CNT_SYNC
Definition: gDpbMessv100.h:110
CbmStar2019MonitorAlgo::fhLostEvtFractPerMsEvo
TH2 * fhLostEvtFractPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:209
CbmStar2019TofPar::Get4ChanToPadiChan
Int_t Get4ChanToPadiChan(UInt_t uChannelInFee)
Definition: CbmStar2019TofPar.cxx:146
CbmStar2019MonitorAlgo::Reset
virtual void Reset()
Definition: CbmStar2019MonitorAlgo.cxx:171
CbmStar2019Algo
Definition: CbmStar2019Algo.h:43
CbmStar2019MonitorAlgo::fhGdpbEndMsBufferNotEmpty
TH1 * fhGdpbEndMsBufferNotEmpty
Definition: CbmStar2019MonitorAlgo.h:191
CbmStar2019MonitorAlgo::fvcSumGdpbGet4
std::vector< TCanvas * > fvcSumGdpbGet4
Definition: CbmStar2019MonitorAlgo.h:261
gdpbv100::GET4_V2X_ERR_SEQUENCE_ER
@ GET4_V2X_ERR_SEQUENCE_ER
Definition: gDpbMessv100.h:127
CbmStar2019MonitorAlgo::fvhStarTrigStarTsEvo
std::vector< TProfile * > fvhStarTrigStarTsEvo
Definition: CbmStar2019MonitorAlgo.h:255
gdpbv100::Message::getGdpbTsLsbStarB
uint64_t getGdpbTsLsbStarB() const
Definition: gDpbMessv100.h:268
CbmStar2019MonitorAlgo::ProcessStarTrig
void ProcessStarTrig(gdpbv100::Message mess)
Definition: CbmStar2019MonitorAlgo.cxx:1218
CbmStar2019MonitorAlgo::fhErrorCntEvo
TH1 * fhErrorCntEvo
Definition: CbmStar2019MonitorAlgo.h:200
CbmStar2019MonitorAlgo::fcStarTrigStarTsEvo
TCanvas * fcStarTrigStarTsEvo
Definition: CbmStar2019MonitorAlgo.h:267
gdpbv100::Message::getStarTrigMsgIndex
uint16_t getStarTrigMsgIndex() const
Definition: gDpbMessv100.h:264
CbmStar2019MonitorAlgo::fhMsgCntEvo
TH1 * fhMsgCntEvo
Definition: CbmStar2019MonitorAlgo.h:198
CbmStar2019MonitorAlgo::fvulGdpbTsLsb
std::vector< ULong64_t > fvulGdpbTsLsb
Definition: CbmStar2019MonitorAlgo.h:156
CbmStar2019MonitorAlgo::fvhTokenMsgType
std::vector< TH1 * > fvhTokenMsgType
Definition: CbmStar2019MonitorAlgo.h:250
gdpbv100::Message::getGdpbSlcEdge
uint32_t getGdpbSlcEdge() const
Definition: gDpbMessv100.h:240
gdpbv100::GET4_32B_SLC_DEADT
@ GET4_32B_SLC_DEADT
Definition: gDpbMessv100.h:102
CbmStar2019MonitorAlgo::fdTsStopTimeCore
Double_t fdTsStopTimeCore
Time in ns of current TS from the index of the first MS first component.
Definition: CbmStar2019MonitorAlgo.h:114
gdpbv100::GET4_V2X_ERR_TOK_RING_ST
@ GET4_V2X_ERR_TOK_RING_ST
Definition: gDpbMessv100.h:115
CbmStar2019Algo< CbmTofDigi >::fdTsCoreSizeInNs
Double_t fdTsCoreSizeInNs
Size of a single MS, [nanoseconds].
Definition: CbmStar2019Algo.h:119
CbmStar2019MonitorAlgo::fvuStarTrigCmdLast
std::vector< UInt_t > fvuStarTrigCmdLast
Definition: CbmStar2019MonitorAlgo.h:163
CbmTofAddress.h
CbmStar2019MonitorAlgo::AddMsComponentToList
void AddMsComponentToList(size_t component, UShort_t usDetectorId)
Definition: CbmStar2019MonitorAlgo.cxx:304
CbmStar2019MonitorAlgo::fvhRemapChCount_gDPB
std::vector< TH1 * > fvhRemapChCount_gDPB
Definition: CbmStar2019MonitorAlgo.h:214
gdpbv100::kuChipIdMergedEpoch
const uint32_t kuChipIdMergedEpoch
Definition: gDpbMessv100.h:51
gdpbv100::GET4_V2X_ERR_ADD_RIS_EDG
@ GET4_V2X_ERR_ADD_RIS_EDG
Definition: gDpbMessv100.h:125
CbmStar2019MonitorAlgo::fuCurrentEquipmentId
UInt_t fuCurrentEquipmentId
Definition: CbmStar2019MonitorAlgo.h:121
CbmStar2019MonitorAlgo::fvhGdpbStateEvoPerTs
std::vector< TH2 * > fvhGdpbStateEvoPerTs
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:248
CbmStar2019MonitorAlgo::fhGet4ChanErrors
TH2 * fhGet4ChanErrors
Definition: CbmStar2019MonitorAlgo.h:181
CbmStar2019TofPar::GetNrOfGet4PerFee
static constexpr UInt_t GetNrOfGet4PerFee()
Definition: CbmStar2019TofPar.h:48
CbmStar2019MonitorAlgo::CreateHistograms
Bool_t CreateHistograms()
Definition: CbmStar2019MonitorAlgo.cxx:1308
CbmStar2019MonitorAlgo::fcSummaryGdpb
TCanvas * fcSummaryGdpb
Definition: CbmStar2019MonitorAlgo.h:260
CbmStar2019TofPar.h
CbmStar2019MonitorAlgo::fhGdpbEpochFlags
TH2 * fhGdpbEpochFlags
Definition: CbmStar2019MonitorAlgo.h:188
gdpbv100::MSG_SYST
@ MSG_SYST
Definition: gDpbMessv100.h:62
CbmStar2019MonitorAlgo::fulStartTs
ULong64_t fulStartTs
Starting state book-keeping.
Definition: CbmStar2019MonitorAlgo.h:146
CbmStar2019MonitorAlgo::fuNrOfFeePerGdpb
UInt_t fuNrOfFeePerGdpb
gDPB ID to index map
Definition: CbmStar2019MonitorAlgo.h:90
CbmStar2019MonitorAlgo::fuCurrDpbIdx
UInt_t fuCurrDpbIdx
Temp holder until Current equipment ID is properly filled in MS.
Definition: CbmStar2019MonitorAlgo.h:125
CbmStar2019MonitorAlgo::fhHitCntPerMsEvo
TH2 * fhHitCntPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:205
CbmStar2019MonitorAlgo::fvvbGdpbLastMissmatchPattern
std::vector< std::vector< bool > > fvvbGdpbLastMissmatchPattern
Definition: CbmStar2019MonitorAlgo.h:232
gdpbv100::Message::getStarTsMidStarC
uint64_t getStarTsMidStarC() const
Definition: gDpbMessv100.h:271
CbmStar2019MonitorAlgo::kuBytesPerMessage
static const UInt_t kuBytesPerMessage
Definition: CbmStar2019MonitorAlgo.h:104
CbmStar2019MonitorAlgo::ResetEvolutionHistograms
void ResetEvolutionHistograms()
Definition: CbmStar2019MonitorAlgo.cxx:2494
CbmStar2019MonitorAlgo::fhGdpbAsicSpiCounts
TH2 * fhGdpbAsicSpiCounts
Definition: CbmStar2019MonitorAlgo.h:183
gdpbv100::GET4_V2X_ERR_TOT_RANGE
@ GET4_V2X_ERR_TOT_RANGE
Definition: gDpbMessv100.h:123
FormatMsHeaderPrintout
std::string FormatMsHeaderPrintout(const fles::MicrosliceDescriptor &msDescriptor)
Definition: CbmFormatMsHeaderPrintout.cxx:5
gdpbv100::GET4_V2X_ERR_DLL_RESET
@ GET4_V2X_ERR_DLL_RESET
Definition: gDpbMessv100.h:120
gdpbv100::GET4_V2X_ERR_SPI
@ GET4_V2X_ERR_SPI
Definition: gDpbMessv100.h:118
CbmStar2019TofPar
Definition: CbmStar2019TofPar.h:18
CbmStar2019MonitorAlgo::fhErrorFractPerMsEvo
TH2 * fhErrorFractPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:208
CbmStar2019MonitorAlgo::fvulStarTsMsb
std::vector< ULong64_t > fvulStarTsMsb
Definition: CbmStar2019MonitorAlgo.h:157
CbmStar2019MonitorAlgo::fuNrOfGet4PerFee
UInt_t fuNrOfGet4PerFee
Number of FEBs per GDPB.
Definition: CbmStar2019MonitorAlgo.h:91
gdpbv100::GET4_V2X_ERR_READ_INIT
@ GET4_V2X_ERR_READ_INIT
Definition: gDpbMessv100.h:108
gdpbv100::Message::getGdpbSysPattPattern
uint32_t getGdpbSysPattPattern() const
Definition: gDpbMessv100.h:261
CbmStar2019MonitorAlgo::fcStarTrigGdpbTsEvo
TCanvas * fcStarTrigGdpbTsEvo
Definition: CbmStar2019MonitorAlgo.h:266
CbmStar2019MonitorAlgo.h
CbmStar2019MonitorAlgo::fhHitCntEvo
TH1 * fhHitCntEvo
Definition: CbmStar2019MonitorAlgo.h:199
CbmStar2019MonitorAlgo::ProcessError
void ProcessError(gdpbv100::FullMessage mess)
Definition: CbmStar2019MonitorAlgo.cxx:838
gdpbv100::MSG_EPOCH
@ MSG_EPOCH
Definition: gDpbMessv100.h:60
CbmStar2019MonitorAlgo::fvhGdpbGet4ChanScm
std::vector< TH2 * > fvhGdpbGet4ChanScm
Definition: CbmStar2019MonitorAlgo.h:195
gdpbv100::Message::getGdpbSysUnkwData
uint32_t getGdpbSysUnkwData() const
Definition: gDpbMessv100.h:255
CbmStar2019MonitorAlgo::fvbMaskedComponents
std::vector< Bool_t > fvbMaskedComponents
If ON not printout at all for critical errors.
Definition: CbmStar2019MonitorAlgo.h:82
gdpbv100::GET4_V2X_ERR_LOST_EVT
@ GET4_V2X_ERR_LOST_EVT
Definition: gDpbMessv100.h:113
CbmStar2019TofPar::GetNrOfGdpbs
Int_t GetNrOfGdpbs()
Definition: CbmStar2019TofPar.h:38
CbmStar2019MonitorAlgo::~CbmStar2019MonitorAlgo
~CbmStar2019MonitorAlgo()
Definition: CbmStar2019MonitorAlgo.cxx:160
gdpbv100::kulEpochCycleFieldSz
const uint64_t kulEpochCycleFieldSz
Definition: gDpbMessv100.h:49
CbmStar2019MonitorAlgo::fhMsgCntPerMsEvo
TH2 * fhMsgCntPerMsEvo
Definition: CbmStar2019MonitorAlgo.h:204
gdpbv100::Message::getGdpbHitIs24b
uint16_t getGdpbHitIs24b() const
Definition: gDpbMessv100.h:218
CbmStar2019MonitorAlgo::fvmEpSupprBuffer
std::vector< gdpbv100::Message > fvmEpSupprBuffer
Epoch + Epoch Cycle.
Definition: CbmStar2019MonitorAlgo.h:142
gdpbv100::Message::getGdpbEpEpochLoss
bool getGdpbEpEpochLoss() const
Definition: gDpbMessv100.h:234
gdpbv100::Message::getGdpbGenChipId
uint16_t getGdpbGenChipId() const
Definition: gDpbMessv100.h:214
CbmStar2019MonitorAlgo::fvvbGdpbLastResyncPattern
std::vector< std::vector< bool > > fvvbGdpbLastResyncPattern
Exclude from dictionnary.
Definition: CbmStar2019MonitorAlgo.h:236
CbmStar2019MonitorAlgo::ReInitContainers
Bool_t ReInitContainers()
Definition: CbmStar2019MonitorAlgo.cxx:185
gdpbv100::GET4_V2X_ERR_READOUT_ERR
@ GET4_V2X_ERR_READOUT_ERR
Definition: gDpbMessv100.h:117
CbmStar2019MonitorAlgo::fvulGdpbTsFullLast
std::vector< ULong64_t > fvulGdpbTsFullLast
Definition: CbmStar2019MonitorAlgo.h:159
CbmStar2019MonitorAlgo::fuNrOfGet4PerGdpb
UInt_t fuNrOfGet4PerGdpb
Total number of Get4 chips in the system.
Definition: CbmStar2019MonitorAlgo.h:95
gdpbv100::Message::getGdpbEpDataLoss
bool getGdpbEpDataLoss() const
Definition: gDpbMessv100.h:233
gdpbv100::MSG_STAR_TRI_B
@ MSG_STAR_TRI_B
Definition: gDpbMessv100.h:64
CbmStar2019MonitorAlgo::fhLostEvtCntEvo
TH1 * fhLostEvtCntEvo
Definition: CbmStar2019MonitorAlgo.h:201
gdpbv100::Message::getGdpbSysErrEdge
bool getGdpbSysErrEdge() const
Definition: gDpbMessv100.h:252
gdpbv100::SYS_PATTERN
@ SYS_PATTERN
Definition: gDpbMessv100.h:76
CbmStar2019MonitorAlgo::fvvbGdpbLastEnablePattern
std::vector< std::vector< bool > > fvvbGdpbLastEnablePattern
Exclude from dictionnary.
Definition: CbmStar2019MonitorAlgo.h:234
CbmStar2019MonitorAlgo::fuNrOfChannelsPerGdpb
UInt_t fuNrOfChannelsPerGdpb
Number of GET4s per GDPB.
Definition: CbmStar2019MonitorAlgo.h:96
CbmStar2019MonitorAlgo::fvhGdpbPatternMissmatchEvo
std::vector< TH2 * > fvhGdpbPatternMissmatchEvo
Definition: CbmStar2019MonitorAlgo.h:225
gdpbv100::Message::getGdpbSlcData
uint32_t getGdpbSlcData() const
Definition: gDpbMessv100.h:242
gdpbv100::Message::getGdpbHitFullTs
uint32_t getGdpbHitFullTs() const
Definition: gDpbMessv100.h:220
gdpbv100::GET4_32B_SLC_SPIREAD
@ GET4_32B_SLC_SPIREAD
Definition: gDpbMessv100.h:103
CbmStar2019Algo< CbmTofDigi >::AddCanvasToVector
void AddCanvasToVector(TCanvas *pointer, std::string sFolder="")
Definition: CbmStar2019Algo.h:87
CbmStar2019MonitorAlgo::ProcessEpSupprBuffer
void ProcessEpSupprBuffer()
Definition: CbmStar2019MonitorAlgo.cxx:656
gdpbv100::FullMessage
Definition: gDpbMessv100.h:362
CbmStar2019MonitorAlgo::fbDebugMonitorMode
Bool_t fbDebugMonitorMode
Control flags.
Definition: CbmStar2019MonitorAlgo.h:79
CbmStar2019MonitorAlgo::fvuStarTokenLast
std::vector< UInt_t > fvuStarTokenLast
Definition: CbmStar2019MonitorAlgo.h:161
gdpbv100::Message::getStarTokenStarD
uint32_t getStarTokenStarD() const
Definition: gDpbMessv100.h:280
CbmStar2019MonitorAlgo::ProcessTs
Bool_t ProcessTs(const fles::Timeslice &ts)
Definition: CbmStar2019MonitorAlgo.cxx:319
CbmStar2019MonitorAlgo::fcStarTrigStarTokenEvo
TCanvas * fcStarTrigStarTokenEvo
Definition: CbmStar2019MonitorAlgo.h:265
CbmStar2019MonitorAlgo::fGdpbIdIndexMap
std::map< UInt_t, UInt_t > fGdpbIdIndexMap
Total number of GDPBs in the system.
Definition: CbmStar2019MonitorAlgo.h:89
CbmStar2019MonitorAlgo::fuMsIndex
UInt_t fuMsIndex
Start Time in ns of current MS from its index field in header.
Definition: CbmStar2019MonitorAlgo.h:117
gdpbv100::Message::getStarTsMsbStarB
uint64_t getStarTsMsbStarB() const
Definition: gDpbMessv100.h:269
CbmStar2019MonitorAlgo::fiSectorIndex
Int_t fiSectorIndex
Definition: CbmStar2019MonitorAlgo.h:83
CbmStar2019TofPar::GetGdpbToSectorOffset
static constexpr UInt_t GetGdpbToSectorOffset()
Definition: CbmStar2019TofPar.h:72
gdpbv100::Message::getGdpbHitChanId
uint16_t getGdpbHitChanId() const
Definition: gDpbMessv100.h:219
CbmStar2019MonitorAlgo::fmLastHit
gdpbv100::Message fmLastHit
Definition: CbmStar2019MonitorAlgo.h:168
CbmStar2019TofPar::GetSizeMsInNs
Double_t GetSizeMsInNs()
Definition: CbmStar2019TofPar.h:93
CbmStar2019MonitorAlgo::fvhGdpbPatternEnableEvo
std::vector< TH2 * > fvhGdpbPatternEnableEvo
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:227
CbmStar2019MonitorAlgo::fhGdpbMessType
TH2 * fhGdpbMessType
Definition: CbmStar2019MonitorAlgo.h:185
CbmStar2019MonitorAlgo::fuHistoryHistoSize
UInt_t fuHistoryHistoSize
Histograms related variables.
Definition: CbmStar2019MonitorAlgo.h:171
CbmStar2019MonitorAlgo::fvhGdpbEnableEvoPerTs
std::vector< TH2 * > fvhGdpbEnableEvoPerTs
Debug histo, only in DebugMonitorMode.
Definition: CbmStar2019MonitorAlgo.h:242
gdpbv100::Message::getGdpbEpMissmatch
bool getGdpbEpMissmatch() const
Definition: gDpbMessv100.h:235
CbmStar2019MonitorAlgo::fvulCurrentEpochFull
std::vector< ULong64_t > fvulCurrentEpochFull
Epoch cycle from the Ms Start message and Epoch counter flip.
Definition: CbmStar2019MonitorAlgo.h:139
CbmStar2019TofPar::GetPadiThresholdVal
Double_t GetPadiThresholdVal(UInt_t uCode)
Definition: CbmStar2019TofPar.cxx:196
gdpbv100::PATT_ENABLE
@ PATT_ENABLE
Definition: gDpbMessv100.h:82
CbmStar2019TofPar::GetNrOfFeePerGdpb
static constexpr UInt_t GetNrOfFeePerGdpb()
Definition: CbmStar2019TofPar.h:60
gdpbv100::GET4_V2X_ERR_UNPAIR_FALL
@ GET4_V2X_ERR_UNPAIR_FALL
Definition: gDpbMessv100.h:126
gdpbv100::SYS_GET4_SYNC_MISS
@ SYS_GET4_SYNC_MISS
Definition: gDpbMessv100.h:73
CbmStar2019MonitorAlgo::fhNbMissPatternPerMs
TH2 * fhNbMissPatternPerMs
Definition: CbmStar2019MonitorAlgo.h:219
CbmStar2019Algo< CbmTofDigi >::fbIgnoreOverlapMs
Bool_t fbIgnoreOverlapMs
Definition: CbmStar2019Algo.h:116
CbmStar2019MonitorAlgo::fvhGdpbMissmatchEvoPerTs
std::vector< TH2 * > fvhGdpbMissmatchEvoPerTs
Exclude from dictionnary.
Definition: CbmStar2019MonitorAlgo.h:238
CbmStar2019MonitorAlgo::fvulStarTsFullLast
std::vector< ULong64_t > fvulStarTsFullLast
Definition: CbmStar2019MonitorAlgo.h:160
gdpbv100::Message::getGdpbSysErrUnused
uint16_t getGdpbSysErrUnused() const
Definition: gDpbMessv100.h:249
CbmStar2019MonitorAlgo::fbEpochSinceLastHit
Bool_t fbEpochSinceLastHit
Duplicate Hits detection.
Definition: CbmStar2019MonitorAlgo.h:166
CbmStar2019MonitorAlgo::fhGdpbEndMsDataLost
TH2 * fhGdpbEndMsDataLost
Definition: CbmStar2019MonitorAlgo.h:192
CbmStar2019MonitorAlgo::InitParameters
Bool_t InitParameters()
Definition: CbmStar2019MonitorAlgo.cxx:203
gdpbv100::Message::getGdpbHit32Tot
uint16_t getGdpbHit32Tot() const
Definition: gDpbMessv100.h:227
CbmStar2019MonitorAlgo::ProcessPattern
void ProcessPattern(gdpbv100::Message mess)
Definition: CbmStar2019MonitorAlgo.cxx:1051
CbmStar2019MonitorAlgo::fvhTriggerRate
std::vector< TH1 * > fvhTriggerRate
Definition: CbmStar2019MonitorAlgo.h:251
CbmFormatMsHeaderPrintout.h
gdpbv100::GET4_V2X_ERR_EVT_DISCARD
@ GET4_V2X_ERR_EVT_DISCARD
Definition: gDpbMessv100.h:124
gdpbv100::Message::getStarDaqCmdStarD
uint32_t getStarDaqCmdStarD() const
Definition: gDpbMessv100.h:279
CbmStar2019MonitorAlgo::fhGet4EpochFlags
TH2 * fhGet4EpochFlags
Definition: CbmStar2019MonitorAlgo.h:182
CbmStar2019MonitorAlgo::ProcessEpoch
void ProcessEpoch(gdpbv100::Message mess)
Definition: CbmStar2019MonitorAlgo.cxx:604
CbmStar2019MonitorAlgo::fhGet4ChanScm
TH2 * fhGet4ChanScm
Definition: CbmStar2019MonitorAlgo.h:180
gdpbv100::GET4_V2X_ERR_EPOCH_OVERF
@ GET4_V2X_ERR_EPOCH_OVERF
Definition: gDpbMessv100.h:128
gdpbv100::SYS_GDPB_UNKWN
@ SYS_GDPB_UNKWN
Definition: gDpbMessv100.h:71
CbmStar2019MonitorAlgo::fvulCurrentEpochCycle
std::vector< ULong64_t > fvulCurrentEpochCycle
Current epoch index, per DPB.
Definition: CbmStar2019MonitorAlgo.h:138