ATLAS Offline Software
Loading...
Searching...
No Matches
Mon Class Reference

Tool to store LATOME mon header and footer data. More...

#include <Mon.h>

Collaboration diagram for Mon:

Public Member Functions

 Mon ()
 ~Mon ()
void fillPacketInfo (uint32_t word)
void fillHeaderSize (uint32_t word)
void fillRegion (uint32_t word)
void fillNStreams (uint32_t word)
void fillStreamNumber (uint32_t word)
void fillDataType (uint32_t word, int i)
void fillNBCs (uint32_t word, int i)
void fillTimeShift (uint32_t word, int i)
void fillNActiveSCs (uint32_t word)

Public Attributes

uint32_t LATOMEID = 0U
uint32_t extendedL1ID = 0U
uint32_t headerMarker
int nPackets = 0
int packetIndex = 0
int packetSize = 0
uint32_t debugMarker
int headerSize = MON_HEADER_SIZE
int region = 0
int nStreams
int streamNumber
std::array< int, 2 > dataType {}
std::array< int, 2 > nBCs {}
std::array< uint32_t, 2 > timeShift {}
int nActiveSCs = 0
int nthMONHWordPacketDetermined = 3
std::array< uint32_t, MON_HEADER_SIZEheaderRef = {0, 0, 0xFF1234FF, 0, 0xDEADBEEF, MON_HEADER_SIZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}
std::array< uint32_t, 2 > trailerRef = {0xC0FFEE00, 0xAAAAAAAA}

Detailed Description

Tool to store LATOME mon header and footer data.

Definition at line 19 of file Mon.h.

Constructor & Destructor Documentation

◆ Mon()

Mon::Mon ( )

Definition at line 11 of file Mon.cxx.

13{}
#define NSTREAMS
Definition Mon.cxx:6
#define STREAMNUMBER
Definition Mon.cxx:7
uint32_t debugMarker
Definition Mon.h:40
uint32_t headerMarker
Definition Mon.h:36
int streamNumber
Definition Mon.h:44
int nStreams
Definition Mon.h:43

◆ ~Mon()

Mon::~Mon ( )

Member Function Documentation

◆ fillDataType()

void Mon::fillDataType ( uint32_t word,
int i )

Definition at line 47 of file Mon.cxx.

47 {
48 dataType[i] = static_cast<int>(word);
49 switch (dataType[i]) {
50 case 0: return;
51 case 1: return;
52 case 2: return;
53 case 3: return;
54 case 0xff: return;
55 default:
56 std::cout << "Unknown calorimeter region word in mon header.\n";
57 }
58}
std::array< int, 2 > dataType
Definition Mon.h:45

◆ fillHeaderSize()

void Mon::fillHeaderSize ( uint32_t word)

◆ fillNActiveSCs()

void Mon::fillNActiveSCs ( uint32_t word)

Definition at line 69 of file Mon.cxx.

69 {
70 nActiveSCs = static_cast<int>(word);
71 if (nActiveSCs != NACTIVESCS) std::cout << "Number of BCs word in mon header is not the standard one.\n";
72}
#define NACTIVESCS
Definition Mon.cxx:9
int nActiveSCs
Definition Mon.h:48

◆ fillNBCs()

void Mon::fillNBCs ( uint32_t word,
int i )

Definition at line 60 of file Mon.cxx.

60 {
61 nBCs[i] = static_cast<int>(word);
62 if (nBCs[i] != NBCS) std::cout << "Number of BCs word in mon header is not the standard one.\n";
63}
#define NBCS
Definition Mon.cxx:8
std::array< int, 2 > nBCs
Definition Mon.h:46

◆ fillNStreams()

void Mon::fillNStreams ( uint32_t word)

Definition at line 37 of file Mon.cxx.

37 {
38 nStreams = static_cast<int>(word);
39 if (nStreams != NSTREAMS) std::cout << "Number of streams word in mon header is not the standard one.\n";
40}

◆ fillPacketInfo()

void Mon::fillPacketInfo ( uint32_t word)

Definition at line 15 of file Mon.cxx.

