CMS 3D CMS Logo

List of all members | Public Member Functions | Public Attributes | Private Member Functions | Private Attributes
SiPixelFedFillerWordEventNumber Class Reference

#include <SiPixelFedFillerWordEventNumber.h>

Inheritance diagram for SiPixelFedFillerWordEventNumber:
edm::EDProducer edm::ProducerBase edm::EDConsumerBase edm::ProductRegistryHelper

Public Member Functions

 SiPixelFedFillerWordEventNumber (const edm::ParameterSet &)
 
 ~SiPixelFedFillerWordEventNumber () override
 
- Public Member Functions inherited from edm::EDProducer
 EDProducer ()
 
SerialTaskQueueglobalLuminosityBlocksQueue ()
 
SerialTaskQueueglobalRunsQueue ()
 
ModuleDescription const & moduleDescription () const
 
 ~EDProducer () override
 
- Public Member Functions inherited from edm::ProducerBase
void callWhenNewProductsRegistered (std::function< void(BranchDescription const &)> const &func)
 
std::vector< edm::ProductResolverIndex > const & indiciesForPutProducts (BranchType iBranchType) const
 
 ProducerBase ()
 
std::vector< edm::ProductResolverIndex > const & putTokenIndexToProductResolverIndex () const
 
std::vector< bool > const & recordProvenanceList () const
 
void registerProducts (ProducerBase *, ProductRegistry *, ModuleDescription const &)
 
std::function< void(BranchDescription const &)> registrationCallback () const
 used by the fwk to register list of products More...
 
void resolvePutIndicies (BranchType iBranchType, ModuleToResolverIndicies const &iIndicies, std::string const &moduleLabel)
 
TypeLabelList const & typeLabelList () const
 used by the fwk to register the list of products of this module More...
 
 ~ProducerBase () noexcept(false) override
 
- Public Member Functions inherited from edm::EDConsumerBase
std::vector< ConsumesInfoconsumesInfo () const
 
void convertCurrentProcessAlias (std::string const &processName)
 Convert "@currentProcess" in InputTag process names to the actual current process name. More...
 
 EDConsumerBase ()
 
 EDConsumerBase (EDConsumerBase &&)=default
 
 EDConsumerBase (EDConsumerBase const &)=delete
 
ESProxyIndex const * esGetTokenIndices (edm::Transition iTrans) const
 
std::vector< ESProxyIndex > const & esGetTokenIndicesVector (edm::Transition iTrans) const
 
std::vector< ESRecordIndex > const & esGetTokenRecordIndicesVector (edm::Transition iTrans) const
 
ProductResolverIndexAndSkipBit indexFrom (EDGetToken, BranchType, TypeID const &) const
 
void itemsMayGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
void itemsToGet (BranchType, std::vector< ProductResolverIndexAndSkipBit > &) const
 
std::vector< ProductResolverIndexAndSkipBit > const & itemsToGetFrom (BranchType iType) const
 
void labelsForToken (EDGetToken iToken, Labels &oLabels) const
 
void modulesWhoseProductsAreConsumed (std::vector< ModuleDescription const * > &modules, ProductRegistry const &preg, std::map< std::string, ModuleDescription const * > const &labelsToDesc, std::string const &processName) const
 
EDConsumerBaseoperator= (EDConsumerBase &&)=default
 
EDConsumerBase const & operator= (EDConsumerBase const &)=delete
 
bool registeredToConsume (ProductResolverIndex, bool, BranchType) const
 
bool registeredToConsumeMany (TypeID const &, BranchType) const
 
ProductResolverIndexAndSkipBit uncheckedIndexFrom (EDGetToken) const
 
void updateLookup (BranchType iBranchType, ProductResolverIndexHelper const &, bool iPrefetchMayGet)
 
void updateLookup (eventsetup::ESRecordsToProxyIndices const &)
 
virtual ~EDConsumerBase () noexcept(false)
 

Public Attributes

std::string instance
 
std::string label
 
bool SaveFillerWordsbool
 

Private Member Functions

void beginJob () override
 
unsigned int CalibStatFillWord (unsigned int, int)
 
void endJob () override
 
void produce (edm::Event &, const edm::EventSetup &) override
 
int PwordSlink64 (uint64_t *, const int, uint32_t &)
 

Private Attributes

unsigned int CalibStatFill
 
edm::ParameterSet config_
 
unsigned int EventNum
 
int status
 
std::vector< uint32_t > vecFillerWordsEventNumber1
 
std::vector< uint32_t >::iterator vecFillerWordsEventNumber1_It
 
std::vector< uint32_t > vecFillerWordsEventNumber2
 
