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

#include <CbmPsdUnpackAlgo.h>

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

Public Member Functions

 CbmPsdUnpackAlgo ()
 Create the Cbm Trd Unpack AlgoBase object.
 
virtual ~CbmPsdUnpackAlgo ()
 Destroy the Cbm Trd Unpack Task object.
 
 CbmPsdUnpackAlgo (const CbmPsdUnpackAlgo &)=delete
 Copy constructor - not implemented.
 
CbmPsdUnpackAlgooperator= (const CbmPsdUnpackAlgo &)=delete
 Assignment operator - not implemented.
 
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

void finish ()
 Finish function for this algorithm base clase.
 
virtual void finishDerived ()
 Function that allows special calls during Finish in the derived algos.
 
Int_t getAddress (size_t channel)
 Get channel address.
 
double getMipCalibration (uint8_t channel)
 Energy calibration constants.
 
virtual Bool_t init ()
 Intialisation at begin of run. Special inits of the derived algos.
 
void makeDigi (CbmPsdDsp dsp)
 Create a digi object from the signal.
 
Bool_t initParSet (FairParGenericSet *parset)
 Handles the distribution of the hidden derived classes to their explicit functions.
 
Bool_t initParSet (CbmMcbm2018PsdPar *parset)
 Handles the distribution of the hidden derived classes to their explicit functions.
 
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.
 

Protected Attributes

UInt_t fuRawDataVersion = 0
 
std::map< UInt_t, UInt_t > fGdpbIdIndexMap = {}
 
std::vector< Bool_t > fvbMaskedComponents = {}
 gDPB ID to index map
 
UInt_t fuNrOfGbtx = 0
 Detector Mapping.
 
UInt_t fuNrOfModules = 0
 
std::vector< Int_t > fviPsdChUId = {}
 
std::vector< Int_t > fChannelAddress = {}
 
std::vector< double > fMipCalibration = {}
 
Double_t fdTimeOffsetNs = 0.0
 User settings: Data correction parameters.
 

Static Protected Attributes

static const Int_t kiMaxNbFlibLinks = 32
 Constants.
 
static const UInt_t kuBytesPerMessage = 8
 
static const UInt_t kuDetMask = 0x0001FFFF
 

Detailed Description

Definition at line 38 of file CbmPsdUnpackAlgo.h.

Constructor & Destructor Documentation

◆ CbmPsdUnpackAlgo() [1/2]

CbmPsdUnpackAlgo::CbmPsdUnpackAlgo ( )

Create the Cbm Trd Unpack AlgoBase object.

Definition at line 22 of file CbmPsdUnpackAlgo.cxx.

◆ ~CbmPsdUnpackAlgo()

CbmPsdUnpackAlgo::~CbmPsdUnpackAlgo ( )
virtual

Destroy the Cbm Trd Unpack Task object.

Definition at line 325 of file CbmPsdUnpackAlgo.cxx.

◆ CbmPsdUnpackAlgo() [2/2]

CbmPsdUnpackAlgo::CbmPsdUnpackAlgo ( const CbmPsdUnpackAlgo & )
delete

Copy constructor - not implemented.

Member Function Documentation

◆ finish()

void CbmPsdUnpackAlgo::finish ( )
inlineprotected

Finish function for this algorithm base clase.

Definition at line 67 of file CbmPsdUnpackAlgo.h.

References finishDerived().

◆ finishDerived()

virtual void CbmPsdUnpackAlgo::finishDerived ( )
inlineprotectedvirtual

Function that allows special calls during Finish in the derived algos.

Definition at line 75 of file CbmPsdUnpackAlgo.h.

Referenced by finish().

◆ getAddress()

Int_t CbmPsdUnpackAlgo::getAddress ( size_t channel)
protected

Get channel address.

Parameters
channelChannel index
Returns
Channel address

Definition at line 25 of file CbmPsdUnpackAlgo.cxx.

References fChannelAddress.

◆ getMipCalibration()

Double_t CbmPsdUnpackAlgo::getMipCalibration ( uint8_t channel)
protected

Energy calibration constants.

Parameters
channelChannel number
Returns
Energy calibration constant

Definition at line 33 of file CbmPsdUnpackAlgo.cxx.

References fMipCalibration.

Referenced by unpack().

◆ GetParContainerRequest()

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

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 42 of file CbmPsdUnpackAlgo.cxx.

◆ init()

Bool_t CbmPsdUnpackAlgo::init ( )
protectedvirtual

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

Return values
Bool_tinitOk

Definition at line 56 of file CbmPsdUnpackAlgo.cxx.

◆ initParSet() [1/2]

◆ initParSet() [2/2]

Bool_t CbmPsdUnpackAlgo::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 59 of file CbmPsdUnpackAlgo.cxx.

References initParSet().

Referenced by initParSet().

◆ makeDigi()

void CbmPsdUnpackAlgo::makeDigi ( CbmPsdDsp dsp)
protected

Create a digi object from the signal.

Parameters
dspSignal object

Definition at line 123 of file CbmPsdUnpackAlgo.cxx.

References CbmPsdDsp::GetAddress(), CbmPsdDsp::GetEdep(), and CbmPsdDsp::GetTime().

Referenced by unpack().

◆ operator=()

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

Assignment operator - not implemented.

◆ unpack()

bool CbmPsdUnpackAlgo::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

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

