Definition at line 9 of file EtSumUnpacker.cc.
Implements l1t::Unpacker.
Definition at line 21 of file EtSumUnpacker.cc.
References coll, l1t::getBXRange(), l1t::BlockHeader::getID(), l1t::BlockHeader::getSize(), l1t::Block::header(), l1t::L1Candidate::hwPt(), l1t::L1Candidate::hwQual(), i, l1t::EtSum::kTotalEt, l1t::EtSum::kTotalHt, LogDebug, l1t::Block::payload(), l1t::L1Candidate::setHwPt(), l1t::L1Candidate::setHwQual(), and l1t::EtSum::setType().
24 LogDebug(
"L1T") <<
"Block ID = " <<
block.header().getID() <<
" size = " <<
block.header().getSize();
26 int nBX, firstBX, lastBX;
27 nBX = int(ceil(
block.header().getSize() / 2.));
30 auto res_ =
static_cast<CaloCollections*
>(
coll)->getEtSums();
31 res_->setBXRange(firstBX, lastBX);
33 LogDebug(
"L1T") <<
"nBX = " << nBX <<
" first BX = " << firstBX <<
" lastBX = " << lastBX;
39 for (
int bx=firstBX; bx<=lastBX; bx++){
43 uint32_t raw_data0 =
block.payload()[i++];
44 uint32_t raw_data1 =
block.payload()[i++];
49 candbit[0] = raw_data0 & 0xFFFF;
50 candbit[1] = raw_data1 & 0xFFFF;
52 int totet=candbit[0] & 0xFFF;
53 int overflowtotet=(candbit[0]>>12) & 0x1;
54 int totht=candbit[1] & 0xFFF;
55 int overflowtotht=(candbit[1]>>12) & 0x1;
61 flagtotet|= overflowtotet;
63 LogDebug(
"L1T") <<
"ET: pT " << et.
hwPt()<<
"is overflow "<<overflowtotet<<std::endl;
70 flagtotht|= overflowtotht;
72 LogDebug(
"L1T") <<
"HT: pT " << ht.
hwPt()<<
"is overflow "<<overflowtotht<<std::endl;
void getBXRange(int nbx, int &first, int &last)
void setType(EtSumType type)