CbmRoot
|
#include <CbmTrdUnpackAlgoBaseR.h>
Public Member Functions | |
CbmTrdUnpackAlgoBaseR (std::string name) | |
Create the Cbm Trd Unpack AlgoBase object. | |
virtual | ~CbmTrdUnpackAlgoBaseR () |
Destroy the Cbm Trd Unpack Task object. | |
CbmTrdUnpackAlgoBaseR (const CbmTrdUnpackAlgoBaseR &)=delete | |
Copy constructor - not implemented. | |
CbmTrdUnpackAlgoBaseR & | operator= (const CbmTrdUnpackAlgoBaseR &)=delete |
Assignment operator - not implemented. | |
void | SetMonitor (std::shared_ptr< CbmTrdUnpackMonitor > monitor) |
Set a predefined monitor. | |
void | SetRawToDigiMethod (std::shared_ptr< CbmTrdRawToDigiBaseR > value) |
Set the Raw To Digi Method. | |
void | SetSpadicObject (std::shared_ptr< CbmTrdSpadic > value) |
Set the Spadic Object. | |
void | SetElinkTimeOffsetMap (std::map< std::uint32_t, std::vector< std::int32_t > > map) |
Register a time offeset to be substracted from the digis which come from a specific CRI. | |
std::int32_t | GetElinkTimeOffset (std::uint32_t criid, std::uint8_t elinkid) |
Get the time offeset to be substracted from the digis which come from a specific CRI. | |
Protected Member Functions | |
void | digestOutput (std::unique_ptr< CbmTrdDigi > digi, CbmTrdRawMessageSpadic raw) |
Handle the output created by the explicit algorithms. E.g. write to output vectors. | |
void | finish () |
Finish function for this algorithm base clase. | |
virtual void | finishDerived ()=0 |
Function that allows special calls during Finish in the derived algos. | |
virtual std::uint32_t | getAsicAddress (std::uint32_t criid, std::uint32_t crobid, std::uint32_t elinkid) |
Get the Asic Address (CbmAddress scheme) for the given hardware Ids. | |
std::uint32_t | getChannelId (std::uint32_t asicaddress, std::uint32_t elinkid, std::uint32_t elinkchannelid) |
Get the Channel Id (CbmAddress scheme) for the given hardware Ids. | |
virtual Bool_t | init () |
Additional initialisation function for all BaseR derived algorithms. | |
Bool_t | initParSet (FairParGenericSet *parset) |
Handles the distribution of the hidden derived classes to their explicit functions. | |
Bool_t | initParSet (CbmTrdParSetAsic *parset) |
Transfer parameters from ParSetAsic container to members. | |
Bool_t | initParSet (CbmTrdParSetDigi *parset) |
Transfer parameters from ParSetDigi container to members. | |
Bool_t | initParSet (CbmMcbm2020TrdTshiftPar *parset) |
Transfer parameters from CbmMcbm2020TrdTshiftPar container to members. | |
Protected Attributes | |
std::shared_ptr< CbmTrdUnpackMonitor > | fMonitor = nullptr |
Potential (online) monitor for the unpacking process. | |
std::shared_ptr< CbmTrdSpadic > | fSpadic = nullptr |
Spadic software reprensentation object. | |
std::shared_ptr< CbmTrdRawToDigiBaseR > | fRTDMethod = nullptr |
raw to digi extraction method, set in the task | |
std::map< size_t, Int_t > | fSpadicAddressMap = {} |
Map to retrieve asic address from CriId/CrobId/ElinkId (see CbmTrdHardwareSetupR) | |
std::map< Int_t, std::vector< Int_t > > | fAsicChannelMap = {} |
Map to retrieve module channelId from asicAddress and asicChannel. | |
std::map< size_t, std::vector< Int_t > > | fTimeshiftsMap = {} |
Map containing the timeshift parameters for the correction of the µSlice timeshifts. The keys are the tsIdx, if no key is found, the shifts of the previous tsIdx are used again. | |
Bool_t | fIsFirstChannelsElinkEven = kFALSE |
Define if the first 16 channels (00..15) are found on the even (set true) or odd (false) eLinkId. Default for mCbm2020 is false thus, initialized as false. | |
size_t | fNrWildRda = 0 |
Number of rda frames outside of a SOM frame range. | |
size_t | fNrWildEom = 0 |
Number of eom frames outside of a SOM frame range. | |
size_t | fNrMissingEom = 0 |
Number of missing EOM frames to finish a SOM frame. | |
size_t | fNrWildNul = 0 |
Number of wild null words, should only appear at the end of a µSlice. | |
size_t | fNrUnknownWords = 0 |
Number of unknown words. | |
size_t | fTsMsbLengthCC = fTsMsbLength / CbmTrdSpadic::GetClockCycle() |
length of one ts_msb in [cc] | |
std::map< std::uint32_t, std::vector< std::int32_t > > | fElinkTimeOffsetMap |
Map to store time offsets for each CRI&Elink combination. | |
Static Protected Attributes | |
static constexpr std::uint16_t | fTsMsbLength = 16000 |
length of one ts_msb in [ns] | |
Definition at line 44 of file CbmTrdUnpackAlgoBaseR.h.
CbmTrdUnpackAlgoBaseR::CbmTrdUnpackAlgoBaseR | ( | std::string | name | ) |
Create the Cbm Trd Unpack AlgoBase object.
Definition at line 20 of file CbmTrdUnpackAlgoBaseR.cxx.
|
virtual |
Destroy the Cbm Trd Unpack Task object.
Definition at line 22 of file CbmTrdUnpackAlgoBaseR.cxx.
|
delete |
Copy constructor - not implemented.
|
protected |
Handle the output created by the explicit algorithms. E.g. write to output vectors.
digi | |
raw |
Definition at line 25 of file CbmTrdUnpackAlgoBaseR.cxx.
References fMonitor.
Referenced by CbmTrdUnpackAlgoLegacy2020R::makeDigi(), and CbmTrdUnpackAlgoR::makeDigi().
|
inlineprotected |
Finish function for this algorithm base clase.
Definition at line 103 of file CbmTrdUnpackAlgoBaseR.h.
References finishDerived(), and fMonitor.
|
protectedpure virtual |
Function that allows special calls during Finish in the derived algos.
Implemented in CbmTrdUnpackAlgoLegacy2020R, and CbmTrdUnpackAlgoR.
Referenced by finish().
|
protectedvirtual |
Get the Asic Address (CbmAddress scheme) for the given hardware Ids.
criid | |
crobid | |
elinkid |
Definition at line 43 of file CbmTrdUnpackAlgoBaseR.cxx.
References fSpadicAddressMap, CbmTrdParAsic::kCriIdPosition, and CbmTrdParAsic::kCrobIdPosition.
Referenced by CbmTrdUnpackAlgoR::digestBufInfoFlags(), CbmTrdUnpackAlgoR::digestInfoMsg(), CbmTrdUnpackAlgoR::digestMsFlags(), CbmTrdUnpackAlgoR::makeDigi(), and CbmTrdUnpackAlgoR::makeDigi().
|
protected |
Get the Channel Id (CbmAddress scheme) for the given hardware Ids.
asicaddress | |
elinkid | |
elinkchannelid |
Definition at line 60 of file CbmTrdUnpackAlgoBaseR.cxx.
References fAsicChannelMap, fIsFirstChannelsElinkEven, and CbmTrdSpadic::GetNrChannels().
Referenced by CbmTrdUnpackAlgoR::makeDigi(), and CbmTrdUnpackAlgoR::makeDigi().
|
inline |
Get the time offeset to be substracted from the digis which come from a specific CRI.
criid |
Definition at line 88 of file CbmTrdUnpackAlgoBaseR.h.
References fElinkTimeOffsetMap.
Referenced by CbmTrdUnpackAlgoR::makeDigi(), and CbmTrdUnpackAlgoR::makeDigi().
|
protectedvirtual |
Additional initialisation function for all BaseR derived algorithms.
Definition at line 145 of file CbmTrdUnpackAlgoBaseR.cxx.
References fMonitor, fRTDMethod, and fSpadic.
|
protected |
Transfer parameters from CbmMcbm2020TrdTshiftPar container to members.
These are mCBM 2020 specific parameters needed to correct in run timeshifts.
parset |
Definition at line 134 of file CbmTrdUnpackAlgoBaseR.cxx.
References fTimeshiftsMap, and CbmMcbm2020TrdTshiftPar::GetTimeshiftsMap().
|
protected |
Transfer parameters from ParSetAsic container to members.
Currently we mainly transfer here the addressing, other parameters are yet to come.
parset |
Definition at line 91 of file CbmTrdUnpackAlgoBaseR.cxx.
References CbmTrdHardwareSetupR::CreateAsicChannelMap(), CbmTrdHardwareSetupR::CreateHwToSwAsicAddressTranslatorMap(), fAsicChannelMap, and fSpadicAddressMap.
|
protected |
Transfer parameters from ParSetDigi container to members.
The monitor needs this to extract module informations, e.g. ncols and nrows.
parset |
Definition at line 115 of file CbmTrdUnpackAlgoBaseR.cxx.
References fMonitor.
|
protected |
Handles the distribution of the hidden derived classes to their explicit functions.
parset |
Definition at line 73 of file CbmTrdUnpackAlgoBaseR.cxx.
References initParSet().
Referenced by initParSet().
|
delete |
Assignment operator - not implemented.
|
inline |
Register a time offeset to be substracted from the digis which come from a specific CRI.
map |
Definition at line 81 of file CbmTrdUnpackAlgoBaseR.h.
References fElinkTimeOffsetMap.
|
inline |
Set a predefined monitor.
monitor | predefined unpacking monitor |
Definition at line 60 of file CbmTrdUnpackAlgoBaseR.h.
References fMonitor.
|
inline |
Set the Raw To Digi Method.
value |
Definition at line 67 of file CbmTrdUnpackAlgoBaseR.h.
References fRTDMethod.
|
inline |
Set the Spadic Object.
value |
Definition at line 74 of file CbmTrdUnpackAlgoBaseR.h.
References fSpadic.
|
protected |
Map to retrieve module channelId from asicAddress and asicChannel.
Definition at line 196 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by getChannelId(), initParSet(), and CbmTrdUnpackAlgoLegacy2020R::makeDigi().
|
protected |
Map to store time offsets for each CRI&Elink combination.
Definition at line 227 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by GetElinkTimeOffset(), and SetElinkTimeOffsetMap().
|
protected |
Define if the first 16 channels (00..15) are found on the even (set true) or odd (false) eLinkId. Default for mCbm2020 is false thus, initialized as false.
Definition at line 203 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by getChannelId(), and CbmTrdUnpackAlgoLegacy2020R::makeDigi().
|
protected |
Potential (online) monitor for the unpacking process.
Definition at line 183 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoR::digestBufInfoFlags(), CbmTrdUnpackAlgoR::digestInfoMsg(), CbmTrdUnpackAlgoR::digestMsFlags(), digestOutput(), finish(), CbmTrdUnpackAlgoLegacy2020R::GetParContainerRequest(), CbmTrdUnpackAlgoR::GetParContainerRequest(), init(), initParSet(), CbmTrdUnpackAlgoR::makeDigi(), SetMonitor(), and CbmTrdUnpackAlgoR::unpack().
|
protected |
Number of missing EOM frames to finish a SOM frame.
Definition at line 212 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoR::finishDerived(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
Number of unknown words.
Definition at line 218 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoLegacy2020R::finishDerived(), CbmTrdUnpackAlgoR::finishDerived(), CbmTrdUnpackAlgoLegacy2020R::unpack(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
Number of eom frames outside of a SOM frame range.
Definition at line 209 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoR::finishDerived(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
Number of wild null words, should only appear at the end of a µSlice.
Definition at line 215 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoR::finishDerived(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
Number of rda frames outside of a SOM frame range.
Definition at line 206 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoLegacy2020R::finishDerived(), CbmTrdUnpackAlgoR::finishDerived(), CbmTrdUnpackAlgoLegacy2020R::unpack(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
raw to digi extraction method, set in the task
Definition at line 190 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by init(), CbmTrdUnpackAlgoLegacy2020R::makeDigi(), CbmTrdUnpackAlgoR::makeDigi(), and SetRawToDigiMethod().
|
protected |
Spadic software reprensentation object.
Definition at line 187 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoLegacy2020R::extractSample(), init(), CbmTrdUnpackAlgoR::makeDigi(), SetSpadicObject(), CbmTrdUnpackAlgoR::unpack(), and CbmTrdUnpackAlgoR::unpackRaw().
|
protected |
Map to retrieve asic address from CriId/CrobId/ElinkId (see CbmTrdHardwareSetupR)
Definition at line 193 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by getAsicAddress(), initParSet(), and CbmTrdUnpackAlgoLegacy2020R::makeDigi().
|
protected |
Map containing the timeshift parameters for the correction of the µSlice timeshifts. The keys are the tsIdx, if no key is found, the shifts of the previous tsIdx are used again.
Definition at line 199 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by initParSet(), and CbmTrdUnpackAlgoLegacy2020R::setDerivedTsParameters().
|
staticconstexprprotected |
length of one ts_msb in [ns]
Definition at line 221 of file CbmTrdUnpackAlgoBaseR.h.
|
protected |
length of one ts_msb in [cc]
Definition at line 224 of file CbmTrdUnpackAlgoBaseR.h.
Referenced by CbmTrdUnpackAlgoR::makeRaw().