11 for (
const auto& chDigi : *dtphDigisBMTF.
getContainer()) {
14 if (chDigi.stNum() == 4)
19 data.
st_q_ = chDigi.code();
20 int bxNumber = chDigi.bxNum();
21 data.
bxNum_ = (3 + bxNumber);
22 data.
st_ = chDigi.stNum() - 1;
24 int bxCnt = (chDigi.BxCnt() >= 0 && chDigi.BxCnt() <= 3) ? chDigi.BxCnt() : 0;
28 data.
fiber_ = chDigi.Ts2Tag();
30 unsigned int amc2 = 0;
31 unsigned int fed = (chDigi.whNum() == -2) ? 1380 : 1381;
32 if (chDigi.scNum() % 2 != 0) {
36 amc = chDigi.scNum() + 1;
38 amc2 = (chDigi.scNum() + 11) % 12;
40 LogTrace(
"") <<
" fed: " << fed <<
" amc: " << amc <<
" DT PH DATA: " << data << std::endl;
41 raws[std::make_pair(fed, amc)].push_back(data.
rawData);
44 LogTrace(
"") <<
" fed: " << fed <<
" amc: " << amc2 <<
" DT PH DATA: " << data << std::endl;
45 raws[std::make_pair(fed, amc2)].push_back(data.
rawData);
52 for (
const auto& chDigi : *dtthDigisBMTF.
getContainer()) {
55 if (chDigi.stNum() == 4)
58 int bxNumber = chDigi.bxNum();
59 data.
bxNum_ = (3 + bxNumber);
60 data.
st_ = chDigi.stNum() - 1;
63 unsigned int amc2 = 0;
64 unsigned int fed = (chDigi.whNum() == -2) ? 1380 : 1381;
65 if (chDigi.scNum() % 2 != 0) {
69 amc = chDigi.scNum() + 1;
71 amc2 = (chDigi.scNum() + 11) % 12;
74 unsigned int etaQ = 0;
75 for (
unsigned int ipos = 0; ipos < 7; ipos++) {
76 if (chDigi.position(ipos) > 1)
77 edm::LogError(
"OmtfDtPacker") <<
"DT TH position to ETA, PROBLEM !!!!";
78 if (chDigi.position(ipos) == 1)
80 if (chDigi.quality(ipos) == 1)
85 bool foundDigi =
false;
86 for (
auto& raw : raws) {
87 if (raw.first.first != fed)
89 unsigned int amcPh = raw.first.second;
90 if (amc != amcPh && amc2 != amcPh)
92 auto& words = raw.second;
93 for (
auto&
word : words) {
99 if (dataRaw.
st_ != data.
st_)
106 LogTrace(
"") <<
"AP fed: " << fed <<
" amc: " << amc <<
" DT TH DATA: " << dataRaw << std::endl;
111 LogTrace(
"") <<
"NFD fed: " << fed <<
" amc: " << amc <<
" DT TH DATA: " << data << std::endl;
112 raws[std::make_pair(fed, amc)].push_back(data.
rawData);
115 LogTrace(
"") <<
"NFD fed: " << fed <<
" amc2: " << amc2 <<
" DT TH DATA: " << data << std::endl;
116 raws[std::make_pair(fed, amc2)].push_back(data.
rawData);
The_Container const * getContainer() const
std::map< std::pair< unsigned int, unsigned int >, std::vector< Word64 > > FedAmcRawsMap
Abs< T >::type abs(const T &t)
void pack(const L1MuDTChambPhContainer *phCont, const L1MuDTChambThContainer *thCont, FedAmcRawsMap &raws)
Phi_Container const * getContainer() const
char data[epos_bytes_allocation]