#include <DataFormats/L1GlobalTrigger/interface/L1TcsWord.h>
Public Member Functions | |
const boost::uint32_t | assignedPartitions () const |
get/set assigned partition: bit "i" correspond to detector partition "i" | |
const boost::uint16_t | boardId () const |
get/set board ID | |
const boost::uint16_t | bxNr () const |
get/set bunch cross number as counted in the TCS chip | |
const boost::uint16_t | daqNr () const |
get/set number of DAQ partition to which the L1A has been sent | |
const boost::uint32_t | eventNr () const |
get/set event number since last L1 reset generated in TCS chip | |
const unsigned int | getSize () const |
get the size of the TCS block in GT EVM record (in multiple of 8 bits) | |
L1TcsWord (boost::uint16_t boardIdValue, boost::uint16_t bxNrValue, boost::uint16_t daqNrValue, boost::uint16_t triggerTypeValue, boost::uint16_t statusValue, boost::uint16_t luminositySegmentNrValue, boost::uint32_t partRunNrValue, boost::uint32_t assignedPartitionsValue, boost::uint32_t partTrigNrValue, boost::uint32_t eventNrValue, boost::uint64_t orbitNrValue) | |
constructor from unpacked values; | |
L1TcsWord () | |
constructors | |
const boost::uint16_t | luminositySegmentNr () const |
get/set luminosity segment number | |
bool | operator!= (const L1TcsWord &) const |
unequal operator | |
bool | operator== (const L1TcsWord &) const |
equal operator | |
const boost::uint64_t | orbitNr () const |
get/set orbit number since start of run | |
const boost::uint32_t | partRunNr () const |
get/set partition run number | |
const boost::uint32_t | partTrigNr () const |
get/set total number of L1A sent since start of the run to this DAQ partition | |
void | print (std::ostream &myCout) const |
pretty print the content of a L1TcsWord | |
void | reset () |
reset the content of a L1TcsWord | |
void | setAssignedPartitions (const boost::uint64_t &word64) |
set the AssignedPartitions value from a 64-bits word | |
void | setAssignedPartitions (const boost::uint32_t assignedPartitionsValue) |
void | setAssignedPartitionsWord64 (boost::uint64_t &word64, int iWord) |
set the AssignedPartitions value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setBoardId (const boost::uint64_t &word64) |
set the BoardId value from a 64-bits word | |
void | setBoardId (const boost::uint16_t boardIdValue) |
set BoardId from a BoardId value | |
void | setBoardIdWord64 (boost::uint64_t &word64, int iWord) |
set the BoardId value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setBxNr (const boost::uint64_t &word64) |
set the BxNr value from a 64-bits word | |
void | setBxNr (const boost::uint16_t bxNrValue) |
void | setBxNrWord64 (boost::uint64_t &word64, int iWord) |
set the BxNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setDaqNr (const boost::uint64_t &word64) |
set the DaqNr value from a 64-bits word | |
void | setDaqNr (const boost::uint16_t daqNrValue) |
void | setDaqNrWord64 (boost::uint64_t &word64, int iWord) |
set the DaqNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setEventNr (const boost::uint64_t &word64) |
set the EventNr value from a 64-bits word | |
void | setEventNr (const boost::uint32_t eventNrValue) |
void | setEventNrWord64 (boost::uint64_t &word64, int iWord) |
set the EventNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setLuminositySegmentNr (const boost::uint64_t &word64) |
set the luminosity segment number value from a 64-bits word | |
void | setLuminositySegmentNr (const boost::uint16_t luminositySegmentNrValue) |
void | setLuminositySegmentNrWord64 (boost::uint64_t &word64, int iWord) |
set the luminosity segment number value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setOrbitNr (const boost::uint64_t orbitNrValue) |
void | setOrbitNrFrom (const boost::uint64_t &word64) |
set the OrbitNr value from a 64-bits word | |
void | setOrbitNrWord64 (boost::uint64_t &word64, int iWord) |
set the OrbitNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setPartRunNr (const boost::uint64_t &word64) |
set the PartRunNr value from a 64-bits word | |
void | setPartRunNr (const boost::uint32_t partRunNrValue) |
void | setPartRunNrWord64 (boost::uint64_t &word64, int iWord) |
set the PartRunNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setPartTrigNr (const boost::uint64_t &word64) |
set the PartTrigNr value from a 64-bits word | |
void | setPartTrigNr (const boost::uint32_t partTrigNrValue) |
void | setPartTrigNrWord64 (boost::uint64_t &word64, int iWord) |
set the PartTrigNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setStatus (const boost::uint64_t &word64) |
set the Status value from a 64-bits word | |
void | setStatus (const boost::uint16_t statusValue) |
void | setStatusWord64 (boost::uint64_t &word64, int iWord) |
set the Status value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
void | setTriggerType (const boost::uint64_t &word64) |
set the TriggerType value from a 64-bits word | |
void | setTriggerType (const boost::uint16_t triggerTypeValue) |
void | setTriggerTypeWord64 (boost::uint64_t &word64, int iWord) |
set the TriggerType value in a 64-bits word, having the index iWord in the GTFE EVM raw record | |
const boost::uint16_t | status () const |
get/set status: 0000 = normal rate; 1000 = low rate = warning | |
const boost::uint16_t | triggerType () const |
get/set trigger type, identical with event type in CMS header | |
void | unpack (const unsigned char *tcsPtr) |
unpack TCS tcsPtr pointer to the beginning of the TCS block in the raw data | |
virtual | ~L1TcsWord () |
destructor | |
Private Attributes | |
boost::uint32_t | m_assignedPartitions |
bit "i" correspond to detector partition "i" if bit = 1, detection partition connected to actual DAQ partition | |
boost::uint16_t | m_boardId |
board identifier | |
boost::uint16_t | m_bxNr |
bunch cross number as counted in the TCS chip | |
boost::uint16_t | m_daqNr |
number of DAQ partition to which the L1A has been sent | |
boost::uint32_t | m_eventNr |
event number since last L1 reset generated in TCS chip | |
boost::uint16_t | m_luminositySegmentNr |
luminosity segment number | |
boost::uint64_t | m_orbitNr |
orbit number since start of run (48 bits, in fact) | |
boost::uint32_t | m_partRunNr |
partition run number | |
boost::uint32_t | m_partTrigNr |
total number of L1A sent since start of the run to this DAQ partition | |
boost::uint16_t | m_status |
0000 = normal rate; 1000 = low rate = warning | |
boost::uint16_t | m_triggerType |
trigger type, identical with event type in CMS header (event type) | |
Static Private Attributes | |
static const boost::uint64_t | AssignedPartitionsMask = 0x00000000FFFFFFFFULL |
static const int | AssignedPartitionsShift = 0 |
static const int | AssignedPartitionsWord = 1 |
static const int | BlockSize = 5 |
static const boost::uint64_t | BoardIdMask = 0xFFFF000000000000ULL |
static const int | BoardIdShift = 48 |
static const int | BoardIdWord = 0 |
static const boost::uint64_t | BxNrMask = 0x00000FFF00000000ULL |
static const int | BxNrShift = 32 |
static const int | BxNrWord = 0 |
static const boost::uint64_t | DaqNrMask = 0x000000000F000000ULL |
static const int | DaqNrShift = 24 |
static const int | DaqNrWord = 0 |
static const boost::uint64_t | EventNrMask = 0x00000000FFFFFFFFULL |
static const int | EventNrShift = 0 |
static const int | EventNrWord = 2 |
static const boost::uint64_t | LuminositySegmentNrMask = 0x000000000000FFFFULL |
static const int | LuminositySegmentNrShift = 0 |
static const int | LuminositySegmentNrWord = 0 |
static const boost::uint64_t | OrbitNrMask = 0x0000FFFFFFFFFFFFULL |
static const int | OrbitNrShift = 0 |
static const int | OrbitNrWord = 3 |
static const boost::uint64_t | PartRunNrMask = 0xFFFFFFFF00000000ULL |
static const int | PartRunNrShift = 32 |
static const int | PartRunNrWord = 1 |
static const boost::uint64_t | PartTrigNrMask = 0xFFFFFFFF00000000ULL |
static const int | PartTrigNrShift = 32 |
static const int | PartTrigNrWord = 2 |
static const boost::uint64_t | StatusMask = 0x00000000000F0000ULL |
static const int | StatusShift = 16 |
static const int | StatusWord = 0 |
static const boost::uint64_t | TriggerTypeMask = 0x0000000000F00000ULL |
static const int | TriggerTypeShift = 20 |
static const int | TriggerTypeWord = 0 |
Description: see header file.
Implementation: <TODO: enter implementation details>
$Date$ $Revision$
Definition at line 31 of file L1TcsWord.h.
L1TcsWord::L1TcsWord | ( | ) |
constructors
Definition at line 32 of file L1TcsWord.cc.
References m_assignedPartitions, m_boardId, m_bxNr, m_daqNr, m_eventNr, m_luminositySegmentNr, m_orbitNr, m_partRunNr, m_partTrigNr, m_status, and m_triggerType.
00033 { 00034 00035 m_boardId = 0; 00036 m_bxNr = 0; 00037 m_daqNr = 0; 00038 m_triggerType = 0; 00039 m_status = 0; 00040 m_luminositySegmentNr = 0; 00041 m_partRunNr = 0; 00042 m_assignedPartitions = 0; 00043 m_partTrigNr = 0; 00044 m_eventNr = 0; 00045 m_orbitNr = 0; 00046 00047 }
L1TcsWord::L1TcsWord | ( | boost::uint16_t | boardIdValue, | |
boost::uint16_t | bxNrValue, | |||
boost::uint16_t | daqNrValue, | |||
boost::uint16_t | triggerTypeValue, | |||
boost::uint16_t | statusValue, | |||
boost::uint16_t | luminositySegmentNrValue, | |||
boost::uint32_t | partRunNrValue, | |||
boost::uint32_t | assignedPartitionsValue, | |||
boost::uint32_t | partTrigNrValue, | |||
boost::uint32_t | eventNrValue, | |||
boost::uint64_t | orbitNrValue | |||
) |
constructor from unpacked values;
Definition at line 50 of file L1TcsWord.cc.
References m_assignedPartitions, m_boardId, m_bxNr, m_daqNr, m_eventNr, m_luminositySegmentNr, m_orbitNr, m_partRunNr, m_partTrigNr, m_status, and m_triggerType.
00062 { 00063 00064 m_boardId = boardIdValue; 00065 m_bxNr = bxNrValue; 00066 m_daqNr = daqNrValue; 00067 m_triggerType = triggerTypeValue; 00068 m_status = statusValue; 00069 m_luminositySegmentNr = luminositySegmentNrValue; 00070 m_partRunNr = partRunNrValue; 00071 m_assignedPartitions = assignedPartitionsValue; 00072 m_partTrigNr = partTrigNrValue; 00073 m_eventNr = eventNrValue; 00074 m_orbitNr = orbitNrValue; 00075 00076 }
L1TcsWord::~L1TcsWord | ( | ) | [virtual] |
const boost::uint32_t L1TcsWord::assignedPartitions | ( | ) | const [inline] |
get/set assigned partition: bit "i" correspond to detector partition "i"
Definition at line 208 of file L1TcsWord.h.
References m_assignedPartitions.
00209 { 00210 return m_assignedPartitions; 00211 }
const boost::uint16_t L1TcsWord::boardId | ( | ) | const [inline] |
get/set board ID
get BoardId value
Definition at line 68 of file L1TcsWord.h.
References m_boardId.
00069 { 00070 return m_boardId; 00071 }
const boost::uint16_t L1TcsWord::bxNr | ( | ) | const [inline] |
get/set bunch cross number as counted in the TCS chip
Definition at line 89 of file L1TcsWord.h.
References m_bxNr.
Referenced by L1TGT::analyze().
00090 { 00091 return m_bxNr; 00092 }
const boost::uint16_t L1TcsWord::daqNr | ( | ) | const [inline] |
get/set number of DAQ partition to which the L1A has been sent
Definition at line 109 of file L1TcsWord.h.
References m_daqNr.
00110 { 00111 return m_daqNr; 00112 }
const boost::uint32_t L1TcsWord::eventNr | ( | ) | const [inline] |
get/set event number since last L1 reset generated in TCS chip
Definition at line 248 of file L1TcsWord.h.
References m_eventNr.
Referenced by L1TGT::analyze().
00249 { 00250 return m_eventNr; 00251 }
const unsigned int L1TcsWord::getSize | ( | ) | const [inline] |
get the size of the TCS block in GT EVM record (in multiple of 8 bits)
Definition at line 287 of file L1TcsWord.h.
References BlockSize, and L1GlobalTriggerReadoutSetup::UnitLength.
Referenced by L1GTEvmDigiToRaw::packTCS(), L1GTEvmDigiToRaw::produce(), L1GlobalTriggerEvmRawToDigi::produce(), and L1GTDigiToRaw::produce().
00288 { 00289 int unitLengthBits = L1GlobalTriggerReadoutSetup::UnitLength; 00290 00291 return BlockSize*unitLengthBits; 00292 }
const boost::uint16_t L1TcsWord::luminositySegmentNr | ( | ) | const [inline] |
get/set luminosity segment number
Definition at line 168 of file L1TcsWord.h.
References m_luminositySegmentNr.
00169 { 00170 return m_luminositySegmentNr; 00171 }
equal operator
Definition at line 87 of file L1TcsWord.cc.
References m_assignedPartitions, m_boardId, m_bxNr, m_daqNr, m_eventNr, m_luminositySegmentNr, m_orbitNr, m_partRunNr, m_partTrigNr, m_status, and m_triggerType.
00088 { 00089 00090 if (m_boardId != result.m_boardId) { 00091 return false; 00092 } 00093 00094 if (m_bxNr != result.m_bxNr) { 00095 return false; 00096 } 00097 00098 if (m_daqNr != result.m_daqNr) { 00099 return false; 00100 } 00101 00102 if (m_triggerType != result.m_triggerType) { 00103 return false; 00104 } 00105 00106 if (m_status != result.m_status) { 00107 return false; 00108 } 00109 00110 if (m_luminositySegmentNr != result.m_luminositySegmentNr) { 00111 return false; 00112 } 00113 00114 if (m_partRunNr != result.m_partRunNr) { 00115 return false; 00116 } 00117 00118 if (m_assignedPartitions != result.m_assignedPartitions) { 00119 return false; 00120 } 00121 00122 if (m_partTrigNr != result.m_partTrigNr) { 00123 return false; 00124 } 00125 00126 if (m_eventNr != result.m_eventNr) { 00127 return false; 00128 } 00129 00130 if (m_orbitNr != result.m_orbitNr) { 00131 return false; 00132 } 00133 00134 // all members identical 00135 return true; 00136 00137 }
const boost::uint64_t L1TcsWord::orbitNr | ( | ) | const [inline] |
get/set orbit number since start of run
Definition at line 268 of file L1TcsWord.h.
References m_orbitNr.
Referenced by L1TGT::analyze(), EBRawDataTask::analyze(), and EERawDataTask::analyze().
00269 { 00270 return m_orbitNr; 00271 }
const boost::uint32_t L1TcsWord::partRunNr | ( | ) | const [inline] |
get/set partition run number
Definition at line 188 of file L1TcsWord.h.
References m_partRunNr.
00189 { 00190 return m_partRunNr; 00191 }
const boost::uint32_t L1TcsWord::partTrigNr | ( | ) | const [inline] |
get/set total number of L1A sent since start of the run to this DAQ partition
Definition at line 228 of file L1TcsWord.h.
References m_partTrigNr.
Referenced by L1TGT::analyze().
00229 { 00230 return m_partTrigNr; 00231 }
void L1TcsWord::print | ( | std::ostream & | myCout | ) | const |
pretty print the content of a L1TcsWord
Definition at line 405 of file L1TcsWord.cc.
References lat::endl(), m_assignedPartitions, m_boardId, m_bxNr, m_daqNr, m_eventNr, m_luminositySegmentNr, m_orbitNr, m_partRunNr, m_partTrigNr, m_status, and m_triggerType.
Referenced by L1GlobalTriggerEvmReadoutRecord::print(), L1GTEvmDigiToRaw::produce(), and L1GlobalTriggerEvmRawToDigi::produce().
00406 { 00407 00408 myCout << "\n L1TcsWord::print \n" << std::endl; 00409 00410 int iWord = 0; 00411 00412 myCout << "\n Word " << iWord << std::endl; 00413 00414 myCout << " Board Id: " 00415 << std::hex << " hex: " << " "<< std::setw(4) << std::setfill('0') << m_boardId 00416 << std::setfill(' ') 00417 << std::dec << " dec: " << m_boardId 00418 << std::endl; 00419 00420 00421 myCout << " BxNr: " 00422 << std::hex << " hex: " << " " << std::setw(3) << std::setfill('0') << m_bxNr 00423 << std::setfill(' ') 00424 << std::dec << " dec: " << m_bxNr 00425 << std::endl; 00426 00427 00428 myCout << " DaqNr: " 00429 << std::hex << " hex: " << " " << std::setw(1) << m_daqNr 00430 << std::dec << " dec: " << m_daqNr 00431 << std::endl; 00432 00433 myCout << " TriggerType: " 00434 << std::hex << " hex: " << " " << std::setw(1) << m_triggerType 00435 << std::dec << " dec: " << m_triggerType 00436 << std::endl; 00437 00438 myCout << " Status: " 00439 << std::hex << " hex: " << " " << std::setw(1) << m_status 00440 << std::dec << " dec: " << m_status 00441 << std::endl; 00442 00443 myCout << " LuminositySegmentNr: " 00444 << std::hex << " hex: " << " " << std::setw(4) << m_luminositySegmentNr 00445 << std::dec << " dec: " << m_luminositySegmentNr 00446 << std::endl; 00447 00448 00449 iWord++; 00450 myCout << "\n Word " << iWord << std::endl; 00451 00452 myCout << " PartRunNr: " 00453 << std::hex << " hex: " << " " << std::setw(8) << std::setfill('0') << m_partRunNr 00454 << std::setfill(' ') 00455 << std::dec << " dec: " << m_partRunNr 00456 << std::endl; 00457 00458 myCout << " AssignedPartitions: " 00459 << std::hex << " hex: " << " " << std::setw(8) << std::setfill('0') 00460 << m_assignedPartitions 00461 << std::setfill(' ') 00462 << std::dec << " dec: " << m_assignedPartitions 00463 << std::endl; 00464 00465 00466 iWord++; 00467 myCout << "\n Word " << iWord << std::endl; 00468 00469 myCout << " PartTrigNr: " 00470 << std::hex << " hex: " << " " << std::setw(8) << std::setfill('0') << m_partTrigNr 00471 << std::setfill(' ') 00472 << std::dec << " dec: " << m_partTrigNr 00473 << std::endl; 00474 00475 00476 myCout << " EventNr: " 00477 << std::hex << " hex: " << " " << std::setw(8) << std::setfill('0') << m_eventNr 00478 << std::setfill(' ') 00479 << std::dec << " dec: " << m_eventNr 00480 << std::endl; 00481 00482 iWord++; 00483 myCout << "\n Word " << iWord << std::endl; 00484 00485 myCout << " OrbitNr: " 00486 << std::hex << " hex: " << "" << std::setw(12) << std::setfill('0') << m_orbitNr 00487 << std::setfill(' ') 00488 << std::dec << " dec: " << m_orbitNr 00489 << std::endl; 00490 00491 iWord++; 00492 myCout << "\n Word " << iWord << std::endl; 00493 00494 myCout << " Empty word " 00495 << std::endl; 00496 00497 }
reset the content of a L1TcsWord
Definition at line 385 of file L1TcsWord.cc.
References m_assignedPartitions, m_boardId, m_bxNr, m_daqNr, m_eventNr, m_luminositySegmentNr, m_orbitNr, m_partRunNr, m_partTrigNr, m_status, and m_triggerType.
Referenced by L1GlobalTriggerEvmRawToDigi::produce().
00386 { 00387 00388 m_boardId = 0; 00389 m_bxNr = 0; 00390 m_daqNr = 0; 00391 m_triggerType = 0; 00392 m_status = 0; 00393 m_luminositySegmentNr = 0; 00394 m_partRunNr = 0; 00395 m_assignedPartitions = 0; 00396 m_partTrigNr = 0; 00397 m_eventNr = 0; 00398 m_orbitNr = 0; 00399 00400 00401 }
void L1TcsWord::setAssignedPartitions | ( | const boost::uint64_t & | word64 | ) |
set the AssignedPartitions value from a 64-bits word
Definition at line 297 of file L1TcsWord.cc.
References AssignedPartitionsMask, AssignedPartitionsShift, and m_assignedPartitions.
00298 { 00299 00300 m_assignedPartitions = (word64 & AssignedPartitionsMask) 00301 >> AssignedPartitionsShift; 00302 00303 }
void L1TcsWord::setAssignedPartitions | ( | const boost::uint32_t | assignedPartitionsValue | ) | [inline] |
Definition at line 213 of file L1TcsWord.h.
References m_assignedPartitions.
Referenced by unpack().
00214 { 00215 m_assignedPartitions = assignedPartitionsValue; 00216 }
set the AssignedPartitions value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 307 of file L1TcsWord.cc.
References AssignedPartitionsShift, AssignedPartitionsWord, and m_assignedPartitions.
Referenced by L1GTEvmDigiToRaw::packTCS().
00308 { 00309 00310 if (iWord == AssignedPartitionsWord) { 00311 word64 = word64 | 00312 (static_cast<boost::uint64_t> (m_assignedPartitions) 00313 << AssignedPartitionsShift); 00314 } 00315 00316 }
void L1TcsWord::setBoardId | ( | const boost::uint64_t & | word64 | ) |
set the BoardId value from a 64-bits word
Definition at line 150 of file L1TcsWord.cc.
References BoardIdMask, BoardIdShift, and m_boardId.
00151 { 00152 m_boardId = (word64 & BoardIdMask) >> BoardIdShift; 00153 00154 }
void L1TcsWord::setBoardId | ( | const boost::uint16_t | boardIdValue | ) | [inline] |
set BoardId from a BoardId value
Definition at line 74 of file L1TcsWord.h.
References m_boardId.
Referenced by L1GlobalTrigger::produce(), and unpack().
00075 { 00076 m_boardId = boardIdValue; 00077 }
set the BoardId value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 158 of file L1TcsWord.cc.
References BoardIdShift, BoardIdWord, and m_boardId.
Referenced by L1GTEvmDigiToRaw::packTCS().
00159 { 00160 00161 if (iWord == BoardIdWord) { 00162 word64 = word64 | (static_cast<boost::uint64_t> (m_boardId) << BoardIdShift); 00163 } 00164 00165 }
void L1TcsWord::setBxNr | ( | const boost::uint64_t & | word64 | ) |
void L1TcsWord::setBxNr | ( | const boost::uint16_t | bxNrValue | ) | [inline] |
Definition at line 94 of file L1TcsWord.h.
References m_bxNr.
Referenced by L1GlobalTrigger::produce(), and unpack().
00095 { 00096 m_bxNr = bxNrValue; 00097 }
set the BxNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 178 of file L1TcsWord.cc.
References BxNrShift, BxNrWord, and m_bxNr.
Referenced by L1GTEvmDigiToRaw::packTCS().
00179 { 00180 00181 if (iWord == BxNrWord) { 00182 word64 = word64 | (static_cast<boost::uint64_t> (m_bxNr) << BxNrShift); 00183 } 00184 00185 }
void L1TcsWord::setDaqNr | ( | const boost::uint64_t & | word64 | ) |
set the DaqNr value from a 64-bits word
Definition at line 190 of file L1TcsWord.cc.
References DaqNrMask, DaqNrShift, and m_daqNr.
00191 { 00192 00193 m_daqNr = (word64 & DaqNrMask) >> DaqNrShift; 00194 00195 }
void L1TcsWord::setDaqNr | ( | const boost::uint16_t | daqNrValue | ) | [inline] |
Definition at line 114 of file L1TcsWord.h.
References m_daqNr.
Referenced by unpack().
00115 { 00116 m_daqNr = daqNrValue; 00117 }
set the DaqNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 199 of file L1TcsWord.cc.
References DaqNrShift, DaqNrWord, and m_daqNr.
Referenced by L1GTEvmDigiToRaw::packTCS().
00200 { 00201 00202 if (iWord == DaqNrWord) { 00203 word64 = word64 | (static_cast<boost::uint64_t> (m_daqNr) << DaqNrShift); 00204 } 00205 00206 }
void L1TcsWord::setEventNr | ( | const boost::uint64_t & | word64 | ) |
set the EventNr value from a 64-bits word
Definition at line 343 of file L1TcsWord.cc.
References EventNrMask, EventNrShift, and m_eventNr.
00344 { 00345 00346 m_eventNr = (word64 & EventNrMask) >> EventNrShift; 00347 00348 }
void L1TcsWord::setEventNr | ( | const boost::uint32_t | eventNrValue | ) | [inline] |
Definition at line 253 of file L1TcsWord.h.
References m_eventNr.
Referenced by L1GlobalTrigger::produce(), and unpack().
00254 { 00255 m_eventNr = eventNrValue; 00256 }
set the EventNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 352 of file L1TcsWord.cc.
References EventNrShift, EventNrWord, and m_eventNr.
Referenced by L1GTEvmDigiToRaw::packTCS().
00353 { 00354 00355 if (iWord == EventNrWord) { 00356 word64 = word64 | 00357 (static_cast<boost::uint64_t> (m_eventNr) << EventNrShift); 00358 } 00359 00360 }
void L1TcsWord::setLuminositySegmentNr | ( | const boost::uint64_t & | word64 | ) |
set the luminosity segment number value from a 64-bits word
Definition at line 252 of file L1TcsWord.cc.
References LuminositySegmentNrMask, LuminositySegmentNrShift, and m_luminositySegmentNr.
00253 { 00254 00255 m_luminositySegmentNr = 00256 (word64 & LuminositySegmentNrMask) >> LuminositySegmentNrShift; 00257 00258 }
void L1TcsWord::setLuminositySegmentNr | ( | const boost::uint16_t | luminositySegmentNrValue | ) | [inline] |
Definition at line 173 of file L1TcsWord.h.
References m_luminositySegmentNr.
Referenced by L1GlobalTrigger::produce(), and unpack().
00174 { 00175 m_luminositySegmentNr = luminositySegmentNrValue; 00176 }
set the luminosity segment number value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 262 of file L1TcsWord.cc.
References LuminositySegmentNrShift, LuminositySegmentNrWord, and m_luminositySegmentNr.
Referenced by L1GTEvmDigiToRaw::packTCS().
00263 { 00264 00265 if (iWord == LuminositySegmentNrWord) { 00266 word64 = word64 | 00267 (static_cast<boost::uint64_t> (m_luminositySegmentNr) << LuminositySegmentNrShift); 00268 } 00269 00270 }
void L1TcsWord::setOrbitNr | ( | const boost::uint64_t | orbitNrValue | ) | [inline] |
Definition at line 273 of file L1TcsWord.h.
References m_orbitNr.
Referenced by L1GlobalTrigger::produce().
00274 { 00275 m_orbitNr = orbitNrValue; 00276 }
void L1TcsWord::setOrbitNrFrom | ( | const boost::uint64_t & | word64 | ) |
set the OrbitNr value from a 64-bits word
Definition at line 365 of file L1TcsWord.cc.
References m_orbitNr, OrbitNrMask, and OrbitNrShift.
Referenced by unpack().
00366 { 00367 00368 m_orbitNr = (word64 & OrbitNrMask) >> OrbitNrShift; 00369 00370 }
set the OrbitNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 374 of file L1TcsWord.cc.
References m_orbitNr, OrbitNrShift, and OrbitNrWord.
Referenced by L1GTEvmDigiToRaw::packTCS().
00375 { 00376 00377 if (iWord == OrbitNrWord) { 00378 word64 = word64 | (static_cast<boost::uint64_t> (m_orbitNr) << OrbitNrShift); 00379 } 00380 00381 }
void L1TcsWord::setPartRunNr | ( | const boost::uint64_t & | word64 | ) |
set the PartRunNr value from a 64-bits word
Definition at line 275 of file L1TcsWord.cc.
References m_partRunNr, PartRunNrMask, and PartRunNrShift.
00276 { 00277 00278 m_partRunNr = (word64 & PartRunNrMask) >> PartRunNrShift; 00279 00280 }
void L1TcsWord::setPartRunNr | ( | const boost::uint32_t | partRunNrValue | ) | [inline] |
Definition at line 193 of file L1TcsWord.h.
References m_partRunNr.
Referenced by unpack().
00194 { 00195 m_partRunNr = partRunNrValue; 00196 }
set the PartRunNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 284 of file L1TcsWord.cc.
References m_partRunNr, PartRunNrShift, and PartRunNrWord.
Referenced by L1GTEvmDigiToRaw::packTCS().
00285 { 00286 00287 if (iWord == PartRunNrWord) { 00288 word64 = word64 | 00289 (static_cast<boost::uint64_t> (m_partRunNr) << PartRunNrShift); 00290 } 00291 00292 }
void L1TcsWord::setPartTrigNr | ( | const boost::uint64_t & | word64 | ) |
set the PartTrigNr value from a 64-bits word
Definition at line 321 of file L1TcsWord.cc.
References m_partTrigNr, PartTrigNrMask, and PartTrigNrShift.
00322 { 00323 00324 m_partTrigNr = (word64 & PartTrigNrMask) >> PartTrigNrShift; 00325 00326 }
void L1TcsWord::setPartTrigNr | ( | const boost::uint32_t | partTrigNrValue | ) | [inline] |
Definition at line 233 of file L1TcsWord.h.
References m_partTrigNr.
Referenced by unpack().
00234 { 00235 m_partTrigNr = partTrigNrValue; 00236 }
set the PartTrigNr value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 330 of file L1TcsWord.cc.
References m_partTrigNr, PartTrigNrShift, and PartTrigNrWord.
Referenced by L1GTEvmDigiToRaw::packTCS().
00331 { 00332 00333 if (iWord == PartTrigNrWord) { 00334 word64 = word64 | 00335 (static_cast<boost::uint64_t> (m_partTrigNr) << PartTrigNrShift); 00336 } 00337 00338 }
void L1TcsWord::setStatus | ( | const boost::uint64_t & | word64 | ) |
set the Status value from a 64-bits word
Definition at line 231 of file L1TcsWord.cc.
References m_status, StatusMask, and StatusShift.
00232 { 00233 00234 m_status = (word64 & StatusMask) >> StatusShift; 00235 00236 }
void L1TcsWord::setStatus | ( | const boost::uint16_t | statusValue | ) | [inline] |
Definition at line 154 of file L1TcsWord.h.
References m_status.
Referenced by unpack().
00155 { 00156 m_status = statusValue; 00157 }
set the Status value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 240 of file L1TcsWord.cc.
References m_status, StatusShift, and StatusWord.
Referenced by L1GTEvmDigiToRaw::packTCS().
00241 { 00242 00243 if (iWord == StatusWord) { 00244 word64 = word64 | (static_cast<boost::uint64_t> (m_status) << StatusShift); 00245 } 00246 00247 }
void L1TcsWord::setTriggerType | ( | const boost::uint64_t & | word64 | ) |
set the TriggerType value from a 64-bits word
Definition at line 210 of file L1TcsWord.cc.
References m_triggerType, TriggerTypeMask, and TriggerTypeShift.
00211 { 00212 00213 m_triggerType = (word64 & TriggerTypeMask) >> TriggerTypeShift; 00214 00215 }
void L1TcsWord::setTriggerType | ( | const boost::uint16_t | triggerTypeValue | ) | [inline] |
Definition at line 134 of file L1TcsWord.h.
References m_triggerType.
Referenced by L1GlobalTrigger::produce(), and unpack().
00135 { 00136 m_triggerType = triggerTypeValue; 00137 }
set the TriggerType value in a 64-bits word, having the index iWord in the GTFE EVM raw record
Definition at line 219 of file L1TcsWord.cc.
References m_triggerType, TriggerTypeShift, and TriggerTypeWord.
Referenced by L1GTEvmDigiToRaw::packTCS().
00220 { 00221 00222 if (iWord == TriggerTypeWord) { 00223 word64 = word64 | 00224 (static_cast<boost::uint64_t> (m_triggerType) << TriggerTypeShift); 00225 } 00226 00227 }
const boost::uint16_t L1TcsWord::status | ( | ) | const [inline] |
get/set status: 0000 = normal rate; 1000 = low rate = warning
Definition at line 149 of file L1TcsWord.h.
References m_status.
00150 { 00151 return m_status; 00152 }
const boost::uint16_t L1TcsWord::triggerType | ( | ) | const [inline] |
get/set trigger type, identical with event type in CMS header
Definition at line 129 of file L1TcsWord.h.
References m_triggerType.
Referenced by L1TGT::analyze().
00130 { 00131 return m_triggerType; 00132 }
void L1TcsWord::unpack | ( | const unsigned char * | tcsPtr | ) |
unpack TCS tcsPtr pointer to the beginning of the TCS block in the raw data
Definition at line 502 of file L1TcsWord.cc.
References AssignedPartitionsWord, BlockSize, BoardIdWord, BxNrWord, DaqNrWord, lat::endl(), EventNrWord, edm::isDebugEnabled(), LogDebug, LogTrace, LuminositySegmentNrWord, OrbitNrWord, PartRunNrWord, PartTrigNrWord, setAssignedPartitions(), setBoardId(), setBxNr(), setDaqNr(), setEventNr(), setLuminositySegmentNr(), setOrbitNrFrom(), setPartRunNr(), setPartTrigNr(), setStatus(), setTriggerType(), StatusWord, and TriggerTypeWord.
Referenced by L1GlobalTriggerEvmRawToDigi::produce().
00503 { 00504 LogDebug("L1GtTcsWord") 00505 << "\nUnpacking TCS block.\n" 00506 << std::endl; 00507 00508 const boost::uint64_t* payload = 00509 reinterpret_cast<boost::uint64_t*>(const_cast<unsigned char*>(tcsPtr)); 00510 00511 setBoardId(payload[BoardIdWord]); 00512 setBxNr(payload[BxNrWord]); 00513 setDaqNr(payload[DaqNrWord]); 00514 setTriggerType(payload[TriggerTypeWord]); 00515 setStatus(payload[StatusWord]); 00516 setLuminositySegmentNr(payload[LuminositySegmentNrWord]); 00517 00518 setPartRunNr(payload[PartRunNrWord]); 00519 setAssignedPartitions(payload[AssignedPartitionsWord]); 00520 00521 setPartTrigNr(payload[PartTrigNrWord]); 00522 setEventNr(payload[EventNrWord]); 00523 00524 setOrbitNrFrom(payload[OrbitNrWord]); 00525 00526 if ( edm::isDebugEnabled() ) { 00527 00528 for (int iWord = 0; iWord < BlockSize; ++iWord) { 00529 LogTrace("L1GtTcsWord") 00530 << std::setw(4) << iWord << " " 00531 << std::hex << std::setfill('0') 00532 << std::setw(16) << payload[iWord] 00533 << std::dec << std::setfill(' ') 00534 << std::endl; 00535 } 00536 00537 } 00538 00539 }
const boost::uint64_t L1TcsWord::AssignedPartitionsMask = 0x00000000FFFFFFFFULL [static, private] |
const int L1TcsWord::AssignedPartitionsShift = 0 [static, private] |
Definition at line 350 of file L1TcsWord.h.
Referenced by setAssignedPartitions(), and setAssignedPartitionsWord64().
const int L1TcsWord::AssignedPartitionsWord = 1 [static, private] |
Definition at line 344 of file L1TcsWord.h.
Referenced by setAssignedPartitionsWord64(), and unpack().
const int L1TcsWord::BlockSize = 5 [static, private] |
const boost::uint64_t L1TcsWord::BoardIdMask = 0xFFFF000000000000ULL [static, private] |
const int L1TcsWord::BoardIdShift = 48 [static, private] |
const int L1TcsWord::BoardIdWord = 0 [static, private] |
const boost::uint64_t L1TcsWord::BxNrMask = 0x00000FFF00000000ULL [static, private] |
const int L1TcsWord::BxNrShift = 32 [static, private] |
const int L1TcsWord::BxNrWord = 0 [static, private] |
const boost::uint64_t L1TcsWord::DaqNrMask = 0x000000000F000000ULL [static, private] |
const int L1TcsWord::DaqNrShift = 24 [static, private] |
const int L1TcsWord::DaqNrWord = 0 [static, private] |
const boost::uint64_t L1TcsWord::EventNrMask = 0x00000000FFFFFFFFULL [static, private] |
const int L1TcsWord::EventNrShift = 0 [static, private] |
const int L1TcsWord::EventNrWord = 2 [static, private] |
const boost::uint64_t L1TcsWord::LuminositySegmentNrMask = 0x000000000000FFFFULL [static, private] |
const int L1TcsWord::LuminositySegmentNrShift = 0 [static, private] |
Definition at line 339 of file L1TcsWord.h.
Referenced by setLuminositySegmentNr(), and setLuminositySegmentNrWord64().
const int L1TcsWord::LuminositySegmentNrWord = 0 [static, private] |
Definition at line 323 of file L1TcsWord.h.
Referenced by setLuminositySegmentNrWord64(), and unpack().
boost::uint32_t L1TcsWord::m_assignedPartitions [private] |
bit "i" correspond to detector partition "i" if bit = 1, detection partition connected to actual DAQ partition
Definition at line 406 of file L1TcsWord.h.
Referenced by assignedPartitions(), L1TcsWord(), operator==(), print(), reset(), setAssignedPartitions(), and setAssignedPartitionsWord64().
boost::uint16_t L1TcsWord::m_boardId [private] |
board identifier
Definition at line 381 of file L1TcsWord.h.
Referenced by boardId(), L1TcsWord(), operator==(), print(), reset(), setBoardId(), and setBoardIdWord64().
boost::uint16_t L1TcsWord::m_bxNr [private] |
bunch cross number as counted in the TCS chip
Definition at line 384 of file L1TcsWord.h.
Referenced by bxNr(), L1TcsWord(), operator==(), print(), reset(), setBxNr(), and setBxNrWord64().
boost::uint16_t L1TcsWord::m_daqNr [private] |
number of DAQ partition to which the L1A has been sent
Definition at line 387 of file L1TcsWord.h.
Referenced by daqNr(), L1TcsWord(), operator==(), print(), reset(), setDaqNr(), and setDaqNrWord64().
boost::uint32_t L1TcsWord::m_eventNr [private] |
event number since last L1 reset generated in TCS chip
Definition at line 415 of file L1TcsWord.h.
Referenced by eventNr(), L1TcsWord(), operator==(), print(), reset(), setEventNr(), and setEventNrWord64().
boost::uint16_t L1TcsWord::m_luminositySegmentNr [private] |
luminosity segment number
Definition at line 396 of file L1TcsWord.h.
Referenced by L1TcsWord(), luminositySegmentNr(), operator==(), print(), reset(), setLuminositySegmentNr(), and setLuminositySegmentNrWord64().
boost::uint64_t L1TcsWord::m_orbitNr [private] |
orbit number since start of run (48 bits, in fact)
Definition at line 420 of file L1TcsWord.h.
Referenced by L1TcsWord(), operator==(), orbitNr(), print(), reset(), setOrbitNr(), setOrbitNrFrom(), and setOrbitNrWord64().
boost::uint32_t L1TcsWord::m_partRunNr [private] |
partition run number
Definition at line 401 of file L1TcsWord.h.
Referenced by L1TcsWord(), operator==(), partRunNr(), print(), reset(), setPartRunNr(), and setPartRunNrWord64().
boost::uint32_t L1TcsWord::m_partTrigNr [private] |
total number of L1A sent since start of the run to this DAQ partition
Definition at line 412 of file L1TcsWord.h.
Referenced by L1TcsWord(), operator==(), partTrigNr(), print(), reset(), setPartTrigNr(), and setPartTrigNrWord64().
boost::uint16_t L1TcsWord::m_status [private] |
0000 = normal rate; 1000 = low rate = warning
Definition at line 393 of file L1TcsWord.h.
Referenced by L1TcsWord(), operator==(), print(), reset(), setStatus(), setStatusWord64(), and status().
boost::uint16_t L1TcsWord::m_triggerType [private] |
trigger type, identical with event type in CMS header (event type)
Definition at line 390 of file L1TcsWord.h.
Referenced by L1TcsWord(), operator==(), print(), reset(), setTriggerType(), setTriggerTypeWord64(), and triggerType().
const boost::uint64_t L1TcsWord::OrbitNrMask = 0x0000FFFFFFFFFFFFULL [static, private] |
const int L1TcsWord::OrbitNrShift = 0 [static, private] |
const int L1TcsWord::OrbitNrWord = 3 [static, private] |
const boost::uint64_t L1TcsWord::PartRunNrMask = 0xFFFFFFFF00000000ULL [static, private] |
const int L1TcsWord::PartRunNrShift = 32 [static, private] |
const int L1TcsWord::PartRunNrWord = 1 [static, private] |
const boost::uint64_t L1TcsWord::PartTrigNrMask = 0xFFFFFFFF00000000ULL [static, private] |
const int L1TcsWord::PartTrigNrShift = 32 [static, private] |
Definition at line 360 of file L1TcsWord.h.
Referenced by setPartTrigNr(), and setPartTrigNrWord64().
const int L1TcsWord::PartTrigNrWord = 2 [static, private] |
const boost::uint64_t L1TcsWord::StatusMask = 0x00000000000F0000ULL [static, private] |
const int L1TcsWord::StatusShift = 16 [static, private] |
const int L1TcsWord::StatusWord = 0 [static, private] |
const boost::uint64_t L1TcsWord::TriggerTypeMask = 0x0000000000F00000ULL [static, private] |
const int L1TcsWord::TriggerTypeShift = 20 [static, private] |
Definition at line 337 of file L1TcsWord.h.
Referenced by setTriggerType(), and setTriggerTypeWord64().
const int L1TcsWord::TriggerTypeWord = 0 [static, private] |