CbmRoot
|
Parameters container for CbmStsParSensorCond. More...
#include <CbmStsParSetSensorCond.h>
Public Member Functions | |
CbmStsParSetSensorCond (const char *name="CbmStsParSetSensorCond", const char *title="STS parameters", const char *context="Default") | |
Constructor. | |
virtual | ~CbmStsParSetSensorCond () |
Destructor. | |
virtual void | clear () |
Reset all parameters. | |
virtual Bool_t | getParams (FairParamList *parList) |
Reading parameters from ASCII. Abstract in base class. | |
const CbmStsParSensorCond & | GetParSensor (UInt_t address) |
Get condition parameters of a sensor. | |
Bool_t | IsSet () const |
Check for parameter set being filled. | |
virtual void | putParams (FairParamList *parList) |
Writing parameters to ASCII. Abstract in base class. | |
UInt_t | ReadParams (const char *fileName) |
Read sensor conditions from file. | |
void | SetGlobalPar (Double_t vDep, Double_t vBias, Double_t temperature, Double_t cCoupling, Double_t cInterstrip) |
Set global conditions (for all sensors) | |
void | SetGlobalPar (const CbmStsParSensorCond &conditions) |
Set global conditions (for all sensors) | |
std::string | ToString () |
Info to string. | |
Private Member Functions | |
void | Init () |
Initialise all condition parameters. | |
ClassDef (CbmStsParSetSensorCond, 2) | |
Initialisation flag. | |
Private Attributes | |
CbmStsParSensorCond | fGlobalParams {} |
Global parameters, used for all sensors. | |
std::map< UInt_t, CbmStsParSensorCond > | fParams {} |
Map of parameters. Key is sensor address. | |
Bool_t | fGlobal = kFALSE |
Use global parameters for all sensors. | |
Bool_t | fIsInit = kFALSE |
Parameters container for CbmStsParSensorCond.
A set of parameters for each STS sensor is administered through FairRuntimeDb.
Definition at line 34 of file CbmStsParSetSensorCond.h.
CbmStsParSetSensorCond::CbmStsParSetSensorCond | ( | const char * | name = "CbmStsParSetSensorCond", |
const char * | title = "STS parameters", | ||
const char * | context = "Default" ) |
Constructor.
name | Name of parameter set |
title | Parameter container factory name |
context | No idea |
|
virtual |
Destructor.
Definition at line 37 of file CbmStsParSetSensorCond.cxx.
|
private |
Initialisation flag.
|
virtual |
Reset all parameters.
Definition at line 42 of file CbmStsParSetSensorCond.cxx.
References fGlobal, fIsInit, and fParams.
Referenced by CbmRecoSts::InitParams(), CbmStsDigitize::InitParams(), CbmTaskStsHitFinderParWrite::InitParams(), and CbmStsDigitize::InitSensors().
|
virtual |
Reading parameters from ASCII. Abstract in base class.
An ASCII I/O is not implemented. The method throws an error.
Definition at line 54 of file CbmStsParSetSensorCond.cxx.
const CbmStsParSensorCond & CbmStsParSetSensorCond::GetParSensor | ( | UInt_t | address | ) |
Get condition parameters of a sensor.
Sensor | address |
Definition at line 63 of file CbmStsParSetSensorCond.cxx.
References fGlobal, fGlobalParams, fIsInit, fParams, and Init().
Referenced by CbmRecoSts::CreateModules(), CbmTaskStsHitFinderParWrite::CreateModules(), CbmStsDigitize::InitSensors(), and CbmStsSetup::SetSensorConditions().
|
private |
Initialise all condition parameters.
When the parameter set is streamed, the derived parameters of the conditions are not set, since the default constructor is called. So, the Init method of all conditions has to be called.
Definition at line 81 of file CbmStsParSetSensorCond.cxx.
References fGlobalParams, fIsInit, fParams, and CbmStsParSensorCond::Init().
Referenced by GetParSensor(), and ToString().
|
inline |
Check for parameter set being filled.
Definition at line 71 of file CbmStsParSetSensorCond.h.
References fGlobal, and fParams.
Referenced by ToString().
|
virtual |
Writing parameters to ASCII. Abstract in base class.
An ASCII I/O is not implemented. The method throws an error.
Definition at line 97 of file CbmStsParSetSensorCond.cxx.
UInt_t CbmStsParSetSensorCond::ReadParams | ( | const char * | fileName | ) |
Read sensor conditions from file.
fileName | Name of file with sensor conditions @value Number of sensors the conditions are set for |
The file with the conditions is read and the condition parameters for the sensor are set accordingly. Each sensor in the setup must show up in the file.
The format is a text file containing for each sensor a line with sensor_name vDep vBias temperature cCoupling cInterstrip separated by blanks. Empty lines or lines starting with '#' (comments) are ignored.
TODO: Is using the RuntimeDb ASCII interface an alternative?
Definition at line 102 of file CbmStsParSetSensorCond.cxx.
void CbmStsParSetSensorCond::SetGlobalPar | ( | const CbmStsParSensorCond & | conditions | ) |
Set global conditions (for all sensors)
conditions | Sensor condition object |
Definition at line 188 of file CbmStsParSetSensorCond.cxx.
References CbmStsParSensorCond::GetCcoupling(), CbmStsParSensorCond::GetCinterstrip(), CbmStsParSensorCond::GetTemperature(), CbmStsParSensorCond::GetVbias(), CbmStsParSensorCond::GetVfd(), and SetGlobalPar().
void CbmStsParSetSensorCond::SetGlobalPar | ( | Double_t | vDep, |
Double_t | vBias, | ||
Double_t | temperature, | ||
Double_t | cCoupling, | ||
Double_t | cInterstrip ) |
Set global conditions (for all sensors)
vDep | Full-depletion voltage [V] |
vBias | Bias voltage [V] |
temperature | Temperature [K] |
cCoupling | Coupling capacitance [pF] |
cInterstrip | Inter-strip capacitance [pF] |
Definition at line 177 of file CbmStsParSetSensorCond.cxx.
References fGlobal, fGlobalParams, and CbmStsParSensorCond::SetParams().
Referenced by CbmRecoSts::InitParams(), CbmStsDigitize::InitParams(), CbmTaskStsHitFinderParWrite::InitParams(), and SetGlobalPar().
std::string CbmStsParSetSensorCond::ToString | ( | ) |
Info to string.
Definition at line 201 of file CbmStsParSetSensorCond.cxx.
References fGlobal, fGlobalParams, fIsInit, fParams, Init(), IsSet(), and CbmStsParSensorCond::ToString().
Referenced by CbmRecoStsPixel::Init(), CbmRecoSts::InitParams(), CbmStsDigitize::InitParams(), and CbmTaskStsHitFinderParWrite::InitParams().
|
private |
Use global parameters for all sensors.
Definition at line 136 of file CbmStsParSetSensorCond.h.
Referenced by clear(), GetParSensor(), IsSet(), ReadParams(), SetGlobalPar(), and ToString().
|
private |
Global parameters, used for all sensors.
Definition at line 131 of file CbmStsParSetSensorCond.h.
Referenced by GetParSensor(), Init(), SetGlobalPar(), and ToString().
|
private |
Definition at line 137 of file CbmStsParSetSensorCond.h.
Referenced by clear(), GetParSensor(), Init(), and ToString().
|
private |
Map of parameters. Key is sensor address.
Definition at line 134 of file CbmStsParSetSensorCond.h.
Referenced by clear(), GetParSensor(), Init(), IsSet(), ReadParams(), and ToString().