std::vector< uint32_t >::iterator vecFillerWordsEventNumber2_It
 
std::vector< uint32_t > vecSaveFillerWords
 
std::vector< uint32_t >::iterator vecSaveFillerWords_It
 

Additional Inherited Members

- Public Types inherited from edm::EDProducer
typedef EDProducer ModuleType
 
- Public Types inherited from edm::ProducerBase
using ModuleToResolverIndicies = std::unordered_multimap< std::string, std::tuple< edm::TypeID const *, const char *, edm::ProductResolverIndex > >
 
typedef ProductRegistryHelper::TypeLabelList TypeLabelList
 
- Public Types inherited from edm::EDConsumerBase
typedef ProductLabels Labels
 
- Static Public Member Functions inherited from edm::EDProducer
static const std::string & baseType ()
 
static void fillDescriptions (ConfigurationDescriptions &descriptions)
 
static void prevalidate (ConfigurationDescriptions &descriptions)
 
static bool wantsGlobalLuminosityBlocks ()
 
static bool wantsGlobalRuns ()
 
static bool wantsInputProcessBlocks ()
 
static bool wantsProcessBlocks ()
 
static bool wantsStreamLuminosityBlocks ()
 
static bool wantsStreamRuns ()
 
- Protected Member Functions inherited from edm::ProducerBase
template<class ProductType >
BranchAliasSetterT< ProductType > produces ()
 declare what type of product will make and with which optional label More...
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces ()
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces ()
 
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<BranchType B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<Transition B>
BranchAliasSetter produces (const TypeID &id, std::string instanceName=std::string(), bool recordProvenance=true)
 
template<typename ProductType , Transition B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<class ProductType >
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
template<typename ProductType , BranchType B>
BranchAliasSetterT< ProductType > produces (std::string instanceName)
 
ProducesCollector producesCollector ()
 
