21 unsigned int amc = block.
amc().getAMCNumber();
22 unsigned int bxid = block.
amc().getBX();
24 if( (amc-1) != ((bxid-1+3)%9) )
return true;
25 LogDebug(
"L1T") <<
"Unpacking AMC " << amc <<
" for BX " << bxid;
32 res1_->setBXRange(0,0);
33 res2_->setBXRange(0,0);
34 res3_->setBXRange(0,0);
35 res4_->setBXRange(0,0);
40 int unsigned fjet = 6;
42 int unsigned ftau = 4;
49 uint32_t raw_data = block.
payload()[fet];
53 et.
setHwPt( static_cast<int32_t>( uint32_t(raw_data & 0xFFFFFF) << 16 ) >> 16 );
67 res2_->push_back(0,et);
72 raw_data = block.
payload()[fht];
77 ht.
setHwPt( static_cast<int32_t>( uint32_t(raw_data & 0xFFFFFF) << 16 ) >> 16 );
90 res2_->push_back(0,ht);
93 for (
unsigned nJet=0; nJet < 2; nJet++){
95 raw_data = block.
payload()[fjet+nJet];
111 int mpEta = etasign*(raw_data & 0x3F);
113 jet.
setHwPhi((raw_data >> 6) & 0x7F);
114 jet.
setHwPt((raw_data >> 13) & 0xFFFF);
119 res1_->push_back(0,jet);
161 for (
unsigned nEG=0; nEG < 2; nEG++){
163 raw_data = block.
payload()[feg+nEG];
179 eg.
setHwEta(etasign*((raw_data >> 4) & 0x3F));
180 eg.
setHwPhi((raw_data >> 10) & 0x7F);
181 eg.
setHwPt((raw_data >> 21) & 0x3FF);
182 eg.
setHwQual(((raw_data >> 3) & 0x1) + (((raw_data >> 1) & 0x1) << 2));
188 res3_->push_back(0,eg);
196 for (
unsigned nTau=0; nTau < 2; nTau++){
198 raw_data = block.
payload()[ftau+nTau];
214 tau.
setHwEta(etasign*((raw_data >> 4) & 0x3F));
215 tau.
setHwPhi((raw_data >> 10) & 0x7F);
216 tau.
setHwPt((raw_data >> 21) & 0x3FF);
217 tau.
setHwQual(((raw_data >> 3) & 0x1) + (((raw_data >> 1) & 0x1) << 2));
230 res4_->push_back(0,tau);
virtual bool unpack(const Block &block, UnpackerCollections *coll) override
BlockHeader header() const
std::vector< uint32_t > payload() const
void setType(EtSumType type)
virtual void setP4(const LorentzVector &p4) final
set 4-momentum
et
define resolution functions of each parameter
#define DEFINE_L1T_UNPACKER(type)
void amc(const amc::Header &h)