Main Page
Namespaces
Classes
Package Documentation
EventFilter
Phase2TrackerRawToDigi
interface
Phase2TrackerFEDHeader.h
Go to the documentation of this file.
1
#ifndef EventFilter_Phase2TrackerRawToDigi_Phase2TrackerPhase2TrackerFEDHeader_H // {
2
#define EventFilter_Phase2TrackerRawToDigi_Phase2TrackerPhase2TrackerFEDHeader_H
3
4
#include "
EventFilter/Phase2TrackerRawToDigi/interface/Phase2TrackerFEDDAQHeader.h
"
5
#include "
EventFilter/Phase2TrackerRawToDigi/interface/Phase2TrackerFEDDAQTrailer.h
"
6
#include <stdint.h>
7
#include <vector>
8
9
namespace
Phase2Tracker
{
10
11
// tracker headers for new CBC system
12
class
Phase2TrackerFEDHeader
13
{
14
public
:
15
Phase2TrackerFEDHeader
() {}
16
17
explicit
Phase2TrackerFEDHeader
(
const
uint8_t* headerPointer);
18
19
// getters:
20
inline
uint8_t
getDataFormatVersion
()
const
{
return
dataFormatVersion_
; }
21
inline
READ_MODE
getDebugMode
()
const
{
return
debugMode_
; }
22
23
inline
uint8_t
getEventType
()
const
{
return
eventType_
; }
24
inline
FEDReadoutMode
getReadoutMode
()
const
{
return
readoutMode_
; }
25
inline
uint8_t
getConditionData
()
const
{
return
conditionData_
; }
26
inline
uint8_t
getDataType
()
const
{
return
dataType_
; }
27
28
inline
uint64_t
getGlibStatusCode
()
const
{
return
glibStatusCode_
; }
29
inline
uint16_t
getNumberOfCBC
()
const
{
return
numberOfCBC_
; }
30
31
// get pointer to Payload data after tracker head
32
const
uint8_t*
getPointerToData
()
const
{
return
pointerToData_
;}
33
// get Front-End Status (16 bits) ==> 16 bool
34
std::vector<bool>
frontendStatus
()
const
;
35
36
inline
uint8_t
getTrackerHeaderSize
()
const
{
return
trackerHeaderSize_
; }
37
38
// CBC status bits, according to debug mode
39
// (empty, 1bit per CBC, 8bits per CBC)
40
std::vector<uint8_t>
CBCStatus
()
const
;
41
42
private
:
43
// readers: read info from Tracker Header and store in local variables
44
45
// version number (4 bits)
46
uint8_t
dataFormatVersion
()
const
;
47
// debug level (2 bits) :
48
// 01 = full debug, 10 = CBC error mode, 00 = summary mode
49
READ_MODE
debugMode
()
const
;
50
// event type (4 bits):
51
// RAW/ZS, condition data, data type (real or simulated)
52
uint8_t
eventType
()
const
;
53
// get readout mode (first bit of the above)
54
FEDReadoutMode
readoutMode
()
const
;
55
uint8_t
conditionData
()
const
;
56
uint8_t
dataType
()
const
;
57
// glib status registers code (38 bits)
58
uint64_t
glibStatusCode
()
const
;
59
// number of CBC chips (8 bits)
60
uint16_t
numberOfCBC
()
const
;
61
// get tracker size (see function) and pointer to end of header. Also sets the TrackerHeaderSize.
62
const
uint8_t*
pointerToData
();
63
64
private
:
65
void
init
();
66
const
uint8_t*
trackerHeader_
;
// pointer to the begining of Tracker Header
67
const
uint8_t*
pointerToData_
;
// pointer next to end of Tracker Header
68
uint8_t
trackerHeaderSize_
;
// Tracker Header in bytes
69
uint64_t
header_first_word_
;
70
uint64_t
header_second_word_
;
71
uint8_t
dataFormatVersion_
;
// shoud be 1
72
READ_MODE
debugMode_
;
// debug, error, sumary ...
73
uint8_t
eventType_
;
// contains readoutMode_, conditionData_ and dataType_
74
FEDReadoutMode
readoutMode_
;
// proc raw or zero suppress
75
uint8_t
conditionData_
;
// condition data present or not
76
uint8_t
dataType_
;
// data fake or real
77
uint64_t
glibStatusCode_
;
// glib status registers
78
uint16_t
numberOfCBC_
;
// Total number of connected CBC
79
80
};
// end of Phase2TrackerFEDHeader class
81
}
82
#endif // } end def EventFilter_Phase2TrackerRawToDigi_Phase2TrackerPhase2TrackerFEDHeader_H
83
Phase2Tracker::Phase2TrackerFEDHeader::CBCStatus
std::vector< uint8_t > CBCStatus() const
Definition:
Phase2TrackerFEDHeader.cc:150
Phase2TrackerFEDDAQHeader.h
Phase2Tracker::Phase2TrackerFEDHeader::getGlibStatusCode
uint64_t getGlibStatusCode() const
Definition:
Phase2TrackerFEDHeader.h:28
Phase2Tracker::Phase2TrackerFEDHeader::glibStatusCode_
uint64_t glibStatusCode_
Definition:
Phase2TrackerFEDHeader.h:77
Phase2Tracker::Phase2TrackerFEDHeader::dataFormatVersion_
uint8_t dataFormatVersion_
Definition:
Phase2TrackerFEDHeader.h:71
Phase2Tracker::Phase2TrackerFEDHeader::conditionData_
uint8_t conditionData_
Definition:
Phase2TrackerFEDHeader.h:75
Phase2Tracker::Phase2TrackerFEDHeader::getDataType
uint8_t getDataType() const
Definition:
Phase2TrackerFEDHeader.h:26
Phase2Tracker::Phase2TrackerFEDHeader::dataFormatVersion
uint8_t dataFormatVersion() const
Definition:
Phase2TrackerFEDHeader.cc:47
Phase2Tracker::Phase2TrackerFEDHeader::pointerToData
const uint8_t * pointerToData()
Definition:
Phase2TrackerFEDHeader.cc:206
Phase2Tracker::Phase2TrackerFEDHeader::debugMode
READ_MODE debugMode() const
Definition:
Phase2TrackerFEDHeader.cc:61
Phase2Tracker::Phase2TrackerFEDHeader::getConditionData
uint8_t getConditionData() const
Definition:
Phase2TrackerFEDHeader.h:25
Phase2Tracker::Phase2TrackerFEDHeader::header_second_word_
uint64_t header_second_word_
Definition:
Phase2TrackerFEDHeader.h:70
Phase2Tracker
Definition:
Phase2TrackerFEDBuffer.h:12
Phase2Tracker::Phase2TrackerFEDHeader::getNumberOfCBC
uint16_t getNumberOfCBC() const
Definition:
Phase2TrackerFEDHeader.h:29
Phase2Tracker::Phase2TrackerFEDHeader::getPointerToData
const uint8_t * getPointerToData() const
Definition:
Phase2TrackerFEDHeader.h:32
Phase2Tracker::Phase2TrackerFEDHeader::Phase2TrackerFEDHeader
Phase2TrackerFEDHeader()
Definition:
Phase2TrackerFEDHeader.h:15
Phase2Tracker::READ_MODE
READ_MODE
Definition:
utils.h:144
Phase2Tracker::Phase2TrackerFEDHeader::frontendStatus
std::vector< bool > frontendStatus() const
Definition:
Phase2TrackerFEDHeader.cc:126
Phase2Tracker::Phase2TrackerFEDHeader::getDataFormatVersion
uint8_t getDataFormatVersion() const
Definition:
Phase2TrackerFEDHeader.h:20
Phase2Tracker::Phase2TrackerFEDHeader::dataType_
uint8_t dataType_
Definition:
Phase2TrackerFEDHeader.h:76
Phase2Tracker::Phase2TrackerFEDHeader::readoutMode
FEDReadoutMode readoutMode() const
Definition:
Phase2TrackerFEDHeader.cc:91
Phase2Tracker::FEDReadoutMode
FEDReadoutMode
Definition:
utils.h:98
Phase2Tracker::Phase2TrackerFEDHeader::pointerToData_
const uint8_t * pointerToData_
Definition:
Phase2TrackerFEDHeader.h:67
Phase2Tracker::Phase2TrackerFEDHeader::dataType
uint8_t dataType() const
Definition:
Phase2TrackerFEDHeader.cc:116
Phase2Tracker::Phase2TrackerFEDHeader::trackerHeaderSize_
uint8_t trackerHeaderSize_
Definition:
Phase2TrackerFEDHeader.h:68
Phase2Tracker::Phase2TrackerFEDHeader::conditionData
uint8_t conditionData() const
Definition:
Phase2TrackerFEDHeader.cc:111
Phase2Tracker::Phase2TrackerFEDHeader::init
void init()
Definition:
Phase2TrackerFEDHeader.cc:18
Phase2Tracker::Phase2TrackerFEDHeader::eventType
uint8_t eventType() const
Definition:
Phase2TrackerFEDHeader.cc:85
Phase2Tracker::Phase2TrackerFEDHeader::numberOfCBC_
uint16_t numberOfCBC_
Definition:
Phase2TrackerFEDHeader.h:78
Phase2TrackerFEDDAQTrailer.h
Phase2Tracker::Phase2TrackerFEDHeader::numberOfCBC
uint16_t numberOfCBC() const
Definition:
Phase2TrackerFEDHeader.cc:137
Phase2Tracker::Phase2TrackerFEDHeader::getDebugMode
READ_MODE getDebugMode() const
Definition:
Phase2TrackerFEDHeader.h:21
Phase2Tracker::Phase2TrackerFEDHeader::getTrackerHeaderSize
uint8_t getTrackerHeaderSize() const
Definition:
Phase2TrackerFEDHeader.h:36
Phase2Tracker::Phase2TrackerFEDHeader::eventType_
uint8_t eventType_
Definition:
Phase2TrackerFEDHeader.h:73
cond::uint64_t
unsigned long long uint64_t
Definition:
Time.h:15
Phase2Tracker::Phase2TrackerFEDHeader::getReadoutMode
FEDReadoutMode getReadoutMode() const
Definition:
Phase2TrackerFEDHeader.h:24
Phase2Tracker::Phase2TrackerFEDHeader
Definition:
Phase2TrackerFEDHeader.h:12
Phase2Tracker::Phase2TrackerFEDHeader::trackerHeader_
const uint8_t * trackerHeader_
Definition:
Phase2TrackerFEDHeader.h:66
Phase2Tracker::Phase2TrackerFEDHeader::getEventType
uint8_t getEventType() const
Definition:
Phase2TrackerFEDHeader.h:23
Phase2Tracker::Phase2TrackerFEDHeader::glibStatusCode
uint64_t glibStatusCode() const
Definition:
Phase2TrackerFEDHeader.cc:121
Phase2Tracker::Phase2TrackerFEDHeader::debugMode_
READ_MODE debugMode_
Definition:
Phase2TrackerFEDHeader.h:72
Phase2Tracker::Phase2TrackerFEDHeader::header_first_word_
uint64_t header_first_word_
Definition:
Phase2TrackerFEDHeader.h:69
Phase2Tracker::Phase2TrackerFEDHeader::readoutMode_
FEDReadoutMode readoutMode_
Definition:
Phase2TrackerFEDHeader.h:74
Generated for CMSSW Reference Manual by
1.8.11