- Protected Member Functions inherited from edm::EDConsumerBase
EDGetToken consumes (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > consumes (edm::InputTag const &tag)
 
template<BranchType B = InEvent>
EDConsumerBaseAdaptor< B > consumes (edm::InputTag tag) noexcept
 
template<BranchType B>
EDGetToken consumes (TypeToGet const &id, edm::InputTag const &tag)
 
ConsumesCollector consumesCollector ()
 Use a ConsumesCollector to gather consumes information from helper functions. More...
 
template<typename ProductType , BranchType B = InEvent>
void consumesMany ()
 
void consumesMany (const TypeToGet &id)
 
template<BranchType B>
void consumesMany (const TypeToGet &id)
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes ()
 
template<Transition Tr = Transition::Event>
constexpr auto esConsumes () noexcept
 
template<typename ESProduct , typename ESRecord , Transition Tr = Transition::Event>
auto esConsumes (ESInputTag const &tag)
 
template<Transition Tr = Transition::Event>
auto esConsumes (ESInputTag tag) noexcept
 
template<Transition Tr = Transition::Event>
ESGetTokenGeneric esConsumes (eventsetup::EventSetupRecordKey const &iRecord, eventsetup::DataKey const &iKey)
 Used with EventSetupRecord::doGet. More...
 
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<BranchType B>
EDGetToken mayConsume (const TypeToGet &id, edm::InputTag const &tag)
 
template<typename ProductType , BranchType B = InEvent>
EDGetTokenT< ProductType > mayConsume (edm::InputTag const &tag)
 

Detailed Description

FedFillerWords/SiPixelFedFillerWordEventNumber /src/SiPixelFedFillerWordEventNumber .cc

Description: <one line="" class="" summary>="">

Implementation: <Notes on="" implementation>="">

Definition at line 22 of file SiPixelFedFillerWordEventNumber.h.

Constructor & Destructor Documentation

◆ SiPixelFedFillerWordEventNumber()

SiPixelFedFillerWordEventNumber::SiPixelFedFillerWordEventNumber ( const edm::ParameterSet iConfig)
explicit

Definition at line 24 of file SiPixelFedFillerWordEventNumber.cc.

24  {
25  SaveFillerWordsbool = iConfig.getParameter<bool>("SaveFillerWords");
26  label = iConfig.getUntrackedParameter<std::string>("InputLabel", "source");
27  instance = iConfig.getUntrackedParameter<std::string>("InputInstance", "");
28  produces<std::vector<uint32_t>>("FillerWordEventNumber1");
29  produces<std::vector<uint32_t>>("FillerWordEventNumber2");
30  if (SaveFillerWordsbool == true) {
31  produces<std::vector<uint32_t>>("SaveFillerWord");
32  }
33  consumes<FEDRawDataCollection>(label);
34 }

References edm::ParameterSet::getParameter(), edm::ParameterSet::getUntrackedParameter(), instance, label, SaveFillerWordsbool, and AlCaHLTBitMon_QueryRunRegistry::string.

◆ ~SiPixelFedFillerWordEventNumber()

SiPixelFedFillerWordEventNumber::~SiPixelFedFillerWordEventNumber ( )
override

Definition at line 36 of file SiPixelFedFillerWordEventNumber.cc.

36 {}

Member Function Documentation

◆ beginJob()

void SiPixelFedFillerWordEventNumber::beginJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDProducer.

Definition at line 445 of file SiPixelFedFillerWordEventNumber.cc.

445 {}

◆ CalibStatFillWord()

unsigned int SiPixelFedFillerWordEventNumber::CalibStatFillWord ( unsigned int  totword,
int  status 
)
private

Definition at line 37 of file SiPixelFedFillerWordEventNumber.cc.

37  {
38  //===== Variables to get each filler word out of the totword and
39  // to conform the last 16 bit filler word if Filler3 is zero.
40  unsigned int Filler1 = (totword)&0x000000ff;
41  unsigned int Filler2 = ((totword)&0x0000ff00) >> 8;
42  unsigned int Filler3 = ((totword)&0x00ff0000) >> 16;
43  unsigned int Filler4 = ((totword)&0xffff0000) >> 16;
44  unsigned int maskFiller4 = ((totword)&0xff000000) >> 16;
45  unsigned int Filler14 = (Filler1 & maskFiller4);
46  unsigned int Filler24 = (Filler2 & maskFiller4);
47  unsigned int CalibFiller1 = 0;
48  unsigned int CalibFiller2 = 0;
49  bool BoolStat = false;
50  //=====Possible cases for the totword. "CalibFiller1" and "CalibFiller2" take their valur
51  // according to the value of the totword.
52  if ((status == 0x1) || (status == 0x9)) {
53  CalibFiller1 = Filler1;
54  if (status == 0x9) {
55  CalibFiller2 = Filler14;
56  }
57  }
58  if ((status == 0x2) || (status == 0xa)) {
59  CalibFiller1 = Filler2;
60  if (status == 0xa) {
61  CalibFiller2 = Filler24;
62  }
63  }
64  if ((status == 0x4) || (status == 0xc)) {
65  CalibFiller1 = Filler3;
66  if (status == 0xc) {
67  CalibFiller2 = Filler4;
68  }
69  }
70  if (status == 0x8) {
71  CalibFiller2 = Filler4;
72  }
73  if ((status == 0x7) || (status == 0xf)) {
74  if ((Filler1 == Filler2) && (Filler1 == Filler3) && (Filler2 == Filler3)) {
75  CalibFiller1 = Filler1;
76  BoolStat = true;
77  if (status == 0xf) {
78  CalibFiller2 = Filler4;
79  }
80  } else {
81  edm::LogError("AnazrFedFillerWords")
82  << "Status: " << status << "Event ID in Filler words don't match" << '\t' << "Filler1: " << (Filler1 % 256)
83  << '\t' << "Filler2: " << (Filler2 % 256) << '\t' << "Filler3: " << (Filler3 % 256) << std::endl;
84  }
85  }
86  if ((status == 0x3) || (status == 0xb)) {
87  if (Filler1 == Filler2) {
88  CalibFiller1 = Filler1;
89  BoolStat = true;
90  if (status == 0xb) {
91  CalibFiller2 = Filler14;
92  }
93  } else {
94  edm::LogError("AnazrFedFillerWords")
95  << "Status: " << status << "Event ID in Filler words don't match" << '\t' << "Filler1: " << (Filler1 % 256)
96  << '\t' << "Filler2: " << (Filler2 % 256) << std::endl;
97  }
98  }
99  if ((status == 0x5) || (status == 0xd)) {
100  if (Filler1 == Filler3) {
101  CalibFiller1 = Filler1;
102  BoolStat = true;
103  if (status == 0xd) {
104  CalibFiller2 = Filler4;
105  }
106  } else {
107  edm::LogError("AnazrFedFillerWords")
108  << "Status: " << status << "Event ID in Filler words don't match" << '\t' << "Filler1: " << (Filler1 % 256)
109  << '\t' << "Filler3: " << (Filler3 % 256) << std::endl;
110  }
111  }
112  if ((status == 0x6) || (status == 0xe)) {
113  if (Filler2 == Filler3) {
114  CalibFiller1 = Filler2;
115  BoolStat = true;
116  if (status == 0xe) {
117  CalibFiller2 = Filler4;
118  }
119  } else {
120  edm::LogError("AnazrFedFillerWords")
121  << "Status: " << status << "Event ID Filler words don't match" << '\t' << "Filler2: " << (Filler2 % 256)
122  << '\t' << "Filler3: " << (Filler3 % 256) << std::endl;
123  }
124  }
125  //===== Using the Event number from CMSSW to get a value to compare with the value encoded
126  // in the filler words.
127  unsigned int CalibEvtNum = ((EventNum - 1) / 10);
128  if ((CalibFiller1 != 0) && (CalibEvtNum != CalibFiller1)) {
129  edm::LogError("AnazrFedFillerWords") << "Error, Event ID Numbers Don't match---->"
130  << "Filler1 Event ID: " << CalibFiller1 << '\t'
131  << "Run Event ID: " << CalibEvtNum << '\t' << std::endl;
132  } else if ((CalibFiller1 != 0) && (CalibEvtNum == CalibFiller1)) {
133  vecFillerWordsEventNumber1.push_back((CalibFiller1 % 256));
134  edm::LogInfo("AnazrFedFillerWords") << "Filler1 Event ID: " << (CalibFiller1 % 256) << std::endl;
135  } else if ((CalibFiller2 != 0) && (BoolStat == true)) {
136  vecFillerWordsEventNumber2.push_back((((CalibFiller2 % 65536) & (0xff00)) >> 8));
137  edm::LogInfo("AnazrFedFillerWords") << "Filler2 Event ID:" << (((CalibFiller2 % 65536) & (0xff00)) >> 8)
138  << std::endl;
139  } else if ((CalibFiller2 != 0) && (BoolStat == false)) {
140  if ((status == 0x9) || (status == 0xa) || (status == 0xc)) {
141  vecFillerWordsEventNumber2.push_back((((CalibFiller2 % 65536) & (0xff00)) >> 8));
142  edm::LogInfo("AnazrFedFillerWords")
143  << "Filler2 Event ID:" << (((CalibFiller2 % 65536) & (0xff00)) >> 8) << std::endl;
144  } else if (status == 0x8) {
145  edm::LogError("AnazrFedFillerWords")
146  << "Status: " << status << " No Filler1 found, is not possible get any Event ID Number" << std::endl;
147  }
148  }
149 
150  return 0;
151 }

References EventNum, status, vecFillerWordsEventNumber1, vecFillerWordsEventNumber2, testProducerWithPsetDescEmpty_cfi::x1, and testProducerWithPsetDescEmpty_cfi::x2.

Referenced by PwordSlink64().

◆ endJob()

void SiPixelFedFillerWordEventNumber::endJob ( void  )
overrideprivatevirtual

Reimplemented from edm::EDProducer.

Definition at line 448 of file SiPixelFedFillerWordEventNumber.cc.

448 {}

Referenced by o2olib.O2ORunMgr::executeJob().

◆ produce()

void SiPixelFedFillerWordEventNumber::produce ( edm::Event iEvent,
const edm::EventSetup iSetup 
)
overrideprivatevirtual

Implements edm::EDProducer.

Definition at line 390 of file SiPixelFedFillerWordEventNumber.cc.

390  {
391  EventNum = iEvent.id().event();
393  iEvent.getByLabel(label, instance, buffers);
394  auto FillerWordEventNumbers1 = std::make_unique<std::vector<uint32_t>>();
395  auto FillerWordEventNumbers2 = std::make_unique<std::vector<uint32_t>>();
396  auto SaveFillerWords = std::make_unique<std::vector<uint32_t>>();
397  //===== Loop over all the FEDs ========================================================
398  std::pair<int, int> fedIds;
399  fedIds.first = 0;
400  fedIds.second = 39;
401 
402  for (int fedId = fedIds.first; fedId <= fedIds.second; fedId++) {
403  edm::LogInfo("FedFillerWords") << " examining FED: " << fedId << std::endl;
404  const FEDRawData& fedRawData = buffers->FEDData(fedId); //get event data for this fed
405  //======== Run the fill word finder...
406  if (fedRawData.size() != 0) {
407  uint32_t totword;
408  int value = PwordSlink64((uint64_t*)fedRawData.data(), (int)fedRawData.size(), totword);
409  if (value != 0) {
410  //====== Verify that the vector is not empty
411  if (!vecSaveFillerWords.empty()) {
414  SaveFillerWords->push_back(*vecSaveFillerWords_It);
415  }
416  } else {
417  edm::LogWarning("FedFillerWords") << "========= Filler Words Vector is empty! ==========" << std::endl;
418  }
419  }
420  edm::LogInfo("FedFillerWords") << "Found " << value << " filler words in FED " << fedId << std::endl;
424  FillerWordEventNumbers1->push_back(*vecFillerWordsEventNumber1_It);
425  }
429  FillerWordEventNumbers2->push_back(*vecFillerWordsEventNumber2_It);
430  }
431  }
432  }
433  iEvent.put(std::move(FillerWordEventNumbers1), "FillerWordEventNumber1");
434  iEvent.put(std::move(FillerWordEventNumbers2), "FillerWordEventNumber2");
435  //====== bool variable to be controled in the config file, allows the user to put or
436  // the filler words inside the output root file
437  if (SaveFillerWordsbool == true) {
438  iEvent.put(std::move(SaveFillerWords), "SaveFillerWord");
439  }
442 }

References EventNum, FEDRawDataCollection::FEDData(), l1tstage2_dqm_sourceclient-live_cfg::fedId, L1TStage2BMTF_cff::fedIds, l1t_dqm_sourceclient-live_cfg::fedRawData, iEvent, instance, createfilelist::int, label, eostools::move(), PwordSlink64(), SaveFillerWordsbool, vecFillerWordsEventNumber1, vecFillerWordsEventNumber1_It, vecFillerWordsEventNumber2, vecFillerWordsEventNumber2_It, vecSaveFillerWords, and vecSaveFillerWords_It.

◆ PwordSlink64()

int SiPixelFedFillerWordEventNumber::PwordSlink64 ( uint64_t *  ldata,
const int  length,
uint32_t &  totword 
)
private

Definition at line 153 of file SiPixelFedFillerWordEventNumber.cc.

153  {
154  edm::LogInfo("FedFillerWords") << "Begin of data" << std::endl;
155 
156  if ((ldata[0] & 0xf000000000000000LL) != 0x5000000000000000LL) //header
157  {
158  return 0;
159  }
160 
161  //========= analyze the data buffer to find private words ================================
162  int fif2cnt = 0;
163  int dumcnt = 0;
164  int gapcnt = 0;
165 
166  uint32_t gap[8];
167  uint32_t dum[8];
168  uint32_t word1 = 0;
169  uint32_t word2 = 0;
170 
171  uint32_t chan = 0;
172  uint32_t roc = 0;
173 
174  const uint32_t rocmsk = 0x3e00000;
175  const uint32_t chnlmsk = 0xfc000000;
176 
177  for (int jk = 0; jk < 8; jk++)
178  gap[jk] = 0;
179  for (int jk = 0; jk < 8; jk++)
180  dum[jk] = 0;
181  totword = 0;
182  int fifcnt = 1;
183  for (int kk = 1; kk < length - 1; kk++) {
184  //======= if statement to make analize just data with the right format ===================
185  if ((((ldata[kk] & 0xff00000000000000LL) >> 32) == 0xa0000000) &&
186  (((ldata[kk] & 0xffffff00000000LL) >> 32) == (uint64_t)(kk + 1))) {
187  break;
188  }
189 
190  word2 = (uint32_t)ldata[kk];
191  word1 = (uint32_t)(ldata[kk] >> 32);
192 
193  //======= 1st word ======================================================================
194 
195  chan = ((word1 & chnlmsk) >> 26);
196  roc = ((word1 & rocmsk) >> 21);
197 
198  //======count non-error words
199  if (roc < 25) {
200  if (dumcnt > 0) {
201  dumcnt = 0;
202  } //stale dummy!
203  if ((chan < 5) && (fifcnt != 1)) {
204  edm::LogError("FedFillerWords") << " error in fifo counting!" << std::endl;
205  }
206  if ((chan > 4) && (chan < 10) && (fifcnt != 2)) {
207  fif2cnt = 0;
208  fifcnt = 2;
209  }
210  if ((chan > 9) && (chan < 14) && (fifcnt != 3)) {
211  fif2cnt = 0;
212  fifcnt = 3;
213  }
214  if ((chan > 13) && (chan < 19) && (fifcnt != 4)) {
215  fif2cnt = 0;
216  fifcnt = 4;
217  }
218  if ((chan > 18) && (chan < 23) && (fifcnt != 5)) {
219  fif2cnt = 0;
220  fifcnt = 5;
221  }
222  if ((chan > 22) && (chan < 28) && (fifcnt != 6)) {
223  fif2cnt = 0;
224  fifcnt = 6;
225  }
226  if ((chan > 27) && (chan < 32) && (fifcnt != 7)) {
227  fif2cnt = 0;
228  fifcnt = 7;
229  }
230  if ((chan > 31) && (fifcnt != 8)) {
231  fif2cnt = 0;
232  fifcnt = 8;
233  }
234  fif2cnt++;
235  }
236  //====== Gap Word
237  if (roc == 26) {
238  gap[fifcnt - 1] = (0x1000 + (word1 & 0xff));
239  gapcnt++;
240  }
241  //====== Dummy Word
242  if ((roc == 27) && ((fif2cnt + dumcnt) < 6)) {
243  dum[fifcnt - 1] = (0x1000 + (word1 & 0xff));
244  dumcnt++;
245  } else if ((roc == 27) && ((fif2cnt + dumcnt) > 6)) {
246  dumcnt = 1;
247  fif2cnt = 0;
248  fifcnt++;
249  }
250 
251  //======== 2nd word ============================================================
252 
253  chan = ((word2 & chnlmsk) >> 26);
254  roc = ((word2 & rocmsk) >> 21);
255 
256  if (roc < 25) {
257  if (dumcnt > 0) {
258  dumcnt = 0;
259  edm::LogInfo("FedFillerWords") << " ***Stale dummy!" << std::endl;
260  } //stale dummy!
261  if ((chan < 5) && (fifcnt != 1)) {
262  edm::LogError("FedFillerWords") << " error in fifo counting!" << std::endl;
263  }
264  if ((chan > 4) && (chan < 10) && (fifcnt != 2)) {
265  fif2cnt = 0;
266  fifcnt = 2;
267  }
268  if ((chan > 9) && (chan < 14) && (fifcnt != 3)) {
269  fif2cnt = 0;
270  fifcnt = 3;
271  }
272  if ((chan > 13) && (chan < 19) && (fifcnt != 4)) {
273  fif2cnt = 0;
274  fifcnt = 4;
275  }
276  if ((chan > 18) && (chan < 23) && (fifcnt != 5)) {
277  fif2cnt = 0;
278  fifcnt = 5;
279  }
280  if ((chan > 22) && (chan < 28) && (fifcnt != 6)) {
281  fif2cnt = 0;
282  fifcnt = 6;
283  }
284  if ((chan > 27) && (chan < 32) && (fifcnt != 7)) {
285  fif2cnt = 0;
286  fifcnt = 7;
287  }
288  if ((chan > 31) && (fifcnt != 8)) {
289  fif2cnt = 0;
290  fifcnt = 8;
291  }
292  fif2cnt++;
293  }
294  if (roc == 26) {
295  gap[fifcnt - 1] = (0x1000 + (word2 & 0xff));
296  gapcnt++;
297  }
298  if ((roc == 27) && ((fif2cnt + dumcnt) < 6)) {
299  dum[fifcnt - 1] = (0x1000 + (word1 & 0xff));
300  dumcnt++;
301  } else if ((roc == 27) && ((fif2cnt + dumcnt) > 6)) {
302  dumcnt = 1;
303  fif2cnt = 0;
304  fifcnt++;
305  }
306 
307  //word check complete
308  if (((fif2cnt + dumcnt) == 6) && (dumcnt > 0)) { //done with this fifo
309  dumcnt = 0;
310  fif2cnt = 0;
311  fifcnt++;
312  }
313  if ((gapcnt > 0) && ((dumcnt + fif2cnt) > 5)) { //done with this fifo
314  gapcnt = 0;
315  fifcnt++;
316  fif2cnt = 0;
317  dumcnt = 0;
318  } else if ((gapcnt > 0) && ((dumcnt + fif2cnt) < 6)) {
319  gapcnt = 0;
320  }
321 
322  } //==End of fifo-3 word loop
323  //========== FPGAs Status ==================================================
324  status = 0;
325 
326  if (gap[0] > 0) {
327  totword = (gap[0] & 0xff);
328  status = 1;
329  } else if (gap[1] > 0) {
330  totword = (gap[1] & 0xff);
331  status = 1;
332  } else if (dum[0] > 0) {
333  totword = (dum[0] & 0xff);
334  status = 1;
335  } else if (dum[1] > 0) {
336  totword = (dum[1] & 0xff);
337  status = 1;
338  }
339 
340  if (gap[2] > 0) {
341  totword = totword | ((gap[2] & 0xff) << 8);
342  status = status | 0x2;
343  } else if (gap[3] > 0) {
344  totword = totword | ((gap[3] & 0xff) << 8);
345  status = status | 0x2;
346  } else if (dum[2] > 0) {
347  totword = totword | ((dum[2] & 0xff) << 8);
348  status = status | 0x2;
349  } else if (dum[3] > 0) {
350  totword = totword | ((dum[3] & 0xff) << 8);
351  status = status | 0x2;
352  }
353 
354  if (gap[4] > 0) {
355  totword = totword | ((gap[4] & 0xff) << 16);
356  status = status | 0x4;
357  } else if (gap[5] > 0) {
358  totword = totword | ((gap[5] & 0xff) << 16);
359  status = status | 0x4;
360  } else if (dum[4] > 0) {
361  totword = totword | ((dum[4] & 0xff) << 16);
362  status = status | 0x4;
363  } else if (dum[5] > 0) {
364  totword = totword | ((dum[5] & 0xff) << 16);
365  status = status | 0x4;
366  }
367 
368  if (gap[6] > 0) {
369  totword = totword | ((gap[6] & 0xff) << 24);
370  status = status | 0x8;
371  } else if (gap[7] > 0) {
372  totword = totword | ((gap[7] & 0xff) << 24);
373  status = status | 0x8;
374  } else if (dum[6] > 0) {
375  totword = totword | ((dum[6] & 0xff) << 24);
376  status = status | 0x8;
377  } else if (dum[7] > 0) {
378  totword = totword | ((dum[7] & 0xff) << 24);
379  status = status | 0x8;
380  }
381  vecSaveFillerWords.push_back(totword);
382  if ((EventNum % 10) == 0) {
384  }
385  edm::LogInfo("FedFillerWords") << "total word = 0x" << std::hex << totword << std::hex << " Status = 0x" << status
386  << std::dec << std::endl;
387  return (status);
388 }

References CalibStatFill, CalibStatFillWord(), officialStyle::chan, TauDecayModes::dec, EventNum, HLT_FULL_cff::gap, GetRecoTauVFromDQM_MC_cff::kk, PixelMapPlotter::roc, status, and vecSaveFillerWords.

Referenced by produce().

Member Data Documentation

◆ CalibStatFill

unsigned int SiPixelFedFillerWordEventNumber::CalibStatFill
private

Definition at line 41 of file SiPixelFedFillerWordEventNumber.h.

Referenced by PwordSlink64().

◆ config_

edm::ParameterSet SiPixelFedFillerWordEventNumber::config_
private

Definition at line 34 of file SiPixelFedFillerWordEventNumber.h.

◆ EventNum

unsigned int SiPixelFedFillerWordEventNumber::EventNum
private

Definition at line 36 of file SiPixelFedFillerWordEventNumber.h.

Referenced by CalibStatFillWord(), produce(), and PwordSlink64().

◆ instance

std::string SiPixelFedFillerWordEventNumber::instance

◆ label

std::string SiPixelFedFillerWordEventNumber::label

◆ SaveFillerWordsbool

bool SiPixelFedFillerWordEventNumber::SaveFillerWordsbool

Definition at line 28 of file SiPixelFedFillerWordEventNumber.h.

Referenced by produce(), and SiPixelFedFillerWordEventNumber().

◆ status

int SiPixelFedFillerWordEventNumber::status
private

◆ vecFillerWordsEventNumber1

std::vector<uint32_t> SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber1
private

Definition at line 44 of file SiPixelFedFillerWordEventNumber.h.

Referenced by CalibStatFillWord(), and produce().

◆ vecFillerWordsEventNumber1_It

std::vector<uint32_t>::iterator SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber1_It
private

Definition at line 45 of file SiPixelFedFillerWordEventNumber.h.

Referenced by produce().

◆ vecFillerWordsEventNumber2

std::vector<uint32_t> SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber2
private

Definition at line 46 of file SiPixelFedFillerWordEventNumber.h.

Referenced by CalibStatFillWord(), and produce().

◆ vecFillerWordsEventNumber2_It

std::vector<uint32_t>::iterator SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber2_It
private

Definition at line 47 of file SiPixelFedFillerWordEventNumber.h.

Referenced by produce().

◆ vecSaveFillerWords

std::vector<uint32_t> SiPixelFedFillerWordEventNumber::vecSaveFillerWords
private

Definition at line 42 of file SiPixelFedFillerWordEventNumber.h.

Referenced by produce(), and PwordSlink64().

◆ vecSaveFillerWords_It

std::vector<uint32_t>::iterator SiPixelFedFillerWordEventNumber::vecSaveFillerWords_It
private

Definition at line 43 of file SiPixelFedFillerWordEventNumber.h.

Referenced by produce().

SiPixelFedFillerWordEventNumber::CalibStatFillWord
unsigned int CalibStatFillWord(unsigned int, int)
Definition: SiPixelFedFillerWordEventNumber.cc:37
SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber2
std::vector< uint32_t > vecFillerWordsEventNumber2
Definition: SiPixelFedFillerWordEventNumber.h:46
SiPixelFedFillerWordEventNumber::SaveFillerWordsbool
bool SaveFillerWordsbool
Definition: SiPixelFedFillerWordEventNumber.h:28
testProducerWithPsetDescEmpty_cfi.x2
x2
Definition: testProducerWithPsetDescEmpty_cfi.py:28
edm::ParameterSet::getUntrackedParameter
T getUntrackedParameter(std::string const &, T const &) const
SiPixelFedFillerWordEventNumber::vecSaveFillerWords_It
std::vector< uint32_t >::iterator vecSaveFillerWords_It
Definition: SiPixelFedFillerWordEventNumber.h:43
edm::LogInfo
Log< level::Info, false > LogInfo
Definition: MessageLogger.h:125
edm::Handle
Definition: AssociativeIterator.h:50
edm::LogWarning
Log< level::Warning, false > LogWarning
Definition: MessageLogger.h:122
FEDRawData
Definition: FEDRawData.h:19
testProducerWithPsetDescEmpty_cfi.x1
x1
Definition: testProducerWithPsetDescEmpty_cfi.py:33
l1t_dqm_sourceclient-live_cfg.fedRawData
fedRawData
Definition: l1t_dqm_sourceclient-live_cfg.py:188
SiPixelFedFillerWordEventNumber::instance
std::string instance
Definition: SiPixelFedFillerWordEventNumber.h:27
SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber2_It
std::vector< uint32_t >::iterator vecFillerWordsEventNumber2_It
Definition: SiPixelFedFillerWordEventNumber.h:47
GetRecoTauVFromDQM_MC_cff.kk
kk
Definition: GetRecoTauVFromDQM_MC_cff.py:84
SiPixelFedFillerWordEventNumber::CalibStatFill
unsigned int CalibStatFill
Definition: SiPixelFedFillerWordEventNumber.h:41
SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber1
std::vector< uint32_t > vecFillerWordsEventNumber1
Definition: SiPixelFedFillerWordEventNumber.h:44
HLT_FULL_cff.gap
gap
Definition: HLT_FULL_cff.py:8498
FEDRawDataCollection::FEDData
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
Definition: FEDRawDataCollection.cc:19
AlCaHLTBitMon_QueryRunRegistry.string
string
Definition: AlCaHLTBitMon_QueryRunRegistry.py:256
createfilelist.int
int
Definition: createfilelist.py:10
iEvent
int iEvent
Definition: GenABIO.cc:224
value
Definition: value.py:1
SiPixelFedFillerWordEventNumber::label
std::string label
Definition: SiPixelFedFillerWordEventNumber.h:26
l1tstage2_dqm_sourceclient-live_cfg.fedId
fedId
Definition: l1tstage2_dqm_sourceclient-live_cfg.py:88
edm::LogError
Log< level::Error, false > LogError
Definition: MessageLogger.h:123
SiPixelFedFillerWordEventNumber::EventNum
unsigned int EventNum
Definition: SiPixelFedFillerWordEventNumber.h:36
eostools.move
def move(src, dest)
Definition: eostools.py:511
officialStyle.chan
chan
lumi = TPaveText(lowX+0.38, lowY+0.061, lowX+0.45, lowY+0.161, "NDC") lumi.SetBorderSize( 0 ) lumi....
Definition: officialStyle.py:106
SiPixelFedFillerWordEventNumber::vecSaveFillerWords
std::vector< uint32_t > vecSaveFillerWords
Definition: SiPixelFedFillerWordEventNumber.h:42
PixelMapPlotter.roc
roc
Definition: PixelMapPlotter.py:498
L1TStage2BMTF_cff.fedIds
fedIds
Definition: L1TStage2BMTF_cff.py:10
edm::ParameterSet::getParameter
T getParameter(std::string const &) const
Definition: ParameterSet.h:303
cond::uint64_t
unsigned long long uint64_t
Definition: Time.h:13
SiPixelFedFillerWordEventNumber::vecFillerWordsEventNumber1_It
std::vector< uint32_t >::iterator vecFillerWordsEventNumber1_It
Definition: SiPixelFedFillerWordEventNumber.h:45
SiPixelFedFillerWordEventNumber::PwordSlink64
int PwordSlink64(uint64_t *, const int, uint32_t &)
Definition: SiPixelFedFillerWordEventNumber.cc:153
SiPixelFedFillerWordEventNumber::status
int status
Definition: SiPixelFedFillerWordEventNumber.h:35
TauDecayModes.dec
dec
Definition: TauDecayModes.py:143