File indexing completed on 2024-04-06 12:10:39
0001 #ifndef ESDATAFORMATTERV1_1_H
0002 #define ESDATAFORMATTERV1_1_H
0003
0004 #include <iostream>
0005 #include <vector>
0006 #include <bitset>
0007 #include <sstream>
0008 #include <map>
0009
0010 #include "DataFormats/EcalDigi/interface/EcalDigiCollections.h"
0011 #include "DataFormats/EcalDigi/interface/ESDataFrame.h"
0012 #include "DataFormats/FEDRawData/interface/FEDRawDataCollection.h"
0013 #include "DataFormats/FEDRawData/interface/FEDRawData.h"
0014 #include "FWCore/ParameterSet/interface/ParameterSet.h"
0015
0016 #include "EventFilter/ESDigiToRaw/interface/ESDataFormatter.h"
0017
0018 class ESDigiToRaw;
0019
0020 class ESDataFormatterV1_1 : public ESDataFormatter {
0021 public:
0022 typedef ESDataFormatter::DetDigis DetDigis;
0023 typedef ESDataFormatter::Digis Digis;
0024
0025 typedef ESDataFormatter::Word8 Word8;
0026 typedef ESDataFormatter::Word16 Word16;
0027 typedef ESDataFormatter::Word32 Word32;
0028 typedef ESDataFormatter::Word64 Word64;
0029
0030 ESDataFormatterV1_1(const edm::ParameterSet& ps);
0031 ~ESDataFormatterV1_1() override;
0032
0033 void DigiToRaw(int fedId, Digis& digis, FEDRawData& fedRawData, const Meta_Data& meta_data) const override;
0034
0035 private:
0036 protected:
0037 static const int bDHEAD, bDH, bDEL, bDERR, bDRUN, bDRUNTYPE, bDTRGTYPE, bDCOMFLAG, bDORBIT;
0038 static const int bDVMINOR, bDVMAJOR, bDCH, bDOPTO;
0039 static const int sDHEAD, sDH, sDEL, sDERR, sDRUN, sDRUNTYPE, sDTRGTYPE, sDCOMFLAG, sDORBIT;
0040 static const int sDVMINOR, sDVMAJOR, sDCH, sDOPTO;
0041 static const int bKEC, bKFLAG2, bKBC, bKFLAG1, bKET, bKCRC, bKCE, bKID, bFIBER, bKHEAD1, bKHEAD2;
0042 static const int sKEC, sKFLAG2, sKBC, sKFLAG1, sKET, sKCRC, sKCE, sKID, sFIBER, sKHEAD1, sKHEAD2;
0043 static const int bHEAD, bE1, bE0, bSTRIP, bPACE, bADC2, bADC1, bADC0;
0044 static const int sHEAD, sE1, sE0, sSTRIP, sPACE, sADC2, sADC1, sADC0;
0045 };
0046
0047 #endif