File indexing completed on 2024-04-06 12:10:45
0001 #ifndef EventFilter_L1GlobalTriggerRawToDigi_L1GlobalTriggerEvmRawToDigi_h
0002 #define EventFilter_L1GlobalTriggerRawToDigi_L1GlobalTriggerEvmRawToDigi_h
0003
0004
0005
0006
0007
0008
0009
0010
0011
0012
0013
0014
0015
0016
0017
0018
0019 #include <memory>
0020 #include <iostream>
0021
0022
0023 #include "FWCore/Framework/interface/Frameworkfwd.h"
0024 #include "FWCore/Framework/interface/stream/EDProducer.h"
0025
0026 #include "FWCore/Framework/interface/Event.h"
0027 #include "FWCore/Framework/interface/MakerMacros.h"
0028
0029 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0030 #include "FWCore/Utilities/interface/InputTag.h"
0031 #include "FWCore/Utilities/interface/typedefs.h"
0032 #include "FWCore/Utilities/interface/ESGetToken.h"
0033
0034 #include "CondFormats/L1TObjects/interface/L1GtBoardMaps.h"
0035 #include "CondFormats/DataRecord/interface/L1GtBoardMapsRcd.h"
0036 #include "CondFormats/L1TObjects/interface/L1GtParameters.h"
0037 #include "CondFormats/DataRecord/interface/L1GtParametersRcd.h"
0038
0039
0040 class L1GtfeWord;
0041 class L1GtfeExtWord;
0042 class L1TcsWord;
0043 class L1GtFdlWord;
0044
0045 class FEDHeader;
0046 class FEDTrailer;
0047
0048
0049 class L1GlobalTriggerEvmRawToDigi : public edm::stream::EDProducer<> {
0050 public:
0051
0052 explicit L1GlobalTriggerEvmRawToDigi(const edm::ParameterSet&);
0053
0054
0055 ~L1GlobalTriggerEvmRawToDigi() override;
0056
0057 private:
0058 void produce(edm::Event&, const edm::EventSetup&) override;
0059
0060
0061
0062
0063 void unpackHeader(const unsigned char*, FEDHeader&);
0064
0065
0066 void unpackTrailer(const unsigned char*, FEDTrailer&);
0067
0068
0069 void produceEmptyProducts(edm::Event&);
0070
0071
0072 void dumpFedRawData(const unsigned char*, int, std::ostream&);
0073
0074 private:
0075 L1GtfeExtWord* m_gtfeWord;
0076 L1TcsWord* m_tcsWord;
0077 L1GtFdlWord* m_gtFdlWord;
0078
0079
0080 edm::InputTag m_evmGtInputTag;
0081
0082
0083
0084 int m_evmGtFedId;
0085
0086
0087 const edm::ESGetToken<L1GtBoardMaps, L1GtBoardMapsRcd> m_l1GtBMToken;
0088
0089
0090 edm::ESGetToken<L1GtParameters, L1GtParametersRcd> m_l1GtParamToken;
0091
0092
0093 cms_uint16_t m_activeBoardsMaskGt;
0094
0095
0096 int m_unpackBxInEvent;
0097
0098
0099
0100 int m_lowSkipBxInEvent;
0101
0102
0103
0104 int m_uppSkipBxInEvent;
0105
0106
0107
0108
0109 int m_recordLength0;
0110
0111
0112 int m_recordLength1;
0113
0114
0115 int m_totalBxInEvent;
0116
0117
0118 int m_bstLengthBytes;
0119
0120 private:
0121
0122 int m_verbosity;
0123 bool m_isDebugEnabled;
0124 };
0125
0126 #endif