ATLAS Offline Software
PixelRawContByteStreamTool.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 // PixelRawContByteStreamTool.h
7 // Header file for class PixelRawContByteStreamTool
9 // (c) ATLAS Pixel Detector software
12 // Version 00-00-39 05/03/2007 Daniel Dobos
14 
15 #ifndef PIXELRAWDATABYTESTREAMCNV_PIXELRAWCONTRAWEVENTTOOL_H
16 #define PIXELRAWDATABYTESTREAMCNV_PIXELRAWCONTRAWEVENTTOOL_H
17 
18 // #define _DEBUG
19 
20 
21 
23 
24 #include "GaudiKernel/ServiceHandle.h"
25 
26 #include "InDetRawData/PixelRDO_Container.h" //typedef
32 #include <cstdint>
33 #include <string>
34 #include <vector>
35 class PixelID;
36 
37 namespace InDetDD{
38  class PixelDetectorManager;
39 }
40 
42 
43  public:
44  // constructor
45  PixelRawContByteStreamTool(const std::string& type,const std::string& name,const IInterface* parent);
46 
47  // destructor
49 
50  // AlgTool InterfaceID
51  static const InterfaceID& interfaceID();
52 
53  virtual StatusCode initialize() override;
54  virtual StatusCode finalize() override;
56 
57  void fillROD(std::vector<uint32_t>& v32rod, std::vector<const PixelRDORawData*> RDOs, int BCs_per_LVL1ID) const;
58 
59  void packIBLcondensed(std::vector <uint32_t > & v32rod, std::vector <uint32_t > & vRows, std::vector <uint32_t > & vCols, std::vector<int> & vTots) const;
60  void packIBLCondensed(std::vector <uint32_t > & v32rod, const std::vector<const PixelRDORawData*> &rdos_sameIBL_offlineId);
65  uint32_t packLinkTrailer(uint32_t errors) const; // for Pixel
66  uint32_t packLinkTrailer_IBL(uint32_t FEonSLink, bool timeOutErrorBit, bool condensedModeBit, bool linkMasked) const; // for IBL
67 
68  private:
70  { this, "ByteStreamCnvSvc", "ByteStreamCnvSvc" };
71 
73  { this, "PixelReadoutManager", "PixelReadoutManager", "Pixel readout manager" };
74 
75  const PixelID* m_PixelID{};
76 
78 
79  unsigned short m_RodBlockVersion{};
81 
83  {this, "PixelCablingCondData", "PixelCablingCondData", "Pixel cabling key"};
84 
86  {this, "PixelHitDiscCnfgData", "PixelHitDiscCnfgData", "Pixel FEI4 HitDiscConfig key"};
87 };
88 
89 class OrderRdos {
90 
91  private:
94 
95  public:
97  m_pixelReadout(pixelReadout), m_offlineId(offlineId) { }
98 
99  bool operator() (const PixelRDORawData* rdo0, const PixelRDORawData* rdo1);
100 };
101 
103 
104  private:
106  const PixelID * m_PixelID{};
108 
109  public:
111  m_pixelReadout(pixelReadout), m_PixelID(pixelID), m_pixCabling(pixCabling) { }
112 
113  bool operator() (const PixelRDORawData* rdo0, const PixelRDORawData* rdo1);
114 };
115 
116 #endif // PIXELRAWDATABYTESTREAMCNV_PIXELRAWCONTRAWEVENTTOOL_H
query_example.row
row
Definition: query_example.py:24
PixelRawContByteStreamTool::packIBLCondensed
void packIBLCondensed(std::vector< uint32_t > &v32rod, const std::vector< const PixelRDORawData * > &rdos_sameIBL_offlineId)
PixelRawContByteStreamTool
Definition: PixelRawContByteStreamTool.h:41
PixelRawContByteStreamTool::initialize
virtual StatusCode initialize() override
Definition: PixelRawContByteStreamTool.cxx:44
PixelRawContByteStreamTool::m_condHitDiscCnfgKey
SG::ReadCondHandleKey< PixelHitDiscCnfgData > m_condHitDiscCnfgKey
Definition: PixelRawContByteStreamTool.h:86
PixelRawContByteStreamTool::interfaceID
static const InterfaceID & interfaceID()
Definition: PixelRawContByteStreamTool.cxx:121
PixelCablingCondData.h
PixelRawContByteStreamTool::packRawDataWord_IBL
uint32_t packRawDataWord_IBL(uint32_t row, uint32_t column, int ToT, uint32_t nLink) const
Definition: PixelRawContByteStreamTool.cxx:658
OrderRdos::m_offlineId
Identifier m_offlineId
Definition: PixelRawContByteStreamTool.h:93
PixelRawContByteStreamTool::fillROD
void fillROD(std::vector< uint32_t > &v32rod, std::vector< const PixelRDORawData * > RDOs, int BCs_per_LVL1ID) const
Definition: PixelRawContByteStreamTool.cxx:130
OrderInitialRdos::m_pixCabling
SG::ReadCondHandle< PixelCablingCondData > m_pixCabling
Definition: PixelRawContByteStreamTool.h:107
SG::ReadCondHandle< PixelCablingCondData >
PixelRawContByteStreamTool::packLinkTrailer_IBL
uint32_t packLinkTrailer_IBL(uint32_t FEonSLink, bool timeOutErrorBit, bool condensedModeBit, bool linkMasked) const
Definition: PixelRawContByteStreamTool.cxx:702
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
PixelRawContByteStreamTool::m_pixelReadout
ServiceHandle< InDetDD::IPixelReadoutManager > m_pixelReadout
Definition: PixelRawContByteStreamTool.h:73
PixelRawContByteStreamTool::m_RodBlockVersion
unsigned short m_RodBlockVersion
Definition: PixelRawContByteStreamTool.h:79
PixelRawContByteStreamTool::convert
StatusCode convert(PixelRDO_Container *cont) const
Definition: PixelRawContByteStreamTool.cxx:70
DeMoUpdate.column
dictionary column
Definition: DeMoUpdate.py:1110
OrderInitialRdos::m_PixelID
const PixelID * m_PixelID
Definition: PixelRawContByteStreamTool.h:106
OrderRdos::operator()
bool operator()(const PixelRDORawData *rdo0, const PixelRDORawData *rdo1)
Definition: PixelRawContByteStreamTool.cxx:755
PixelRawContByteStreamTool::finalize
virtual StatusCode finalize() override
Definition: PixelRawContByteStreamTool.cxx:63
InDetRawDataContainer
Definition: InDetRawDataContainer.h:27
PixelRawContByteStreamTool::packLinkHeader_IBL
uint32_t packLinkHeader_IBL(uint32_t module, uint32_t bcid, uint32_t lvl1id, uint32_t feFlag) const
Definition: PixelRawContByteStreamTool.cxx:641
OrderRdos::OrderRdos
OrderRdos(Identifier offlineId, const ServiceHandle< InDetDD::IPixelReadoutManager > &pixelReadout)
Definition: PixelRawContByteStreamTool.h:96
OrderInitialRdos::operator()
bool operator()(const PixelRDORawData *rdo0, const PixelRDORawData *rdo1)
Definition: PixelRawContByteStreamTool.cxx:791
PixelRawContByteStreamTool::~PixelRawContByteStreamTool
virtual ~PixelRawContByteStreamTool()
Definition: PixelRawContByteStreamTool.cxx:38
python.PyAthena.module
module
Definition: PyAthena.py:131
OrderRdos
Definition: PixelRawContByteStreamTool.h:89
OrderInitialRdos
Definition: PixelRawContByteStreamTool.h:102
PixelRawContByteStreamTool::m_byteStreamCnvSvc
ServiceHandle< IByteStreamCnvSvc > m_byteStreamCnvSvc
Definition: PixelRawContByteStreamTool.h:70
EL::StatusCode
::StatusCode StatusCode
StatusCode definition for legacy code.
Definition: PhysicsAnalysis/D3PDTools/EventLoop/EventLoop/StatusCode.h:22
AthAlgTool.h
test_pyathena.parent
parent
Definition: test_pyathena.py:15
PixelRawContByteStreamTool::m_condCablingKey
SG::ReadCondHandleKey< PixelCablingCondData > m_condCablingKey
Definition: PixelRawContByteStreamTool.h:83
IPixelReadoutManager.h
PixelRawContByteStreamTool::m_pixelManager
const InDetDD::PixelDetectorManager * m_pixelManager
Definition: PixelRawContByteStreamTool.h:77
OrderInitialRdos::OrderInitialRdos
OrderInitialRdos(const ServiceHandle< InDetDD::IPixelReadoutManager > &pixelReadout, const PixelID *pixelID, SG::ReadCondHandle< PixelCablingCondData > &pixCabling)
Definition: PixelRawContByteStreamTool.h:110
ReadCondHandleKey.h
mergePhysValFiles.errors
list errors
Definition: DataQuality/DataQualityUtils/scripts/mergePhysValFiles.py:43
PixelRawContByteStreamTool::packIBLcondensed
void packIBLcondensed(std::vector< uint32_t > &v32rod, std::vector< uint32_t > &vRows, std::vector< uint32_t > &vCols, std::vector< int > &vTots) const
Definition: PixelRawContByteStreamTool.cxx:726
InDetDD::PixelDetectorManager
Definition: PixelDetectorManager.h:47
name
std::string name
Definition: Control/AthContainers/Root/debug.cxx:228
PixelRawContByteStreamTool::PixelRawContByteStreamTool
PixelRawContByteStreamTool(const std::string &type, const std::string &name, const IInterface *parent)
Definition: PixelRawContByteStreamTool.cxx:27
xAOD::bcid
setEventNumber setTimeStamp bcid
Definition: EventInfo_v1.cxx:133
PixelRDO_Container.h
OrderInitialRdos::m_pixelReadout
ServiceHandle< InDetDD::IPixelReadoutManager > m_pixelReadout
Definition: PixelRawContByteStreamTool.h:105
SG::ReadCondHandleKey< PixelCablingCondData >
PixelRawContByteStreamTool::m_BCs_per_LVL1ID
int m_BCs_per_LVL1ID
Definition: PixelRawContByteStreamTool.h:80
PixelRawContByteStreamTool::packRawDataWord
uint32_t packRawDataWord(uint32_t FE, uint32_t row, uint32_t column, uint32_t ToT) const
Definition: PixelRawContByteStreamTool.cxx:674
InDetDD
Message Stream Member.
Definition: FakeTrackBuilder.h:8
PixelRawContByteStreamTool::packLinkTrailer
uint32_t packLinkTrailer(uint32_t errors) const
Definition: PixelRawContByteStreamTool.cxx:689
PixelHitDiscCnfgData.h
PixelRawContByteStreamTool::m_PixelID
const PixelID * m_PixelID
Definition: PixelRawContByteStreamTool.h:75
python.CaloScaleNoiseConfig.type
type
Definition: CaloScaleNoiseConfig.py:78
PixelRDORawData
Definition: PixelRDORawData.h:23
PixelRawContByteStreamTool::packLinkHeader
uint32_t packLinkHeader(uint32_t module, uint32_t bcid, uint32_t lvl1id, uint32_t lvl1idskip, uint32_t errors) const
Definition: PixelRawContByteStreamTool.cxx:625
AthAlgTool
Definition: AthAlgTool.h:26
IByteStreamCnvSvc.h
PixelID
Definition: PixelID.h:67
ServiceHandle< IByteStreamCnvSvc >
OrderRdos::m_pixelReadout
ServiceHandle< InDetDD::IPixelReadoutManager > m_pixelReadout
Definition: PixelRawContByteStreamTool.h:92
Identifier
Definition: IdentifierFieldParser.cxx:14