CbmRoot
Loading...
Searching...
No Matches
CbmMcbm2018RawConverterGdpb.h
Go to the documentation of this file.
1/* Copyright (C) 2019 Facility for Antiproton and Ion Research in Europe, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Pierre-Alain Loizeau [committer] */
4
5// -----------------------------------------------------------------------------
6// ----- -----
7// ----- CbmMcbm2018RawConverterGdpb -----
8// ----- Created 01.07.2019 by P.-A. Loizeau -----
9// ----- -----
10// -----------------------------------------------------------------------------
11
12#ifndef CbmMcbm2018RawConverterGdpb_H
13#define CbmMcbm2018RawConverterGdpb_H
14
15// Data
16#include "Timeslice.hpp"
17
18#include "gDpbMessv100.h"
19
20// CbmRoot
21#include "CbmMcbmUnpack.h"
22
23// C/C++
24#include <map>
25#include <vector>
26
28
30public:
31 CbmMcbm2018RawConverterGdpb(UInt_t uNbGdpb = 1);
32
35
37
38 virtual Bool_t Init();
39 virtual Bool_t DoUnpack(const fles::Timeslice& ts, size_t component);
40 virtual void Reset();
41
42 virtual void Finish();
43
44 void SetParContainers();
45
46 Bool_t InitContainers();
47
48 Bool_t ReInitContainers();
49
51 void AddMsComponentToList(size_t component, UShort_t usDetectorId);
52 void SetNbMsInTs(size_t /*uCoreMsNb*/, size_t /*uOverlapMsNb*/) {};
53
54 void SetIgnoreOverlapMs(Bool_t bFlagIn = kTRUE) { fbIgnoreOverlapMs = bFlagIn; }
55
56private:
58 TList* fParCList;
61 UInt_t fuNrOfDpbs;
62 std::map<UInt_t, UInt_t> fDpbIdIndexMap;
63
65 static const Int_t kiMaxNbFlibLinks = 32;
66 static const UInt_t kuBytesPerMessage = 8;
67
69 std::vector<Bool_t> fvbMaskedComponents;
70
72 std::vector<size_t> fvMsComponentsList;
75 size_t fuNbMsLoop;
77 Double_t fdMsSizeInNs;
80
83 ULong64_t fulCurrentTsIdx;
84 ULong64_t fulCurrentMsIdx;
85 Double_t fdTsStartTime;
87 Double_t fdMsTime;
88 UInt_t fuMsIndex;
91 UInt_t fuCurrDpbId;
92 UInt_t fuCurrDpbIdx;
93
95 std::vector<std::vector<gdpbv100::Message>*> fvGdpbMessages;
96
98};
99
100#endif
Double_t fdMsSizeInNs
/‍** Ignore Overlap Ms: all fuNbOverMsPerTs MS at the end of timeslice **‍/
std::vector< Bool_t > fvbMaskedComponents
Control flags.
std::map< UInt_t, UInt_t > fDpbIdIndexMap
Total number of gDPBs to convert.
static const Int_t kiMaxNbFlibLinks
Map of DPB Identifier to DPB index.
TList * fParCList
Settings from parameter file.
Double_t fdTsFullSizeInNs
Total size of the core MS in a TS, [nanoseconds].
ULong64_t fulCurrentTsIdx
Total size of the core MS in a TS, [nanoseconds].
std::vector< size_t > fvMsComponentsList
Parameters related to FLES containers.
Double_t fdMsTime
End Time in ns of current TS Core from the index of the first MS first component.
Double_t fdTsStopTimeCore
Time in ns of current TS from the index of the first MS first component.
UInt_t fuCurrDpbId
Current equipment ID, tells from which DPB the current MS is originating.
std::vector< std::vector< gdpbv100::Message > * > fvGdpbMessages
Index of the DPB from which the MS currently unpacked is coming.
UInt_t fuMsIndex
Start Time in ns of current MS from its index field in header.
Double_t fdTsCoreSizeInNs
Size of a single MS, [nanoseconds].
UInt_t fuCurrDpbIdx
Temp holder until Current equipment ID is properly filled in MS.
void SetIgnoreOverlapMs(Bool_t bFlagIn=kTRUE)
CbmMcbm2018RawConverterGdpb operator=(const CbmMcbm2018RawConverterGdpb &)=delete
CbmMcbm2018RawConverterGdpb(const CbmMcbm2018RawConverterGdpb &)=delete
virtual Bool_t DoUnpack(const fles::Timeslice &ts, size_t component)
void AddMsComponentToList(size_t component, UShort_t usDetectorId)
Temp until we change from CbmMcbmUnpack to something else.