CbmRoot
Loading...
Searching...
No Matches
CbmStsUnpackAlgo Class Reference

#include <CbmStsUnpackAlgo.h>

Inheritance diagram for CbmStsUnpackAlgo:
[legend]
Collaboration diagram for CbmStsUnpackAlgo:
[legend]

Public Member Functions

 CbmStsUnpackAlgo ()
 Create the Cbm Sts Unpack AlgoBase object.
 
virtual ~CbmStsUnpackAlgo ()
 Destroy the Cbm Sts Unpack Task object.
 
 CbmStsUnpackAlgo (const CbmStsUnpackAlgo &)=delete
 Copy constructor - not implemented.
 
CbmStsUnpackAlgooperator= (const CbmStsUnpackAlgo &)=delete
 Assignment operator - not implemented.
 
virtual void MaskNoisyChannel (const uint32_t uFeb, const uint32_t uChan, const bool bMasked=true)
 Mask a Noisy Channel.
 
void SetMonitor (std::shared_ptr< CbmStsUnpackMonitor > monitor)
 Set a predefined monitor.
 
void SetMinAdcCut (uint32_t value)
 Set the minimum adc cut value.
 
void SetMinAdcCut (uint32_t febid, uint32_t value)
 
void SetAsicTimeOffsetVec (std::vector< double > value)
 Set the time offset per Asic.
 
void SetWalkMap (const std::map< uint32_t, CbmStsParModule > &mapIn)
 Enable/Disable time-walk correction.
 
void SetDuplicatesRejection (bool bIn=true, bool bDiffAdc=true)
 Enable/Disable the duplicate digis rejection, without or with same ADC checks.
 
void SetFwBinning (bool useFwBinning)
 Enable/Disable firmware binning (switch only supported by older implementations)
 
virtual std::vector< std::pair< std::string, std::shared_ptr< FairParGenericSet > > > * GetParContainerRequest (std::string geoTag, std::uint32_t runId)
 Get the requested parameter containers. To be defined in the derived classes! Return the required parameter containers together with the paths to the ascii files to.
 

Protected Member Functions

uint32_t getAsicIndex (uint32_t dpbidx, uint32_t crobidx, uint16_t elinkidx)
 Get the Asic Index.
 
uint64_t getFullTimeStamp (const uint16_t usRawTs)
 Get the Full Time Stamp from raw time stamp.
 
Bool_t init ()
 Intialisation at begin of run. Special inits of the derived algos.
 
void initDpbIdIndexMap (CbmMcbm2018StsPar *parset)
 Initialize the DpbIdIndexMap with the information from the parset.
 
void initInternalStatus (CbmMcbm2018StsPar *parset)
 experts please add description here
 
Bool_t initParSet (FairParGenericSet *parset)
 Handles the distribution of the hidden derived classes to their explicit functions.
 
Bool_t initParSet (CbmMcbm2018StsPar *parset)
 Initialize the parameters from CbmMcbm2018StsPar.
 
void initTempVectors (CbmMcbm2018StsPar *parset, std::vector< int32_t > *viModuleType, std::vector< int32_t > *viModAddress, std::vector< std::vector< std::vector< int32_t > > > *viFebModuleIdx, std::vector< std::vector< bool > > *vbCrobActiveFlag, std::vector< std::vector< std::vector< int32_t > > > *viFebModuleSide)
 Initialize and transfer the informations to the parameters storage vectors.
 
void loopMsMessages (const uint8_t *msContent, const uint32_t uSize, const size_t uMsIdx)
 Main loop over the sts xyter messages in the µSlices.
 
void printActiveCrobs (CbmMcbm2018StsPar *parset, const std::vector< std::vector< bool > > &vbCrobActiveFlag)
 experts please add description
 
void printAddressMaps (CbmMcbm2018StsPar *parset, const std::vector< std::vector< std::vector< int32_t > > > &viFebModuleIdx, const std::vector< std::vector< std::vector< int32_t > > > &viFebModuleSide)
 experts please add description
 
void processEpochInfo (const stsxyter::Message &)
 experts please add description marked as not used currently
 
void processErrorInfo (const stsxyter::Message &mess)
 experts please add description
 
void processHitInfo (const stsxyter::Message &mess)
 Process the information of the hit message and create a StsDigi from it.
 
void processStatusInfo (const stsxyter::Message &mess, uint32_t uIdx)
 experts please add description
 
void processTsMsbInfo (const stsxyter::Message &mess, uint32_t uMessIdx, uint32_t uMsIdx)
 experts please add description
 
void refreshTsMsbFields (const uint32_t imslice, const size_t mstime)
 experts please add description here
 
bool setDerivedTsParameters (size_t)
 Set the Derived Ts Parameters.
 
bool unpack (const fles::Timeslice *ts, std::uint16_t icomp, UInt_t imslice)
 Unpack a given microslice. To be implemented in the derived unpacker algos.
 
virtual void finish ()
 Finish function for this algorithm base clase.
 

Protected Attributes

