CbmRoot
Loading...
Searching...
No Matches
rich/ReadoutConfig.h
Go to the documentation of this file.
1/* Copyright (C) 2022 GSI Helmholtzzentrum fuer Schwerionenforschung, Darmstadt
2 SPDX-License-Identifier: GPL-3.0-only
3 Authors: Volker Friese, Dominik Smith [committer] */
4
5#ifndef ALGO_DETECTORS_RICH_READOUTCONFIG_H
6#define ALGO_DETECTORS_RICH_READOUTCONFIG_H
7
8#include <cstdint>
9#include <map>
10#include <sstream>
11#include <utility>
12#include <vector>
13
14namespace cbm::algo::rich
15{
16
17
30
31 public:
34
35
37 virtual ~ReadoutConfig();
38
39
43 std::vector<uint16_t> GetEquipmentIds();
44
45
50 size_t GetNumElinks(uint16_t equipmentId);
51
52
56 size_t GetNumElinks();
57
58
65 double Map(uint16_t equipmentId, uint32_t address, uint16_t chan);
66
71 std::map<uint32_t, std::vector<double>> Map(uint16_t equipmentId);
72
73
75 std::string PrintReadoutMap();
76
77
78 private:
79 // --- RICH readout map
80 // --- Map index: (equipment, trb address, channel), map value: (tot shift)
81 std::map<uint16_t, std::map<uint32_t, std::vector<double>>> fReadoutMap = {};
82
83
85 void Init();
86 };
87
88} // namespace cbm::algo::rich
89
90#endif /* ALGO_DETECTORS_RICH_READOUTCONFIG_H_ */
Provides the hardware-to-software address mapping for the CBM-RICH.
double Map(uint16_t equipmentId, uint32_t address, uint16_t chan)
API: Mapping from component, address and channel to tot shift.
void Init()
Initialisation of readout map.
std::vector< uint16_t > GetEquipmentIds()
Equipment in the configuration.
size_t GetNumElinks()
Total number of elinks for RICH.
std::map< uint16_t, std::map< uint32_t, std::vector< double > > > fReadoutMap
std::string PrintReadoutMap()
Debug output of readout map.