#include <DataFormats/L1GlobalTrigger/interface/L1GtfeWord.h>
Public Member Functions | |
const boost::uint16_t | activeBoards () const |
get/set boards contributing to EVM respectively DAQ record | |
const boost::uint16_t | altNrBxBoard () const |
get/set alternative for number of BX per board | |
const boost::uint16_t | boardId () const |
get/set board ID | |
const int | bstFlag () const |
get / set BST flag: 0 or 1 - via setup version (no private member) | |
const boost::uint16_t | bxNr () const |
get/set bunch cross number as counted in the GTFE board | |
const unsigned int | getSize () const |
get the size of the GTFE block in GT DAQ record (in multiple of 8 bits) | |
L1GtfeWord (boost::uint16_t boardIdValue, boost::uint16_t recordLength1Value, boost::uint16_t recordLengthValue, boost::uint16_t bxNrValue, boost::uint32_t setupVersionValue, boost::uint16_t activeBoardsValue, boost::uint16_t altNrBxBoardValue, boost::uint32_t totalTriggerNrValue) | |
constructor from unpacked values; | |
L1GtfeWord () | |
constructors | |
bool | operator!= (const L1GtfeWord &) const |
unequal operator | |
bool | operator== (const L1GtfeWord &) const |
equal operator | |
virtual void | print (std::ostream &myCout) const |
pretty print the content of a L1GtfeWord | |
const boost::uint16_t | recordLength () const |
get/set record length for alternative 0 | |
const boost::uint16_t | recordLength1 () const |
get/set record length for alternative 1 | |
virtual void | reset () |
reset the content of a L1GtfeWord | |
void | setActiveBoards (const boost::uint64_t &word64) |
void | setActiveBoards (boost::uint16_t activeBoardsValue) |
void | setActiveBoardsWord64 (boost::uint64_t &word64, int iWord, boost::int16_t activeBoardsValue) |
set the ActiveBoards value in a 64-bits word, having the index iWord in the GTFE raw record from the value activeBoardsValue | |
void | setActiveBoardsWord64 (boost::uint64_t &word64, int iWord) |
set the ActiveBoards value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setAltNrBxBoard (const boost::uint64_t &word64) |
void | setAltNrBxBoard (boost::uint16_t altNrBxBoardValue) |
void | setAltNrBxBoardWord64 (boost::uint64_t &word64, int iWord, boost::int16_t altNrBxBoardValue) |
set the AltNrBxBoard value in a 64-bits word, having the index iWord in the GTFE raw record from the value altNrBxBoardValue | |
void | setAltNrBxBoardWord64 (boost::uint64_t &word64, int iWord) |
set the AltNrBxBoard value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setBoardId (const boost::uint64_t &word64) |
set the BoardId value from a 64-bits word | |
void | setBoardId (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 | setBstFlag (const int) |
void | setBxNr (const boost::uint64_t &word64) |
void | setBxNr (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 raw record | |
void | setRecordLength (const boost::uint64_t &word64) |
void | setRecordLength (boost::uint16_t recordLengthValue) |
void | setRecordLength1 (const boost::uint64_t &word64) |
void | setRecordLength1 (boost::uint16_t recordLengthValue) |
void | setRecordLength1Word64 (boost::uint64_t &word64, int iWord) |
set the RecordLength value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setRecordLengthWord64 (boost::uint64_t &word64, int iWord) |
set the RecordLength value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setSetupVersion (const boost::uint64_t &word64) |
void | setSetupVersion (boost::uint32_t setupVersionValue) |
void | setSetupVersionWord64 (boost::uint64_t &word64, int iWord) |
set the SetupVersion value in a 64-bits word, having the index iWord in the GTFE raw record | |
void | setTotalTriggerNr (const boost::uint64_t &word64) |
void | setTotalTriggerNr (boost::uint32_t totalTriggerNrValue) |
void | setTotalTriggerNrWord64 (boost::uint64_t &word64, int iWord) |
set the TotalTriggerNr value in a 64-bits word, having the index iWord in the GTFE raw record | |
const boost::uint32_t | setupVersion () const |
get/set setup version | |
const boost::uint32_t | totalTriggerNr () const |
get/set total number of L1A sent since start of run | |
virtual void | unpack (const unsigned char *gtfePtr) |
unpack GTFE gtfePtr pointer to the beginning of the GTFE block in the raw data | |
virtual | ~L1GtfeWord () |
destructor | |
Private Attributes | |
boost::uint16_t | m_activeBoards |
active boards contributing to EVM respectively DAQ record | |
boost::uint16_t | m_altNrBxBoard |
alternative for number of BX per board correlated with active boards bit value is 0: take alternative 0 bit value is 1: take alternative 1 | |
boost::uint16_t | m_boardId |
board identifier | |
boost::uint16_t | m_bxNr |
bunch cross number as counted in the GTFE board | |
boost::uint16_t | m_recordLength |
record length for alternative 0 | |
boost::uint16_t | m_recordLength1 |
record length for alternative 1 | |
boost::uint32_t | m_setupVersion |
boost::uint32_t | m_totalTriggerNr |
total number of L1A sent since start of run | |
Static Private Attributes | |
static const boost::uint64_t | ActiveBoardsMask = 0xFFFF000000000000ULL |
static const int | ActiveBoardsShift = 48 |
static const int | ActiveBoardsWord = 1 |
static const boost::uint64_t | AltNrBxBoardMask = 0x0000FFFF00000000ULL |
static const int | AltNrBxBoardShift = 32 |
static const int | AltNrBxBoardWord = 1 |
static const int | BlockSize = 2 |
static const boost::uint64_t | BoardIdMask = 0xFF00000000000000ULL |
static const int | BoardIdShift = 56 |
static const int | BoardIdWord = 0 |
static const boost::uint32_t | BstFlagMask = 0x0001 |
static const boost::uint64_t | BxNrMask = 0x00000FFF00000000ULL |
static const int | BxNrShift = 32 |
static const int | BxNrWord = 0 |
static const boost::uint64_t | RecordLength1Mask = 0x00F0000000000000ULL |
static const int | RecordLength1Shift = 52 |
static const int | RecordLength1Word = 0 |
static const boost::uint64_t | RecordLengthMask = 0x000F000000000000ULL |
static const int | RecordLengthShift = 48 |
static const int | RecordLengthWord = 0 |
static const boost::uint64_t | SetupVersionMask = 0x00000000FFFFFFFFULL |
static const int | SetupVersionShift = 0 |
static const int | SetupVersionWord = 0 |
static const boost::uint64_t | TotalTriggerNrMask = 0x00000000FFFFFFFFULL |
static const int | TotalTriggerNrShift = 0 |
static const int | TotalTriggerNrWord = 1 |
Implementation: <TODO: enter implementation details>
$Date$ $Revision$
Definition at line 32 of file L1GtfeWord.h.
L1GtfeWord::L1GtfeWord | ( | ) |
constructors
Definition at line 31 of file L1GtfeWord.cc.
00031 : 00032 m_boardId(0), m_recordLength1(0), m_recordLength(0), m_bxNr(0), m_setupVersion(0), 00033 m_activeBoards(0), m_altNrBxBoard(0), m_totalTriggerNr(0) { 00034 00035 // empty 00036 00037 }
L1GtfeWord::L1GtfeWord | ( | boost::uint16_t | boardIdValue, | |
boost::uint16_t | recordLength1Value, | |||
boost::uint16_t | recordLengthValue, | |||
boost::uint16_t | bxNrValue, | |||
boost::uint32_t | setupVersionValue, | |||
boost::uint16_t | activeBoardsValue, | |||
boost::uint16_t | altNrBxBoardValue, | |||
boost::uint32_t | totalTriggerNrValue | |||
) |
constructor from unpacked values;
Definition at line 40 of file L1GtfeWord.cc.
00044 : 00045 m_boardId(boardIdValue), m_recordLength1(recordLength1Value), 00046 m_recordLength(recordLengthValue), m_bxNr(bxNrValue), 00047 m_setupVersion(setupVersionValue), m_activeBoards(activeBoardsValue), m_altNrBxBoard( 00048 altNrBxBoardValue), m_totalTriggerNr(totalTriggerNrValue) 00049 00050 { 00051 00052 // empty 00053 }
L1GtfeWord::~L1GtfeWord | ( | ) | [virtual] |
const boost::uint16_t L1GtfeWord::activeBoards | ( | ) | const [inline] |
get/set boards contributing to EVM respectively DAQ record
Definition at line 165 of file L1GtfeWord.h.
References m_activeBoards.
Referenced by L1TGT::analyze(), EBRawDataTask::analyze(), EERawDataTask::analyze(), L1GtDataEmulAnalyzer::compareGTFE(), L1GTEvmDigiToRaw::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GTDigiToRaw::produce(), and L1GlobalTriggerRawToDigi::produce().
00166 { 00167 return m_activeBoards; 00168 }
const boost::uint16_t L1GtfeWord::altNrBxBoard | ( | ) | const [inline] |
get/set alternative for number of BX per board
Definition at line 189 of file L1GtfeWord.h.
References m_altNrBxBoard.
Referenced by L1GTEvmDigiToRaw::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GTDigiToRaw::produce(), and L1GlobalTriggerRawToDigi::produce().
00190 { 00191 return m_altNrBxBoard; 00192 }
const boost::uint16_t L1GtfeWord::boardId | ( | ) | const [inline] |
get/set board ID
get BoardId value
Definition at line 67 of file L1GtfeWord.h.
References m_boardId.
Referenced by L1GtDataEmulAnalyzer::compareGTFE().
00068 { 00069 return m_boardId; 00070 }
const int L1GtfeWord::bstFlag | ( | ) | const |
get / set BST flag: 0 or 1 - via setup version (no private member)
Definition at line 208 of file L1GtfeWord.cc.
References BstFlagMask, and m_setupVersion.
00208 { 00209 00210 int bstFlagValue = 0; 00211 bstFlagValue = static_cast<int> (m_setupVersion & BstFlagMask); 00212 00213 return bstFlagValue; 00214 00215 }
const boost::uint16_t L1GtfeWord::bxNr | ( | ) | const [inline] |
get/set bunch cross number as counted in the GTFE board
Definition at line 124 of file L1GtfeWord.h.
References m_bxNr.
Referenced by L1TGT::analyze(), L1Scalers::analyze(), and L1GtDataEmulAnalyzer::compareGTFE().
00125 { 00126 return m_bxNr; 00127 }
const unsigned int L1GtfeWord::getSize | ( | ) | const [inline] |
get the size of the GTFE block in GT DAQ record (in multiple of 8 bits)
Reimplemented in L1GtfeExtWord.
Definition at line 231 of file L1GtfeWord.h.
References BlockSize, and L1GlobalTriggerReadoutSetup::UnitLength.
Referenced by L1GtfeExtWord::getSize(), L1GTDigiToRaw::packGTFE(), L1GTDigiToRaw::produce(), L1GlobalTriggerRawToDigi::produce(), and L1GtfeExtWord::unpack().
00232 { 00233 int unitLengthBits = L1GlobalTriggerReadoutSetup::UnitLength; 00234 00235 return BlockSize*unitLengthBits; 00236 }
bool L1GtfeWord::operator!= | ( | const L1GtfeWord & | result | ) | const |
bool L1GtfeWord::operator== | ( | const L1GtfeWord & | result | ) | const |
equal operator
Definition at line 64 of file L1GtfeWord.cc.
References m_activeBoards, m_altNrBxBoard, m_boardId, m_bxNr, m_recordLength, m_recordLength1, m_setupVersion, and m_totalTriggerNr.
00065 { 00066 00067 if(m_boardId != result.m_boardId) { 00068 return false; 00069 } 00070 00071 if(m_recordLength1 != result.m_recordLength1) { 00072 return false; 00073 } 00074 00075 if(m_recordLength != result.m_recordLength) { 00076 return false; 00077 } 00078 00079 if(m_bxNr != result.m_bxNr) { 00080 return false; 00081 } 00082 00083 if(m_setupVersion != result.m_setupVersion) { 00084 return false; 00085 } 00086 00087 if(m_activeBoards != result.m_activeBoards) { 00088 return false; 00089 } 00090 00091 if(m_altNrBxBoard != result.m_altNrBxBoard) { 00092 return false; 00093 } 00094 00095 if(m_totalTriggerNr != result.m_totalTriggerNr) { 00096 return false; 00097 } 00098 00099 // all members identical 00100 return true; 00101 00102 }
void L1GtfeWord::print | ( | std::ostream & | myCout | ) | const [virtual] |
pretty print the content of a L1GtfeWord
Reimplemented in L1GtfeExtWord.
Definition at line 323 of file L1GtfeWord.cc.
References lat::endl(), m_activeBoards, m_altNrBxBoard, m_boardId, m_bxNr, m_recordLength, m_recordLength1, m_setupVersion, and m_totalTriggerNr.
Referenced by L1GtPackUnpackAnalyzer::analyzeGT(), L1GtDataEmulAnalyzer::compareGTFE(), L1GlobalTriggerReadoutRecord::print(), L1GtfeExtWord::print(), L1GTDigiToRaw::produce(), and L1GlobalTriggerRawToDigi::produce().
00324 { 00325 00326 myCout << "\n L1GtfeWord::print \n" << std::endl; 00327 00328 myCout << " BoardId: " 00329 << std::hex << " hex: " << " " << std::setw(2) << std::setfill('0') << m_boardId 00330 << std::setfill(' ') 00331 << std::dec << " dec: " << m_boardId 00332 << std::endl; 00333 00334 myCout << " BX for alternative 1: " 00335 << std::hex << " hex: " << " " << std::setw(1) << m_recordLength1 00336 << std::dec << " dec: " << m_recordLength1 00337 << std::endl; 00338 00339 myCout << " BX for alternative 0: " 00340 << std::hex << " hex: " << " " << std::setw(1) << m_recordLength 00341 << std::dec << " dec: " << m_recordLength 00342 << std::endl; 00343 00344 myCout << " BxNr: " 00345 << std::hex << " hex: " << " " << std::setw(3) << std::setfill('0') << m_bxNr 00346 << std::setfill(' ') 00347 << std::dec << " dec: " << m_bxNr 00348 << std::endl; 00349 00350 myCout << " SetupVersion: " 00351 << std::hex << " hex: " << std::setw(8) << std::setfill('0') << m_setupVersion 00352 << std::setfill(' ') 00353 << std::dec << " dec: " << m_setupVersion 00354 << std::endl; 00355 00356 // 00357 00358 myCout << " ActiveBoards: " 00359 << std::hex << " hex: " << " " << std::setw(4) << std::setfill('0') << m_activeBoards 00360 << std::setfill(' ') 00361 << std::dec << " dec: " << m_activeBoards 00362 << std::endl; 00363 00364 myCout << " AltNrBxBoard: " 00365 << std::hex << " hex: " << " " << std::setw(4) << std::setfill('0') << m_altNrBxBoard 00366 << std::setfill(' ') 00367 << std::dec << " dec: " << m_altNrBxBoard 00368 << std::endl; 00369 00370 myCout << " TotalTriggerNr: " 00371 << std::hex << " hex: " << std::setw(8) << std::setfill('0') << m_totalTriggerNr 00372 << std::setfill(' ') 00373 << std::dec << " dec: " << m_totalTriggerNr 00374 << std::endl; 00375 00376 00377 }
const boost::uint16_t L1GtfeWord::recordLength | ( | ) | const [inline] |
get/set record length for alternative 0
Definition at line 106 of file L1GtfeWord.h.
References m_recordLength.
Referenced by L1GtDataEmulAnalyzer::compareGTFE(), L1GTEvmDigiToRaw::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GTDigiToRaw::produce(), and L1GlobalTriggerRawToDigi::produce().
00107 { 00108 return m_recordLength; 00109 }
const boost::uint16_t L1GtfeWord::recordLength1 | ( | ) | const [inline] |
get/set record length for alternative 1
Definition at line 87 of file L1GtfeWord.h.
References m_recordLength1.
Referenced by L1GTEvmDigiToRaw::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GTDigiToRaw::produce(), and L1GlobalTriggerRawToDigi::produce().
00088 { 00089 return m_recordLength1; 00090 }
reset the content of a L1GtfeWord
Reimplemented in L1GtfeExtWord.
Definition at line 308 of file L1GtfeWord.cc.
References m_activeBoards, m_altNrBxBoard, m_boardId, m_bxNr, m_recordLength, m_recordLength1, m_setupVersion, and m_totalTriggerNr.
Referenced by L1GlobalTriggerRawToDigi::produce(), L1GlobalTriggerReadoutRecord::reset(), and L1GtfeExtWord::reset().
00309 { 00310 00311 m_boardId = 0; 00312 m_recordLength1 = 0; 00313 m_recordLength = 0; 00314 m_bxNr = 0; 00315 m_setupVersion = 0; 00316 // 00317 m_activeBoards = 0; 00318 m_altNrBxBoard = 0; 00319 m_totalTriggerNr = 0; 00320 }
void L1GtfeWord::setActiveBoards | ( | const boost::uint64_t & | word64 | ) |
Definition at line 226 of file L1GtfeWord.cc.
References ActiveBoardsMask, ActiveBoardsShift, and m_activeBoards.
00227 { 00228 m_activeBoards = (word64 & ActiveBoardsMask) >> ActiveBoardsShift; 00229 }
void L1GtfeWord::setActiveBoards | ( | boost::uint16_t | activeBoardsValue | ) | [inline] |
Definition at line 170 of file L1GtfeWord.h.
References m_activeBoards.
Referenced by L1GlobalTrigger::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GlobalTriggerRawToDigi::produce(), and unpack().
00171 { 00172 m_activeBoards = activeBoardsValue; 00173 }
void L1GtfeWord::setActiveBoardsWord64 | ( | boost::uint64_t & | word64, | |
int | iWord, | |||
boost::int16_t | activeBoardsValue | |||
) |
set the ActiveBoards value in a 64-bits word, having the index iWord in the GTFE raw record from the value activeBoardsValue
Definition at line 245 of file L1GtfeWord.cc.
References ActiveBoardsShift, and ActiveBoardsWord.
00247 { 00248 if (iWord == ActiveBoardsWord) { 00249 word64 = word64 | 00250 (static_cast<boost::uint64_t> (activeBoardsValue) << ActiveBoardsShift); 00251 } 00252 00253 }
set the ActiveBoards value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 233 of file L1GtfeWord.cc.
References ActiveBoardsShift, ActiveBoardsWord, and m_activeBoards.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00234 { 00235 00236 if (iWord == ActiveBoardsWord) { 00237 word64 = word64 | 00238 (static_cast<boost::uint64_t> (m_activeBoards) << ActiveBoardsShift); 00239 } 00240 00241 }
void L1GtfeWord::setAltNrBxBoard | ( | const boost::uint64_t & | word64 | ) |
Definition at line 258 of file L1GtfeWord.cc.
References AltNrBxBoardMask, AltNrBxBoardShift, and m_altNrBxBoard.
00259 { 00260 m_altNrBxBoard = (word64 & AltNrBxBoardMask) >> AltNrBxBoardShift; 00261 }
void L1GtfeWord::setAltNrBxBoard | ( | boost::uint16_t | altNrBxBoardValue | ) | [inline] |
Definition at line 194 of file L1GtfeWord.h.
References m_altNrBxBoard.
Referenced by unpack().
00195 { 00196 m_altNrBxBoard = altNrBxBoardValue; 00197 }
void L1GtfeWord::setAltNrBxBoardWord64 | ( | boost::uint64_t & | word64, | |
int | iWord, | |||
boost::int16_t | altNrBxBoardValue | |||
) |
set the AltNrBxBoard value in a 64-bits word, having the index iWord in the GTFE raw record from the value altNrBxBoardValue
Definition at line 277 of file L1GtfeWord.cc.
References AltNrBxBoardShift, and AltNrBxBoardWord.
00279 { 00280 if (iWord == AltNrBxBoardWord) { 00281 word64 = word64 | 00282 (static_cast<boost::uint64_t> (altNrBxBoardValue) << AltNrBxBoardShift); 00283 } 00284 00285 }
set the AltNrBxBoard value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 265 of file L1GtfeWord.cc.
References AltNrBxBoardShift, AltNrBxBoardWord, and m_altNrBxBoard.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00266 { 00267 00268 if (iWord == AltNrBxBoardWord) { 00269 word64 = word64 | 00270 (static_cast<boost::uint64_t> (m_altNrBxBoard) << AltNrBxBoardShift); 00271 } 00272 00273 }
void L1GtfeWord::setBoardId | ( | const boost::uint64_t & | word64 | ) |
set the BoardId value from a 64-bits word
Definition at line 115 of file L1GtfeWord.cc.
References BoardIdMask, BoardIdShift, and m_boardId.
00116 { 00117 m_boardId = (word64 & BoardIdMask) >> BoardIdShift; 00118 }
void L1GtfeWord::setBoardId | ( | boost::uint16_t | boardIdValue | ) | [inline] |
set BoardId from a BoardId value
Definition at line 73 of file L1GtfeWord.h.
References m_boardId.
Referenced by L1GlobalTrigger::produce(), and unpack().
00074 { 00075 m_boardId = boardIdValue; 00076 }
set the BoardId value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 122 of file L1GtfeWord.cc.
References BoardIdShift, BoardIdWord, and m_boardId.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00123 { 00124 00125 if (iWord == BoardIdWord) { 00126 word64 = word64 | (static_cast<boost::uint64_t> (m_boardId) << BoardIdShift); 00127 } 00128 00129 }
void L1GtfeWord::setBstFlag | ( | const | int | ) |
Definition at line 217 of file L1GtfeWord.cc.
References BstFlagMask, and m_setupVersion.
00217 { 00218 00219 m_setupVersion = m_setupVersion | ( static_cast<boost::uint32_t> (bstFlagValue) & BstFlagMask ); 00220 00221 }
void L1GtfeWord::setBxNr | ( | const boost::uint64_t & | word64 | ) |
void L1GtfeWord::setBxNr | ( | boost::uint16_t | bxNrValue | ) | [inline] |
Definition at line 129 of file L1GtfeWord.h.
References m_bxNr.
Referenced by L1GlobalTrigger::produce(), and unpack().
00130 { 00131 m_bxNr = bxNrValue; 00132 }
set the BxNr value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 178 of file L1GtfeWord.cc.
References BxNrShift, BxNrWord, and m_bxNr.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00179 { 00180 00181 if (iWord == BxNrWord) { 00182 word64 = word64 | (static_cast<boost::uint64_t> (m_bxNr) << BxNrShift); 00183 } 00184 00185 }
void L1GtfeWord::setRecordLength | ( | const boost::uint64_t & | word64 | ) |
Definition at line 152 of file L1GtfeWord.cc.
References m_recordLength, RecordLengthMask, and RecordLengthShift.
00153 { 00154 m_recordLength = (word64 & RecordLengthMask) >> RecordLengthShift; 00155 }
void L1GtfeWord::setRecordLength | ( | boost::uint16_t | recordLengthValue | ) | [inline] |
Definition at line 111 of file L1GtfeWord.h.
References m_recordLength.
Referenced by L1GlobalTrigger::produce(), L1GlobalTriggerEvmRawToDigi::produce(), L1GlobalTriggerRawToDigi::produce(), and unpack().
00112 { 00113 m_recordLength = recordLengthValue; 00114 }
void L1GtfeWord::setRecordLength1 | ( | const boost::uint64_t & | word64 | ) |
Definition at line 133 of file L1GtfeWord.cc.
References m_recordLength1, RecordLength1Mask, and RecordLength1Shift.
00134 { 00135 m_recordLength1 = (word64 & RecordLength1Mask) >> RecordLength1Shift; 00136 }
void L1GtfeWord::setRecordLength1 | ( | boost::uint16_t | recordLengthValue | ) | [inline] |
Definition at line 92 of file L1GtfeWord.h.
References m_recordLength1.
Referenced by L1GlobalTriggerEvmRawToDigi::produce(), L1GlobalTriggerRawToDigi::produce(), and unpack().
00093 { 00094 m_recordLength1 = recordLengthValue; 00095 }
set the RecordLength value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 140 of file L1GtfeWord.cc.
References m_recordLength1, RecordLength1Shift, and RecordLength1Word.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00141 { 00142 00143 if (iWord == RecordLength1Word) { 00144 word64 = word64 | 00145 (static_cast<boost::uint64_t> (m_recordLength1) << RecordLength1Shift); 00146 } 00147 00148 }
set the RecordLength value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 159 of file L1GtfeWord.cc.
References m_recordLength, RecordLengthShift, and RecordLengthWord.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00160 { 00161 00162 if (iWord == RecordLengthWord) { 00163 word64 = word64 | 00164 (static_cast<boost::uint64_t> (m_recordLength) << RecordLengthShift); 00165 } 00166 00167 }
void L1GtfeWord::setSetupVersion | ( | const boost::uint64_t & | word64 | ) |
Definition at line 189 of file L1GtfeWord.cc.
References m_setupVersion, SetupVersionMask, and SetupVersionShift.
00190 { 00191 m_setupVersion = (word64 & SetupVersionMask) >> SetupVersionShift; 00192 }
void L1GtfeWord::setSetupVersion | ( | boost::uint32_t | setupVersionValue | ) | [inline] |
Definition at line 147 of file L1GtfeWord.h.
References m_setupVersion.
Referenced by unpack().
00148 { 00149 m_setupVersion = setupVersionValue; 00150 }
set the SetupVersion value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 196 of file L1GtfeWord.cc.
References m_setupVersion, SetupVersionShift, and SetupVersionWord.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00197 { 00198 00199 if (iWord == SetupVersionWord) { 00200 word64 = word64 | 00201 (static_cast<boost::uint64_t> (m_setupVersion) << SetupVersionShift); 00202 } 00203 00204 }
void L1GtfeWord::setTotalTriggerNr | ( | const boost::uint64_t & | word64 | ) |
Definition at line 288 of file L1GtfeWord.cc.
References m_totalTriggerNr, TotalTriggerNrMask, and TotalTriggerNrShift.
00289 { 00290 m_totalTriggerNr = (word64 & TotalTriggerNrMask) >> TotalTriggerNrShift; 00291 }
void L1GtfeWord::setTotalTriggerNr | ( | boost::uint32_t | totalTriggerNrValue | ) | [inline] |
Definition at line 218 of file L1GtfeWord.h.
References m_totalTriggerNr.
Referenced by L1GlobalTrigger::produce(), and unpack().
00219 { 00220 m_totalTriggerNr = totalTriggerNrValue; 00221 }
set the TotalTriggerNr value in a 64-bits word, having the index iWord in the GTFE raw record
Definition at line 295 of file L1GtfeWord.cc.
References m_totalTriggerNr, TotalTriggerNrShift, and TotalTriggerNrWord.
Referenced by L1GTEvmDigiToRaw::packGTFE(), and L1GTDigiToRaw::packGTFE().
00296 { 00297 00298 if (iWord == TotalTriggerNrWord) { 00299 word64 = word64 | 00300 (static_cast<boost::uint64_t> (m_totalTriggerNr) << TotalTriggerNrShift); 00301 } 00302 00303 }
const boost::uint32_t L1GtfeWord::setupVersion | ( | ) | const [inline] |
get/set setup version
Definition at line 142 of file L1GtfeWord.h.
References m_setupVersion.
Referenced by L1TGT::analyze(), and L1GtDataEmulAnalyzer::compareGTFE().
00143 { 00144 return m_setupVersion; 00145 }
const boost::uint32_t L1GtfeWord::totalTriggerNr | ( | ) | const [inline] |
get/set total number of L1A sent since start of run
Definition at line 213 of file L1GtfeWord.h.
References m_totalTriggerNr.
Referenced by L1GtDataEmulAnalyzer::compareGTFE().
00214 { 00215 return m_totalTriggerNr; 00216 }
void L1GtfeWord::unpack | ( | const unsigned char * | gtfePtr | ) | [virtual] |
unpack GTFE gtfePtr pointer to the beginning of the GTFE block in the raw data
Reimplemented in L1GtfeExtWord.
Definition at line 382 of file L1GtfeWord.cc.
References ActiveBoardsWord, AltNrBxBoardWord, BlockSize, BoardIdWord, BxNrWord, lat::endl(), edm::isDebugEnabled(), LogDebug, LogTrace, RecordLength1Word, RecordLengthWord, setActiveBoards(), setAltNrBxBoard(), setBoardId(), setBxNr(), setRecordLength(), setRecordLength1(), setSetupVersion(), setTotalTriggerNr(), SetupVersionWord, and TotalTriggerNrWord.
Referenced by L1GlobalTriggerRawToDigi::produce(), and L1GtfeExtWord::unpack().
00383 { 00384 LogDebug("L1GtfeWord") 00385 << "\nUnpacking GTFE block.\n" 00386 << std::endl; 00387 00388 const boost::uint64_t* payload = 00389 reinterpret_cast<boost::uint64_t*>(const_cast<unsigned char*>(gtfePtr)); 00390 00391 setBoardId(payload[BoardIdWord]); 00392 setRecordLength1(payload[RecordLength1Word]); 00393 setRecordLength(payload[RecordLengthWord]); 00394 setBxNr(payload[BxNrWord]); 00395 setSetupVersion(payload[SetupVersionWord]); 00396 setActiveBoards(payload[ActiveBoardsWord]); 00397 setAltNrBxBoard(payload[AltNrBxBoardWord]); 00398 setTotalTriggerNr(payload[TotalTriggerNrWord]); 00399 00400 00401 if ( edm::isDebugEnabled() ) { 00402 00403 for (int iWord = 0; iWord < BlockSize; ++iWord) { 00404 LogTrace("L1GtfeWord") 00405 << std::setw(4) << iWord << " " 00406 << std::hex << std::setfill('0') 00407 << std::setw(16) << payload[iWord] 00408 << std::dec << std::setfill(' ') 00409 << std::endl; 00410 } 00411 00412 } 00413 00414 }
const boost::uint64_t L1GtfeWord::ActiveBoardsMask = 0xFFFF000000000000ULL [static, private] |
const int L1GtfeWord::ActiveBoardsShift = 48 [static, private] |
Definition at line 287 of file L1GtfeWord.h.
Referenced by setActiveBoards(), and setActiveBoardsWord64().
const int L1GtfeWord::ActiveBoardsWord = 1 [static, private] |
const boost::uint64_t L1GtfeWord::AltNrBxBoardMask = 0x0000FFFF00000000ULL [static, private] |
const int L1GtfeWord::AltNrBxBoardShift = 32 [static, private] |
Definition at line 288 of file L1GtfeWord.h.
Referenced by setAltNrBxBoard(), and setAltNrBxBoardWord64().
const int L1GtfeWord::AltNrBxBoardWord = 1 [static, private] |
const int L1GtfeWord::BlockSize = 2 [static, private] |
const boost::uint64_t L1GtfeWord::BoardIdMask = 0xFF00000000000000ULL [static, private] |
const int L1GtfeWord::BoardIdShift = 56 [static, private] |
const int L1GtfeWord::BoardIdWord = 0 [static, private] |
const boost::uint32_t L1GtfeWord::BstFlagMask = 0x0001 [static, private] |
const boost::uint64_t L1GtfeWord::BxNrMask = 0x00000FFF00000000ULL [static, private] |
const int L1GtfeWord::BxNrShift = 32 [static, private] |
const int L1GtfeWord::BxNrWord = 0 [static, private] |
boost::uint16_t L1GtfeWord::m_activeBoards [private] |
active boards contributing to EVM respectively DAQ record
Definition at line 308 of file L1GtfeWord.h.
Referenced by activeBoards(), operator==(), print(), reset(), setActiveBoards(), and setActiveBoardsWord64().
boost::uint16_t L1GtfeWord::m_altNrBxBoard [private] |
alternative for number of BX per board correlated with active boards bit value is 0: take alternative 0 bit value is 1: take alternative 1
Definition at line 314 of file L1GtfeWord.h.
Referenced by altNrBxBoard(), operator==(), print(), reset(), setAltNrBxBoard(), and setAltNrBxBoardWord64().
boost::uint16_t L1GtfeWord::m_boardId [private] |
board identifier
Definition at line 295 of file L1GtfeWord.h.
Referenced by boardId(), operator==(), print(), reset(), setBoardId(), and setBoardIdWord64().
boost::uint16_t L1GtfeWord::m_bxNr [private] |
bunch cross number as counted in the GTFE board
Definition at line 304 of file L1GtfeWord.h.
Referenced by bxNr(), operator==(), print(), reset(), setBxNr(), and setBxNrWord64().
boost::uint16_t L1GtfeWord::m_recordLength [private] |
record length for alternative 0
Definition at line 301 of file L1GtfeWord.h.
Referenced by operator==(), print(), recordLength(), reset(), setRecordLength(), and setRecordLengthWord64().
boost::uint16_t L1GtfeWord::m_recordLength1 [private] |
record length for alternative 1
Definition at line 298 of file L1GtfeWord.h.
Referenced by operator==(), print(), recordLength1(), reset(), setRecordLength1(), and setRecordLength1Word64().
boost::uint32_t L1GtfeWord::m_setupVersion [private] |
Definition at line 305 of file L1GtfeWord.h.
Referenced by bstFlag(), operator==(), print(), reset(), setBstFlag(), setSetupVersion(), setSetupVersionWord64(), and setupVersion().
boost::uint32_t L1GtfeWord::m_totalTriggerNr [private] |
total number of L1A sent since start of run
Definition at line 317 of file L1GtfeWord.h.
Referenced by operator==(), print(), reset(), setTotalTriggerNr(), setTotalTriggerNrWord64(), and totalTriggerNr().
const boost::uint64_t L1GtfeWord::RecordLength1Mask = 0x00F0000000000000ULL [static, private] |
const int L1GtfeWord::RecordLength1Shift = 52 [static, private] |
Definition at line 273 of file L1GtfeWord.h.
Referenced by setRecordLength1(), and setRecordLength1Word64().
const int L1GtfeWord::RecordLength1Word = 0 [static, private] |
const boost::uint64_t L1GtfeWord::RecordLengthMask = 0x000F000000000000ULL [static, private] |
const int L1GtfeWord::RecordLengthShift = 48 [static, private] |
Definition at line 274 of file L1GtfeWord.h.
Referenced by setRecordLength(), and setRecordLengthWord64().
const int L1GtfeWord::RecordLengthWord = 0 [static, private] |
const boost::uint64_t L1GtfeWord::SetupVersionMask = 0x00000000FFFFFFFFULL [static, private] |
const int L1GtfeWord::SetupVersionShift = 0 [static, private] |
Definition at line 276 of file L1GtfeWord.h.
Referenced by setSetupVersion(), and setSetupVersionWord64().
const int L1GtfeWord::SetupVersionWord = 0 [static, private] |
const boost::uint64_t L1GtfeWord::TotalTriggerNrMask = 0x00000000FFFFFFFFULL [static, private] |
const int L1GtfeWord::TotalTriggerNrShift = 0 [static, private] |
Definition at line 289 of file L1GtfeWord.h.
Referenced by setTotalTriggerNr(), and setTotalTriggerNrWord64().
const int L1GtfeWord::TotalTriggerNrWord = 1 [static, private] |