uint64_t fMsStartTime = 0
 Current µSlice time.
 
std::map< uint32_t, uint32_t > fDpbIdIndexMap = {}
 Map of DPB Identifier to DPB index.
 
uint32_t fuCurrDpbIdx = 0
 Current dpb id.
 
std::vector< bool > fvbMaskedComponents
 Masked components to print out missing component only once.
 
uint32_t fuNbFebs = 0
 Number of FEBs with StsXyter ASICs.
 
std::vector< uint32_t > fvbFebAdcCut = {}
 ADC cuts for FEBs.
 
uint32_t fNrElinksPerCrob = 0
 Number of eLinks per CROB.
 
uint32_t fNrAsicsPerCrob = 0
 Number of ASICs per CROB.
 
uint32_t fNrAsicsPerFeb = 0
 Number of ASICs per FEB.
 
uint32_t fNrChsPerAsic = 0
 Number of Channels per Asic.
 
uint32_t fNrChsPerFeb = 0
 Number of Channels per FEB.
 
uint32_t fNrCrobPerDpb = 0
 Number of CROBs per DPB.
 
uint32_t fNrFebsPerCrob = 0
 Number of FEBs per CROB.
 
std::vector< int > fElinkIdxToFebIdxVec = {}
 Vector used for the translation between eLink index and FEB index.
 
std::vector< std::pair< uint32_t, uint32_t > > fElinkIdxToAsicIdxVec = {}
 Vector used for the translation between eLink index and Asic index first is feb type A second is feb type b.
 
bool fbUseChannelMask = false
 flag if channel mask is to be used or not. Set automatically via MaskNoisyChannels
 
std::vector< std::vector< bool > > fvvbMaskedChannels = {}
 Vector of channel masks, [ NbFeb ][ NbCHanInFeb ], used only if fbUseChannelMask is true.
 
std::vector< std::vector< std::vector< int32_t > > > fviFebType = {}
 FEB type, [ NbDpb ][ NbCrobPerDpb ][ NbFebsPerCrob ], 0 = A, 1 = B, -1 if inactive.
 
std::vector< bool > fvbFebPulser
 Pulser flag for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].
 
std::vector< int32_t > fviFebAddress
 STS address for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].
 
std::vector< int32_t > fviFebSide
 Module side for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].
 
std::vector< double > fvdFebAdcGain
 ADC gain in e-/b, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].
 
std::vector< double > fvdFebAdcOffs
 ADC offset in e-, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].
 
std::vector< uint64_t > fvulCurrentTsMsb = {}
 Current TS MSB for each DPB.
 
std::vector< uint32_t > fvuCurrentTsMsbCycle = {}
 Current TS MSB cycle for DPB.
 
uint64_t fulTsStartInTsMsb = 0
 Start time of the TS expressed in TS_MSB instead of ns.
 
std::vector< uint64_t > fulTsMsbIndexInTs = {}
 Current TS MSB cycle for DPB relative to TS start.
 
std::vector< std::vector< uint16_t > > fvvusLastTsChan = {}
 TS of last hit message for each channel, [ AsicIdx ][ Chan ].
 
std::vector< std::vector< uint16_t > > fvvusLastAdcChan = {}
 ADC of last hit message for each channel, [ AsicIdx ][ Chan ].
 
std::vector< std::vector< uint64_t > > fvvulLastTsMsbChan = {}
 TS MSB in TS of last hit message for each channel, [ AsicIdx ][ Chan ].
 
std::shared_ptr< CbmStsUnpackMonitorfMonitor = nullptr
 Potential (online) monitor for the unpacking process.
 
uint32_t fdAdcCut = 0
 Minimum adc cut to store a hit.
 
std::map< uint32_t, uint32_t > fdAdcCut_perFeb
 Minimum adc cut per Feb to store a hit.
 
std::vector< double > fvdTimeOffsetNsAsics = {}
 Time offsets per Asic???
 
bool fbUseTimeWalkCorrection = false
 Enable/Disable time-walk correction.
 
std::map< uint32_t, std::vector< std::vector< double > > > fWalkLookup = {}
 Per-ASIC's sensors Time-Walk correction mapping.
 
bool fbRejectDuplicateDigis = false
 Enables the rejection of duplicate digis.
 
bool fbDupliWithoutAdc = true
 If rejecting duplicate digis, enables rejection even if ADC differs.
 
bool fbUseFwBinning = true
 Enables firmware binning (some implementations ignore this)
 

Static Protected Attributes

static const uint32_t kuMaxTsMsbDiffDuplicates = 8
 Duplicate hits suppression.
 

Detailed Description

Definition at line 28 of file CbmStsUnpackAlgo.h.

Constructor & Destructor Documentation

◆ CbmStsUnpackAlgo() [1/2]

CbmStsUnpackAlgo::CbmStsUnpackAlgo ( )

Create the Cbm Sts Unpack AlgoBase object.

Definition at line 19 of file CbmStsUnpackAlgo.cxx.

◆ ~CbmStsUnpackAlgo()

CbmStsUnpackAlgo::~CbmStsUnpackAlgo ( )
virtual

Destroy the Cbm Sts Unpack Task object.

Definition at line 21 of file CbmStsUnpackAlgo.cxx.

◆ CbmStsUnpackAlgo() [2/2]

CbmStsUnpackAlgo::CbmStsUnpackAlgo ( const CbmStsUnpackAlgo & )
delete

Copy constructor - not implemented.

Member Function Documentation

◆ finish()

virtual void CbmStsUnpackAlgoBase::finish ( )
inlineprotectedvirtualinherited

Finish function for this algorithm base clase.

Definition at line 108 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fMonitor.

◆ getAsicIndex()

uint32_t CbmStsUnpackAlgo::getAsicIndex ( uint32_t dpbidx,
uint32_t crobidx,
uint16_t elinkidx )
protected

Get the Asic Index.

Parameters
dpbidx
crobidx
elinkidx

Definition at line 24 of file CbmStsUnpackAlgo.cxx.

References fElinkIdxToAsicIdxVec, fElinkIdxToFebIdxVec, fNrAsicsPerCrob, fNrCrobPerDpb, and fviFebType.

Referenced by processHitInfo(), and processStatusInfo().

◆ getFullTimeStamp()

uint64_t CbmStsUnpackAlgo::getFullTimeStamp ( const uint16_t usRawTs)
protected

Get the Full Time Stamp from raw time stamp.

Parameters
usRawTs
Returns
uint64_t

Definition at line 41 of file CbmStsUnpackAlgo.cxx.

References fuCurrDpbIdx, fulTsMsbIndexInTs, and stsxyter::kuHitNbTsBinsBinning.

Referenced by processHitInfo(), and processStatusInfo().

◆ GetParContainerRequest()

std::vector< std::pair< std::string, std::shared_ptr< FairParGenericSet > > > * CbmStsUnpackAlgoBase::GetParContainerRequest ( std::string geoTag,
std::uint32_t runId )
virtualinherited

Get the requested parameter containers. To be defined in the derived classes! Return the required parameter containers together with the paths to the ascii files to.

Parameters
[in]std::stringgeoTag as used in CbmSetup
[in]std::uint32_trunId for runwise defined parameters
Returns
fParContVec

Definition at line 13 of file CbmStsUnpackAlgoBase.cxx.

◆ init()

Bool_t CbmStsUnpackAlgo::init ( )
protected

Intialisation at begin of run. Special inits of the derived algos.

Return values
Bool_tinitOk

Definition at line 55 of file CbmStsUnpackAlgo.cxx.

References CbmStsUnpackAlgoBase::fbUseFwBinning.

◆ initDpbIdIndexMap()

void CbmStsUnpackAlgo::initDpbIdIndexMap ( CbmMcbm2018StsPar * parset)
protected

Initialize the DpbIdIndexMap with the information from the parset.

Parameters
[in]parsetparameter set for the Sts unpacker

Definition at line 64 of file CbmStsUnpackAlgo.cxx.

References fDpbIdIndexMap, CbmMcbm2018StsPar::GetDpbId(), and CbmMcbm2018StsPar::GetNrOfDpbs().

Referenced by initParSet().

◆ initInternalStatus()

void CbmStsUnpackAlgo::initInternalStatus ( CbmMcbm2018StsPar * parset)
protected

◆ initParSet() [1/2]

Bool_t CbmStsUnpackAlgo::initParSet ( CbmMcbm2018StsPar * parset)
protected

Initialize the parameters from CbmMcbm2018StsPar.

Parameters
parset
Returns
Bool_t initOk

! FIXME: 1) Geometry is using front/back while we are using P/N !!!! => Assuming that front facing modules have connectors on right side +> Volker warns that the front side should be electrons one so N 2) No accessor/setter to change only the side field of an STS address => hardcode the shift +> The bit is unused in the current scheme: the side is encoded in the Digi channel

! FIXME: 1) Geometry is using front/back while we are using P/N !!!! => Assuming that front facing modules have connectors on right side +> Volker warns that the front side should be electrons one so N 2) No accessor/setter to change only the side field of an STS address => hardcode the shift +> The bit is unused in the current scheme: the side is encoded in the Digi channel

Definition at line 88 of file CbmStsUnpackAlgo.cxx.