15 {
16 nPackets = static_cast<int>((word & 0xff000000) >> 24);
17 packetIndex = static_cast<int>((word & 0xff0000) >> 16);
18 uint16_t sizeInBytes = static_cast<uint16_t>(word & 0xffff);
19 if (sizeInBytes % 4) std::cout << "ERROR: Packet size written in the mon header is not multiple of 4 (cannot be converted from [bytes] to [32 bit words])\n";
20 else packetSize = static_cast<int>(sizeInBytes / 4);
21}
int packetSize
Definition Mon.h:39
int nPackets
Definition Mon.h:37
int packetIndex
Definition Mon.h:38
setWord1 uint16_t

◆ fillRegion()

void Mon::fillRegion ( uint32_t word)

Definition at line 23 of file Mon.cxx.

23 {
24 region = static_cast<int>(word);
25 switch (region) {
26 case 0: return;
27 case 1: return;
28 case 2: return;
29 case 3: return;
30 case 4: return;
31 case 5: return;
32 default:
33 std::cout << "Unknown calorimeter region word in mon header.\n";
34 }
35}
int region
Definition Mon.h:42

◆ fillStreamNumber()

void Mon::fillStreamNumber ( uint32_t word)

Definition at line 42 of file Mon.cxx.

42 {
43 streamNumber = static_cast<int>(word);
44 if (streamNumber != STREAMNUMBER) std::cout << "Stream number word in mon header is not the standard one.\n";
45}

◆ fillTimeShift()

void Mon::fillTimeShift ( uint32_t word,
int i )

Definition at line 65 of file Mon.cxx.

65 {
66 timeShift[i] = word;
67}
std::array< uint32_t, 2 > timeShift
Definition Mon.h:47

Member Data Documentation

◆ dataType

std::array<int, 2> Mon::dataType {}

Definition at line 45 of file Mon.h.

45{};

◆ debugMarker

uint32_t Mon::debugMarker

Definition at line 40 of file Mon.h.

◆ extendedL1ID

uint32_t Mon::extendedL1ID = 0U

Definition at line 35 of file Mon.h.

◆ headerMarker

uint32_t Mon::headerMarker

Definition at line 36 of file Mon.h.

◆ headerRef

std::array<uint32_t, MON_HEADER_SIZE> Mon::headerRef = {0, 0, 0xFF1234FF, 0, 0xDEADBEEF, MON_HEADER_SIZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}

Definition at line 50 of file Mon.h.

50{0, 0, 0xFF1234FF, 0, 0xDEADBEEF, MON_HEADER_SIZE, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
#define MON_HEADER_SIZE
Definition Mon.h:17

◆ headerSize

int Mon::headerSize = MON_HEADER_SIZE

Definition at line 41 of file Mon.h.

◆ LATOMEID

uint32_t Mon::LATOMEID = 0U

Definition at line 34 of file Mon.h.

◆ nActiveSCs

int Mon::nActiveSCs = 0

Definition at line 48 of file Mon.h.

◆ nBCs

std::array<int, 2> Mon::nBCs {}

Definition at line 46 of file Mon.h.

46{};

◆ nPackets

int Mon::nPackets = 0

Definition at line 37 of file Mon.h.

◆ nStreams

int Mon::nStreams

Definition at line 43 of file Mon.h.

◆ nthMONHWordPacketDetermined

int Mon::nthMONHWordPacketDetermined = 3

Definition at line 49 of file Mon.h.

◆ packetIndex

int Mon::packetIndex = 0

Definition at line 38 of file Mon.h.

◆ packetSize

int Mon::packetSize = 0

Definition at line 39 of file Mon.h.

◆ region

int Mon::region = 0

Definition at line 42 of file Mon.h.

◆ streamNumber

int Mon::streamNumber

Definition at line 44 of file Mon.h.

◆ timeShift

std::array<uint32_t, 2> Mon::timeShift {}

Definition at line 47 of file Mon.h.

47{};

◆ trailerRef

std::array<uint32_t, 2> Mon::trailerRef = {0xC0FFEE00, 0xAAAAAAAA}

Definition at line 51 of file Mon.h.

51{0xC0FFEE00, 0xAAAAAAAA};

The documentation for this class was generated from the following files: