6 #include "GaudiKernel/ServiceHandle.h"
12 m_onlineHelper(nullptr),
22 return (StatusCode::SUCCESS);
31 const std::vector<unsigned>&
Pattern,
const std::vector<unsigned>& DAC,
const std::vector<unsigned>& Delay)
38 for (
unsigned i=0;
i<
DAC.size();
i++)
40 for (
unsigned i=0;
i<
Delay.size();
i++)
50 const std::vector<unsigned>& DAC,
const std::vector<unsigned>& Delay)
56 for (
unsigned i=0;
i<
DAC.size();
i++)
58 for (
unsigned i=0;
i<
Delay.size();
i++)
77 unsigned iPattern=(
event/PatternStepSize)%(
m_Pattern.size()/4);
79 const unsigned nWord=lineNumber>>5;
81 const unsigned nBit=lineNumber&0x1f;
88 const unsigned DelayStepSize=m_nTrigger*m_Pattern.size()/4;
89 const unsigned iDelay=(
event/DelayStepSize)%m_Delay.size();
90 return m_Delay[iDelay];
96 const unsigned DACStepSize=m_nTrigger*m_Delay.size()*m_Pattern.size()/4;
97 const unsigned iDAC=
event/DACStepSize;
98 if (iDAC<m_DAC.size()) {
104 log << MSG::ERROR <<
"Event #" <<
event <<
": DAC index out of range! ("
105 << iDAC <<
"max=" << m_DAC.size() <<
"). Return kmaxDAC" <<
endmsg;
119 log << MSG::ERROR <<
"LArOnlineID not defined! Can't determine Delay value." <<
endmsg;
123 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
127 return map_it->second.Delay(
event);
138 log << MSG::ERROR <<
"LArOnlineID not defined! Can't determine DAC value." <<
endmsg;
142 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
146 return map_it->second.DAC(
event);
156 log << MSG::ERROR <<
"LArOnlineID not defined! Can't determine isPulsed value." <<
endmsg;
164 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
169 return map_it->second.isPulsed(
event,
line);
177 const unsigned nConfig=
m_mCalibBoards.begin()->second.m_DAC.size()*
182 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
186 const unsigned nConfig=map_it->second.m_DAC.size()*
187 map_it->second.m_Delay.size()*map_it->second.m_Pattern.size()/4;
200 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
204 return map_it->second.m_nTrigger;
221 const unsigned nPatt =
m_mCalibBoards.begin()->second.m_Pattern.size()/4;
225 const std::map<HWIdentifier, CalibBoard>::const_iterator map_it=
m_mCalibBoards.find(calibModuleID);
229 const unsigned nPatt = map_it->second.m_Pattern.size()/4;