References CbmMcbm2018StsPar::ElinkIdxToAsicIdxFebA(), CbmMcbm2018StsPar::ElinkIdxToAsicIdxFebB(), CbmMcbm2018StsPar::ElinkIdxToFebIdx(), CbmStsUnpackAlgoBase::fdAdcCut, CbmStsUnpackAlgoBase::fdAdcCut_perFeb, fElinkIdxToAsicIdxVec, fElinkIdxToFebIdxVec, CbmStsUnpackAlgoBase::fMonitor, fNrAsicsPerCrob, fNrAsicsPerFeb, fNrChsPerAsic, fNrChsPerFeb, fNrCrobPerDpb, fNrElinksPerCrob, fNrFebsPerCrob, fuNbFebs, fvbFebAdcCut, fvbFebPulser, fvdFebAdcGain, fvdFebAdcOffs, CbmStsUnpackAlgoBase::fvdTimeOffsetNsAsics, fviFebAddress, fviFebSide, fviFebType, CbmMcbm2018StsPar::GetFebAdcGain(), CbmMcbm2018StsPar::GetFebAdcOffset(), CbmMcbm2018StsPar::GetNbAsicsPerCrob(), CbmMcbm2018StsPar::GetNbAsicsPerFeb(), CbmMcbm2018StsPar::GetNbChanPerAsic(), CbmMcbm2018StsPar::GetNbChanPerFeb(), CbmMcbm2018StsPar::GetNbCrobsPerDpb(), CbmMcbm2018StsPar::GetNbElinkPerCrob(), CbmMcbm2018StsPar::GetNbFebsPerCrob(), CbmMcbm2018StsPar::GetNbOfModules(), CbmMcbm2018StsPar::GetNrOfAsics(), CbmMcbm2018StsPar::GetNrOfDpbs(), CbmMcbm2018StsPar::GetNrOfFebs(), initDpbIdIndexMap(), initInternalStatus(), initTempVectors(), CbmMcbm2018StsPar::IsFebPulser(), printActiveCrobs(), and printAddressMaps().

◆ initParSet() [2/2]

Bool_t CbmStsUnpackAlgo::initParSet ( FairParGenericSet * parset)
protected

Handles the distribution of the hidden derived classes to their explicit functions.

Parameters
parset
Returns
Bool_t initOk

Definition at line 75 of file CbmStsUnpackAlgo.cxx.

References initParSet().

Referenced by initParSet().

◆ initTempVectors()

void CbmStsUnpackAlgo::initTempVectors ( CbmMcbm2018StsPar * parset,
std::vector< int32_t > * viModuleType,
std::vector< int32_t > * viModAddress,
std::vector< std::vector< std::vector< int32_t > > > * viFebModuleIdx,
std::vector< std::vector< bool > > * vbCrobActiveFlag,
std::vector< std::vector< std::vector< int32_t > > > * viFebModuleSide )
protected

◆ loopMsMessages()

void CbmStsUnpackAlgo::loopMsMessages ( const uint8_t * msContent,
const uint32_t uSize,
const size_t uMsIdx )
protected

Main loop over the sts xyter messages in the µSlices.

Parameters
msContent
uSize
uMsIdx
bError
sMessPatt
vNbMessType

Get message type

Definition at line 311 of file CbmStsUnpackAlgo.cxx.

References stsxyter::Dummy, stsxyter::Empty, stsxyter::EndOfMs, stsxyter::Epoch, CbmStsUnpackAlgoBase::fMonitor, fuCurrDpbIdx, stsxyter::Message::GetMessType(), stsxyter::Hit, stsxyter::Message::PrintMessType(), processEpochInfo(), processErrorInfo(), processHitInfo(), processStatusInfo(), processTsMsbInfo(), stsxyter::Status, and stsxyter::TsMsb.

Referenced by unpack().

◆ MaskNoisyChannel()

void CbmStsUnpackAlgo::MaskNoisyChannel ( const uint32_t uFeb,
const uint32_t uChan,
const bool bMasked = true )
virtual

Mask a Noisy Channel.

Parameters
uFeb
uChan
bMasked

Reimplemented from CbmStsUnpackAlgoBase.

Definition at line 376 of file CbmStsUnpackAlgo.cxx.

References fbUseChannelMask, fNrChsPerFeb, fuNbFebs, and fvvbMaskedChannels.

◆ operator=()

CbmStsUnpackAlgo & CbmStsUnpackAlgo::operator= ( const CbmStsUnpackAlgo & )
delete

Assignment operator - not implemented.

◆ printActiveCrobs()

void CbmStsUnpackAlgo::printActiveCrobs ( CbmMcbm2018StsPar * parset,
const std::vector< std::vector< bool > > & vbCrobActiveFlag )
protected

experts please add description

Definition at line 395 of file CbmStsUnpackAlgo.cxx.

References fNrCrobPerDpb, and CbmMcbm2018StsPar::GetNrOfDpbs().

Referenced by initParSet().

◆ printAddressMaps()

void CbmStsUnpackAlgo::printAddressMaps ( CbmMcbm2018StsPar * parset,
const std::vector< std::vector< std::vector< int32_t > > > & viFebModuleIdx,
const std::vector< std::vector< std::vector< int32_t > > > & viFebModuleSide )
protected

◆ processEpochInfo()

void CbmStsUnpackAlgo::processEpochInfo ( const stsxyter::Message & )
inlineprotected

experts please add description marked as not used currently

Definition at line 127 of file CbmStsUnpackAlgo.h.

Referenced by loopMsMessages().

◆ processErrorInfo()

