ATLAS Offline Software
STGTPPackets.h
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
3 */
4 #ifndef MUONNSWCOMMONDECODE_STGTPPACKETS_H
5 #define MUONNSWCOMMONDECODE_STGTPPACKETS_H
6 
7 #include <array>
8 #include <cstddef>
9 #include <cstdint>
10 #include <exception>
11 #include <vector>
12 
14 
15 namespace Muon::nsw {
17  public:
18  explicit STGTPPadPacket(const std::vector<std::uint32_t>& payload);
19  virtual ~STGTPPadPacket() = default;
20  [[nodiscard]] std::uint32_t BCID() const { return m_BCID; };
21  [[nodiscard]] std::uint32_t BandID(const std::size_t num) const { return m_bandIDs.at(num); };
22  [[nodiscard]] std::uint32_t PhiID(const std::size_t num) const { return m_phiIDs.at(num); };
23  [[nodiscard]] std::uint32_t PadIdleFlag() const { return m_idleFlag; };
24  [[nodiscard]] std::uint32_t CoincidenceWedge() const { return m_coincWedge; };
25 
26  private:
28  std::array<std::uint32_t, STGTPPad::num_pads> m_bandIDs{};
29  std::array<std::uint32_t, STGTPPad::num_pads> m_phiIDs{};
32 };
33 
35  public:
36  struct SegmentData {
44  };
45 
46  explicit STGTPSegmentPacket(const std::vector<std::uint32_t>& payload);
47 
48  virtual ~STGTPSegmentPacket() = default;
49  [[nodiscard]] std::uint32_t LUT_ChoiceSelection() const { return m_lut_choice; }
50  [[nodiscard]] std::uint32_t NSW_SegmentSelector() const { return m_nsw_segment_selector; }
52 
53  [[nodiscard]] const std::array<SegmentData, STGTPSegments::num_segments>& Segments() const { return m_segmentData; }
54  [[nodiscard]] const SegmentData& Segment(std::size_t segment) const;
55 
56  [[nodiscard]] std::uint32_t BCID() const { return m_BCID; };
57  [[nodiscard]] std::uint32_t SectorID() const { return m_sectorID; }
58 
59  private:
63 
64  std::array<SegmentData, STGTPSegments::num_segments> m_segmentData{};
65 
68 };
69 
70 } // namespace Muon::nsw
71 
72 #endif // MUONNSWCOMMONDECODE_STGTPPACKETS_H
Muon::nsw::STGTPPadPacket::STGTPPadPacket
STGTPPadPacket(const std::vector< std::uint32_t > &payload)
Definition: STGTPPackets.cxx:18
Muon::nsw::STGTPPadPacket::m_coincWedge
std::uint32_t m_coincWedge
Definition: STGTPPackets.h:31
Muon::nsw::STGTPPadPacket::BCID
std::uint32_t BCID() const
Definition: STGTPPackets.h:20
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
Muon::nsw::STGTPSegmentPacket::SegmentData::dTheta
std::uint32_t dTheta
Definition: STGTPPackets.h:41
Muon::nsw::STGTPPadPacket::~STGTPPadPacket
virtual ~STGTPPadPacket()=default
Muon::nsw::STGTPPadPacket::m_idleFlag
std::uint32_t m_idleFlag
Definition: STGTPPackets.h:30
Muon::nsw::STGTPSegmentPacket::m_lut_choice
std::uint32_t m_lut_choice
Definition: STGTPPackets.h:60
Muon::nsw::STGTPSegmentPacket::SectorID
std::uint32_t SectorID() const
Definition: STGTPPackets.h:57
NSWSTGTPDecodeBitmaps.h
Muon::nsw::STGTPSegmentPacket::STGTPSegmentPacket
STGTPSegmentPacket(const std::vector< std::uint32_t > &payload)
Definition: STGTPPackets.cxx:48
Muon::nsw::STGTPSegmentPacket::m_BCID
std::uint32_t m_BCID
Definition: STGTPPackets.h:66
Muon::nsw::STGTPSegmentPacket::m_valid_segment_selector
std::uint32_t m_valid_segment_selector
Definition: STGTPPackets.h:62
Muon::nsw::STGTPSegmentPacket::ValidSegmentSelector
std::uint32_t ValidSegmentSelector() const
Definition: STGTPPackets.h:51
Muon::nsw::STGTPPadPacket::m_phiIDs
std::array< std::uint32_t, STGTPPad::num_pads > m_phiIDs
Definition: STGTPPackets.h:29
Muon::nsw::STGTPPadPacket::BandID
std::uint32_t BandID(const std::size_t num) const
Definition: STGTPPackets.h:21
Muon::SegmentData
Definition: MuonHoughPatternFinderTool.cxx:32
Muon::nsw::STGTPPadPacket::CoincidenceWedge
std::uint32_t CoincidenceWedge() const
Definition: STGTPPackets.h:24
Muon::nsw::STGTPSegmentPacket::BCID
std::uint32_t BCID() const
Definition: STGTPPackets.h:56
Muon::nsw::STGTPSegmentPacket::m_segmentData
std::array< SegmentData, STGTPSegments::num_segments > m_segmentData
Definition: STGTPPackets.h:64
Muon::nsw::STGTPSegmentPacket::NSW_SegmentSelector
std::uint32_t NSW_SegmentSelector() const
Definition: STGTPPackets.h:50
Muon::nsw::STGTPSegmentPacket::Segments
const std::array< SegmentData, STGTPSegments::num_segments > & Segments() const
Definition: STGTPPackets.h:53
Muon::nsw
Definition: MapperMMG.h:13
Muon::nsw::STGTPPadPacket::m_bandIDs
std::array< std::uint32_t, STGTPPad::num_pads > m_bandIDs
Definition: STGTPPackets.h:28
Muon::nsw::STGTPSegmentPacket::Segment
const SegmentData & Segment(std::size_t segment) const
Definition: STGTPPackets.cxx:79
Muon::nsw::STGTPSegmentPacket::SegmentData::phiRes
std::uint32_t phiRes
Definition: STGTPPackets.h:40
Muon::nsw::STGTPSegmentPacket::~STGTPSegmentPacket
virtual ~STGTPSegmentPacket()=default
Muon::nsw::STGTPPadPacket::PadIdleFlag
std::uint32_t PadIdleFlag() const
Definition: STGTPPackets.h:23
Muon::nsw::STGTPSegmentPacket::m_nsw_segment_selector
std::uint32_t m_nsw_segment_selector
Definition: STGTPPackets.h:61
trigbs_pickEvents.num
num
Definition: trigbs_pickEvents.py:76
Muon::nsw::STGTPSegmentPacket::SegmentData::monitor
std::uint32_t monitor
Definition: STGTPPackets.h:37
Muon::nsw::STGTPSegmentPacket::SegmentData::lowRes
std::uint32_t lowRes
Definition: STGTPPackets.h:39
Muon::nsw::STGTPSegmentPacket::m_sectorID
std::uint32_t m_sectorID
Definition: STGTPPackets.h:67
PixelModuleFeMask_create_db.payload
string payload
Definition: PixelModuleFeMask_create_db.py:69
Muon::nsw::STGTPPadPacket::m_BCID
std::uint32_t m_BCID
Definition: STGTPPackets.h:27
Muon::nsw::STGTPSegmentPacket::SegmentData::spare
std::uint32_t spare
Definition: STGTPPackets.h:38
Muon::nsw::STGTPPadPacket::PhiID
std::uint32_t PhiID(const std::size_t num) const
Definition: STGTPPackets.h:22
Muon::nsw::STGTPSegmentPacket::LUT_ChoiceSelection
std::uint32_t LUT_ChoiceSelection() const
Definition: STGTPPackets.h:49
Muon::nsw::STGTPSegmentPacket::SegmentData::rIndex
std::uint32_t rIndex
Definition: STGTPPackets.h:43
Muon::nsw::STGTPSegmentPacket::SegmentData
Definition: STGTPPackets.h:36
Muon::nsw::STGTPPadPacket
Definition: STGTPPackets.h:16
Muon::nsw::STGTPSegmentPacket::SegmentData::phiID
std::uint32_t phiID
Definition: STGTPPackets.h:42
Muon::nsw::STGTPSegmentPacket
Definition: STGTPPackets.h:34
NSWL1::PadTriggerAdapter::segment
Muon::NSW_PadTriggerSegment segment(const NSWL1::PadTrigger &data)
Definition: PadTriggerAdapter.cxx:5