From 594bb31dd9d1410f95e402e12c9d5d00c68884a9 Mon Sep 17 00:00:00 2001 From: Andrew Loeliger Date: Wed, 26 Jun 2024 11:29:49 -0500 Subject: [PATCH] Fix mistaken bits convention --- .../plugins/implementations_stage2/CICADAUnpacker.cc | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/EventFilter/L1TRawToDigi/plugins/implementations_stage2/CICADAUnpacker.cc b/EventFilter/L1TRawToDigi/plugins/implementations_stage2/CICADAUnpacker.cc index f3a52e754c522..a34e5156ee339 100644 --- a/EventFilter/L1TRawToDigi/plugins/implementations_stage2/CICADAUnpacker.cc +++ b/EventFilter/L1TRawToDigi/plugins/implementations_stage2/CICADAUnpacker.cc @@ -27,10 +27,9 @@ namespace l1t { return false; } else { const uint32_t* base = block.payload().data(); - //This differs slightly from uGT, in that we grab the first 4 bits - //of the last 4 words (still in first to last order) and arrange those - uint32_t word = (caloCrateCicadaBitsPattern & base[2]) >> 16 | (caloCrateCicadaBitsPattern & base[3]) >> 20 | - (caloCrateCicadaBitsPattern & base[4]) >> 24 | (caloCrateCicadaBitsPattern & base[5]) >> 28; + //First 4 bits of the first 4 words are CICADA bits + uint32_t word = (caloCrateCicadaBitsPattern & base[0]) >> 16 | (caloCrateCicadaBitsPattern & base[1]) >> 20 | + (caloCrateCicadaBitsPattern & base[2]) >> 24 | (caloCrateCicadaBitsPattern & base[3]) >> 28; float score = static_cast(word) / 256.f; res->push_back(0, score); return true;