6 #ifndef QC_MODULE_MUONCHAMBERS_DATA_DECODER_H 7 #define QC_MODULE_MUONCHAMBERS_DATA_DECODER_H 10 #include "MCH/sampa_header.h" 11 #include "MCH/Mapping.h" 12 #include "MCHBase/Digit.h" 18 namespace quality_control_modules
20 namespace muonchambers
23 enum DualSampaStatus {
35 uint8_t cru_id, fee_id, data_path, link_id, ds_addr, chan_addr;
38 std::vector<uint16_t> samples;
46 DualSampaStatus status;
49 uint64_t powerMultiplier;
53 int32_t csize, ctime, cid, sample;
60 double pedestal[2][32], noise[2][32];
61 int32_t min[2][32], max[2][32], delta[2][32];
81 void processData(
const char* buf,
size_t size);
82 void decodeRaw(uint32_t* payload_buf,
size_t nGBTwords,
int cru_id,
int link_id);
83 void decodeUL(uint32_t* payload_buf,
size_t nWords,
int cru_id,
int dpw_id);
86 std::vector<SampaHit>& getHits() {
return mHits; }
87 std::vector<o2::mch::Digit>& getDigits() {
return mDigits; }
90 int32_t getMapCRU(
int cruid,
int linkid)
92 return mMapCRU.getLink(cruid, linkid);
95 bool getMapCRUInv(int32_t link_id, int32_t& cruid, int32_t& crulink)
97 return mMapCRU.getLinkInv(link_id, cruid, crulink);
100 int32_t getMapFEC(uint32_t link_id, uint32_t ds_addr, uint32_t& de, uint32_t& dsid)
102 if (!mMapFEC.getDSMapping(link_id, ds_addr, de, dsid))
107 int32_t getMapFECinv(uint32_t de, uint32_t dsid, uint32_t& link_id, uint32_t& ds_addr)
109 if (!mMapFEC.getDSMappingInv(de, dsid, link_id, ds_addr))
114 MapFEC& getMapFEC() {
return mMapFEC; }
120 int ds_enable[MCH_MAX_CRU_IN_FLP][24][40];
121 std::vector<SampaHit> mHits;
122 std::vector<o2::mch::Digit> mDigits;
132 #endif // QC_MODULE_MUONCHAMBERS_DATA_DECODER_H Definition: Decoding.h:44
Definition: Mapping.h:100
Definition: Decoding.h:34
These methods can be used to build a complex processing topology. It spawns 3 separate dummy processi...
Definition: Activity.h:19
decoding of MCH data
Definition: Decoding.h:71
Definition: Decoding.h:65