Try to get it from the second message in buffer (first is epoch cycle without gDPB ID) TODO!!!!

Save start time of first valid MS

Todo
check if this is really needed

Energy deposition from FPGA [MeV]

ZeroLevel from waveform [adc counts]

FPGA FEE Accumulator

Adc time of measurement

Energy deposition from waveform [MeV]

Amplitude from waveform [mV]

Minimum of waveform [adc samples]

Time of maximum in waveform [adc samples]

Amplitude from fit of waveform [mV]

ZeroLevel from fit of waveform [adc counts]

Energy deposition from fit of waveform [MeV]

Quality of waveform fit [] – good near 0

Time of maximum in fit of waveform [adc samples]

Definition at line 136 of file CbmPsdUnpackAlgo.cxx.

References PsdSignalFitting::PronyFitter::CalculateFitAmplitudes(), PsdSignalFitting::PronyFitter::ChooseBestSignalBegin(), fdTimeOffsetNs, fGdpbIdIndexMap, fvbMaskedComponents, fviPsdChUId, PsdSignalFitting::PronyFitter::GetFitWfm(), PsdSignalFitting::PronyFitter::GetIntegral(), PsdSignalFitting::PronyFitter::GetMaxAmplitude(), getMipCalibration(), PsdSignalFitting::PronyFitter::GetRSquare(), PsdSignalFitting::PronyFitter::GetSignalMaxTime(), PsdDataV100::PsdGbtReader::GetTotalGbtWordsRead(), PsdSignalFitting::PronyFitter::GetZeroLevel(), PsdDataV100::PsdGbtReader::HitHdr, kuBytesPerMessage, makeDigi(), PsdDataV100::PsdGbtReader::PrintOut(), PsdDataV100::PsdGbtReader::ReadMs(), PsdSignalFitting::PronyFitter::SetDebugMode(), PsdSignalFitting::PronyFitter::SetExternalHarmonics(), PsdDataV100::PsdGbtReader::SetPrintOutMode(), PsdSignalFitting::PronyFitter::SetSignalBegin(), PsdSignalFitting::PronyFitter::SetWaveform(), PsdDataV100::PsdHitHeader::uHitChannel, PsdDataV100::PsdHitHeader::uWfmWords, PsdDataV100::PsdGbtReader::VectHitData, PsdDataV100::PsdGbtReader::VectHitHdr, and PsdDataV100::PsdGbtReader::VectPackHdr.

Member Data Documentation

◆ fChannelAddress

std::vector<Int_t> CbmPsdUnpackAlgo::fChannelAddress = {}
protected

Definition at line 144 of file CbmPsdUnpackAlgo.h.

Referenced by getAddress().

◆ fdTimeOffsetNs

Double_t CbmPsdUnpackAlgo::fdTimeOffsetNs = 0.0
protected

User settings: Data correction parameters.

Definition at line 150 of file CbmPsdUnpackAlgo.h.

Referenced by unpack().

◆ fGdpbIdIndexMap

std::map<UInt_t, UInt_t> CbmPsdUnpackAlgo::fGdpbIdIndexMap = {}
protected

Raw data versioning Readout chain dimensions and mapping

Definition at line 133 of file CbmPsdUnpackAlgo.h.

Referenced by initParSet(), and unpack().

◆ fMipCalibration

std::vector<double> CbmPsdUnpackAlgo::fMipCalibration = {}
protected

Definition at line 147 of file CbmPsdUnpackAlgo.h.

Referenced by getMipCalibration(), and initParSet().

◆ fuNrOfGbtx

UInt_t CbmPsdUnpackAlgo::fuNrOfGbtx = 0
protected

Detector Mapping.

Definition at line 138 of file CbmPsdUnpackAlgo.h.

Referenced by initParSet().

◆ fuNrOfModules

UInt_t CbmPsdUnpackAlgo::fuNrOfModules = 0
protected

Definition at line 139 of file CbmPsdUnpackAlgo.h.

◆ fuRawDataVersion

UInt_t CbmPsdUnpackAlgo::fuRawDataVersion = 0
protected

Definition at line 131 of file CbmPsdUnpackAlgo.h.

Referenced by initParSet().

◆ fvbMaskedComponents

std::vector<Bool_t> CbmPsdUnpackAlgo::fvbMaskedComponents = {}
protected

gDPB ID to index map

Definition at line 134 of file CbmPsdUnpackAlgo.h.

Referenced by unpack().

◆ fviPsdChUId

std::vector<Int_t> CbmPsdUnpackAlgo::fviPsdChUId = {}
protected

Definition at line 140 of file CbmPsdUnpackAlgo.h.

Referenced by initParSet(), and unpack().

◆ kiMaxNbFlibLinks

const Int_t CbmPsdUnpackAlgo::kiMaxNbFlibLinks = 32
staticprotected

Constants.

Definition at line 153 of file CbmPsdUnpackAlgo.h.

◆ kuBytesPerMessage

const UInt_t CbmPsdUnpackAlgo::kuBytesPerMessage = 8
staticprotected

Definition at line 154 of file CbmPsdUnpackAlgo.h.

Referenced by unpack().

◆ kuDetMask

const UInt_t CbmPsdUnpackAlgo::kuDetMask = 0x0001FFFF
staticprotected

Definition at line 155 of file CbmPsdUnpackAlgo.h.


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