Belle II Software development
ARICHHvChannelsMapping.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#include <map>
13#include <vector>
14
15#define N_HVCHANNELS 24
16
17namespace Belle2 {
23
26 class ARICHHvChannelsMapping : public TObject {
27
28 public:
29
32
39 std::vector<int> getChannelValues(int connectionID, int pinID) const;
40
46 int getPinID(std::vector<int> channel) const;
47
53 int getConnectionID(std::vector<int> channel) const;
54
61 int getCrate(int connectionID, int pinID) const;
62
69 int getSlot(int connectionID, int pinID) const;
70
77 int getChannel(int connectionID, int pinID) const;
78
87 void addMapping(int crate, int slot, int channelID, int connectionID, int pinID);
88
89 private:
90
91 std::map<std::vector<int>, std::vector<int>> m_channel2type;
95 };
96
98} // namespace
The Class for ARICH mapping of bias power supply channels to modules.
std::vector< int > getChannelValues(int connectionID, int pinID) const
Get bias power supply channel ID from inner cable type and ID.
std::map< std::vector< int >, std::vector< int > > m_channel2type
power suply channel ID link to inner cable
int getPinID(std::vector< int > channel) const
Get inner cable pin ID from hv power supply channel ID.
ClassDef(ARICHHvChannelsMapping, 1)
ClassDef, must be the last term before the closing {}.
int getConnectionID(std::vector< int > channel) const
Get connection ID from hv power supply channel ID.
int getSlot(int connectionID, int pinID) const
Get connection ID from hv power supply channel ID.
ARICHHvChannelsMapping()
Default constructor.
int getCrate(int connectionID, int pinID) const
Get connection ID from hv power supply channel ID.
int getChannel(int connectionID, int pinID) const
Get connection ID from hv power supply channel ID.
void addMapping(int crate, int slot, int channelID, int connectionID, int pinID)
Add new entry to the mapping table.
Abstract base class for different kinds of events.