void CbmStsUnpackAlgo::processErrorInfo ( const stsxyter::Message & mess)
protected

◆ processHitInfo()

void CbmStsUnpackAlgo::processHitInfo ( const stsxyter::Message & mess)
protected

Process the information of the hit message and create a StsDigi from it.

Store hit for output only if it is mapped to a module!!!

Store only if masking is disabled or if channeld is not masked 2D vector is safe as always right size if masking enabled

Duplicate hits rejection

FIXME: add plots to check what is done in this rejection

FIXME: see issue #1549 N side: 0-1023 => 0-1023 P side: 0-1023 => 2047-1024

Catch the pulser digis and either save them to their own output or drop them

If EM flag ON, store a corresponding error message with the next flag after all other possible status flags set

Definition at line 454 of file CbmStsUnpackAlgo.cxx.

References CbmStsUnpackAlgoBase::fbDupliWithoutAdc, CbmStsUnpackAlgoBase::fbRejectDuplicateDigis, fbUseChannelMask, CbmStsUnpackAlgoBase::fbUseTimeWalkCorrection, fElinkIdxToFebIdxVec, CbmStsUnpackAlgoBase::fMonitor, fNrAsicsPerFeb, fNrChsPerAsic, fNrChsPerFeb, fNrCrobPerDpb, fNrElinksPerCrob, fNrFebsPerCrob, fuCurrDpbIdx, fulTsMsbIndexInTs, fvbFebAdcCut, fvbFebPulser, fvdFebAdcGain, fvdFebAdcOffs, CbmStsUnpackAlgoBase::fvdTimeOffsetNsAsics, fviFebAddress, fviFebSide, fvvbMaskedChannels, fvvulLastTsMsbChan, fvvusLastAdcChan, fvvusLastTsChan, CbmStsUnpackAlgoBase::fWalkLookup, getAsicIndex(), getFullTimeStamp(), stsxyter::Message::GetHitAdc(), stsxyter::Message::GetHitChannel(), stsxyter::Message::GetHitTimeBinning(), stsxyter::Message::GetLinkIndexHitBinning(), stsxyter::Message::IsHitMissedEvts(), stsxyter::kdClockCycleNs, kSts, and stsxyter::kusLenStatStatus.

Referenced by loopMsMessages().

◆ processStatusInfo()

void CbmStsUnpackAlgo::processStatusInfo ( const stsxyter::Message & mess,
uint32_t uIdx )
protected

◆ processTsMsbInfo()

void CbmStsUnpackAlgo::processTsMsbInfo ( const stsxyter::Message & mess,
uint32_t uMessIdx,
uint32_t uMsIdx )
protected

experts please add description

Case where we reach a normal cycle edge

First TS_MSB in MS may jump if TS dropped by DAQ

Msg 1 and 2 will be same TS_MSB if data in 1st bin

New FW introduced TS_MSB suppression + large TS_MSB => warning only if value not increasing

Values Printout

Definition at line 615 of file CbmStsUnpackAlgo.cxx.

References CbmStsUnpackAlgoBase::fMonitor, fuCurrDpbIdx, fulTsMsbIndexInTs, fulTsStartInTsMsb, fvuCurrentTsMsbCycle, fvulCurrentTsMsb, stsxyter::Message::GetTsMsbValBinning(), stsxyter::kusLenTsMsbValBinning, and stsxyter::kuTsMsbNbTsBinsBinning.

Referenced by loopMsMessages().

◆ refreshTsMsbFields()

void CbmStsUnpackAlgo::refreshTsMsbFields ( const uint32_t imslice,
const size_t mstime )
protected

experts please add description here

Values Printout

Transition at the edge of two MS, the first TS_MSB message (idx 1) will make the cycle

Definition at line 673 of file CbmStsUnpackAlgo.cxx.

References fuCurrDpbIdx, fulTsMsbIndexInTs, fulTsStartInTsMsb, fvuCurrentTsMsbCycle, fvulCurrentTsMsb, stsxyter::kdClockCycleNs, stsxyter::kuHitNbTsBinsBinning, stsxyter::kulTsCycleNbBinsBinning, stsxyter::kusLenTsMsbValBinning, and stsxyter::kuTsMsbNbTsBinsBinning.

Referenced by unpack().

◆ SetAsicTimeOffsetVec()

void CbmStsUnpackAlgoBase::SetAsicTimeOffsetVec ( std::vector< double > value)
inlineinherited

Set the time offset per Asic.

Definition at line 65 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fvdTimeOffsetNsAsics.

◆ setDerivedTsParameters()

bool CbmStsUnpackAlgo::setDerivedTsParameters ( size_t )
inlineprotected

Set the Derived Ts Parameters.

In this function parameters required by the explicit algo connected to the timeslice can be set.

Parameters
itimeslice
Returns
true
false

Definition at line 153 of file CbmStsUnpackAlgo.h.

◆ SetDuplicatesRejection()

void CbmStsUnpackAlgoBase::SetDuplicatesRejection ( bool bIn = true,
bool bDiffAdc = true )
inlineinherited

