CbmRoot
Loading...
Searching...
No Matches
cbm::algo::sts::UnpackMS Class Reference

Unpack algorithm for STS. More...

#include <UnpackMS.h>

Inheritance diagram for cbm::algo::sts::UnpackMS:
[legend]
Collaboration diagram for cbm::algo::sts::UnpackMS:
[legend]

Classes

struct  TimeSpec
 Structure to hold the current time information for the current microslice. More...
 

Public Types

using Digi_t
 
using Monitor_t
 
using Aux_t
 
using Result_t
 

Public Member Functions

 UnpackMS (const UnpackPar &pars)
 Default constructor.
 
 ~UnpackMS () override
 Destructor.
 
Result_t operator() (const uint8_t *msContent, const fles::MicrosliceDescriptor &msDescr, const uint64_t tTimeslice) const override
 Algorithm execution.
 
void SetParams (std::unique_ptr< UnpackPar > params)
 Set the parameter container.
 

Private Member Functions

void ProcessHitMessage (const stsxyter::Message &message, const TimeSpec &time, std::vector< CbmStsDigi > &digiVec, UnpackMonitorData &monitor, UnpackAuxData &aux) const
 Process a hit message.
 
void ProcessTsmsbMessage (const stsxyter::Message &message, TimeSpec &time) const
 Process an epoch message (TS_MSB)
 

Private Attributes

UnpackPar fParams = {}
 Parameter container.
 

Static Private Attributes

static constexpr uint64_t fkEpochsPerCycle = stsxyter::kuTsMsbNbTsBinsBinning
 
static constexpr uint64_t fkEpochLength = stsxyter::kuHitNbTsBinsBinning
 
static constexpr uint32_t fkClockCycleNom = stsxyter::kulClockCycleNom
 
static constexpr uint32_t fkClockCycleDen = stsxyter::kulClockCycleDen
 
static constexpr uint64_t fkCycleLength = (fkEpochsPerCycle * fkEpochLength * fkClockCycleNom) / fkClockCycleDen
 

Detailed Description

Unpack algorithm for STS.

Author
Pierre-Alain Loizeau p.-a..nosp@m.loiz.nosp@m.eau@g.nosp@m.si.d.nosp@m.e
Volker Friese v.fri.nosp@m.ese@.nosp@m.gsi.d.nosp@m.e
Since
25 November 2021

Definition at line 117 of file sts/UnpackMS.h.

Member Typedef Documentation

◆ Aux_t

Definition at line 23 of file UnpackMSBase.h.

◆ Digi_t

Definition at line 21 of file UnpackMSBase.h.

◆ Monitor_t

Definition at line 22 of file UnpackMSBase.h.

◆ Result_t

Definition at line 25 of file UnpackMSBase.h.

Constructor & Destructor Documentation

◆ UnpackMS()

cbm::algo::sts::UnpackMS::UnpackMS ( const UnpackPar & pars)

Default constructor.

Definition at line 23 of file sts/UnpackMS.cxx.

◆ ~UnpackMS()

cbm::algo::sts::UnpackMS::~UnpackMS ( )
overridedefault

Destructor.

Member Function Documentation

◆ operator()()

UnpackMS::Result_t cbm::algo::sts::UnpackMS::operator() ( const uint8_t * msContent,
const fles::MicrosliceDescriptor & msDescr,
const uint64_t tTimeslice ) const
overridevirtual

Algorithm execution.

Parameters
msContentMicroslice payload
msDescrMicroslice descriptor
tTimesliceUnix start time of timeslice [ns]
Returns
STS digi data

Implements cbm::algo::UnpackMSBase< CbmStsDigi, UnpackMonitorData, UnpackAuxData >.

Definition at line 27 of file sts/UnpackMS.cxx.

References cbm::algo::sts::UnpackMS::TimeSpec::currentCycle, cbm::algo::sts::UnpackMS::TimeSpec::currentTsTime, stsxyter::Epoch, fkClockCycleDen, fkClockCycleNom, fkCycleLength, fkEpochLength, stsxyter::Hit, L_, ProcessHitMessage(), ProcessTsmsbMessage(), and stsxyter::TsMsb.

◆ ProcessHitMessage()

void cbm::algo::sts::UnpackMS::ProcessHitMessage ( const stsxyter::Message & message,
const TimeSpec & time,
std::vector< CbmStsDigi > & digiVec,
UnpackMonitorData & monitor,
UnpackAuxData & aux ) const
private

Process a hit message.

Parameters
messageSMX message (32-bit word)
digiVecVector to append the created digi to
monitorReference to monitor object
auxReference to auxiliary data object

Referenced by operator()().

◆ ProcessTsmsbMessage()

void cbm::algo::sts::UnpackMS::ProcessTsmsbMessage ( const stsxyter::Message & message,
TimeSpec & time ) const
inlineprivate

◆ SetParams()

void cbm::algo::sts::UnpackMS::SetParams ( std::unique_ptr< UnpackPar > params)
inline

Set the parameter container.

Parameters
paramsPointer to parameter container

Definition at line 140 of file sts/UnpackMS.h.

References fParams.

Member Data Documentation

◆ fkClockCycleDen

uint32_t cbm::algo::sts::UnpackMS::fkClockCycleDen = stsxyter::kulClockCycleDen
staticconstexprprivate

Definition at line 180 of file sts/UnpackMS.h.

Referenced by operator()().

◆ fkClockCycleNom

uint32_t cbm::algo::sts::UnpackMS::fkClockCycleNom = stsxyter::kulClockCycleNom
staticconstexprprivate

Clock cycle nominator [ns] and denominator. The clock cycle in ns is nominator / denominator.

Definition at line 179 of file sts/UnpackMS.h.

Referenced by operator()().

◆ fkCycleLength

uint64_t cbm::algo::sts::UnpackMS::fkCycleLength = (fkEpochsPerCycle * fkEpochLength * fkClockCycleNom) / fkClockCycleDen
staticconstexprprivate

Epoch cycle length in ns

Definition at line 183 of file sts/UnpackMS.h.

Referenced by operator()().

◆ fkEpochLength

uint64_t cbm::algo::sts::UnpackMS::fkEpochLength = stsxyter::kuHitNbTsBinsBinning
staticconstexprprivate

Length of TS_MSB epoch in clock cycles

Definition at line 176 of file sts/UnpackMS.h.

Referenced by operator()(), and ProcessTsmsbMessage().

◆ fkEpochsPerCycle

uint64_t cbm::algo::sts::UnpackMS::fkEpochsPerCycle = stsxyter::kuTsMsbNbTsBinsBinning
staticconstexprprivate

Number of TS_MSB epochs per cycle

Definition at line 173 of file sts/UnpackMS.h.

Referenced by ProcessTsmsbMessage().

◆ fParams

UnpackPar cbm::algo::sts::UnpackMS::fParams = {}
private

Parameter container.

Definition at line 170 of file sts/UnpackMS.h.

Referenced by SetParams().


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