Belle II Software light-2406-ragdoll
|
Database object containing the nominal accelerator RF value and the prescales to derive the clock frequencies of the sub-detectors. More...
#include <HardwareClockSettings.h>
Public Member Functions | |
HardwareClockSettings () | |
Constructor. | |
double | getClockPrescale (Const::EDetector detector, std::string label) const |
Get the prescale factor used to derive a detector clock from the global clock frequency. | |
double | getClockFrequency (Const::EDetector detector, std::string label) const |
Get the frequency of a detector clock. | |
double | getGlobalClockFrequency () const |
Get the global clock (system clock) frequency. | |
double | getAcceleratorRF () const |
Get the accelerator RF value. | |
void | setClockPrescale (const Const::EDetector detector, std::string label, double prescale) |
Set the prescale value used to derive a detector clock from the global clock frequency. | |
void | setClockFrequency (const Const::EDetector detector, std::string label, double frequency) |
Set the frequency value of detector clock not derived from the global clock. | |
void | setAcceleratorRF (double acceleratorRF) |
Set the accelerator RF value. | |
bool | isPrescaleAvailable (Const::EDetector detector, std::string label) const |
Check if the prescale of a clock is available. | |
bool | isFrequencyAvailable (Const::EDetector detector, std::string label) const |
Check if the frequency of a detector clock is available. | |
void | print () const |
Print the content of the class. | |
Private Attributes | |
std::map< Const::EDetector, std::map< std::string, double > > | m_prescaleMap |
Map of prescale factors used to derive the clock frequencies from the global clock frequency. | |
std::map< Const::EDetector, std::map< std::string, double > > | m_clocksMap |
Map of clock frequencies not derived from the global clock frequency. | |
double | m_acceleratorRF = 0 |
Accelerator radio frequency [GHz]. | |
Database object containing the nominal accelerator RF value and the prescales to derive the clock frequencies of the sub-detectors.
Global clock frequency (system clock) is RF/4.
Definition at line 25 of file HardwareClockSettings.h.
double getAcceleratorRF | ( | ) | const |
Get the accelerator RF value.
Definition at line 57 of file HardwareClockSettings.cc.
double getClockFrequency | ( | Const::EDetector | detector, |
std::string | label | ||
) | const |
Get the frequency of a detector clock.
detector | The ID of the detector. |
label | The label for the clock. |
Definition at line 34 of file HardwareClockSettings.cc.
double getClockPrescale | ( | Const::EDetector | detector, |
std::string | label | ||
) | const |
Get the prescale factor used to derive a detector clock from the global clock frequency.
detector | The ID of the detector. |
label | The label for the clock. |
Definition at line 62 of file HardwareClockSettings.cc.
double getGlobalClockFrequency | ( | ) | const |
Get the global clock (system clock) frequency.
Definition at line 52 of file HardwareClockSettings.cc.
bool isFrequencyAvailable | ( | Const::EDetector | detector, |
std::string | label | ||
) | const |
Check if the frequency of a detector clock is available.
The check is performed for both the clocks derived from the globalclock and the clocks not derived from it.
detector | The ID of the detector. |
label | The label for the clock. |
Definition at line 25 of file HardwareClockSettings.cc.
bool isPrescaleAvailable | ( | Const::EDetector | detector, |
std::string | label | ||
) | const |
Check if the prescale of a clock is available.
detector | The ID of the detector. |
label | The label for the clock. |
Definition at line 18 of file HardwareClockSettings.cc.
void print | ( | ) | const |
Print the content of the class.
Definition at line 88 of file HardwareClockSettings.cc.
void setAcceleratorRF | ( | double | acceleratorRF | ) |
Set the accelerator RF value.
acceleratorRF | Accelerator RF value [GHz]. |
Definition at line 83 of file HardwareClockSettings.cc.
void setClockFrequency | ( | const Const::EDetector | detector, |
std::string | label, | ||
double | frequency | ||
) |
Set the frequency value of detector clock not derived from the global clock.
detector | The ID of the detector. |
label | The label for the clock. |
frequency | The frequency for the clock [GHz] |
Definition at line 78 of file HardwareClockSettings.cc.
void setClockPrescale | ( | const Const::EDetector | detector, |
std::string | label, | ||
double | prescale | ||
) |
Set the prescale value used to derive a detector clock from the global clock frequency.
detector | The ID of the detector. |
label | The label for the clock. |
prescale | The prescale factor of the clock. |
Definition at line 72 of file HardwareClockSettings.cc.
|
private |
Accelerator radio frequency [GHz].
Definition at line 119 of file HardwareClockSettings.h.
|
private |
Map of clock frequencies not derived from the global clock frequency.
Clock frequency units are GHz.
Definition at line 114 of file HardwareClockSettings.h.
|
private |
Map of prescale factors used to derive the clock frequencies from the global clock frequency.
Definition at line 108 of file HardwareClockSettings.h.