ATLAS Offline Software
Public Member Functions | Protected Member Functions | Private Attributes | List of all members
L1Topo::Status Class Reference

Represents the L1Topo status word of the L1Topo DAQ header, with decoder and encoder. More...

#include <Status.h>

Collaboration diagram for L1Topo::Status:

Public Member Functions

 Status (const uint32_t overflow, const uint32_t crc)
 Construct from contents and encode word. More...
 
 Status (const uint32_t word)
 Construct from word and encode contents. More...
 
uint32_t overflow () const
 access method More...
 
uint32_t crc () const
 access method More...
 
uint32_t word () const
 access method More...
 

Protected Member Functions

void decode ()
 method used by constructor to decode word More...
 
void encode ()
 method used by constructor to encode word More...
 

Private Attributes

uint32_t m_overflow
 overflow flag More...
 
uint32_t m_crc
 CRC mismatch flag. More...
 
uint32_t m_word
 The raw data representation. More...
 

Detailed Description

Represents the L1Topo status word of the L1Topo DAQ header, with decoder and encoder.

Used to decode/encode the 32-bit word whch contains just two 1-bit flags: overflow flag and CRC mismatch flag.

Definition at line 19 of file Status.h.

Constructor & Destructor Documentation

◆ Status() [1/2]

L1Topo::Status::Status ( const uint32_t  overflow,
const uint32_t  crc 
)

Construct from contents and encode word.

Definition at line 12 of file Status.cxx.

14  this->encode();
15  }

◆ Status() [2/2]

L1Topo::Status::Status ( const uint32_t  word)

Construct from word and encode contents.

Definition at line 17 of file Status.cxx.

18  :m_overflow(0), m_crc(0), m_word(word) {
19  this->decode();
20  }

Member Function Documentation

◆ crc()

uint32_t L1Topo::Status::crc ( ) const

access method

Definition at line 41 of file Status.cxx.

41  {
42  return m_crc;
43  }

◆ decode()

void L1Topo::Status::decode ( )
protected

method used by constructor to decode word

Definition at line 28 of file Status.cxx.

28  {
29  m_overflow = (m_word >> 27) & 0x1;
30  m_crc = (m_word >> 26) & 0x1;
31  }

◆ encode()

void L1Topo::Status::encode ( )
protected

method used by constructor to encode word

Definition at line 22 of file Status.cxx.

22  {
23  m_word = static_cast<uint32_t>(L1Topo::BlockTypes::STATUS) << 28;
24  m_word |= (m_overflow & 0x1) << 27;
25  m_word |= (m_crc & 0x1) << 26;
26  }

◆ overflow()

uint32_t L1Topo::Status::overflow ( ) const

access method

Definition at line 37 of file Status.cxx.

37  {
38  return m_overflow;
39  }

◆ word()

uint32_t L1Topo::Status::word ( ) const

access method

Definition at line 33 of file Status.cxx.

33  {
34  return m_word;
35  }

Member Data Documentation

◆ m_crc

uint32_t L1Topo::Status::m_crc
private

CRC mismatch flag.

Definition at line 40 of file Status.h.

◆ m_overflow

uint32_t L1Topo::Status::m_overflow
private

overflow flag

Definition at line 38 of file Status.h.

◆ m_word

uint32_t L1Topo::Status::m_word
private

The raw data representation.

Definition at line 42 of file Status.h.


The documentation for this class was generated from the following files:
plotBeamSpotCompare.x1
x1
Definition: plotBeamSpotCompare.py:216
L1Topo::Status::encode
void encode()
method used by constructor to encode word
Definition: Status.cxx:22
xAOD::uint32_t
setEventNumber uint32_t
Definition: EventInfo_v1.cxx:127
L1Topo::BlockTypes::STATUS
@ STATUS
L1Topo::Status::m_overflow
uint32_t m_overflow
overflow flag
Definition: Status.h:38
L1Topo::Status::m_crc
uint32_t m_crc
CRC mismatch flag.
Definition: Status.h:40
L1Topo::Status::decode
void decode()
method used by constructor to decode word
Definition: Status.cxx:28
L1Topo::Status::crc
uint32_t crc() const
access method
Definition: Status.cxx:41
L1Topo::Status::word
uint32_t word() const
access method
Definition: Status.cxx:33
L1Topo::Status::overflow
uint32_t overflow() const
access method
Definition: Status.cxx:37
L1Topo::Status::m_word
uint32_t m_word
The raw data representation.
Definition: Status.h:42