14 LogDebug(
"L1T") <<
"Block ID = " <<
block.header().getID() <<
" size = " <<
block.header().getSize();
17 if (
block.header().getSize() < 1) {
46 for (
const auto& bxBlock : bxBlocks) {
48 const auto bx = bxBlock.header().getBx();
49 if (bx < firstBX || bx >
lastBX) {
51 <<
"Corrupt RAW data from FED " <<
fed_ <<
", AMC " <<
block.amc().getAMCNumber() <<
". BX number " <<
bx 52 <<
" in BX header is outside of the BX range [" <<
firstBX <<
"," <<
lastBX 53 <<
"] defined in the block header.";
61 const std::vector<uint32_t>&
payload,
63 unsigned int startIdx) {
64 unsigned int i = startIdx + 2;
76 unsigned linkID{(blockID - link_offset) / 2};
108 for (
unsigned nWord = 2; nWord <
nWords_; nWord += 2) {
109 uint32_t raw_data_spare =
payload[startIdx + 1];
110 uint32_t raw_data_00_31 =
payload[
i++];
111 uint32_t raw_data_32_63 =
payload[
i++];
112 LogDebug(
"L1T") <<
"raw_data_spare = 0x" << hex << raw_data_spare <<
" raw_data_00_31 = 0x" << raw_data_00_31
113 <<
" raw_data_32_63 = 0x" << raw_data_32_63;
116 LogDebug(
"L1T") <<
"Muon hwPt zero. Skip.";
125 LogDebug(
"L1T") <<
"Mu" << nWord / 2 <<
": eta " <<
mu.hwEta() <<
" phi " <<
mu.hwPhi() <<
" pT " <<
mu.hwPt()
126 <<
" iso " <<
mu.hwIso() <<
" qual " <<
mu.hwQual() <<
" charge " <<
mu.hwCharge()
127 <<
" charge valid " <<
mu.hwChargeValid();
133 <<
" are required. Not unpacking the data for BX " <<
bx <<
".";
constexpr int32_t ceil(float num)
unsigned int getAlgoVersion()
void unpackBx(int bx, const std::vector< uint32_t > &payload, unsigned int blockID, unsigned int startIdx=0)
static void fillMuon(Muon &mu, uint32_t raw_data_spare, uint32_t raw_data_00_31, uint32_t raw_data_32_63, int fed, int fw, int muInBx)
void getBXRange(int nbx, int &first, int &last)
static constexpr unsigned bxzs_enable_shift_
static constexpr unsigned nWords_
bool isEmpty(int bx) const
void setOneTightInTime(const bool bit)
void setOneNominalInTime(const bool bit)
bool unpack(const Block &block, UnpackerCollections *coll) override
MuonShowerBxCollection * muonShowerCollection_
static constexpr int kUgmtFwVersionShowersFrom2023
const T & at(int bx, unsigned i) const
void setTwoLooseDiffSectorsInTime(const bool bit)
static bool showerFired(uint32_t shower_word, int fedId, int fwId)
static constexpr unsigned ptShift_
MuonBxCollection * muonCollection_
void setBXRange(int bxFirst, int bxLast)
void erase(int bx, unsigned i)
#define DEFINE_L1T_UNPACKER(type)
Log< level::Warning, false > LogWarning
static constexpr unsigned ptMask_
void push_back(int bx, T object)