Belle II Software development
TOPCalAsicShift.h
1/**************************************************************************
2 * basf2 (Belle II Analysis Software Framework) *
3 * Author: The Belle II Collaboration *
4 * *
5 * See git log for contributors and copyright holders. *
6 * This file is licensed under LGPL-3.0, see LICENSE.md. *
7 **************************************************************************/
8
9#pragma once
10
11#include <TObject.h>
12
13namespace Belle2 {
23 class TOPCalAsicShift: public TObject {
24 public:
25
29 enum EStatus {
32 c_Unusable = 2
33 };
34
35
40 {}
41
48 void setT0(int moduleID, unsigned asic, double T0);
49
55 void setUnusable(int moduleID, unsigned asic);
56
63 double getT0(int moduleID, unsigned asic) const;
64
71 bool isCalibrated(int moduleID, unsigned asic) const;
72
79 bool isDefault(int moduleID, unsigned asic) const;
80
87 bool isUnusable(int moduleID, unsigned asic) const;
88
89 private:
90
94 enum {c_numModules = 16,
95 c_numAsics = 64
96 };
97
98 float m_T0[c_numModules][c_numAsics] = {{0}};
103 };
104
106} // end namespace Belle2
107
Calibration constants for ASIC shifts of all 16 modules.
@ c_numModules
number of modules
@ c_numAsics
number of ASIC's per module
float m_T0[c_numModules][c_numAsics]
calibration constants
EStatus m_status[c_numModules][c_numAsics]
calibration status
EStatus
Calibration status of a constant.
@ c_Calibrated
good calibrated value
@ c_Unusable
bad calibrated value
@ c_Default
uncalibrated default value
ClassDef(TOPCalAsicShift, 1)
ClassDef.
TOPCalAsicShift()
Default constructor.
void setUnusable(int moduleID, unsigned asic)
Switches calibration status to unusable to flag badly calibrated constant.
bool isCalibrated(int moduleID, unsigned asic) const
Returns calibration status.
bool isDefault(int moduleID, unsigned asic) const
Returns calibration status.
bool isUnusable(int moduleID, unsigned asic) const
Returns calibration status.
void setT0(int moduleID, unsigned asic, double T0)
Sets calibration for a single ASIC and switches status to calibrated.
double getT0(int moduleID, unsigned asic) const
Returns T0 of a single asic.
Abstract base class for different kinds of events.