Enable/Disable the duplicate digis rejection, without or with same ADC checks.

Definition at line 71 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fbDupliWithoutAdc, and CbmStsUnpackAlgoBase::fbRejectDuplicateDigis.

◆ SetFwBinning()

void CbmStsUnpackAlgoBase::SetFwBinning ( bool useFwBinning)
inlineinherited

Enable/Disable firmware binning (switch only supported by older implementations)

Definition at line 78 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fbUseFwBinning.

◆ SetMinAdcCut() [1/2]

void CbmStsUnpackAlgoBase::SetMinAdcCut ( uint32_t febid,
uint32_t value )
inlineinherited

Definition at line 62 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fdAdcCut_perFeb.

◆ SetMinAdcCut() [2/2]

void CbmStsUnpackAlgoBase::SetMinAdcCut ( uint32_t value)
inlineinherited

Set the minimum adc cut value.

Parameters
[in]value

Definition at line 60 of file CbmStsUnpackAlgoBase.h.

References CbmStsUnpackAlgoBase::fdAdcCut.

◆ SetMonitor()

void CbmStsUnpackAlgo::SetMonitor ( std::shared_ptr< CbmStsUnpackMonitor > monitor)
inline

Set a predefined monitor.

Parameters
monitorpredefined unpacking monitor

Definition at line 52 of file CbmStsUnpackAlgo.h.

References CbmStsUnpackAlgoBase::fMonitor.

◆ SetWalkMap()

void CbmStsUnpackAlgoBase::SetWalkMap ( const std::map< uint32_t, CbmStsParModule > & mapIn)
inherited

Enable/Disable time-walk correction.

Definition at line 26 of file CbmStsUnpackAlgoBase.cxx.

References CbmStsUnpackAlgoBase::fbUseTimeWalkCorrection, and CbmStsUnpackAlgoBase::fWalkLookup.

◆ unpack()

bool CbmStsUnpackAlgo::unpack ( const fles::Timeslice * ts,
std::uint16_t icomp,
UInt_t imslice )
protected

Unpack a given microslice. To be implemented in the derived unpacker algos.

Parameters
tstimeslice pointer
icompindex to the component to be unpacked
imsliceindex of the microslice to be unpacked
Returns
true
false
Remarks
The content of the µslice can only be accessed via the timeslice. Hence, we need to pass the pointer to the full timeslice

If monitoring enable, fill here the "Per Timeslice" histograms with info from the previous TS as only way to detect TS transitions due to the multiple calls in case of multiple components. Time set to tlast MS in previous TS. Last TS will be missed.

Check if this sDPB ID was declared in parameter file and stop there if not

If first TS being analyzed, we are probably detecting STS/MUCH boards with same sysid => Do not report the MS as bad, just ignore it

Extract the time base only on MS 0, assuming that we get all TS of a component in order

Definition at line 730 of file CbmStsUnpackAlgo.cxx.

References fDpbIdIndexMap, CbmStsUnpackAlgoBase::fMonitor, fMsStartTime, fuCurrDpbIdx, fulTsStartInTsMsb, fvbMaskedComponents, stsxyter::kdClockCycleNs, stsxyter::kuHitNbTsBinsBinning, loopMsMessages(), and refreshTsMsbFields().

Member Data Documentation

◆ fbDupliWithoutAdc

bool CbmStsUnpackAlgoBase::fbDupliWithoutAdc = true
protectedinherited

If rejecting duplicate digis, enables rejection even if ADC differs.

Definition at line 137 of file CbmStsUnpackAlgoBase.h.

Referenced by CbmStsUnpackAlgoLegacy::ProcessHitInfo(), processHitInfo(), and CbmStsUnpackAlgoBase::SetDuplicatesRejection().

◆ fbRejectDuplicateDigis

bool CbmStsUnpackAlgoBase::fbRejectDuplicateDigis = false
protectedinherited

Enables the rejection of duplicate digis.

Definition at line 134 of file CbmStsUnpackAlgoBase.h.

Referenced by CbmStsUnpackAlgoLegacy::ProcessHitInfo(), processHitInfo(), and CbmStsUnpackAlgoBase::SetDuplicatesRejection().

◆ fbUseChannelMask

bool CbmStsUnpackAlgo::fbUseChannelMask = false
protected

flag if channel mask is to be used or not. Set automatically via MaskNoisyChannels

Definition at line 216 of file CbmStsUnpackAlgo.h.

Referenced by MaskNoisyChannel(), and processHitInfo().

◆ fbUseFwBinning

bool CbmStsUnpackAlgoBase::fbUseFwBinning = true
protectedinherited

◆ fbUseTimeWalkCorrection

bool CbmStsUnpackAlgoBase::fbUseTimeWalkCorrection = false
protectedinherited

Enable/Disable time-walk correction.

Definition at line 128 of file CbmStsUnpackAlgoBase.h.

Referenced by processHitInfo(), and CbmStsUnpackAlgoBase::SetWalkMap().

