CMS 3D CMS Logo

RPCTwinMuxRawToDigi.h
Go to the documentation of this file.
1 #ifndef EventFilter_RPCRawToDigi_RPCTwinMuxRawToDigi_h
2 #define EventFilter_RPCRawToDigi_RPCTwinMuxRawToDigi_h
3 
4 #include <cstdint>
5 #include <vector>
6 #include <utility>
7 #include <set>
8 
12 
19 
21 
22 namespace edm {
24  class Event;
25  class EventSetup;
26  class ParameterSet;
27  class Run;
28 } // namespace edm
29 
31 public:
33  ~RPCTwinMuxRawToDigi() override;
34 
35  static void compute_crc_64bit(std::uint16_t& crc, std::uint64_t const& word);
36 
38 
39  void beginRun(edm::Run const& run, edm::EventSetup const& setup) override;
40  void produce(edm::Event& event, edm::EventSetup const& setup) override;
41 
42 protected:
43  bool processCDFHeaders(int fed,
44  std::uint64_t const*& word,
45  std::uint64_t const*& word_end,
46  std::uint16_t& crc,
47  RPCAMCLinkCounters& counters) const;
48  bool processCDFTrailers(int fed,
49  unsigned int nwords,
50  std::uint64_t const*& word,
51  std::uint64_t const*& word_end,
52  std::uint16_t& crc,
53  RPCAMCLinkCounters& counters) const;
54  bool processBlock(int fed,
55  std::uint64_t const*& word,
56  std::uint64_t const* word_end,
57  std::uint16_t& crc,
58  RPCAMCLinkCounters& counters,
59  std::set<std::pair<RPCDetId, RPCDigi> >& digis) const;
60  bool processTwinMux(int fed,
61  unsigned int amc_number,
62  unsigned int size,
63  std::uint64_t const*& word,
64  std::uint64_t const* word_end,
65  std::uint16_t& crc,
66  RPCAMCLinkCounters& counters,
67  std::set<std::pair<RPCDetId, RPCDigi> >& digis) const;
68  void processRPCRecord(int fed,
69  unsigned int amc_number,
70  unsigned int bx_counter,
72  RPCAMCLinkCounters& counters,
73  std::set<std::pair<RPCDetId, RPCDigi> >& digis,
74  int bx_min,
75  int bx_max,
76  unsigned int link,
77  unsigned int link_max) const;
78  void putRPCDigis(edm::Event& event, std::set<std::pair<RPCDetId, RPCDigi> > const& digis);
79  void putCounters(edm::Event& event, std::unique_ptr<RPCAMCLinkCounters> counters);
80 
81 protected:
83 
86 
88  std::vector<int> feds_;
91 };
92 
93 #endif // EventFilter_RPCRawToDigi_RPCTwinMuxRawToDigi_h
RPCTwinMuxRawToDigi::processBlock
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
Definition: RPCTwinMuxRawToDigi.cc:214
RPCTwinMuxRawToDigi::processTwinMux
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
Definition: RPCTwinMuxRawToDigi.cc:273
RPCTwinMuxRawToDigi
Definition: RPCTwinMuxRawToDigi.h:30
MainPageGenerator.link
link
Definition: MainPageGenerator.py:271
edm::ESWatcher< RPCTwinMuxLinkMapRcd >
ESHandle.h
RPCTwinMuxRawToDigi::produce
void produce(edm::Event &event, edm::EventSetup const &setup) override
Definition: RPCTwinMuxRawToDigi.cc:67
edm::Run
Definition: Run.h:45
edm::EDGetTokenT< FEDRawDataCollection >
edm
HLT enums.
Definition: AlignableModifier.h:19
GlobalPosition_Frontier_DevDB_cff.record
record
Definition: GlobalPosition_Frontier_DevDB_cff.py:10
EDProducer.h
RPCTwinMuxRawToDigi::bx_max_
int bx_max_
Definition: RPCTwinMuxRawToDigi.h:85
RPCTwinMuxRawToDigi::fillDescriptions
static void fillDescriptions(edm::ConfigurationDescriptions &descs)
Definition: RPCTwinMuxRawToDigi.cc:46
RPCTwinMuxRawToDigi::processRPCRecord
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
Definition: RPCTwinMuxRawToDigi.cc:389
singleTopDQM_cfi.setup
setup
Definition: singleTopDQM_cfi.py:37
RPCTwinMuxRawToDigi::putRPCDigis
void putRPCDigis(edm::Event &event, std::set< std::pair< RPCDetId, RPCDigi > > const &digis)
Definition: RPCTwinMuxRawToDigi.cc:507
RPCTwinMuxRecord.h
word
uint64_t word
Definition: CTPPSTotemDataFormatter.cc:29
RPCAMCLinkMap.h
RPCTwinMuxRawToDigi::processCDFTrailers
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
Definition: RPCTwinMuxRawToDigi.cc:175
config
Definition: config.py:1
RPCTwinMuxRawToDigi::putCounters
void putCounters(edm::Event &event, std::unique_ptr< RPCAMCLinkCounters > counters)
Definition: RPCTwinMuxRawToDigi.cc:530
RPCTwinMuxLinkMapRcd.h
RPCLBLinkMap.h
RPCTwinMuxRawToDigi::~RPCTwinMuxRawToDigi
~RPCTwinMuxRawToDigi() override
Definition: RPCTwinMuxRawToDigi.cc:36
RPCTwinMuxRawToDigi::feds_
std::vector< int > feds_
Definition: RPCTwinMuxRawToDigi.h:88
RPCTwinMuxRawToDigi::RPCTwinMuxRawToDigi
RPCTwinMuxRawToDigi(edm::ParameterSet const &config)
Definition: RPCTwinMuxRawToDigi.cc:24
edm::ESHandle< RPCAMCLinkMap >
Event
RPCDigi.h
edm::ConfigurationDescriptions
Definition: ConfigurationDescriptions.h:28
edm::ParameterSet
Definition: ParameterSet.h:36
ParameterSet
Definition: Functions.h:16
RPCTwinMuxRawToDigi::processCDFHeaders
bool processCDFHeaders(int fed, std::uint64_t const *&word, std::uint64_t const *&word_end, std::uint16_t &crc, RPCAMCLinkCounters &counters) const
Definition: RPCTwinMuxRawToDigi.cc:137
RPCTwinMuxRawToDigi::es_tm_link_map_
edm::ESHandle< RPCAMCLinkMap > es_tm_link_map_
Definition: RPCTwinMuxRawToDigi.h:89
FEDRawDataCollection.h
edm::stream::EDProducer
Definition: EDProducer.h:38
edm::EventSetup
Definition: EventSetup.h:57
rpctwinmux::RPCRecord
Definition: RPCTwinMuxRecord.h:352
RPCAMCLinkCounters.h
RPCTwinMuxRawToDigi::fill_counters_
bool fill_counters_
Definition: RPCTwinMuxRawToDigi.h:84
RPCTwinMuxRawToDigi::es_tm_link_map_watcher_
edm::ESWatcher< RPCTwinMuxLinkMapRcd > es_tm_link_map_watcher_
Definition: RPCTwinMuxRawToDigi.h:87
writedatasetfile.run
run
Definition: writedatasetfile.py:27
ConfigurationDescriptions
ESWatcher.h
RPCTwinMuxRawToDigi::bx_min_
int bx_min_
Definition: RPCTwinMuxRawToDigi.h:85
RPCTwinMuxRawToDigi::raw_token_
edm::EDGetTokenT< FEDRawDataCollection > raw_token_
Definition: RPCTwinMuxRawToDigi.h:82
RPCTwinMuxRawToDigi::compute_crc_64bit
static void compute_crc_64bit(std::uint16_t &crc, std::uint64_t const &word)
Definition: RPCTwinMuxRawToDigi.cc:38
RPCTwinMuxRawToDigi::es_lb_link_map_
edm::ESHandle< RPCLBLinkMap > es_lb_link_map_
Definition: RPCTwinMuxRawToDigi.h:90
cond::uint64_t
unsigned long long uint64_t
Definition: Time.h:13
RPCTwinMuxRawToDigi::beginRun
void beginRun(edm::Run const &run, edm::EventSetup const &setup) override
Definition: RPCTwinMuxRawToDigi.cc:56
EventSetup
event
Definition: event.py:1
edm::Event
Definition: Event.h:73
RPCTwinMuxRawToDigi::calculate_crc_
bool calculate_crc_
Definition: RPCTwinMuxRawToDigi.h:84
RPCAMCLinkCounters
Definition: RPCAMCLinkCounters.h:9
findQualityFiles.size
size
Write out results.
Definition: findQualityFiles.py:443
Run