Go to the documentation of this file.00001 #ifndef DQM_SiStripMonitorHardware_SiStripSpyDigiConverter_H
00002 #define DQM_SiStripMonitorHardware_SiStripSpyDigiConverter_H
00003
00004 #include "boost/cstdint.hpp"
00005 #include <memory>
00006 #include <vector>
00007
00008 #include "DataFormats/Common/interface/DetSetVector.h"
00009 #include "DataFormats/SiStripDigi/interface/SiStripRawDigi.h"
00010
00011 #include "DQM/SiStripMonitorHardware/interface/SiStripSpyUtilities.h"
00012
00013
00014 class SiStripFedCabling;
00015
00016 namespace sistrip {
00017
00025 class SpyDigiConverter
00026 {
00027 public:
00028 typedef edm::DetSetVector<SiStripRawDigi> DSVRawDigis;
00029
00030
00031 SpyDigiConverter() {}
00032 ~SpyDigiConverter() {}
00033
00039 static std::auto_ptr<DSVRawDigis> extractPayloadDigis(const DSVRawDigis * inputScopeDigis,
00040 std::vector<uint32_t> * pAPVAddresses,
00041 const bool discardDigisWithAPVAddrErr,
00042 const sistrip::SpyUtilities::FrameQuality & aQuality,
00043 const uint16_t expectedPos);
00044
00045
00046 static std::auto_ptr<DSVRawDigis> reorderDigis(const DSVRawDigis* inputPayloadDigis);
00047
00048
00049 static std::auto_ptr<DSVRawDigis> mergeModuleChannels(const DSVRawDigis* inputPhysicalOrderChannelDigis, const SiStripFedCabling& cabling);
00050
00051
00052 private:
00053 typedef DSVRawDigis::detset DetSetRawDigis;
00054
00055 static void processFED(const uint16_t aPreviousFedId,
00056 const bool discardDigisWithAPVAddrErr,
00057 std::vector<uint32_t> * pAPVAddresses,
00058 std::vector<DetSetRawDigis> & outputData,
00059 std::vector<uint16_t> & aAddrVec,
00060 std::vector<uint16_t> & aHeaderBitVec,
00061 std::vector<DSVRawDigis::const_iterator> & aFedScopeDigis
00062 );
00063
00064 };
00065
00066 }
00067
00068 #endif // DQM_SiStripMonitorHardware_SiStripSpyDigiConverter_H