◆ fdAdcCut

uint32_t CbmStsUnpackAlgoBase::fdAdcCut = 0
protectedinherited

Minimum adc cut to store a hit.

Definition at line 119 of file CbmStsUnpackAlgoBase.h.

Referenced by initParSet(), CbmStsUnpackAlgoLegacy::ProcessHitInfo(), and CbmStsUnpackAlgoBase::SetMinAdcCut().

◆ fdAdcCut_perFeb

std::map<uint32_t, uint32_t> CbmStsUnpackAlgoBase::fdAdcCut_perFeb
protectedinherited

Minimum adc cut per Feb to store a hit.

Definition at line 122 of file CbmStsUnpackAlgoBase.h.

Referenced by initParSet(), and CbmStsUnpackAlgoBase::SetMinAdcCut().

◆ fDpbIdIndexMap

std::map<uint32_t, uint32_t> CbmStsUnpackAlgo::fDpbIdIndexMap = {}
protected

Map of DPB Identifier to DPB index.

Definition at line 174 of file CbmStsUnpackAlgo.h.

Referenced by initDpbIdIndexMap(), and unpack().

◆ fElinkIdxToAsicIdxVec

std::vector<std::pair<uint32_t, uint32_t> > CbmStsUnpackAlgo::fElinkIdxToAsicIdxVec = {}
protected

Vector used for the translation between eLink index and Asic index first is feb type A second is feb type b.

Definition at line 213 of file CbmStsUnpackAlgo.h.

Referenced by getAsicIndex(), and initParSet().

◆ fElinkIdxToFebIdxVec

std::vector<int> CbmStsUnpackAlgo::fElinkIdxToFebIdxVec = {}
protected

Vector used for the translation between eLink index and FEB index.

Definition at line 210 of file CbmStsUnpackAlgo.h.

Referenced by getAsicIndex(), initParSet(), processHitInfo(), and processStatusInfo().

◆ fMonitor

◆ fMsStartTime

uint64_t CbmStsUnpackAlgo::fMsStartTime = 0
protected

Current µSlice time.

Definition at line 170 of file CbmStsUnpackAlgo.h.

Referenced by processErrorInfo(), and unpack().

◆ fNrAsicsPerCrob

uint32_t CbmStsUnpackAlgo::fNrAsicsPerCrob = 0
protected

Number of ASICs per CROB.

Definition at line 192 of file CbmStsUnpackAlgo.h.

Referenced by getAsicIndex(), and initParSet().

◆ fNrAsicsPerFeb

uint32_t CbmStsUnpackAlgo::fNrAsicsPerFeb = 0
protected

Number of ASICs per FEB.

Definition at line 195 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and processHitInfo().

◆ fNrChsPerAsic

uint32_t CbmStsUnpackAlgo::fNrChsPerAsic = 0
protected

Number of Channels per Asic.

Definition at line 198 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), initParSet(), and processHitInfo().

◆ fNrChsPerFeb

uint32_t CbmStsUnpackAlgo::fNrChsPerFeb = 0
protected

Number of Channels per FEB.

Definition at line 201 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), MaskNoisyChannel(), and processHitInfo().

◆ fNrCrobPerDpb

uint32_t CbmStsUnpackAlgo::fNrCrobPerDpb = 0
protected

Number of CROBs per DPB.

Definition at line 204 of file CbmStsUnpackAlgo.h.

Referenced by getAsicIndex(), initParSet(), initTempVectors(), printActiveCrobs(), printAddressMaps(), and processHitInfo().

◆ fNrElinksPerCrob

uint32_t CbmStsUnpackAlgo::fNrElinksPerCrob = 0
protected

Number of eLinks per CROB.

Definition at line 189 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), processHitInfo(), and processStatusInfo().

◆ fNrFebsPerCrob

uint32_t CbmStsUnpackAlgo::fNrFebsPerCrob = 0
protected

Number of FEBs per CROB.

Definition at line 207 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and processHitInfo().

◆ fuCurrDpbIdx

uint32_t CbmStsUnpackAlgo::fuCurrDpbIdx = 0
protected

◆ fulTsMsbIndexInTs

std::vector<uint64_t> CbmStsUnpackAlgo::fulTsMsbIndexInTs = {}
protected

Current TS MSB cycle for DPB relative to TS start.

Definition at line 243 of file CbmStsUnpackAlgo.h.

Referenced by getFullTimeStamp(), initInternalStatus(), processHitInfo(), processTsMsbInfo(), and refreshTsMsbFields().

◆ fulTsStartInTsMsb

uint64_t CbmStsUnpackAlgo::fulTsStartInTsMsb = 0
protected

Start time of the TS expressed in TS_MSB instead of ns.

Definition at line 241 of file CbmStsUnpackAlgo.h.

Referenced by processTsMsbInfo(), refreshTsMsbFields(), and unpack().

◆ fuNbFebs

uint32_t CbmStsUnpackAlgo::fuNbFebs = 0
protected

