98 msg(MSG::DEBUG) <<
" ALFA_RoDDecoder_charge::fillCollection" <<
endmsg;
102 uint32_t wordPos = 0;
104 std::vector<uint32_t> VData;
110uint32_t Event_num_max=0;
113uint16_t tmpCharge=10;
161 robFrag->rod_data(vint);
164 uint32_t size = robFrag->rod_ndata();
167 uint32_t ROD_source_ID = robFrag->rod_source_id();
170 uint32_t ROD_LVL1_ID = robFrag->rod_lvl1_id();
172msg(MSG::DEBUG) <<
"============================" << std::endl;
173msg(MSG::DEBUG) <<
"Frag Size : " << robFrag->rod_fragment_size_word() <<
endmsg;
174msg(MSG::DEBUG) <<
"Header Size: " << robFrag->rod_header_size_word() <<
endmsg;
175msg(MSG::DEBUG) <<
"Source ID : " << ROD_source_ID <<
endmsg;
176msg(MSG::DEBUG) <<
"Run num : " << robFrag->rod_run_no() <<
endmsg;
177msg(MSG::DEBUG) <<
"Version : " << robFrag->rod_version() <<
endmsg;
178msg(MSG::DEBUG) <<
" ROD_LVL1_ID " <<ROD_LVL1_ID<<
endmsg;
179msg(MSG::DEBUG) <<
"============================" << std::endl;
182uint32_t evt_Id = ((robFrag->rod_lvl1_id()) & 0xFF000000) >> 24;
183uint32_t lvl1_Id = ((robFrag->rod_lvl1_id()) & 0x00FFFFFF) ;
186msg(MSG::DEBUG) <<
" evt_Id : " << evt_Id <<
" lvl1_Id : " << lvl1_Id <<
endmsg;
211 if (n==0) Event_num = LvL1;
212 else Event_num = ((robFrag->rod_lvl1_id()) & 0x00FFFFFF) + Event_num;
214 LvL1 = ((robFrag->rod_lvl1_id()) & 0x00FFFFFF)+1 ;
215 EcrId = ((robFrag->rod_lvl1_id()) & 0xFF000000) >> 24;
217 if(l==1) Event_num_max=Event_num;
219 Event_num = ((robFrag->rod_lvl1_id()) & 0x00FFFFFF)+1 + Event_num_max;
224 msg(MSG::INFO) <<
" Event_num " << Event_num <<
" Count_evt " << Count_evt <<
endmsg;
231 msg(MSG::DEBUG) <<
" Found the beginning of buffer "<<
endmsg;
235 msg(MSG::DEBUG) <<
" Beginning of block not found BOB "<<
endmsg;
248 msg(MSG::ERROR)<<
" Error: data corrupted" <<
endmsg;
249 return StatusCode::FAILURE;
257 msg(MSG::DEBUG) <<
" Found the beginning of Link BOL"<<
endmsg;
264 msg(MSG::DEBUG)<<
" Error: collection not found " <<
endmsg;
265 return StatusCode::FAILURE;
270 if (wordPos >= size) {
271 msg(MSG::ERROR)<<
" Error: data corrupted"<<
endmsg;
272 return StatusCode::FAILURE;
283 msg(MSG::DEBUG)<<
" Decoding data from Slot Id number : " << slotIdNum <<
endmsg;
293 msg(MSG::DEBUG)<<
" Error: data corrupted" <<
endmsg;
294 return StatusCode::FAILURE;
300 uint16_t ChannelIdNum;
319 for (
unsigned int i=0;i<8;i++){
321 charge_hit = (char) tmpCharge & 0x00000001;
327 if(CountPMF0==1) collection =
getCollection(MBIdNum,rdoCont );
330 if(CountPMF0==1)
msg(MSG::DEBUG)<<
" DECODER : MBIdNum " << MBIdNum <<
endmsg;
351 auto rawData_charge = std::make_unique< ALFA_RawData_charge >(PMFIdNum);
353 rawData_charge->SetChannelNum_PMF(ChannelIdNum);
354 rawData_charge->SetPMFId_PMF(PMFIdNum);
355 rawData_charge->SetMBId_PMF(MBIdNum);
356 rawData_charge->SetChargeChan_PMF(ChargeNum);
359 msg(MSG::DEBUG)<<
" PMFIdNum = " << PMFIdNum <<
" ChannelIdNum = " << ChannelIdNum <<
" chargeNum = " << ChargeNum <<
endmsg;
361 std::vector<uint16_t> ChargeHitId;
362 ChargeHitId.push_back(ChargeNum);
363 rawData_charge->SetChargeChanVect_PMF(ChargeHitId);
365 rawData_charge->addData(vint[wordPos]);
366 rawData_charge->PushBack_PMF(ChargeNum);
368 if(collection) collection->
push_back(rawData_charge.release());
393 if (wordPos >= size) {
394 msg(MSG::DEBUG)<<
" Error: data corrupted" <<
endmsg;
395 return StatusCode::FAILURE;
407 msg(MSG::DEBUG)<<
" Error: data corrupted" <<
endmsg;
408 return StatusCode::FAILURE;
416const eformat::FullEventFragment<const uint32_t*> *
event =
m_robDataProvider->getEvent(Gaudi::Hive::currentContext());
418msg(MSG::DEBUG) <<
"========FULL Event=============" << std::endl;
419msg(MSG::DEBUG) <<
"Event time (sec): " << (uint32_t)event->bc_time_seconds() << std::endl;
420msg(MSG::DEBUG) <<
"Event time (ns): " << (uint32_t)event->bc_time_nanoseconds() << std::endl;
421msg(MSG::DEBUG) <<
"Global ID: " << (uint32_t)event->global_id() << std::endl;
422msg(MSG::DEBUG) <<
"Run Type: " << (uint32_t)event->run_type() << std::endl;
423msg(MSG::DEBUG) <<
"Run Number: " << (uint32_t)event->run_no() << std::endl;
424msg(MSG::DEBUG) <<
"Lumi Block: " << (uint32_t)event->lumi_block() << std::endl;
425msg(MSG::DEBUG) <<
"Level1 ID: " << (uint32_t)event->lvl1_id() << std::endl;
426msg(MSG::DEBUG) <<
"BCID: " << (uint32_t)event->bc_id() << std::endl;
427msg(MSG::DEBUG) <<
"Level1 trig type: " << (uint32_t)event->lvl1_trigger_type() << std::endl;
428msg(MSG::DEBUG) <<
"Level1 Nwords: " << (uint32_t)event->nlvl1_trigger_info() << std::endl;
429msg(MSG::DEBUG) <<
"============================" << std::endl;
431uint32_t Time_StampID =
event->bc_time_seconds();
432uint32_t BC_ID =
event->bc_id();
447 msg(MSG::DEBUG) <<
" Found the end of block EOB ---------------------- "<<
endmsg;
454 return StatusCode::SUCCESS;