ATLAS Offline Software
ZdcSubBlockHeader.cxx
Go to the documentation of this file.
1 /*
2  Copyright (C) 2002-2020 CERN for the benefit of the ATLAS collaboration
3 */
4 
6 
8 
9 //using namespace LVL1BS;
10 
11 namespace {
12  const ZdcWordDecoder subBlockHeaderDecoder(
13  {
14  BitField("Type", 28, 4),
15  BitField("Version", 25, 3),
16  BitField("Format", 22, 3),
17  BitField("SeqNum", 16, 6),
18  BitField("Crate", 12, 4),
19  BitField("Module", 8, 4),
20  BitField("nSlice2", 3, 5),
21  BitField("nSlice1", 0, 3)
22  });
23 }
24 
26  m_header(header){
27 }
28 
29 
31  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 0); }
32 
34  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 1);
35 }
37  return ::subBlockHeaderDecoder.get<uint8_t>(m_header,2);
38 }
40  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 3);
41 }
43  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 4);
44 }
46  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 5);
47 }
49  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 6);
50 }
52  return ::subBlockHeaderDecoder.get<uint8_t>(m_header, 7);
53 }
54 
56  return (type() & 0xc) == 0xc;
57 }
58 
60  return ZdcSubBlockHeader(word).isSubBlockHeader();
61 }
62 
64  return (type() & 0xe) == 0xc;
65 }
66 
67 
header
Definition: hcg.cxx:526
xAOD::uint8_t
uint8_t
Definition: Muon_v1.cxx:557
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
ZdcSubBlockHeader::isPpmBlock
bool isPpmBlock() const
Definition: ZdcSubBlockHeader.cxx:63
ZdcSubBlockHeader.h
ZdcSubBlockHeader::module
uint8_t module() const
Definition: ZdcSubBlockHeader.cxx:45
ZdcSubBlockHeader::format
uint8_t format() const
Definition: ZdcSubBlockHeader.cxx:36
BitField
Definition: ZdcWordDecoder.h:14
ZdcSubBlockHeader::version
uint8_t version() const
Definition: ZdcSubBlockHeader.cxx:33
ZdcSubBlockHeader::nSlice1
uint8_t nSlice1() const
Definition: ZdcSubBlockHeader.cxx:51
ZdcSubBlockHeader::type
uint8_t type() const
Definition: ZdcSubBlockHeader.cxx:30
ZdcSubBlockHeader::m_header
uint32_t m_header
Definition: ZdcSubBlockHeader.h:22
ZdcSubBlockHeader::nSlice2
uint8_t nSlice2() const
Definition: ZdcSubBlockHeader.cxx:48
ZdcSubBlockHeader::seqNum
uint8_t seqNum() const
Definition: ZdcSubBlockHeader.cxx:39
ZdcSubBlockHeader::crate
uint8_t crate() const
Definition: ZdcSubBlockHeader.cxx:42
ZdcWordDecoder
Definition: ZdcWordDecoder.h:37
ZdcSubBlockHeader::ZdcSubBlockHeader
ZdcSubBlockHeader(uint32_t header=0x0)
Constructor - default just sets word ID and number of header words.
Definition: ZdcSubBlockHeader.cxx:25
ZdcWordDecoder.h
ZdcSubBlockHeader::isSubBlockHeader
bool isSubBlockHeader() const
Definition: ZdcSubBlockHeader.cxx:55