11 #ifndef EventFilter_HGCalRawToDigi_HGCalUnpacker_h 12 #define EventFilter_HGCalRawToDigi_HGCalUnpacker_h 86 void parseSLink(
const std::vector<uint32_t>& inputArray,
87 const std::function<uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)>& enabledERXMapping,
94 const std::vector<uint32_t>& inputArray,
95 const std::function<uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)>& enabledERXMapping,
101 void parseECOND(
const std::vector<uint32_t>& inputArray,
102 const std::function<uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)>& enabledERXMapping,
114 const uint32_t
erxBodyLeftShift_[16] = {2, 0, 2, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
115 const uint32_t
erxBodyRightShift_[16] = {0, 8, 0, 8, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0};
117 0b00000000000011111111110000000000,
118 0b00111111111111111111110000000000,
119 0b00000000000011111111111111111111,
120 0b00111111111111111111111111111111,
121 0b00111111111111111111111111111111,
122 0b00111111111111111111111111111111,
123 0b00111111111111111111111111111111,
124 0b11111111111111111111111111111111,
125 0b11111111111111111111111111111111,
126 0b11111111111111111111111111111111,
127 0b11111111111111111111111111111111,
128 0b11111111111111111111111111111111,
129 0b11111111111111111111111111111111,
130 0b11111111111111111111111111111111,
131 0b11111111111111111111111111111111};
132 const uint32_t
erxBodyBits_[16] = {24, 16, 24, 24, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32, 32};
const uint32_t erxBodyLeftShift_[16]
const std::vector< HGCROCChannelDataFrame< D > > & channelData() const
uint32_t channelMax
maximum number of channels unpacked
void parseSLink(const std::vector< uint32_t > &inputArray, const std::function< uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)> &enabledERXMapping, const std::function< D(HGCalElectronicsId elecID)> &logicalMapping)
const uint32_t erxBodyMask_[16]
std::vector< uint32_t > commonModeIndex_
Array for logicalMapping between unpacked channels to first common mode.
const uint32_t erxBodyRightShift_[16]
uint32_t sLinkCaptureBlockMax
maximum number of capture blocks in one S-Link
size_t channelDataSize_
Size of unpacked channels.
This class is designed to unpack raw data from HGCal, formatted as S-Links, capture blocks...
uint32_t erxChannelMax
maximum number of channels in one eRx
uint32_t payloadLengthMax
maximum length of payload length
uint32_t captureBlockECONDMax
maximum number of ECON-Ds in one capture block
uint32_t econdHeaderMarker
ECON-D header Marker pattern.
std::vector< HGCROCChannelDataFrame< D > > channelData_
Array for unpacked channels.
void parseECOND(const std::vector< uint32_t > &inputArray, const std::function< uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)> &enabledERXMapping, const std::function< D(HGCalElectronicsId elecID)> &logicalMapping)
size_t commonModeDataSize_
Size of unpacked common modes.
wrapper for a 32b data word identifying a readout channel in the raw data The format is the following...
uint32_t econdERXMax
maximum number of eRxs in one ECON-D
const std::vector< uint16_t > & commonModeData() const
const std::vector< uint32_t > & badECOND() const
const std::vector< uint32_t > & commonModeIndex() const
DecomposeProduct< arg, typename Div::arg > D
uint32_t commonModeMax
maximum number of common modes unpacked
uint32_t captureBlockReserved
Capture block reserved pattern.
HGCalUnpackerConfig config_
uint32_t sLinkBOE
S-Link BOE pattern.
HGCalUnpacker(HGCalUnpackerConfig config)
std::vector< uint32_t > badECOND_
Array of indices of bad ECON-Ds.
void parseCaptureBlock(const std::vector< uint32_t > &inputArray, const std::function< uint16_t(uint16_t sLink, uint8_t captureBlock, uint8_t econd)> &enabledERXMapping, const std::function< D(HGCalElectronicsId elecID)> &logicalMapping)
const uint32_t erxBodyBits_[16]
std::vector< uint16_t > commonModeData_
Array for unpacked common modes.