Back to home page

Project CMSSW displayed by LXR

 
 

    


File indexing completed on 2024-04-06 12:10:44

0001 #ifndef EventFilter_HGCalRawToDigi_SlinkTypes_h
0002 #define EventFilter_HGCalRawToDigi_SlinkTypes_h
0003 
0004 #include <cstdint>
0005 #include <map>
0006 #include <tuple>
0007 #include <vector>
0008 
0009 #include "EventFilter/HGCalRawToDigi/interface/HGCalRawDataDefinitions.h"
0010 
0011 namespace hgcal::econd {
0012 
0013   /// Event index (L1A/BX/orbit)
0014   typedef std::tuple<uint32_t, uint32_t, uint32_t> EventId;
0015 
0016   /// chip/half
0017   typedef std::pair<uint8_t, uint8_t> ERxId_t;
0018 
0019   /// parsed e-rx data
0020   struct ERxData {
0021     uint32_t cm0{0}, cm1{0};
0022     std::vector<ToTStatus> tctp;
0023     std::vector<uint16_t> adc, adcm, toa, tot;
0024     std::vector<uint32_t> meta;  ///< additional words accompanying the e-rx data
0025     uint32_t crc32{0};
0026   };
0027 
0028   /// eRx data maps
0029   typedef std::map<ERxId_t, ERxData> ERxInput;
0030 
0031   /// ECON-D inputs for a given event
0032   typedef std::pair<EventId, ERxInput> ECONDInput;
0033 
0034   /// collection of ECON-D inputs
0035   typedef std::map<EventId, ERxInput> ECONDInputColl;
0036 
0037   /// list of channels enabled in eRx
0038   typedef std::vector<bool> ERxChannelEnable;
0039 }  // namespace hgcal::econd
0040 
0041 #endif