ATLAS Offline Software
Toggle main menu visibility
Loading...
Searching...
No Matches
MuonSpectrometer
MuonCnv
MuonTGC_CnvTools
src
TgcRODReadOut.h
Go to the documentation of this file.
1
/*
2
Copyright (C) 2002-2026 CERN for the benefit of the ATLAS collaboration
3
*/
4
5
#ifndef MUONTGC_CNVTOOLS_TGCRODREADOUT_H
6
#define MUONTGC_CNVTOOLS_TGCRODREADOUT_H
7
8
9
#include "
ByteStreamData/RawEvent.h
"
10
#include "
MuonRDO/TgcRdo.h
"
11
#include "
MuonTGC_Cabling/TgcCablingMap.h
"
12
#include "
TgcSlbDataHelper.h
"
13
14
#include <inttypes.h>
15
#include <vector>
16
#include <memory>
17
#include <array>
18
#include <atomic>
19
20
class
MsgStream;
21
namespace
Muon
{
22
class
TgcSlbData
;
23
class
TgcSlbDataHelper
;
24
38
39
class
TgcRODReadOut
{
40
private
:
41
typedef
OFFLINE_FRAGMENTS_NAMESPACE::PointerType
ByteStream
;
42
43
public
:
45
TgcRODReadOut
() =
default
;
47
virtual
~TgcRODReadOut
();
48
50
StatusCode
byteStream2Rdo
(
const
ByteStream
& bs,
TgcRdo
& tgcRdo,
51
uint32_t source_id,
const
TgcCablingMap
& cabling,
52
MsgStream& log)
const
;
55
bool
check
(
const
ByteStream
& bs,
const
TgcRdo
& tgcRdo, uint32_t source_id,
56
const
TgcCablingMap
& cabling,
57
58
MsgStream& log)
const
;
60
void
compare
(
const
TgcRdo
& rdo,
const
TgcRdo
& newRdo, MsgStream&
msg
)
const
;
62
static
bool
isMatched
(
const
TgcRawData
& rdo1,
const
TgcRawData
& rdo2);
64
StatusCode
decodeRodToRdo
(
TgcRdo
& tgcRdo,
const
ByteStream
& vData,
65
uint16_t subDetectorId, uint16_t rodId,
66
uint32_t l1Id, uint16_t
bcId
,
67
const
TgcCablingMap
& cabling,
68
MsgStream& log)
const
;
69
70
protected
:
71
enum
{
72
RawDataFragMask
= 0xFF000000,
// RawData Fragment HEADER Mask
73
FragmentIdMask
= 0xFF000000,
// Fragmen ID Mask
74
FragmentCountMask
= 0x00FFFFFF,
// Fragmen ID Mask
75
HeaderMask
= 0xE0000000,
//
76
HeaderEvent
= 0x00000000,
// Event Header
77
HeaderError
= 0x20000000,
// Error Report
78
HeaderSLB10
= 0x40000000,
// SLB Header 10
79
HeaderSLB11
= 0x60000000,
// SLB Header 11
80
HeaderSLBC
= 0x80000000,
// central bunch
81
HeaderSLBP
= 0xA0000000,
// previous bunch
82
HeaderSLBN
= 0xC0000000,
// next bunch
83
HeaderTrailer
= 0x70000000,
// SLB Header 11
84
85
ROD_START
= 0xEE1234EE,
86
ROD_HEADER_SIZE
= 0x09,
87
ROD_STATUS_SIZE
= 0x05
88
};
89
91
bool
setSbLoc
(uint16_t subDetectorId, uint16_t rodId,
TgcSlbData
* slb,
92
int
rxId,
const
TgcCablingMap
& cabling, MsgStream& log)
const
;
93
94
private
:
96
enum
NROD_SIDE
{
97
NROD
= 24 + 1,
98
NSROD
= 6 + 1,
99
ASIDE
= 0x67,
// 103
100
CSIDE
= 0x68
// 104
101
};
102
103
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1>
104
m_failedDecodeRodToRdo
ATLAS_THREAD_SAFE
{};
106
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1>
107
m_failedHeaderSizeRawData
ATLAS_THREAD_SAFE
{};
109
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1> m_failedSetSbLoc
110
ATLAS_THREAD_SAFE
{};
112
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1> m_failedSetType
113
ATLAS_THREAD_SAFE
{};
115
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1>
116
m_failedGetSLBIDfromRxID
ATLAS_THREAD_SAFE
{};
118
mutable
std::array<std::atomic<unsigned int>,
NROD
+ 1>
119
m_failedGetReadoutIDfromSLBID
ATLAS_THREAD_SAFE
{};
120
122
std::unique_ptr<TgcSlbDataHelper>
m_tgcSlbDataHelper
{
123
std::make_unique<TgcSlbDataHelper>()};
124
};
125
126
}
// namespace Muon
127
128
#endif
// MUONTGC_CNVTOOLS_TGCRODREADOUT_H
RawEvent.h
bcId
uint16_t bcId(uint32_t data)
Definition
TgcByteStreamData.h:326
TgcCablingMap.h
TgcRdo.h
TgcSlbDataHelper.h
Muon::TgcCablingMap
Definition
TgcCablingMap.h:21
Muon::TgcRODReadOut::byteStream2Rdo
StatusCode byteStream2Rdo(const ByteStream &bs, TgcRdo &tgcRdo, uint32_t source_id, const TgcCablingMap &cabling, MsgStream &log) const
Convert BS (ROB fragment) to RDO.
Definition
TgcRODReadOut.cxx:50
Muon::TgcRODReadOut::TgcRODReadOut
TgcRODReadOut()=default
Constructor.
Muon::TgcRODReadOut::compare
void compare(const TgcRdo &rdo, const TgcRdo &newRdo, MsgStream &msg) const
Compare two RDO containers.
Definition
TgcRODReadOut.cxx:132
Muon::TgcRODReadOut::NROD_SIDE
NROD_SIDE
The number of RODs (1-24 for 12-fold).
Definition
TgcRODReadOut.h:96
Muon::TgcRODReadOut::CSIDE
@ CSIDE
Definition
TgcRODReadOut.h:100
Muon::TgcRODReadOut::ASIDE
@ ASIDE
Definition
TgcRODReadOut.h:99
Muon::TgcRODReadOut::NSROD
@ NSROD
Definition
TgcRODReadOut.h:98
Muon::TgcRODReadOut::NROD
@ NROD
Definition
TgcRODReadOut.h:97
Muon::TgcRODReadOut::check
bool check(const ByteStream &bs, const TgcRdo &tgcRdo, uint32_t source_id, const TgcCablingMap &cabling, MsgStream &log) const
Convert BS (ROB fragment) to RDO and compare decoded RDO container and another RDO container decoded ...
Definition
TgcRODReadOut.cxx:97
Muon::TgcRODReadOut::setSbLoc
bool setSbLoc(uint16_t subDetectorId, uint16_t rodId, TgcSlbData *slb, int rxId, const TgcCablingMap &cabling, MsgStream &log) const
Set sbLoc.
Definition
TgcRODReadOut.cxx:656
Muon::TgcRODReadOut::~TgcRODReadOut
virtual ~TgcRODReadOut()
Destructor.
Definition
TgcRODReadOut.cxx:11
Muon::TgcRODReadOut::isMatched
static bool isMatched(const TgcRawData &rdo1, const TgcRawData &rdo2)
Compare two RDOs.
Definition
TgcRODReadOut.cxx:190
Muon::TgcRODReadOut::RawDataFragMask
@ RawDataFragMask
Definition
TgcRODReadOut.h:72
Muon::TgcRODReadOut::HeaderSLB11
@ HeaderSLB11
Definition
TgcRODReadOut.h:79
Muon::TgcRODReadOut::HeaderTrailer
@ HeaderTrailer
Definition
TgcRODReadOut.h:83
Muon::TgcRODReadOut::FragmentIdMask
@ FragmentIdMask
Definition
TgcRODReadOut.h:73
Muon::TgcRODReadOut::ROD_HEADER_SIZE
@ ROD_HEADER_SIZE
Definition
TgcRODReadOut.h:86
Muon::TgcRODReadOut::ROD_STATUS_SIZE
@ ROD_STATUS_SIZE
Definition
TgcRODReadOut.h:87
Muon::TgcRODReadOut::HeaderSLBC
@ HeaderSLBC
Definition
TgcRODReadOut.h:80
Muon::TgcRODReadOut::HeaderEvent
@ HeaderEvent
Definition
TgcRODReadOut.h:76
Muon::TgcRODReadOut::FragmentCountMask
@ FragmentCountMask
Definition
TgcRODReadOut.h:74
Muon::TgcRODReadOut::HeaderSLB10
@ HeaderSLB10
Definition
TgcRODReadOut.h:78
Muon::TgcRODReadOut::HeaderSLBN
@ HeaderSLBN
Definition
TgcRODReadOut.h:82
Muon::TgcRODReadOut::HeaderError
@ HeaderError
Definition
TgcRODReadOut.h:77
Muon::TgcRODReadOut::HeaderSLBP
@ HeaderSLBP
Definition
TgcRODReadOut.h:81
Muon::TgcRODReadOut::ROD_START
@ ROD_START
Definition
TgcRODReadOut.h:85
Muon::TgcRODReadOut::HeaderMask
@ HeaderMask
Definition
TgcRODReadOut.h:75
Muon::TgcRODReadOut::ByteStream
OFFLINE_FRAGMENTS_NAMESPACE::PointerType ByteStream
Definition
TgcRODReadOut.h:41
Muon::TgcRODReadOut::m_tgcSlbDataHelper
std::unique_ptr< TgcSlbDataHelper > m_tgcSlbDataHelper
TGC SLB data helper.
Definition
TgcRODReadOut.h:122
Muon::TgcRODReadOut::decodeRodToRdo
StatusCode decodeRodToRdo(TgcRdo &tgcRdo, const ByteStream &vData, uint16_t subDetectorId, uint16_t rodId, uint32_t l1Id, uint16_t bcId, const TgcCablingMap &cabling, MsgStream &log) const
Decode BS to RDO container.
Definition
TgcRODReadOut.cxx:296
Muon::TgcRODReadOut::ATLAS_THREAD_SAFE
std::array< std::atomic< unsigned int >, NROD+1 > m_failedDecodeRodToRdo ATLAS_THREAD_SAFE
The number of failures on decodeRodToRdo.
Definition
TgcRODReadOut.h:104
Muon::TgcSlbDataHelper
This is the SLB data helper class which stores bit map, reconstructs to hits and coincidences,...
Definition
TgcSlbDataHelper.h:32
Muon::TgcSlbData
This is the SLB data class which represents an SLB block.
Definition
TgcSlbData.h:20
TgcRawData
An unit object of TGC ROD output.
Definition
TgcRawData.h:23
TgcRdo
Definition
TgcRdo.h:22
Muon
NRpcCablingAlg reads raw condition data and writes derived condition data to the condition store.
Definition
TrackSystemController.h:46
OFFLINE_FRAGMENTS_NAMESPACE::PointerType
const DataType * PointerType
Definition
RawEvent.h:25
msg
MsgStream & msg
Definition
testRead.cxx:32
Generated on
for ATLAS Offline Software by
1.17.0