CbmRoot
|
Definition of SPADIC parameters. More...
#include <CbmTrdParSpadic.h>
Public Types | |
enum | ECbmTrdComponentIdDecoding : ULong_t { kElinkIdPosition = 1 , kCrobNrPosition = 100 , kCrobIdPosition = 1000 , kCriIdPosition = 100000 } |
Enum for decodation of spadic componentId (Hardware to software mapping) Since the length of the CriIds is currently unknown, this is defined as ULong to not loose the needed precision. More... | |
Public Member Functions | |
CbmTrdParSpadic (Int_t address=0, Int_t FebGrouping=-1, Double_t x=0, Double_t y=0, Double_t z=0, size_t compId=0) | |
virtual | ~CbmTrdParSpadic () |
virtual void | LoadParams (FairParamList *inList) |
Loads the specific params for the spadic placed at fAddress, e.g. channel calibration parameters. | |
virtual Int_t | GetNchannels () const |
virtual Double_t | GetSizeX () const |
virtual Double_t | GetSizeY () const |
virtual Double_t | GetSizeZ () const |
std::vector< UInt_t > | GetSpadicChannelVec () |
Return the vector with the corresponding spadic channel numbers sorted from channel 00..31 in pad plane coordinates. | |
std::uint16_t | GetCriId () |
std::uint8_t | GetCrobId () |
std::uint8_t | GetCrobNumber () |
std::uint8_t | GetElinkId (Int_t channelId) |
eLinkId for the current asic par set and the given channelId (in the asic coordinates, i.e. 00..31). | |
UInt_t | GetElinkNr (Int_t moduleChannel, UInt_t nChannelsPerRow) |
Return the number of the elink (counting started in channel order from bottom left to right) correlated to module wide channel number passed as argument, e.g. 000...767 for the mcbm module type. | |
UInt_t | GetAddressOnModule () const |
Returns the number of the asic on the module counted from top left. | |
Int_t | GetAsicChAddress (const Int_t asicChannel) |
Returns the nth asic Channel in asic coordinates in single asic padplane coordinates. Spadic channels are not mapped from 00 to 31 in padplane coordinates, this function returns the padplane channelnumber in the system of one asic(not in the channel map of a full module !) | |
virtual Double_t | GetX () const |
virtual Double_t | GetY () const |
virtual Double_t | GetZ () const |
virtual Int_t | GetAddress () const |
virtual size_t | GetComponentId () const |
virtual Int_t | GetFebGrouping () const |
virtual std::vector< Int_t > | GetChannelAddresses () const |
virtual bool | IsChannelMasked (int) const |
virtual void | Print (Option_t *opt="") const |
virtual Int_t | QueryChannel (Int_t ch) const |
Query ASIC for specific pad address. | |
virtual void | SetChannelAddress (Int_t address) |
virtual void | SetChannelAddresses (std::vector< Int_t > addresses) |
virtual void | SetFebGrouping (Int_t feb) |
virtual void | SetPosition (Double_t x=0, Double_t y=0, Double_t z=0) |
virtual void | SetComponentId (size_t id) |
virtual uint16_t | GetConfig () const |
virtual int | GetModuleId () const |
virtual uint8_t | GetVersion () const |
virtual void | SetConfigId (uint16_t c) |
virtual void | SetModuleId (int m) |
virtual void | SetVersion (uint8_t v) |
Static Public Member Functions | |
static size_t | CreateComponentId (Int_t criId, Int_t crobId, Int_t nThCrobOnModule, Int_t eLinkId) |
Create the componentId from a given criId, crobId, eLinkId and the nThCrobOnModule count, according to the scheme, defined by ECbmTrdComponentIdDecoding. | |
static Int_t | GetNasicsOnModule (Int_t moduleType) |
Returns the number of asics on a given moduleType defined in eCbmTrdModuleTypes. | |
static Int_t | GetNasicsPerCrob (Int_t moduleType) |
Returns the number of asics per Crob on a given moduleType defined in eCbmTrdModuleTypes. | |
static std::uint16_t | GetCriId (size_t componentId) |
Extracts the CriId from a given componentId - Remark when the par files are created from geometries the CriId is set to the unique module number. | |
static std::uint8_t | GetCrobId (size_t componentId) |
Extracts the CrobId from a given componentId. | |
static std::uint8_t | GetCrobNumber (size_t componentId) |
Extracts the CrobNumber (nTh Crob on the module) from a given componentId. | |
static std::uint8_t | GetElinkId (size_t componentId, Int_t channelId) |
eLinkId for the given asicAddress and channelId (in the asic coordinates, i.e. 00..31). Remark: no check of a correct componentId is performed | |
Protected Attributes | |
Int_t | fAddress |
unique ASIC ID | |
Double_t | fX |
center of asic in global c.s. [cm] | |
Double_t | fY |
center of asic in global c.s. [cm] | |
Double_t | fZ |
center of asic in global c.s. [cm] | |
Int_t | fFebGrouping |
no of ASIC in ROB | |
size_t | fComponentId |
Hardware component Id used for addressing For the digit decoding see ECbmTrdComponentIdDecoding. nTh cRob on the module counted from top to bottom along the sensitive side. This Id is needed to connect the microslice to a given channel, has to be set "by hand", i.e. is not given in the geometry macros. ComponentIdMaps for the Spadic are stored in CbmTrdHardwareSetupR. A macro to write those Ids to the parameter files can be found at https://git.cbm.gsi.de/trd/macros/mcbm2020/blob/master/writeSpadicHwAddresses.C. | |
std::vector< Int_t > | fChannelAddresses |
addresses of individual output channels | |
uint8_t | fVersion = 0 |
version of the parameter | |
uint16_t | fConfig = 0 |
configuration setup of the module | |
int | fModuleId = 0 |
module id | |
Private Member Functions | |
void | FillAsicChannelToElinkMap (std::map< UInt_t, UInt_t > *map) |
Write the eLink to asicChannel mapping to the passed map. | |
Private Attributes | |
const std::vector< UInt_t > | fVecSpadicChannels |
std::map< UInt_t, UInt_t > | fMapAsicChannelToElink = {} |
Static Private Attributes | |
static Double_t | fgSizeX = 6.0 |
SPADIC half size in x [cm]. | |
static Double_t | fgSizeY = 3.0 |
SPADIC half size in y [cm]. | |
static Double_t | fgSizeZ = 0.5 |
SPADIC half size in z [cm]. | |
Definition of SPADIC parameters.
Definition at line 22 of file CbmTrdParSpadic.h.
|
inherited |
Enum for decodation of spadic componentId (Hardware to software mapping) Since the length of the CriIds is currently unknown, this is defined as ULong to not loose the needed precision.
Enumerator | |
---|---|
kElinkIdPosition | |
kCrobNrPosition | |
kCrobIdPosition | |
kCriIdPosition |
Definition at line 28 of file CbmTrdParAsic.h.
CbmTrdParSpadic::CbmTrdParSpadic | ( | Int_t | address = 0, |
Int_t | FebGrouping = -1, | ||
Double_t | x = 0, | ||
Double_t | y = 0, | ||
Double_t | z = 0, | ||
size_t | compId = 0 ) |
Definition at line 22 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::fChannelAddresses, FillAsicChannelToElinkMap(), fMapAsicChannelToElink, and NSPADICCH.
|
inlinevirtual |
Definition at line 26 of file CbmTrdParSpadic.h.
|
static |
Create the componentId from a given criId, crobId, eLinkId and the nThCrobOnModule count, according to the scheme, defined by ECbmTrdComponentIdDecoding.
Definition at line 67 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::kCriIdPosition, CbmTrdParAsic::kCrobIdPosition, and CbmTrdParAsic::kCrobNrPosition.
Referenced by LoadParams().
|
private |
Write the eLink to asicChannel mapping to the passed map.
Definition at line 181 of file CbmTrdParSpadic.cxx.
References fVecSpadicChannels, and NSPADICCH.
Referenced by CbmTrdParSpadic().
|
inlinevirtualinherited |
Definition at line 43 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fAddress.
Referenced by CbmTrdParManager::CreateModuleParameters(), and CbmTrdParModAsic::SetAsicPar().
|
inline |
Returns the number of the asic on the module counted from top left.
Definition at line 69 of file CbmTrdParSpadic.h.
References CbmTrdParAsic::fAddress.
Int_t CbmTrdParSpadic::GetAsicChAddress | ( | const Int_t | asicChannel | ) |
Returns the nth asic Channel in asic coordinates in single asic padplane coordinates. Spadic channels are not mapped from 00 to 31 in padplane coordinates, this function returns the padplane channelnumber in the system of one asic(not in the channel map of a full module !)
< Returns the nth asic Channel in asic coordinates in single asic padplane coordinates. Spadic channels are not mapped from 00 to 31 in padplane coordinates, this function returns the padplane channelnumber in the system of one asic(not in the channel map of a full module !)
Definition at line 169 of file CbmTrdParSpadic.cxx.
References fVecSpadicChannels.
Referenced by CbmTrdParManager::CreateModuleParameters().
|
inlinevirtualinherited |
Definition at line 47 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fChannelAddresses.
Referenced by CbmTrdUnpackFaspMonitor::addParam(), CbmTrdHardwareSetupR::CreateAsicChannelMap(), CbmTaskTrdUnpackParWrite::Init(), and CbmTrdParSetAsic::putParams().
|
inlinevirtualinherited |
Definition at line 44 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fComponentId.
Referenced by CbmTrdHardwareSetupR::CreateHwToSwAsicAddressTranslatorMap(), and CbmTaskTrdUnpackParWrite::Init().
|
inlinevirtualinherited |
Definition at line 17 of file CbmTrdParMod.h.
References CbmTrdParMod::fConfig.
std::uint16_t CbmTrdParSpadic::GetCriId | ( | ) |
Definition at line 76 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::fComponentId, and GetCriId().
Referenced by GetCriId(), and CbmTrdParSetAsic::putParams().
|
static |
Extracts the CriId from a given componentId - Remark when the par files are created from geometries the CriId is set to the unique module number.
Definition at line 79 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::kCriIdPosition.
Referenced by CbmTaskTrdUnpackParWrite::Init().
std::uint8_t CbmTrdParSpadic::GetCrobId | ( | ) |
Definition at line 86 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::fComponentId, and GetCrobId().
Referenced by GetCrobId(), and CbmTrdParSetAsic::putParams().
|
static |
Extracts the CrobId from a given componentId.
Definition at line 89 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::kCriIdPosition, and CbmTrdParAsic::kCrobIdPosition.
Referenced by CbmTaskTrdUnpackParWrite::Init().
std::uint8_t CbmTrdParSpadic::GetCrobNumber | ( | ) |
Definition at line 97 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::fComponentId, and GetCrobNumber().
Referenced by GetCrobNumber(), and CbmTrdParSetAsic::putParams().
|
static |
Extracts the CrobNumber (nTh Crob on the module) from a given componentId.
Definition at line 100 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::kCrobIdPosition, and CbmTrdParAsic::kCrobNrPosition.
std::uint8_t CbmTrdParSpadic::GetElinkId | ( | Int_t | channelId | ) |
eLinkId for the current asic par set and the given channelId (in the asic coordinates, i.e. 00..31).
Definition at line 108 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::fComponentId, and GetElinkId().
|
static |
eLinkId for the given asicAddress and channelId (in the asic coordinates, i.e. 00..31). Remark: no check of a correct componentId is performed
Definition at line 111 of file CbmTrdParSpadic.cxx.
References CbmTrdParAsic::kCrobNrPosition, and NSPADICCH.
Referenced by CbmTrdHardwareSetupR::CreateAsicChannelMap(), CbmTrdHardwareSetupR::CreateHwToSwAsicAddressTranslatorMap(), GetElinkId(), CbmTaskTrdUnpackParWrite::Init(), and CbmTrdParSetAsic::putParams().
UInt_t CbmTrdParSpadic::GetElinkNr | ( | Int_t | moduleChannel, |
UInt_t | nChannelsPerRow ) |
Return the number of the elink (counting started in channel order from bottom left to right) correlated to module wide channel number passed as argument, e.g. 000...767 for the mcbm module type.
< Return the number of the elink (counting started in channel order from bottom left to right) correlated to module wide channel number passed as argument, e.g. 000...767 for the mcbm module type
Definition at line 201 of file CbmTrdParSpadic.cxx.
References fMapAsicChannelToElink, and NSPADICCH.
|
inlinevirtualinherited |
Definition at line 46 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fFebGrouping.
|
inlinevirtualinherited |
Definition at line 18 of file CbmTrdParMod.h.
References CbmTrdParMod::fModuleId.
Referenced by CbmTrdParSet::addParam(), and CbmMcbm2018UnpackerAlgoTrdR::CreateHistogram().
|
static |
Returns the number of asics on a given moduleType defined in eCbmTrdModuleTypes.
Definition at line 137 of file CbmTrdParSpadic.cxx.
Referenced by CbmTrdParManager::CreateModuleParameters(), and GetNasicsPerCrob().
|
static |
Returns the number of asics per Crob on a given moduleType defined in eCbmTrdModuleTypes.
Definition at line 152 of file CbmTrdParSpadic.cxx.
References GetNasicsOnModule().
|
inlinevirtual |
Implements CbmTrdParAsic.
Definition at line 32 of file CbmTrdParSpadic.h.
References NSPADICCH.
Referenced by CbmTrdParManager::CreateModuleParameters().
|
inlinevirtual |
Accessors
Implements CbmTrdParAsic.
Definition at line 34 of file CbmTrdParSpadic.h.
References fgSizeX.
|
inlinevirtual |
|
inlinevirtual |
Definition at line 36 of file CbmTrdParSpadic.h.
References fgSizeZ.
|
inline |
Return the vector with the corresponding spadic channel numbers sorted from channel 00..31 in pad plane coordinates.
Definition at line 43 of file CbmTrdParSpadic.h.
References fVecSpadicChannels.
|
inlinevirtualinherited |
Definition at line 19 of file CbmTrdParMod.h.
References CbmTrdParMod::fVersion.
|
inlinevirtualinherited |
Definition at line 39 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fX.
Referenced by CbmTrdHitRateFastQa::ScanModulePlane().
|
inlinevirtualinherited |
Definition at line 40 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fY.
Referenced by CbmTrdHitRateFastQa::ScanModulePlane().
|
inlinevirtualinherited |
Definition at line 41 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fZ.
|
inlinevirtualinherited |
Reimplemented in CbmTrdParFasp.
Definition at line 48 of file CbmTrdParAsic.h.
Referenced by CbmTrdModuleAbstract::IsChannelMasked().
|
virtual |
Loads the specific params for the spadic placed at fAddress, e.g. channel calibration parameters.
Reimplemented from CbmTrdParAsic.
Definition at line 30 of file CbmTrdParSpadic.cxx.
References CreateComponentId(), CbmTrdParAsic::fAddress, CbmTrdParAsic::fChannelAddresses, CbmTrdParAsic::fComponentId, and NSPADICCH.
|
virtualinherited |
Reimplemented in CbmTrdParFasp.
Definition at line 25 of file CbmTrdParAsic.cxx.
References CbmTrdParAsic::fAddress, CbmTrdParAsic::fX, and CbmTrdParAsic::fY.
Referenced by CbmTrdParFasp::Print().
|
virtualinherited |
Query ASIC for specific pad address.
[in] | ch | pad address within module as provided by CbmTrdModuleAbstract::GetPadAddress() |
Definition at line 31 of file CbmTrdParAsic.cxx.
References CbmTrdParAsic::fChannelAddresses.
Referenced by CbmTrdParManager::CreateModuleParameters(), CbmTrdModuleSim2D::FlushBuffer(), CbmTrdParFasp::GetChannel(), and CbmTrdParAsic::SetChannelAddress().
|
virtualinherited |
Definition at line 41 of file CbmTrdParAsic.cxx.
References CbmTrdParAsic::fChannelAddresses, and CbmTrdParAsic::QueryChannel().
Referenced by CbmTrdParManager::CreateModuleParameters(), CbmTrdParFasp::LoadParams(), CbmTrdParFasp::LoadParams(), and CbmTrdModuleSimR::SetAsicPar().
|
virtualinherited |
Definition at line 51 of file CbmTrdParAsic.cxx.
References CbmTrdParAsic::fChannelAddresses, and CbmTrdParAsic::GetNchannels().
Referenced by CbmTrdParManager::CreateModuleParameters(), and CbmTrdParSetAsic::getParams().
|
inlinevirtualinherited |
Definition at line 65 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fComponentId.
Referenced by CbmTrdParManager::CreateModuleParameters(), CbmTrdParSetAsic::getParams(), and CbmTrdHardwareSetupR::WriteComponentIdsToParams().
|
inlinevirtualinherited |
Definition at line 21 of file CbmTrdParMod.h.
References CbmTrdParMod::fConfig.
|
inlinevirtualinherited |
Definition at line 58 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fFebGrouping.
|
inlinevirtualinherited |
Definition at line 22 of file CbmTrdParMod.h.
References CbmTrdParMod::fModuleId.
Referenced by CbmTrdParManager::CreateModuleParameters(), CbmTrdParSetAsic::getParams(), and CbmTrdParSetGeo::Init().
|
inlinevirtualinherited |
Definition at line 59 of file CbmTrdParAsic.h.
References CbmTrdParAsic::fX, CbmTrdParAsic::fY, CbmTrdParAsic::fZ, x, and y.
|
inlinevirtualinherited |
Definition at line 23 of file CbmTrdParMod.h.
References CbmTrdParMod::fVersion, and v.
|
protectedinherited |
unique ASIC ID
Definition at line 68 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetAddress(), GetAddressOnModule(), CbmTrdParFasp::LoadParams(), LoadParams(), and CbmTrdParAsic::Print().
|
protectedinherited |
addresses of individual output channels
Definition at line 81 of file CbmTrdParAsic.h.
Referenced by CbmTrdParSpadic(), CbmTrdParFasp::GetChannelAddress(), CbmTrdParAsic::GetChannelAddresses(), LoadParams(), CbmTrdParFasp::Print(), CbmTrdParAsic::QueryChannel(), CbmTrdParAsic::SetChannelAddress(), and CbmTrdParAsic::SetChannelAddresses().
|
protectedinherited |
Hardware component Id used for addressing For the digit decoding see ECbmTrdComponentIdDecoding. nTh cRob on the module counted from top to bottom along the sensitive side. This Id is needed to connect the microslice to a given channel, has to be set "by hand", i.e. is not given in the geometry macros. ComponentIdMaps for the Spadic are stored in CbmTrdHardwareSetupR. A macro to write those Ids to the parameter files can be found at https://git.cbm.gsi.de/trd/macros/mcbm2020/blob/master/writeSpadicHwAddresses.C.
Definition at line 78 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetComponentId(), GetCriId(), GetCrobId(), GetCrobNumber(), GetElinkId(), LoadParams(), and CbmTrdParAsic::SetComponentId().
|
protectedinherited |
configuration setup of the module
Definition at line 27 of file CbmTrdParMod.h.
Referenced by CbmTrdParMod::GetConfig(), CbmTrdParModDigi::GetPadPlaneType(), and CbmTrdParMod::SetConfigId().
|
protectedinherited |
no of ASIC in ROB
Definition at line 72 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetFebGrouping(), and CbmTrdParAsic::SetFebGrouping().
|
staticprivate |
SPADIC half size in x [cm].
Definition at line 78 of file CbmTrdParSpadic.h.
Referenced by GetSizeX().
|
staticprivate |
SPADIC half size in y [cm].
Definition at line 79 of file CbmTrdParSpadic.h.
Referenced by GetSizeY().
|
staticprivate |
SPADIC half size in z [cm].
Definition at line 80 of file CbmTrdParSpadic.h.
Referenced by GetSizeZ().
|
private |
Definition at line 84 of file CbmTrdParSpadic.h.
Referenced by CbmTrdParSpadic(), and GetElinkNr().
|
protectedinherited |
module id
Definition at line 28 of file CbmTrdParMod.h.
Referenced by CbmTrdParModGas::CbmTrdParModGas(), CbmTrdParMod::GetModuleId(), CbmTrdParModDigi::Print(), CbmTrdParModGas::Print(), CbmTrdParModGas::SetDriftMap(), and CbmTrdParMod::SetModuleId().
|
private |
Definition at line 82 of file CbmTrdParSpadic.h.
Referenced by FillAsicChannelToElinkMap(), GetAsicChAddress(), and GetSpadicChannelVec().
|
protectedinherited |
version of the parameter
Definition at line 26 of file CbmTrdParMod.h.
Referenced by CbmTrdParModDigi::GetPadPlaneType(), CbmTrdParMod::GetVersion(), and CbmTrdParMod::SetVersion().
|
protectedinherited |
center of asic in global c.s. [cm]
Definition at line 69 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetX(), CbmTrdParAsic::Print(), and CbmTrdParAsic::SetPosition().
|
protectedinherited |
center of asic in global c.s. [cm]
Definition at line 70 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetY(), CbmTrdParAsic::Print(), and CbmTrdParAsic::SetPosition().
|
protectedinherited |
center of asic in global c.s. [cm]
Definition at line 71 of file CbmTrdParAsic.h.
Referenced by CbmTrdParAsic::GetZ(), and CbmTrdParAsic::SetPosition().