CbmRoot
|
Parameters of the STS readout ASIC. More...
#include <CbmStsParAsic.h>
Public Member Functions | |
CbmStsParAsic () | |
Default constructor. | |
CbmStsParAsic (uint16_t nChannels, uint16_t nAdc, double dynRange, double threshold, double timeResol, double deadTime, double noise, double znr) | |
Constructor with parameters. | |
CbmStsParAsic (const CbmStsParAsic &) | |
Copy constructor (implicitely disable move constructor and assignment) | |
CbmStsParAsic & | operator= (const CbmStsParAsic &other) |
Copy assignment operator. | |
~CbmStsParAsic () | |
Destructor. | |
double | AdcToCharge (uint16_t adc) const |
Charge from ADC channel (mean) | |
uint16_t | DeactivateRandomChannels (double fraction) |
Randomly deactivate a fraction of the channels. | |
uint16_t | ChargeToAdc (double charge) const |
ADC channel for a given charge. | |
double | GetDeadTime () const |
Single-channel dead time. | |
double | GetDynRange () const |
Dynamic range of ADC. | |
uint16_t | GetNofAdc () const |
Number of ADC channels. | |
uint16_t | GetNofChannels () const |
Number of readout channels. | |
double | GetNoise () const |
Electronic noise RMS. | |
double | GetNoiseRate () const |
Single-channel noise rate. | |
double | GetRandomNoiseCharge () const |
Random noise charge. | |
double | GetThreshold () const |
ADC Threshold. | |
double | GetTimeResol () const |
Time resolution. | |
double | GetZeroNoiseRate () const |
Zero-crossing noise rate. | |
void | Init () |
Initialisation. | |
Bool_t | IsChannelActive (uint16_t channel) const |
Check for a channel being active. | |
void | Set (uint16_t nChannels, uint16_t nAdc, double dynRange, double threshold, double timeResol, double deadTime, double noise, double zeroNoiseRate, std::set< uint16_t > deadChannels={}) |
Set parameters. | |
void | SetTimeOffset (double offset) |
Set time offset. | |
void | SetWalkCoef (std::array< double, 31 > par) |
Set coefficients for walk correction. | |
double | GetWalkCoef (uint32_t uIdx) const |
Get one of the coefficients for walk correction. | |
std::string | ToString () const |
Info to string. | |
Private Member Functions | |
ClassDefNV (CbmStsParAsic, 4) | |
Private Attributes | |
uint16_t | fNofChannels = 0 |
Number of readout channels. | |
uint16_t | fNofAdc = 0 |
Number of ADC channels. | |
double | fDynRange = 0. |
Dynamic range [e]. | |
double | fThreshold = 0. |
Threshold [e]. | |
double | fTimeResolution = 0. |
Time resolution [ns]. | |
double | fDeadTime = 0. |
Channel dead time [ns]. | |
double | fNoise = 0. |
RMS of noise [e]. | |
double | fZeroNoiseRate = 0. |
Zero-crossing noise rate [1/ns]. | |
double | fTimeOffset = 0. |
Time offset [ns]. | |
std::array< double, 31 > | fWalkCoef = {} |
Parameters for correction of walk effect. | |
std::set< uint16_t > | fDeadChannels {} |
Map of dead channels. | |
bool | fIsInit = kFALSE |
TF1 * | fNoiseCharge = nullptr |
Flag for being initialised. | |
Parameters of the STS readout ASIC.
This class represents the configuration parameters of a readout ASIC of the STS (STSXYTER).
Definition at line 24 of file CbmStsParAsic.h.
|
inline |
Default constructor.
Definition at line 28 of file CbmStsParAsic.h.
CbmStsParAsic::CbmStsParAsic | ( | uint16_t | nChannels, |
uint16_t | nAdc, | ||
double | dynRange, | ||
double | threshold, | ||
double | timeResol, | ||
double | deadTime, | ||
double | noise, | ||
double | znr ) |
Constructor with parameters.
nChannels | Number of readout channels |
nAdc | Number of ADC channels |
dynRange | Dynamic range of ADC [e] |
threshold | ADC threshold [e] |
timeResol | Time resolution [ns] |
deadTime | Single-channel dead time [ns] |
noise | Noise RMS [e] |
znr | Zero-crossing noise rate [1/ns] |
CbmStsParAsic::CbmStsParAsic | ( | const CbmStsParAsic & | other | ) |
Copy constructor (implicitely disable move constructor and assignment)
Definition at line 30 of file CbmStsParAsic.cxx.
References fDeadTime, fDynRange, fNofAdc, fNofChannels, fNoise, fThreshold, fTimeOffset, fTimeResolution, fWalkCoef, fZeroNoiseRate, Set(), SetTimeOffset(), and SetWalkCoef().
CbmStsParAsic::~CbmStsParAsic | ( | ) |
|
inline |
Charge from ADC channel (mean)
adc | ADC channel |
Definition at line 61 of file CbmStsParAsic.h.
References fDynRange, fNofAdc, and fThreshold.
Referenced by TEST(), TEST(), TEST(), and CbmStsAlgoAnaCluster::WeightedMean().
|
inline |
ADC channel for a given charge.
charge | Charge [e] |
Returns 0 for charge below threshold.
Definition at line 77 of file CbmStsParAsic.h.
References fDynRange, fNofAdc, and fThreshold.
|
private |
uint16_t CbmStsParAsic::DeactivateRandomChannels | ( | double | fraction | ) |
Randomly deactivate a fraction of the channels.
fraction | Fraction of channels to deactivate |
Definition at line 58 of file CbmStsParAsic.cxx.
References fDeadChannels, fNofChannels, and IsChannelActive().
|
inline |
Single-channel dead time.
Definition at line 86 of file CbmStsParAsic.h.
References fDeadTime.
Referenced by CbmStsSimModule::AddSignal(), CbmStsDigitizeQaReport::Create(), CbmRecoSts::CreateModules(), and CbmTaskStsHitFinderParWrite::CreateModules().
|
inline |
Dynamic range of ADC.
Definition at line 92 of file CbmStsParAsic.h.
References fDynRange.
Referenced by CbmStsDigitizeQaReport::Create(), CbmRecoSts::CreateModules(), CbmTaskStsHitFinderParWrite::CreateModules(), TEST(), and TEST().
|
inline |
Number of ADC channels.
Definition at line 98 of file CbmStsParAsic.h.
References fNofAdc.
Referenced by CbmStsDigitizeQaReport::Create(), CbmStsDigitizeQa::CreateDigiHistograms(), CbmRecoSts::CreateModules(), CbmTaskStsHitFinderParWrite::CreateModules(), TEST(), and TEST().
|
inline |
Number of readout channels.
Definition at line 104 of file CbmStsParAsic.h.
References fNofChannels.
Referenced by CbmStsParModule::SetAllAsics().
|
inline |
Electronic noise RMS.
Definition at line 110 of file CbmStsParAsic.h.
References fNoise.
Referenced by CbmStsAlgoAnaCluster::AnaSizeN(), CbmStsDigitizeQaReport::Create(), CbmRecoSts::CreateModules(), and CbmTaskStsHitFinderParWrite::CreateModules().
double CbmStsParAsic::GetNoiseRate | ( | ) | const |
Single-channel noise rate.
Definition at line 87 of file CbmStsParAsic.cxx.
References fNoise, fThreshold, and fZeroNoiseRate.
Referenced by ToString().
double CbmStsParAsic::GetRandomNoiseCharge | ( | ) | const |
Random noise charge.
The noise charge is samples from a Gaussian with zero mean and width equal to the noise RMS, starting from threshold and up to 10 times the noise RMS.
Definition at line 97 of file CbmStsParAsic.cxx.
References fIsInit, and fNoiseCharge.
|
inline |
ADC Threshold.
Definition at line 132 of file CbmStsParAsic.h.
References fThreshold.
Referenced by CbmStsDigitizeQaReport::Create(), CbmRecoSts::CreateModules(), CbmTaskStsHitFinderParWrite::CreateModules(), TEST(), TEST(), TEST(), and TEST().
|
inline |
Time resolution.
Definition at line 138 of file CbmStsParAsic.h.
References fTimeResolution.
Referenced by CbmStsAlgoFindClusters::CheckChannel(), CbmStsDigitizeQaReport::Create(), CbmRecoSts::CreateModules(), CbmTaskStsHitFinderParWrite::CreateModules(), CbmStsSimModule::ProcessAnalogBuffer(), and CbmRecoStsPixel::ProcessData().
|
inline |
Get one of the coefficients for walk correction.
uIdx | Index of the correction parameter |
Definition at line 193 of file CbmStsParAsic.h.
References fWalkCoef.
|
inline |
Zero-crossing noise rate.
Definition at line 144 of file CbmStsParAsic.h.
References fZeroNoiseRate.
Referenced by CbmRecoSts::CreateModules(), and CbmTaskStsHitFinderParWrite::CreateModules().
void CbmStsParAsic::Init | ( | ) |
Initialisation.
Calculates the noise charge distribution.
Definition at line 106 of file CbmStsParAsic.cxx.
References fIsInit, fNoise, fNoiseCharge, and fThreshold.
Referenced by Set(), and CbmStsParModule::SetAllAsics().
|
inline |
Check for a channel being active.
channel | Channel number within ASIC |
Definition at line 158 of file CbmStsParAsic.h.
References fDeadChannels.
Referenced by DeactivateRandomChannels(), and CbmStsParModule::IsChannelActive().
CbmStsParAsic & CbmStsParAsic::operator= | ( | const CbmStsParAsic & | other | ) |
Copy assignment operator.
Definition at line 40 of file CbmStsParAsic.cxx.
References fDeadTime, fDynRange, fNofAdc, fNofChannels, fNoise, fThreshold, fTimeOffset, fTimeResolution, fWalkCoef, fZeroNoiseRate, Set(), SetTimeOffset(), and SetWalkCoef().
void CbmStsParAsic::Set | ( | uint16_t | nChannels, |
uint16_t | nAdc, | ||
double | dynRange, | ||
double | threshold, | ||
double | timeResol, | ||
double | deadTime, | ||
double | noise, | ||
double | zeroNoiseRate, | ||
std::set< uint16_t > | deadChannels = {} ) |
Set parameters.
nChannels | Number of readout channels |
nAdc | Number of ADC channels |
dynRange | Dynamic range [e] |
threshold | Threshold [e] |
timeResol | Time resolution [ns] |
deadTime | Channel dead time [ns] |
noise | Noise RMS |
zeroNoiseRate | Zero-crossing noise rate |
deadChannels | Set of dead channels |
Definition at line 117 of file CbmStsParAsic.cxx.
References fDeadChannels, fDeadTime, fDynRange, fNofAdc, fNofChannels, fNoise, fThreshold, fTimeResolution, fZeroNoiseRate, and Init().
Referenced by CbmStsParAsic(), and operator=().
|
inline |
Set time offset.
offset | Time offset for this ASIC [ns] |
The time offset will be subtracted from the message at the unpacking stage.
Definition at line 181 of file CbmStsParAsic.h.
References fTimeOffset.
Referenced by CbmStsParAsic(), and operator=().
|
inline |
Set coefficients for walk correction.
par | Array of correction parameters |
Definition at line 187 of file CbmStsParAsic.h.
References fWalkCoef.
Referenced by CbmStsParAsic(), and operator=().
std::string CbmStsParAsic::ToString | ( | ) | const |
Info to string.
Definition at line 145 of file CbmStsParAsic.cxx.
References fDeadTime, fDynRange, fNofAdc, fNoise, fThreshold, fTimeResolution, fZeroNoiseRate, and GetNoiseRate().
Referenced by CbmStsDigitize::InitParams(), and CbmStsDigitizePixel::InitParams().
|
private |
Map of dead channels.
Definition at line 214 of file CbmStsParAsic.h.
Referenced by DeactivateRandomChannels(), IsChannelActive(), and Set().
|
private |
Channel dead time [ns].
Definition at line 209 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), GetDeadTime(), operator=(), Set(), and ToString().
|
private |
Dynamic range [e].
Definition at line 206 of file CbmStsParAsic.h.
Referenced by AdcToCharge(), CbmStsParAsic(), ChargeToAdc(), GetDynRange(), operator=(), Set(), and ToString().
|
private |
Definition at line 216 of file CbmStsParAsic.h.
Referenced by GetRandomNoiseCharge(), and Init().
|
private |
Number of ADC channels.
Definition at line 205 of file CbmStsParAsic.h.
Referenced by AdcToCharge(), CbmStsParAsic(), ChargeToAdc(), GetNofAdc(), operator=(), Set(), and ToString().
|
private |
Number of readout channels.
Definition at line 204 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), DeactivateRandomChannels(), GetNofChannels(), operator=(), and Set().
|
private |
RMS of noise [e].
Definition at line 210 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), GetNoise(), GetNoiseRate(), Init(), operator=(), Set(), and ToString().
|
private |
Flag for being initialised.
Noise charge distribution. Is instantiated by the Init method in order to avoid frequent re-calculation.
Definition at line 220 of file CbmStsParAsic.h.
Referenced by GetRandomNoiseCharge(), Init(), and ~CbmStsParAsic().
|
private |
Threshold [e].
Definition at line 207 of file CbmStsParAsic.h.
Referenced by AdcToCharge(), CbmStsParAsic(), ChargeToAdc(), GetNoiseRate(), GetThreshold(), Init(), operator=(), Set(), and ToString().
|
private |
Time offset [ns].
Definition at line 212 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), operator=(), and SetTimeOffset().
|
private |
Time resolution [ns].
Definition at line 208 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), GetTimeResol(), operator=(), Set(), and ToString().
|
private |
Parameters for correction of walk effect.
Definition at line 213 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), GetWalkCoef(), operator=(), and SetWalkCoef().
|
private |
Zero-crossing noise rate [1/ns].
Definition at line 211 of file CbmStsParAsic.h.
Referenced by CbmStsParAsic(), GetNoiseRate(), GetZeroNoiseRate(), operator=(), Set(), and ToString().