Number of FEBs with StsXyter ASICs.

Definition at line 183 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and MaskNoisyChannel().

◆ fvbFebAdcCut

std::vector<uint32_t> CbmStsUnpackAlgo::fvbFebAdcCut = {}
protected

ADC cuts for FEBs.

Definition at line 186 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and processHitInfo().

◆ fvbFebPulser

std::vector<bool> CbmStsUnpackAlgo::fvbFebPulser
protected

Pulser flag for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].

Definition at line 225 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and processHitInfo().

◆ fvbMaskedComponents

std::vector<bool> CbmStsUnpackAlgo::fvbMaskedComponents
protected

Masked components to print out missing component only once.

Definition at line 180 of file CbmStsUnpackAlgo.h.

Referenced by unpack().

◆ fvdFebAdcGain

std::vector<double> CbmStsUnpackAlgo::fvdFebAdcGain
protected

ADC gain in e-/b, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].

Definition at line 231 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), printAddressMaps(), and processHitInfo().

◆ fvdFebAdcOffs

std::vector<double> CbmStsUnpackAlgo::fvdFebAdcOffs
protected

ADC offset in e-, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].

Definition at line 233 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), printAddressMaps(), and processHitInfo().

◆ fvdTimeOffsetNsAsics

std::vector<double> CbmStsUnpackAlgoBase::fvdTimeOffsetNsAsics = {}
protectedinherited

◆ fviFebAddress

std::vector<int32_t> CbmStsUnpackAlgo::fviFebAddress
protected

STS address for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].

Definition at line 227 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), printAddressMaps(), and processHitInfo().

◆ fviFebSide

std::vector<int32_t> CbmStsUnpackAlgo::fviFebSide
protected

Module side for each FEB, [ NbDpb * NbCrobPerDpb * NbFebsPerCrob ].

Definition at line 229 of file CbmStsUnpackAlgo.h.

Referenced by initParSet(), and processHitInfo().

◆ fviFebType

std::vector<std::vector<std::vector<int32_t> > > CbmStsUnpackAlgo::fviFebType = {}
protected

FEB type, [ NbDpb ][ NbCrobPerDpb ][ NbFebsPerCrob ], 0 = A, 1 = B, -1 if inactive.

Definition at line 222 of file CbmStsUnpackAlgo.h.

Referenced by getAsicIndex(), initParSet(), and printAddressMaps().

◆ fvuCurrentTsMsbCycle

std::vector<uint32_t> CbmStsUnpackAlgo::fvuCurrentTsMsbCycle = {}
protected

Current TS MSB cycle for DPB.

Definition at line 238 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), processTsMsbInfo(), and refreshTsMsbFields().

◆ fvulCurrentTsMsb

std::vector<uint64_t> CbmStsUnpackAlgo::fvulCurrentTsMsb = {}
protected

Current TS MSB for each DPB.

Definition at line 236 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), processTsMsbInfo(), and refreshTsMsbFields().

◆ fvvbMaskedChannels

std::vector<std::vector<bool> > CbmStsUnpackAlgo::fvvbMaskedChannels = {}
protected

Vector of channel masks, [ NbFeb ][ NbCHanInFeb ], used only if fbUseChannelMask is true.

Definition at line 219 of file CbmStsUnpackAlgo.h.

Referenced by MaskNoisyChannel(), and processHitInfo().

◆ fvvulLastTsMsbChan

std::vector<std::vector<uint64_t> > CbmStsUnpackAlgo::fvvulLastTsMsbChan = {}
protected

TS MSB in TS of last hit message for each channel, [ AsicIdx ][ Chan ].

Definition at line 252 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), and processHitInfo().

◆ fvvusLastAdcChan

std::vector<std::vector<uint16_t> > CbmStsUnpackAlgo::fvvusLastAdcChan = {}
protected

ADC of last hit message for each channel, [ AsicIdx ][ Chan ].

Definition at line 250 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), and processHitInfo().

◆ fvvusLastTsChan

std::vector<std::vector<uint16_t> > CbmStsUnpackAlgo::fvvusLastTsChan = {}
protected

TS of last hit message for each channel, [ AsicIdx ][ Chan ].

Definition at line 248 of file CbmStsUnpackAlgo.h.

Referenced by initInternalStatus(), and processHitInfo().

◆ fWalkLookup

std::map<uint32_t, std::vector<std::vector<double> > > CbmStsUnpackAlgoBase::fWalkLookup = {}
protectedinherited

Per-ASIC's sensors Time-Walk correction mapping.

Definition at line 131 of file CbmStsUnpackAlgoBase.h.

Referenced by processHitInfo(), and CbmStsUnpackAlgoBase::SetWalkMap().

◆ kuMaxTsMsbDiffDuplicates

const uint32_t CbmStsUnpackAlgo::kuMaxTsMsbDiffDuplicates = 8
staticprotected

Duplicate hits suppression.

Definition at line 246 of file CbmStsUnpackAlgo.h.


The documentation for this class was generated from the following files: