CMS 3D CMS Logo

RPCTwinMuxRawToDigi.cc
Go to the documentation of this file.
2 
3 #include <memory>
4 
14 
23 
25  : calculate_crc_(config.getParameter<bool>("calculateCRC"))
26  , fill_counters_(config.getParameter<bool>("fillCounters"))
27  , bx_min_(config.getParameter<int>("bxMin"))
28  , bx_max_(config.getParameter<int>("bxMax"))
29 {
30  produces<RPCDigiCollection>();
31  if (fill_counters_) {
32  produces<RPCAMCLinkCounters>();
33  }
34  raw_token_ = consumes<FEDRawDataCollection>(config.getParameter<edm::InputTag>("inputTag"));
35 }
36 
38 {}
39 
40 void RPCTwinMuxRawToDigi::compute_crc_64bit(std::uint16_t & crc, std::uint64_t const & word)
41 { // overcome constness problem evf::compute_crc_64bit
42  unsigned char const * uchars(reinterpret_cast<unsigned char const *>(&word));
43  for (unsigned char const * uchar = uchars + 7
44  ; uchar >= uchars ; --uchar) {
45  crc = evf::compute_crc_8bit(crc, *uchar);
46  }
47 }
48 
50 {
52  desc.add<edm::InputTag>("inputTag", edm::InputTag("rawDataCollector", ""));
53  desc.add<bool>("calculateCRC", true);
54  desc.add<bool>("fillCounters", true);
55  desc.add<int>("bxMin", -2);
56  desc.add<int>("bxMax", 2);
57  descs.add("rpcTwinMuxRawToDigi", desc);
58 }
59 
61 {
62  if (es_tm_link_map_watcher_.check(setup)) {
64  std::set<int> feds;
65  for (auto const & tm_link : es_tm_link_map_->getMap()) {
66  feds.insert(tm_link.first.getFED());
67  }
68  feds_.assign(feds.begin(), feds.end());
69  }
70 }
71 
73 {
74  // Get EventSetup Electronics Maps
76  setup.get<RPCLBLinkMapRcd>().get(es_lb_link_map_);
77 
78  // Get RAW Data
79  edm::Handle<FEDRawDataCollection> raw_data_collection;
80  event.getByToken(raw_token_, raw_data_collection);
81 
82  std::set<std::pair<RPCDetId, RPCDigi> > rpc_digis;
83  std::unique_ptr<RPCAMCLinkCounters> counters(new RPCAMCLinkCounters());
84 
85  // Loop over the FEDs
86  for (int fed : feds_) {
87 
88  if (fill_counters_) {
90  }
91 
92  std::uint16_t crc(0xffff);
93 
94  FEDRawData const & raw_data = raw_data_collection->FEDData(fed);
95  unsigned int nwords(raw_data.size() / sizeof(std::uint64_t));
96  if (!nwords) {
97  continue;
98  }
99 
100  std::uint64_t const * word(reinterpret_cast<std::uint64_t const *>(raw_data.data()));
101  std::uint64_t const * word_end = word + nwords;
102 
103  LogDebug("RPCTwinMuxRawToDigi") << "Handling FED " << fed << " with length " << nwords;
104 
105  // Handle the CDF Headers
106  if (!processCDFHeaders(fed
107  , word, word_end
108  , crc, *counters)) {
109  continue;
110  }
111 
112  // Handle the CDF Trailers
113  if (!processCDFTrailers(fed, nwords
114  , word, word_end
115  , crc, *counters)) {
116  continue;
117  }
118 
119  // Loop over the Blocks
120  while (word < word_end) {
121  processBlock(fed
122  , word, word_end
123  , crc, *counters, rpc_digis);
124  }
125 
126  // Complete CRC check with trailer
127  if (calculate_crc_) {
128  word = word_end;
129  word_end = reinterpret_cast<std::uint64_t const *>(raw_data.data()) + nwords - 1;
130  for ( ; word < word_end ; ++word) {
131  compute_crc_64bit(crc, *word);
132  }
133  compute_crc_64bit(crc, (*word & 0xffffffff0000ffff)); // trailer excluding crc
134  FEDTrailer trailer(reinterpret_cast<unsigned char const *>(word_end));
135  if ((unsigned int)(trailer.crc()) != crc) {
136  if (fill_counters_) {
138  }
139  edm::LogWarning("RPCTwinMuxRawToDigi") << "FED Trailer CRC doesn't match for FED id " << fed;
140  }
141  }
142  }
143 
144  putRPCDigis(event, rpc_digis);
145  if (fill_counters_) {
146  putCounters(event, std::move(counters));
147  }
148 }
149 
151  , std::uint64_t const * & word, std::uint64_t const * & word_end
152  , std::uint16_t & crc
153  , RPCAMCLinkCounters & counters) const
154 {
155  bool more_headers(true);
156  for ( ; word < word_end && more_headers ; ++word) {
157  if (calculate_crc_) {
158  compute_crc_64bit(crc, *word);
159  }
160 
161  LogDebug("RPCTwinMuxRawToDigi") << "CDF Header " << std::hex << *word << std::dec;
162  FEDHeader header(reinterpret_cast<unsigned char const *>(word));
163  if (!header.check()) {
164  if (fill_counters_) {
166  }
167  edm::LogWarning("RPCTwinMuxRawToDigi") << "FED Header check failed for FED id " << fed;
168  ++word;
169  break;
170  }
171  if (header.sourceID() != fed) {
172  if (fill_counters_) {
174  }
175  edm::LogWarning("RPCTwinMuxRawToDigi") << "FED Header Source ID " << header.sourceID()
176  << " does not match requested FED id " << fed;
177  break;
178  }
179 
180  // moreHeaders() not used
181  // more_headers = header.moreHeaders();
182  more_headers = false;
183  }
184 
185  return !more_headers;
186 }
187 
188 bool RPCTwinMuxRawToDigi::processCDFTrailers(int fed, unsigned int nwords
189  , std::uint64_t const * & word, std::uint64_t const * & word_end
190  , std::uint16_t & crc
191  , RPCAMCLinkCounters & counters) const
192 {
193  bool more_trailers(true);
194  for (--word_end ; word_end > word && more_trailers ; --word_end) {
195  FEDTrailer trailer(reinterpret_cast<unsigned char const *>(word_end));
196  LogDebug("RPCTwinMuxRawToDigi") << "CDF Trailer " << std::hex << *word_end << std::dec
197  << ", length " << trailer.fragmentLength();
198  if (!trailer.check()) {
199  if (fill_counters_) {
201  }
202  edm::LogWarning("RPCTwinMuxRawToDigi") << "FED Trailer check failed for FED id " << fed;
203  --word_end;
204  break;
205  }
206  if (trailer.fragmentLength() != nwords) {
207  if (fill_counters_) {
209  }
210  edm::LogWarning("RPCTwinMuxRawToDigi") << "FED Trailer length " << trailer.fragmentLength()
211  << " does not match actual data size " << nwords
212  << " for FED id " << fed;
213  --word_end;
214  break;
215  }
216 
217  // moreTrailers() not used
218  // more_trailers = trailer.moreTrailers();
219  more_trailers = false;
220  }
221 
222  ++word_end;
223 
224  return !more_trailers;
225 }
226 
228  , std::uint64_t const * & word, std::uint64_t const * word_end
229  , std::uint16_t & crc
230  , RPCAMCLinkCounters & counters
231  , std::set<std::pair<RPCDetId, RPCDigi> > & digis) const
232 {
233  // Block Header and Content
234  rpctwinmux::BlockHeader block_header(*word);
235  if (calculate_crc_) {
236  compute_crc_64bit(crc, *word);
237  }
238  ++word;
239 
240  unsigned int n_amc(block_header.getNAMC());
241  if (word + n_amc + 1 >= word_end) {
242  if (fill_counters_) {
244  }
245  edm::LogWarning("RPCTwinMuxRawToDigi") << "Block can not be complete for FED " << fed;
246  word = word_end;
247  return false;
248  }
249 
250  std::vector<std::pair<unsigned int, unsigned int> > amc_size_map;
251  for (unsigned int amc = 0 ; amc < n_amc ; ++amc) {
252  LogDebug("RPCTwinMuxRawToDigi") << "Block AMC " << amc;
253  rpctwinmux::BlockAMCContent amc_content(*word);
254  if (calculate_crc_) {
255  compute_crc_64bit(crc, *word);
256  }
257  ++word;
258 
259  amc_size_map.push_back(std::make_pair(amc_content.getAMCNumber(), amc_content.getSize()));
260  if (!amc_content.isValid()) {
261  if (fill_counters_) {
263  }
264  edm::LogWarning("RPCTwinMuxRawToDigi") << "BlockAMCContent is reporting an invalid "
265  << "Event Counter or Bunch Counter for FED " << fed
266  << ", AMC " << amc_content.getAMCNumber();
267  }
268  }
269 
270  for (std::pair<unsigned int, unsigned int> const & amc_size : amc_size_map) {
271  processTwinMux(fed, amc_size.first, amc_size.second
272  , word, word_end
273  , crc, counters
274  , digis);
275  }
276 
277  if (word < word_end) {
278  rpctwinmux::BlockTrailer block_trailer(*word);
279  if (calculate_crc_) {
280  compute_crc_64bit(crc, *word);
281  }
282  ++word;
283  return true;
284  } else {
285  return false;
286  }
287 }
288 
289 bool RPCTwinMuxRawToDigi::processTwinMux(int fed, unsigned int amc_number, unsigned int size
290  , std::uint64_t const * & word, std::uint64_t const * word_end
291  , std::uint16_t & crc
292  , RPCAMCLinkCounters & counters
293  , std::set<std::pair<RPCDetId, RPCDigi> > & digis) const
294 {
295  LogDebug("RPCTwinMuxRawToDigi") << "TwinMux AMC#" << amc_number << ", size " << size;
296  if (!size) {
297  return true;
298  }
299  if (amc_number > (unsigned int)RPCAMCLink::max_amcnumber_) {
300  if (fill_counters_) {
302  }
303  edm::LogWarning("RPCTwinMuxRawToDigi") << "Invalid AMC Number " << amc_number
304  << " for FED " << fed;
305  if (calculate_crc_) {
306  for ( ; size > 0 ; --size, ++word) {
307  compute_crc_64bit(crc, *word);
308  }
309  } else {
310  word += size;
311  }
312  return false;
313  }
314  if (word + size >= word_end || size < 3) {
315  if (fill_counters_) {
316  counters.add(RPCAMCLinkEvents::amc_payload_incomplete_, RPCAMCLink(fed, amc_number));
317  }
318  edm::LogWarning("RPCTwinMuxRawToDigi") << "TwinMux Data can not be complete for FED " << fed << " AMC #" << amc_number;
319  if (calculate_crc_) {
320  for ( ; size > 0 ; --size, ++word) {
321  compute_crc_64bit(crc, *word);
322  }
323  } else {
324  word += size;
325  }
326  return false;
327  }
328 
330  unsigned int bx_counter(header.getBXCounter());
331  if (calculate_crc_) {
332  compute_crc_64bit(crc, *word); ++word;
333  compute_crc_64bit(crc, *word); ++word;
334  } else {
335  word += 2;
336  }
337  size -= 2;
338 
339  if (amc_number != header.getAMCNumber()) {
340  if (fill_counters_) {
341  counters.add(RPCAMCLinkEvents::amc_number_mismatch_, RPCAMCLink(fed, amc_number));
342  }
343  edm::LogWarning("RPCTwinMuxRawToDigi") << "AMC Number inconsistent in TwinMuxHeader vs BlockAMCContent: " << header.getAMCNumber()
344  << " vs " << amc_number;
345  if (calculate_crc_) {
346  for ( ; size > 0 ; --size, ++word) {
347  compute_crc_64bit(crc, *word);
348  }
349  } else {
350  word += size;
351  }
352  return false;
353  }
354 
355  int bx_min(bx_min_), bx_max(bx_max_);
356  if (header.hasRPCBXWindow()) {
357  bx_min = std::max(bx_min, header.getRPCBXMin());
358  bx_max = std::min(bx_max, header.getRPCBXMax());
359  LogDebug("RPCTwinMuxRawToDigi") << "BX range set to " << bx_min << ", " << bx_max;
360  }
361 
362  bool has_first_rpc_word(false);
363  rpctwinmux::RPCRecord rpc_record;
364  for ( ; size > 1 ; --size, ++word) {
365  if (calculate_crc_) {
366  compute_crc_64bit(crc, *word);
367  }
368  unsigned int type(rpctwinmux::TwinMuxRecord::getType(*word));
369  LogDebug("RPCTwinMuxRawToDigi") << "TwinMux data type " << std::hex << type << std::dec;
371  if (has_first_rpc_word) {
372  processRPCRecord(fed, amc_number, bx_counter, rpc_record, counters, digis, bx_min, bx_max, 0, 1);
373  }
374  rpc_record.reset();
375  rpc_record.set(0, *word);
376  has_first_rpc_word = true;
377  } else if (type == rpctwinmux::TwinMuxRecord::rpc_second_type_) {
378  if (!has_first_rpc_word) {
379  edm::LogWarning("RPCTwinMuxRawToDigi") << "Received second RPC word without first";
380  } else {
381  rpc_record.set(1, *word);
382  processRPCRecord(fed, amc_number, bx_counter, rpc_record, counters, digis, bx_min, bx_max, 0, 4);
383  has_first_rpc_word = false;
384  }
385  }
386  }
387  if (has_first_rpc_word) {
388  processRPCRecord(fed, amc_number, bx_counter, rpc_record, counters, digis, bx_min, bx_max, 0, 1);
389  }
390 
391  rpctwinmux::TwinMuxTrailer trailer(*word);
392  LogDebug("RPCTwinMuxRawToDigi") << "TwinMux Trailer " << std::hex << *word << std::dec;
393  if (calculate_crc_) {
394  compute_crc_64bit(crc, *word);
395  }
396  ++word;
397  return true;
398 }
399 
400 void RPCTwinMuxRawToDigi::processRPCRecord(int fed, unsigned int amc_number
401  , unsigned int bx_counter
402  , rpctwinmux::RPCRecord const & record
403  , RPCAMCLinkCounters & counters
404  , std::set<std::pair<RPCDetId, RPCDigi> > & digis
405  , int bx_min, int bx_max
406  , unsigned int link, unsigned int link_max) const
407 {
408  LogDebug("RPCTwinMuxRawToDigi") << "RPCRecord " << std::hex << record.getRecord()[0]
409  << ", " << record.getRecord()[1] << std::dec << std::endl;
410  int bx_offset(record.getBXOffset());
411  RPCAMCLink tm_link(fed, amc_number);
412  for ( ; link <= link_max ; ++link) {
413  tm_link.setAMCInput(link);
414  rpctwinmux::RPCLinkRecord link_record(record.getRPCLinkRecord(link));
415 
416  if (link_record.isError()) {
417  if (fill_counters_ && bx_offset == 0) {
418  counters.add(RPCAMCLinkEvents::input_link_error_, tm_link);
419  }
420  LogDebug("RPCTwinMuxRawToDigi") << "Link in error for " << tm_link;
421  continue;
422  } else if (!link_record.isAcknowledge()) {
423  if (fill_counters_ && bx_offset == 0) {
424  counters.add(RPCAMCLinkEvents::input_link_ack_fail_, tm_link);
425  }
426  LogDebug("RPCTwinMuxRawToDigi") << "Link without acknowledge for " << tm_link;
427  continue;
428  }
429 
430  if (!link_record.getPartitionData()) {
431  continue;
432  }
433 
434  int bx(bx_offset - (int)(link_record.getDelay()));
435  LogDebug("RPCTwinMuxRawToDigi") << "RPC BX " << bx << " for offset " << bx_offset;
436 
437  if (fill_counters_ && bx == 0 && link_record.isEOD()) { // EOD comes at the last delay
438  counters.add(RPCAMCLinkEvents::input_eod_, tm_link);
439  }
440 
441  RPCAMCLinkMap::map_type::const_iterator tm_link_it = es_tm_link_map_->getMap().find(tm_link);
442  if (tm_link_it == es_tm_link_map_->getMap().end()) {
443  if (fill_counters_ && bx_offset == 0) {
444  counters.add(RPCAMCLinkEvents::amc_link_invalid_, RPCAMCLink(fed, amc_number));
445  }
446  LogDebug("RPCTwinMuxRawToDigi") << "Skipping unknown TwinMuxLink " << tm_link;
447  continue;
448  }
449 
450  RPCLBLink lb_link = tm_link_it->second;
451 
452  if (link_record.getLinkBoard() > (unsigned int)RPCLBLink::max_linkboard_) {
453  if (fill_counters_ && bx_offset == 0) {
454  counters.add(RPCAMCLinkEvents::input_lb_invalid_, tm_link);
455  }
456  LogDebug("RPCTwinMuxRawToDigi") << "Skipping invalid LinkBoard " << link_record.getLinkBoard()
457  << " for record " << link << " (" << std::hex << link_record.getRecord()
458  << " in " << record.getRecord()[0] << ':' << record.getRecord()[1] << std::dec
459  << " from " << tm_link;
460  continue;
461  }
462 
463  if (link_record.getConnector() > (unsigned int)RPCLBLink::max_connector_) {
464  if (fill_counters_ && bx_offset == 0) {
466  }
467  LogDebug("RPCTwinMuxRawToDigi") << "Skipping invalid Connector " << link_record.getConnector()
468  << " for record " << link << " (" << std::hex << link_record.getRecord()
469  << " in " << record.getRecord()[0] << ':' << record.getRecord()[1] << std::dec
470  << ") from " << tm_link;
471  continue;
472  }
473 
474  lb_link.setLinkBoard(link_record.getLinkBoard());
475  lb_link.setConnector(link_record.getConnector());
476 
477  RPCLBLinkMap::map_type::const_iterator lb_link_it = es_lb_link_map_->getMap().find(lb_link);
478  if (lb_link_it == es_lb_link_map_->getMap().end()) {
479  if (fill_counters_ && bx_offset == 0) {
481  }
482  LogDebug("RPCTwinMuxRawToDigi") << "Could not find " << lb_link
483  << " for record " << link << " (" << std::hex << link_record.getRecord()
484  << " in " << record.getRecord()[0] << ':' << record.getRecord()[1] << std::dec
485  << ") from " << tm_link;
486  continue;
487  }
488 
489  if (bx < bx_min || bx > bx_max) {
490  continue;
491  }
492 
493  if (fill_counters_ && bx == 0) {
494  counters.add(RPCAMCLinkEvents::amc_event_, RPCAMCLink(fed, amc_number));
495  counters.add(RPCAMCLinkEvents::input_event_, tm_link);
496  }
497 
498  RPCFebConnector const & feb_connector(lb_link_it->second);
499  RPCDetId det_id(feb_connector.getRPCDetId());
500  unsigned int channel_offset(link_record.getPartition() ? 9 : 1); // 1-16
501  std::uint8_t data(link_record.getPartitionData());
502 
503  for (unsigned int channel = 0 ; channel < 8 ; ++channel) {
504  if (data & (0x1 << channel)) {
505  unsigned int strip(feb_connector.getStrip(channel + channel_offset));
506  if (strip) {
507  digis.insert(std::pair<RPCDetId, RPCDigi>(det_id, RPCDigi(strip, bx)));
508  LogDebug("RPCTwinMuxRawToDigi") << "RPCDigi " << det_id.rawId()
509  << ", " << strip << ", " << bx;
510  }
511  }
512  }
513 
514  // rpctwinmux::RPCBXRecord checks postponed: not implemented in firmware as planned and tbd if design or firmware should change
515 
516  }
517 }
518 
520  , std::set<std::pair<RPCDetId, RPCDigi> > const & digis)
521 {
522  std::unique_ptr<RPCDigiCollection> rpc_digi_collection(new RPCDigiCollection());
523  RPCDetId rpc_det_id;
524  std::vector<RPCDigi> local_digis;
525  for (std::pair<RPCDetId, RPCDigi> const & rpc_digi : digis) {
526  LogDebug("RPCTwinMuxRawToDigi") << "RPCDigi " << rpc_digi.first.rawId()
527  << ", " << rpc_digi.second.strip() << ", " << rpc_digi.second.bx();
528  if (rpc_digi.first != rpc_det_id) {
529  if (!local_digis.empty()) {
530  rpc_digi_collection->put(RPCDigiCollection::Range(local_digis.begin(), local_digis.end()), rpc_det_id);
531  local_digis.clear();
532  }
533  rpc_det_id = rpc_digi.first;
534  }
535  local_digis.push_back(rpc_digi.second);
536  }
537  if (!local_digis.empty()) {
538  rpc_digi_collection->put(RPCDigiCollection::Range(local_digis.begin(), local_digis.end()), rpc_det_id);
539  }
540 
541  event.put(std::move(rpc_digi_collection));
542 }
543 
545  , std::unique_ptr<RPCAMCLinkCounters>counters)
546 {
547  event.put(std::move(counters));
548 }
549 
#define LogDebug(id)
size
Write out results.
type
Definition: HCALResponse.h:21
static unsigned int const fed_amc13_amc_number_invalid_
T getParameter(std::string const &) const
unsigned int getStrip(unsigned int channel) const
static unsigned int const fed_trailer_crc_mismatch_
unsigned int getNAMC() const
static unsigned int const input_connector_not_used_
RPCLinkRecord getRPCLinkRecord(unsigned int link) const
static unsigned int const amc_payload_incomplete_
static unsigned int const amc_event_
JetCorrectorParameters::Record record
Definition: classes.h:7
std::uint64_t const * getRecord() const
static unsigned int const fed_header_check_fail_
bool processCDFHeaders(int fed, std::uint64_t const *&word, std::uint64_t const *&word_end, std::uint16_t &crc, RPCAMCLinkCounters &counters) const
void beginRun(edm::Run const &run, edm::EventSetup const &setup) override
static unsigned int const input_link_error_
#define DEFINE_FWK_MODULE(type)
Definition: MakerMacros.h:17
bool check() const
Check that the header is OK.
Definition: FEDHeader.cc:72
static unsigned int const input_lb_invalid_
uint16_t sourceID() const
Identifier of the FED.
Definition: FEDHeader.cc:32
def setup(process, global_tag, zero_tesla=False)
Definition: GeneralSetup.py:2
uint16_t crc() const
Cyclic Redundancy Code of the event fragment including header and trailer.
Definition: FEDTrailer.cc:22
int getBXOffset() const
bool check() const
Check that the trailer is OK.
Definition: FEDTrailer.cc:83
Definition: config.py:1
static unsigned int const amc_amc13_evc_bc_invalid_
bool processTwinMux(int fed, unsigned int amc_number, unsigned int size, std::uint64_t const *&word, std::uint64_t const *word_end, std::uint16_t &crc, RPCAMCLinkCounters &counters, std::set< std::pair< RPCDetId, RPCDigi > > &digis) const
unsigned int getAMCNumber() const
static unsigned int const fed_trailer_length_mismatch_
size_t size() const
Lenght of the data buffer in bytes.
Definition: FEDRawData.h:47
uint32_t fragmentLength() const
The length of the event fragment counted in 64-bit words including header and trailer.
Definition: FEDTrailer.cc:17
RPCTwinMuxRawToDigi(edm::ParameterSet const &config)
static unsigned int const amc_link_invalid_
unsigned int getBXCounter() const
void processRPCRecord(int fed, unsigned int amc_number, unsigned int bx_counter, rpctwinmux::RPCRecord const &record, RPCAMCLinkCounters &counters, std::set< std::pair< RPCDetId, RPCDigi > > &digis, int bx_min, int bx_max, unsigned int link, unsigned int link_max) const
void set(unsigned int word, std::uint64_t const record)
const FEDRawData & FEDData(int fedid) const
retrieve data for fed
unsigned int getType() const
unsigned int getAMCNumber() const
double amc
Definition: hdecay.h:20
edm::EDGetTokenT< FEDRawDataCollection > raw_token_
MuonDigiCollection< RPCDetId, RPCDigi > RPCDigiCollection
bool processBlock(int fed, std::uint64_t const *&word, std::uint64_t const *word_end, std::uint16_t &crc, RPCAMCLinkCounters &counters, std::set< std::pair< RPCDetId, RPCDigi > > &digis) const
bool processCDFTrailers(int fed, unsigned int nwords, std::uint64_t const *&word, std::uint64_t const *&word_end, std::uint16_t &crc, RPCAMCLinkCounters &counters) const
map_type & getMap()
Definition: RPCAMCLinkMap.h:28
T min(T a, T b)
Definition: MathUtil.h:58
ParameterDescriptionBase * add(U const &iLabel, T const &value)
static unsigned int const rpc_first_type_
map_type & getMap()
Definition: RPCLBLinkMap.h:28
static unsigned int const fed_header_id_mismatch_
static unsigned int const amc_number_mismatch_
static unsigned int const fed_amc13_block_incomplete_
static unsigned int const input_event_
void add(unsigned int event, RPCAMCLink const &link, unsigned int count=1)
static unsigned int const fed_event_
edm::ESWatcher< RPCTwinMuxLinkMapRcd > es_tm_link_map_watcher_
static unsigned int const rpc_second_type_
static unsigned int const input_link_ack_fail_
unsigned long long uint64_t
Definition: Time.h:15
void add(std::string const &label, ParameterSetDescription const &psetDescription)
unsigned short compute_crc_8bit(unsigned short crc, unsigned char data)
Definition: CRC16.h:79
bool check(const edm::EventSetup &iSetup)
Definition: ESWatcher.h:57
bool hasRPCBXWindow() const
unsigned int getSize() const
char data[epos_bytes_allocation]
Definition: EPOS_Wrapper.h:82
static void fillDescriptions(edm::ConfigurationDescriptions &descs)
T get() const
Definition: EventSetup.h:62
void produce(edm::Event &event, edm::EventSetup const &setup) override
const unsigned char * data() const
Return a const pointer to the beginning of the data buffer.
Definition: FEDRawData.cc:28
std::vector< int > feds_
std::pair< const_iterator, const_iterator > Range
void putCounters(edm::Event &event, std::unique_ptr< RPCAMCLinkCounters > counters)
static void compute_crc_64bit(std::uint16_t &crc, std::uint64_t const &word)
edm::ESHandle< RPCLBLinkMap > es_lb_link_map_
Definition: AMCSpec.h:8
edm::ESHandle< RPCAMCLinkMap > es_tm_link_map_
static unsigned int const fed_trailer_check_fail_
def move(src, dest)
Definition: eostools.py:511
RPCDetId getRPCDetId() const
void putRPCDigis(edm::Event &event, std::set< std::pair< RPCDetId, RPCDigi > > const &digis)
Definition: event.py:1
Definition: Run.h:44
static unsigned int const input_eod_
static unsigned int const input_connector_invalid_