12#ifndef CBMMCBM2018MONITORSTSSYNC_H
13#define CBMMCBM2018MONITORSTSSYNC_H
15#include "Timeslice.hpp"
33class CbmCern2017UnpackParHodo;
34class CbmCern2017UnpackParSts;
41 virtual Bool_t
Init();
43 virtual Bool_t
DoUnpack(
const fles::Timeslice& ts,
size_t component);
56 virtual void SetNbMsInTs(
size_t uCoreMsNb,
size_t uOverlapMsNb);
60 void SetRunStart(Int_t dateIn, Int_t timeIn, Int_t iBinSize = 5);
93 std::vector<std::vector<UInt_t>>
128 std::vector<std::vector<std::vector<Double_t>>>
130 std::vector<std::vector<std::vector<UShort_t>>>
136 std::chrono::steady_clock::time_point
140 std::vector<stsxyter::FinalHit>
142 std::vector<std::vector<stsxyter::FinalHit>>
std::vector< std::vector< Double_t > > fvdChanLastHitTime
Last hit time in bins for each Channel.
UInt_t fuCurrDpbIdx
Temp holder until Current equipment ID is properly filled in MS.
virtual void SetNbMsInTs(size_t uCoreMsNb, size_t uOverlapMsNb)
stsxyter::MessagePrintMask fPrintMessCtrl
std::vector< std::vector< Double_t > > fvdMeanTimeDiffAsicPair
std::vector< TH1 * > fhPulserChanCntRaw
CbmMcbm2018MonitorStsSync()
std::vector< std::vector< TH2 * > > fhPulserTimeDiffEvoPerAsicPair
static const UInt_t kuNbValuesForTimeDiffMean
std::vector< std::vector< TH2 * > > fhPulserTsLsbMatchPerAsicPair
ULong64_t fulCurrentTsIdx
std::vector< UInt_t > fvuCurrentTsMsbCycle
Current TS MSB for each DPB.
TH2 * fhPulserSysMessTypePerDpb
std::vector< std::vector< ULong64_t > > fvulChanLastHitTime
TS from last hit for DPB.
std::vector< TH1 * > fhPulserFebRateEvoLong
std::vector< stsxyter::FinalHit > fvmHitsInMs
CbmMcbm2018MonitorStsSync operator=(const CbmMcbm2018MonitorStsSync &)
Int_t fiRunStartDateTimeSec
Index of the DPB from which the MS currently unpacked is coming.
std::vector< stsxyter::FinalHit > fvmLastHitAsic
Last hits in each ASIC.
void SavePulserHistos(TString sFileName="")
UInt_t fuLongHistoNbSeconds
static const Int_t kiMaxNbFlibLinks
Vector holding for each link the corresponding ASIC index [fuNrOfDpbs * fuNbElinksPerDpb].
UInt_t fuLongHistoBinSizeSec
std::vector< TH2 * > fhPulserChanRawTs
UInt_t fuNbElinksPerDpb
Map of DPB Identifier to DPB index.
std::vector< TH1 * > fhPulserChanCntRawGood
std::vector< std::vector< std::vector< Double_t > > > fvdChanLastHitTimeInMs
Number of hits in each MS for each Channel.
ULong64_t fulCurrentMsIdx
TH1 * fhPulserSysMessType
Double_t fdStartTs
Pulser time difference histos.
std::vector< Double_t > fvdMsTime
Last hit time in ns for each Channel.
TH2 * fhPulserMessTypePerElink
UInt_t fuMaxNbMicroslices
All hits (time in bins, ADC in bins, asic, channel) in last TS, per ASIC, sorted with "<" operator.
virtual ~CbmMcbm2018MonitorStsSync()
static constexpr const double kdTimeDiffToMeanMargin
ns
std::vector< TH2 * > fhPulserChanAdcRaw
void UseDaqBuffer(Bool_t)
std::vector< std::vector< TH1 * > > fhPulserTimeDiffClkPerAsicPair
void SetMsOverlap(size_t uOverlapMsNb=1)
TH2 * fhPulserMsStatusFieldType
std::vector< TH2 * > fhPulserChanMissEvtEvo
TH2 * fhPulserSysMessTypePerElink
UInt_t fuNbStsXyters
Number of possible eLinks per DPB.
TString fsHistoFileFullname
static const UInt_t kuBytesPerMessage
std::vector< TH2 * > fhPulserChanHitRateEvoLong
std::map< UInt_t, UInt_t > fDpbIdIndexMap
Total number of Sts DPBs in system.
void SaveAllHistos(TString sFileName="")
CbmCern2017UnpackParHodo * fUnpackParHodo
/** Ignore Overlap Ms: all fuOverlapMsNb MS at the end of timeslice **/
std::vector< TH1 * > fhPulserFebRateEvo
UInt_t fuNbChanPerAsic
Number of StsXyter ASICs.
std::vector< std::vector< std::vector< UInt_t > > > fvuChanNbHitsInMs
Header time of each MS.
void FillTsMsbInfo(stsxyter::Message mess, UInt_t uMessIdx=0, UInt_t uMsIdx=0)
std::vector< UInt_t > fvuInitialHeaderDone
Current TS MSB cycle for DPB.
void SetHistoFileName(TString sFileName="data/SetupHistos.root")
void SetLongDurationLimits(UInt_t uDurationSeconds=3600, UInt_t uBinSize=1)
CbmMcbm2018MonitorStsSync(const CbmMcbm2018MonitorStsSync &)
std::vector< TH1 * > fhPulserIntervalAsic
std::vector< std::vector< std::vector< Double_t > > > fvdLastTimeDiffValuesAsicPair
std::chrono::steady_clock::time_point ftStartTimeUnix
std::vector< std::vector< UInt_t > > fvuLastTimeDiffSlotAsicPair
void SetRunStart(Int_t dateIn, Int_t timeIn, Int_t iBinSize=5)
std::vector< std::vector< TProfile * > > fhPulserTimeDiffEvoPerAsicPairProf
std::vector< UInt_t > fvuInitialTsMsbCycleHeader
Flag set after seeing MS header in 1st MS for DPB.
virtual void AddMsComponentToList(size_t component, UShort_t usDetectorId)
TH2 * fhPulserStatusMessType
std::vector< std::vector< UInt_t > > fvuElinkToAsic
Number of channels per StsXyter ASIC => should be constant somewhere!!!!
std::vector< std::vector< TProfile * > > fhPulserRawTimeDiffEvoPerAsicPairProf
std::map< stsxyter::MessType, UInt_t > fmMsgCounter
std::vector< TH2 * > fhPulserChanMissEvt
virtual Bool_t DoUnpack(const fles::Timeslice &ts, size_t component)
std::vector< std::vector< TProfile * > > fhPulserTsMsbDiffEvoPerAsicPairProf
Bool_t ReInitContainers()
std::vector< std::vector< TH2 * > > fhPulserTsMsbMatchPerAsicPair
UInt_t fuCurrentEquipmentId
std::vector< UInt_t > fvuElinkLastTsHit
TS MSB cycle from MS header in 1st MS for DPB.
std::vector< std::vector< TProfile * > > fhPulserTsLsbDiffEvoPerAsicPairProf
Double_t fdStartTime
Last hit ADC in bins in each MS for each Channel.
void FillHitInfo(stsxyter::Message mess, const UShort_t &usElinkIdx, const UInt_t &uAsicIdx, const UInt_t &uMsIdx)
Int_t fiBinSizeDatePlots
Start of run time since "epoch" in s, for the plots with date as X axis.
std::vector< size_t > fvMsComponentsList
TProfile * fhMsSzTime[kiMaxNbFlibLinks]
void SetPrintMessage(Bool_t bPrintMessOn=kTRUE, stsxyter::MessagePrintMask ctrl=stsxyter::MessagePrintMask::msg_print_Hex|stsxyter::MessagePrintMask::msg_print_Human)
TH2 * fhPulserMessTypePerDpb
std::vector< TH1 * > fhPulserIntervalLongAsic
std::vector< std::vector< TH1 * > > fhPulserTimeDiffPerAsicPair
static constexpr const double kdPulserPeriod
std::vector< ULong64_t > fvulCurrentTsMsb
Bin size in s for the plots with date as X axis.
std::vector< TProfile * > fhPulserChanAdcRawProf
std::vector< std::vector< stsxyter::FinalHit > > fvmAsicHitsInMs
All hits (time in bins, ADC in bins, asic, channel) in last TS, sorted with "<" operator.
std::vector< TH2 * > fhPulserChanHitRateEvo
TH1 * fhPulserMessType
Histogram manager.
std::vector< TH2 * > fhPulserTimeDiffPerAsic
Last hits in each ASIC.
void SetCoincidenceBorder(Double_t dCenterPos, Double_t dBorderVal)
void FillEpochInfo(stsxyter::Message mess)
std::vector< std::vector< std::vector< UShort_t > > > fvusChanLastHitAdcInMs
Last hit time in bins in each MS for each Channel.
void UpdatePairMeanValue(UInt_t uAsicA, UInt_t uAsicB, Double_t dNewValue)
TH1 * fhMsSz[kiMaxNbFlibLinks]
std::vector< TH1 * > fhPulserFebMissEvtEvo
UInt_t fuCurrDpbId
Current equipment ID, tells from which DPB the current MS is originating.
MessagePrintMask
Printout control.