16#ifndef O2_MID_CHANNELSCALERS_H
17#define O2_MID_CHANNELSCALERS_H
20#include <unordered_map>
36 void reset() { mScalers.clear(); }
53 const std::unordered_map<uint32_t, uint32_t>&
getScalers()
const {
return mScalers; }
70 inline uint32_t getChannelId(
uint8_t deId,
uint8_t columnId,
int lineId,
int strip,
int cathode) {
return strip | (lineId << 4) | (cathode << 6) | (static_cast<uint32_t>(columnId) << 8) | (
static_cast<uint32_t>(deId) << 12); }
72 std::unordered_map<uint32_t, uint32_t> mScalers{};
76std::ostream&
operator<<(std::ostream& os,
const ChannelScalers& channelScalers);
Strip pattern (aka digits)
unsigned short int uint16_t
void merge(const ChannelScalers &other)
Merges two counters.
const std::unordered_map< uint32_t, uint32_t > & getScalers() const
Gets the scalers.
uint8_t getCathode(uint32_t uniqueId) const
Gets cathode from unique Id.
uint8_t getLineId(uint32_t uniqueId) const
Gets lineId from unique Id.
void reset()
Resets scalers.
uint8_t getDeId(uint32_t uniqueId) const
Gets deId from unique Id.
uint8_t getColumnId(uint32_t uniqueId) const
Gets columnId from unique Id.
uint8_t getStrip(uint32_t uniqueId) const
Gets strip from unique Id.
std::ostream & operator<<(std::ostream &os, const Cluster &data)
a couple of static helper functions to create timestamp values for CCDB queries or override obsolete ...
Column data structure for MID.
VectorOfTObjectPtrs other
std::array< uint16_t, 5 > pattern