77 boost::uint16_t bxNrValue, boost::uint32_t eventNrValue,
81 boost::uint16_t gtPrescaleFactorIndexTechValue,
82 boost::uint16_t gtPrescaleFactorIndexAlgoValue,
83 boost::uint16_t noAlgoValue, boost::uint16_t finalORValue,
84 boost::uint32_t orbitNrValue, boost::uint16_t lumiSegmentNrValue,
85 boost::uint16_t localBxNrValue) :
86 m_boardId(boardIdValue), m_bxInEvent(bxInEventValue), m_bxNr(bxNrValue),
87 m_eventNr(eventNrValue),
88 m_gtTechnicalTriggerWord(gtTechnicalTriggerWordValue),
89 m_gtDecisionWord(gtDecisionWordValue),
90 m_gtDecisionWordExtended(gtDecisionWordExtendedValue),
91 m_gtPrescaleFactorIndexTech(gtPrescaleFactorIndexTechValue),
92 m_gtPrescaleFactorIndexAlgo(gtPrescaleFactorIndexAlgoValue),
93 m_noAlgo(noAlgoValue), m_finalOR(finalORValue),
94 m_orbitNr(orbitNrValue), m_lumiSegmentNr(lumiSegmentNrValue),
95 m_localBxNr(localBxNrValue)
182 return !( result == *
this);
213 m_bxInEvent = (hexBxInEvent + baseValue/2)%baseValue - baseValue/2;
224 int hexBxInEvent = (
m_bxInEvent + baseValue)%baseValue;
276 myCout <<
" Technical triggers (bitset style): \n " ;
284 myCout << (*ritBit ?
'1' :
'0');
286 if ( (((iBit + 1)%16) == (sizeW64%16)) && (iBit != 63) ) {
300 int word64Size =
sizeof(word64)*8;
305 for (
int iBit = 0; iBit < word64Size; ++iBit) {
318 int word64Size =
sizeof(word64)*8;
328 wordTT = wordTT | (iDecision << iBit);
331 if (iBit >= word64Size) {
357 std::ostringstream stream64;
359 std::vector<std::string> decWord;
360 decWord.reserve(nrDecWord);
362 for (std::vector<bool>::const_reverse_iterator ritBit =
m_gtDecisionWord.rbegin();
365 stream64 << (*ritBit ?
'1' :
'0');
367 if ( (((iBit + 1)%16) == (sizeW64%16)) ) {
371 if ( ((iBit + 1)%sizeW64) == 0) {
372 std::string iW = stream64.str();
375 decWord.push_back(iW);
385 for (std::vector<std::string>::reverse_iterator ritWord = decWord.rbegin();
386 ritWord != decWord.rend(); ++ritWord) {
389 myCout <<
" DecisionWord (bitset style): bits "
390 << iWord*sizeW64 + sizeW64 - 1 <<
" : " << iWord*sizeW64 <<
"\n ";
403 int word64Size =
sizeof(word64)*8;
408 for (
int iBit = 0; iBit < word64Size; ++iBit) {
419 int word64Size =
sizeof(word64)*8;
424 for (
int iBit = 0; iBit < word64Size; ++iBit) {
442 int word64Size =
sizeof(word64)*8;
452 wordA = wordA | (iDecision << iBit);
455 if (iBit >= word64Size) {
478 int word64Size =
sizeof(word64)*8;
487 if (iBit >= word64Size) {
490 wordB = wordB | ( iDecision << (iBit - word64Size) );
508 myCout <<
" DecisionWordExtended (bitset style): \n " ;
516 myCout << (*ritBit ?
'1' :
'0');
518 if ( (((iBit + 1)%16) == (sizeW64%16)) && (iBit != 63) ) {
532 int word64Size =
sizeof(word64)*8;
538 for (
int iBit = 0; iBit < word64Size; ++iBit) {
552 int word64Size =
sizeof(word64)*8;
562 wordE = wordE | (iDecision << iBit);
565 if (iBit >= word64Size) {
771 myCout <<
"\n L1GtFdlWord::print \n" << std::endl;
775 myCout <<
"\n Word " << iWord << std::endl;
777 myCout <<
" Board Id: "
778 << std::hex <<
" hex: " <<
" " << std::setw(4) << std::setfill(
'0') <<
m_boardId
785 int hexBxInEvent = (
m_bxInEvent + baseValue)%baseValue;
787 myCout <<
" BxInEvent: "
788 << std::hex <<
" hex: " <<
" " << std::setw(1) << hexBxInEvent
793 << std::hex <<
" hex: " <<
" " << std::setw(3) << std::setfill(
'0') <<
m_bxNr
795 << std::dec <<
" dec: " <<
m_bxNr
799 myCout <<
" EventNr: "
800 << std::hex <<
" hex: " <<
" " << std::setw(6) << std::setfill(
'0') <<
m_eventNr
808 myCout <<
"\n Word " << iWord << std::endl;
816 myCout <<
"\n Word " << iWord;
818 myCout <<
" and word " << iWord;
826 myCout <<
"\n Word " << iWord << std::endl;
833 myCout <<
"\n Word " << iWord << std::endl;
835 myCout <<
" PhysicsDeclared: "
836 << std::hex <<
" hex: " <<
" " << std::setw(4) << std::setfill(
'0')
842 myCout <<
" GtPrescaleFactorIndexTech: "
843 << std::hex <<
" hex: " <<
" " << std::setw(4) << std::setfill(
'0')
849 myCout <<
" GtPrescaleFactorIndexAlgo: "
850 << std::hex <<
" hex: " <<
" " << std::setw(4) << std::setfill(
'0')
856 myCout <<
" NoAlgo: "
857 << std::hex <<
" hex: " <<
" " << std::setw(1) << std::setfill(
'0') <<
m_noAlgo
862 myCout <<
" FinalOR: "
863 << std::hex <<
" hex: " <<
" " << std::setw(2) << std::setfill(
'0') <<
m_finalOR
869 myCout <<
"\n Word " << iWord << std::endl;
871 myCout <<
" OrbitNr: "
872 << std::hex <<
" hex: " <<
"" << std::setw(8) << std::setfill(
'0') <<
m_orbitNr
877 myCout <<
" LumiSegmentNr: "
878 << std::hex <<
" hex: " <<
" " << std::setw(4) << std::setfill(
'0') <<
m_lumiSegmentNr
883 myCout <<
" LocalBxNr: "
884 << std::hex <<
" hex: " <<
" " << std::setw(3) << std::setfill(
'0') <<
m_localBxNr
896 <<
"\nUnpacking FDL block.\n"
900 reinterpret_cast<boost::uint64_t*
>(
const_cast<unsigned char*
>(fdlPtr));
927 for (
int iWord = 0; iWord <
BlockSize; ++iWord) {
929 << std::setw(4) << iWord <<
" "
930 << std::hex << std::setfill(
'0')
931 << std::setw(16) << payload[iWord]
932 << std::dec << std::setfill(
' ')
static const boost::uint64_t BoardIdMask
void setLocalBxNrWord64(boost::uint64_t &word64, const int iWord)
void setFinalORWord64(boost::uint64_t &word64, const int iWord)
void setEventNrWord64(boost::uint64_t &word64, const int iWord)
void setPhysicsDeclaredWord64(boost::uint64_t &word64, const int iWord)
static const boost::uint64_t BxInEventMask
static const int EventNrShift
static const int GtPrescaleFactorIndexTechShift
boost::uint16_t m_localBxNr
static const unsigned int NumberTechnicalTriggers
static const int BxInEventShift
static const int GtDecisionWordBShift
boost::uint16_t m_lumiSegmentNr
luminosity segment number
void unpack(const unsigned char *fdlPtr)
static const boost::uint64_t LumiSegmentNrMask
static const int FinalORWord
static const int BxNrShift
static const boost::uint64_t OrbitNrMask
void setBxNr(const boost::uint16_t &bxNrValue)
void setGtPrescaleFactorIndexTechWord64(boost::uint64_t &word64, const int iWord)
static const int PhysicsDeclaredShift
static const int LocalBxNrShift
void printGtDecisionWord(std::ostream &myCout) const
static const int OrbitNrShift
static const int GtDecisionWordBWord
void setGtDecisionWordA(const boost::uint64_t &word64)
void setLocalBxNr(const boost::uint16_t &localBxNrValue)
static const int GtDecisionWordAShift
std::vector< bool > DecisionWordExtended
void setGtPrescaleFactorIndexAlgo(const boost::uint16_t >PrescaleFactorIndexAlgoValue)
static const boost::uint64_t BxNrMask
void setGtPrescaleFactorIndexAlgoWord64(boost::uint64_t &word64, const int iWord)
static const boost::uint64_t NoAlgoMask
static const unsigned int NumberPhysTriggersExtended
static const int GtPrescaleFactorIndexAlgoWord
static const int LumiSegmentNrShift
void setGtTechnicalTriggerWord(const TechnicalTriggerWord >TechnicalTriggerWordValue)
static const int BoardIdShift
static const int NoAlgoShift
void setEventNr(const boost::uint32_t &eventNrValue)
std::vector< bool > DecisionWord
typedefs
static const boost::uint64_t GtPrescaleFactorIndexAlgoMask
static const int BlockSize
boost::uint16_t m_physicsDeclared
set to true when physics declared
virtual ~L1GtFdlWord()
destructor
void setPhysicsDeclared(const boost::uint16_t &physicsDeclaredValue)
void setGtDecisionWordBWord64(boost::uint64_t &word64, const int iWord)
static const boost::uint64_t GtDecisionWordAMask
boost::uint16_t m_bxNr
bunch cross number of the actual bx
void printGtDecisionWordExtended(std::ostream &myCout) const
void reset()
reset the content of a L1GtFdlWord
static const int LumiSegmentNrWord
void setOrbitNr(const boost::uint32_t &orbitNrValue)
std::vector< bool > TechnicalTriggerWord
technical trigger bits (64 bits)
static const int EventNrWord
static const unsigned int NumberPhysTriggers
DecisionWord m_gtDecisionWord
algorithm bits
void setBoardId(const boost::uint16_t &boardIdValue)
set BoardId from a BoardId value
static const int BoardIdWord
static const int BxInEventWord
void setLumiSegmentNr(const boost::uint16_t &lumiSegmentNrValue)
void print(std::ostream &myCout) const
pretty print the content of a L1GtFdlWord
void setGtDecisionWordB(const boost::uint64_t &word64)
static const int GtTechnicalTriggerWordShift
void setBxInEventWord64(boost::uint64_t &word64, const int iWord)
boost::uint16_t m_finalOR
static const boost::uint64_t EventNrMask
static const boost::uint64_t GtPrescaleFactorIndexTechMask
void setGtDecisionWordExtendedWord64(boost::uint64_t &word64, const int iWord)
void setBoardIdWord64(boost::uint64_t &word64, const int iWord)
static const int GtDecisionWordAWord
bool operator!=(const L1GtFdlWord &) const
unequal operator
unsigned long long uint64_t
void setNoAlgoWord64(boost::uint64_t &word64, const int iWord)
static const int FinalORShift
static const int BxNrWord
void setBxNrWord64(boost::uint64_t &word64, const int iWord)
boost::uint16_t m_gtPrescaleFactorIndexAlgo
int m_bxInEvent
bunch cross in the GT event record
static const int PhysicsDeclaredWord
static const boost::uint64_t GtTechnicalTriggerWordMask
static const int OrbitNrWord
static const boost::uint64_t PhysicsDeclaredMask
static const int GtTechnicalTriggerWordWord
void setOrbitNrWord64(boost::uint64_t &word64, const int iWord)
static const int LocalBxNrWord
void printGtTechnicalTriggerWord(std::ostream &myCout) const
void setLumiSegmentNrWord64(boost::uint64_t &word64, const int iWord)
static const int GtDecisionWordExtendedWord
static const boost::uint64_t GtDecisionWordBMask
void setBxInEvent(const int bxInEventValue)
DecisionWordExtended m_gtDecisionWordExtended
extended algorithm bits, in addition to 128
boost::uint16_t m_boardId
board identifier
static const int GtPrescaleFactorIndexTechWord
void setGtTechnicalTriggerWordWord64(boost::uint64_t &word64, const int iWord)
boost::uint16_t m_noAlgo
true if no algorithm (from a defined group - default all) triggered
static const boost::uint64_t GtDecisionWordExtendedMask
boost::uint32_t m_eventNr
event number since last L1 reset generated in FDL
bool operator==(const L1GtFdlWord &) const
equal operator
void setNoAlgo(const boost::uint16_t &noAlgoValue)
static const int NoAlgoWord
boost::uint32_t m_orbitNr
orbit number
void setGtDecisionWordExtended(const DecisionWordExtended >DecisionWordExtendedValue)
TechnicalTriggerWord m_gtTechnicalTriggerWord
technical trigger bits
static const boost::uint64_t LocalBxNrMask
void setGtPrescaleFactorIndexTech(const boost::uint16_t >PrescaleFactorIndexTechValue)
static const int GtPrescaleFactorIndexAlgoShift
boost::uint16_t m_gtPrescaleFactorIndexTech
static const int GtDecisionWordExtendedShift
static const boost::uint64_t FinalORMask
void setGtDecisionWordAWord64(boost::uint64_t &word64, const int iWord)
void setFinalOR(const boost::uint16_t &finalORValue)
L1GtFdlWord()
constructors