9 orbitBuffer_ = std::vector<std::vector<l1ScoutingRun3::Muon>>(3565);
15 produces<l1ScoutingRun3::MuonOrbitCollection>().setBranchAlias(
"MuonOrbitCollection");
28 size_t orbitSize = sourceRawData.
size();
61 uint32_t mAcount = (
header & header_masks::mAcount) >> header_shifts::mAcount;
62 uint32_t mBcount = (
header & header_masks::mBcount) >> header_shifts::mBcount;
66 pos += 4 + 4 + (mAcount + mBcount) * 12;
69 uint32_t orbit = bl->
orbit & 0x7FFFFFFF;
73 std::cout <<
"GMT Orbit " << orbit <<
", BX -> " <<
bx <<
", nMuons -> " << mAcount + mBcount << std::endl;
79 for (
unsigned int i = 0;
i < mAcount + mBcount;
i++) {
80 uint32_t interm = (bl->
mu[
i].
extra >> ugmt::shiftsMuon::interm) & ugmt::masksMuon::interm;
83 std::cout <<
" -> Excluding intermediate muon\n";
89 uint32_t ietaextu = (bl->
mu[
i].
f >> ugmt::shiftsMuon::etaext) & ugmt::masksMuon::etaextv;
91 if (((bl->
mu[
i].
f >> ugmt::shiftsMuon::etaext) & ugmt::masksMuon::etaexts) != 0) {
92 ietaext = ietaextu -= 256;
98 int32_t iptuncon = (bl->
mu[
i].
s >> ugmt::shiftsMuon::ptuncon) & ugmt::masksMuon::ptuncon;
109 int32_t iphiext = ((bl->
mu[
i].
f >> ugmt::shiftsMuon::phiext) & ugmt::masksMuon::phiext);
115 uint32_t iso = (bl->
mu[
i].
s >> ugmt::shiftsMuon::iso) & ugmt::masksMuon::iso;
117 if (((bl->
mu[
i].
s >> ugmt::shiftsMuon::chrgv) & ugmt::masksMuon::chrgv) == 1)
118 chrg = ((bl->
mu[
i].
s >> ugmt::shiftsMuon::chrg) & ugmt::masksMuon::chrg) == 1 ? -1 : 1;
144 l1ScoutingRun3::Muon muon(ipt,
ieta,
iphi,
qual, chrg, chrg != 0, iso,
index, ietaext, iphiext, iptuncon, idxy);
static void fillDescriptions(edm::ConfigurationDescriptions &descriptions)
T getParameter(std::string const &) const
void unpackOrbit(const unsigned char *buf, size_t len)
edm::InputTag srcInputTag
void printMuon(const Muon &muon, std::ostream &outs=std::cout)
const FEDRawData & FEDData(int sourceId) const
size_t size() const
Lenght of the data buffer in bytes.
std::vector< std::vector< l1ScoutingRun3::Muon > > orbitBuffer_
void produce(edm::Event &, const edm::EventSetup &) override
T getUntrackedParameter(std::string const &, T const &) const
void addDefault(ParameterSetDescription const &psetDescription)
#define DEFINE_FWK_MODULE(type)
~ScGMTRawToDigi() override
ScGMTRawToDigi(const edm::ParameterSet &)
static constexpr int GmtSDSID
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.