ATLAS Offline Software
Loading...
Searching...
No Matches
TileBchDecoder.h
Go to the documentation of this file.
1/*
2 Copyright (C) 2002-2017 CERN for the benefit of the ATLAS collaboration
3*/
4
5#ifndef TILECALIBBLOBOBJS_TILEBCHDECODER_H
6#define TILECALIBBLOBOBJS_TILEBCHDECODER_H
7
25
26#include <stdint.h>
27#include <vector>
28#include <set>
29#include <map>
30#include <string>
31#include <iostream>
35
37{
38 public:
39
45
47 TileBchDecoder(BitPatVer bitPatVer);
48
50 void printBitAssignment() const { printBitAssignment(std::cout); }
53 void printBitAssignment(std::ostream& stm) const;
54
56 TileBchStatus decode(uint32_t status_channel, uint32_t status_adc=0) const;
57
59 TileBchStatus decode(const TileBchWords& words) const
60 { return decode(words[0],words[1]); }
61
68 TileBchWords encode(const TileBchStatus& status) const;
69
70 private:
71
73 void init_BitPat_ofl01();
75 void init_BitPat_onl01();
76
77
79 void initPrbToBit();
80
82 std::vector<TileBchPrbs::Prb> m_bitToPrbChn;
84 std::vector<TileBchPrbs::Prb> m_bitToPrbAdc;
88 std::map<TileBchPrbs::Prb, std::pair<unsigned int,unsigned int> > m_prbToBit;
89};
90
91#endif
void init_BitPat_ofl01()
Initializes bit pattern version "ofl01".
TileBchStatus decode(uint32_t status_channel, uint32_t status_adc=0) const
Decode the status word.
std::vector< TileBchPrbs::Prb > m_bitToPrbChn
Bit to problem association for the channel word.
void printBitAssignment() const
Print status bits and their assigned problem.
TileBchDecoder(BitPatVer bitPatVer)
Ctor.
TileBchWords encode(const TileBchStatus &status) const
Encode an ADC status into channel and adc status word bits.
TileBchStatus decode(const TileBchWords &words) const
Decode the status word.
void init_BitPat_onl01()
Initializes bit pattern version "ofl01".
std::vector< TileBchPrbs::Prb > m_bitToPrbAdc
Bit to problem association for the ADC word.
void initPrbToBit()
Initializes the problem to bit map.
std::map< TileBchPrbs::Prb, std::pair< unsigned int, unsigned int > > m_prbToBit
Problem to status word and bit association.
Class holding bad channel problems.