7#include "FairDetParIo.h"
9#include "FairParamList.h"
19 : FairParGenericSet(name, title, context)
26 , fnFebsIdsArrayGemA()
27 , fnFebsIdsArrayGemB()
33 , fChannelsToPadXRpc()
34 , fChannelsToPadYRpc()
86 if (!l)
return kFALSE;
88 if (!l->fill(
"NrOfDpbs", &
fuNrOfDpbs))
return kFALSE;
91 if (!l->fill(
"DbpIdArray", &
fiDbpIdArray))
return kFALSE;
96 if (!l->fill(
"NrOfFebsInGemA", &
fuFebsInGemA))
return kFALSE;
101 if (!l->fill(
"NrOfFebsInGemB", &
fuFebsInGemB))
return kFALSE;
106 if (!l->fill(
"NrOfFebsInRpc", &
fuFebsInRpc))
return kFALSE;
130 if (!l->fill(
"RealX", &
fRealX))
return kFALSE;
143 LOG(warning) <<
"CbmMcbm2018MuchPar::ElinkIdxToFebIdx => Index out of bound, "
144 <<
"returning crazy value!";
153 LOG(warning) <<
"CbmMcbm2018MuchPar::ElinkIdxToAsicIdxFebMuch => Index out of bound, "
154 <<
"returning crazy value!";
163 LOG(warning) <<
"CbmMcbm2018MuchPar::GetDpbId => Index out of bound, "
164 <<
"returning crazy value!";
173 LOG(warning) <<
"CbmMcbm2018MuchPar::IsCrobActive => Crob Index out of bound, "
174 <<
"returning default inactive!";
179 LOG(warning) <<
"CbmMcbm2018MuchPar::IsCrobActive => Dpb Index out of bound, "
180 <<
"returning default inactive!";
192 LOG(warning) <<
"CbmMcbm2018MuchPar::IsFebActive => Feb Index out of bound, "
193 <<
"returning default inactive!";
206 LOG(warning) <<
"CbmMcbm2018MuchPar::IsFebActive => Feb Index out of bound, "
207 <<
"returning default inactive!";
212 LOG(warning) <<
"CbmMcbm2018MuchPar::IsFebActive => Crob Index out of bound, "
213 <<
"returning default inactive!";
218 LOG(warning) <<
"CbmMcbm2018MuchPar::IsFebActive => Dpb Index out of bound, "
219 <<
"returning default inactive!";
226 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadXA => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
227 <<
" VS " <<
fChannelsToPadXA.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
237 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadYA => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
238 <<
" VS " <<
fChannelsToPadYA.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
248 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadXB => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
249 <<
" VS " <<
fChannelsToPadXB.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
259 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadYB => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
260 <<
" VS " <<
fChannelsToPadYB.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
271 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadXRpc => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
272 <<
" VS " <<
fChannelsToPadXRpc.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
282 LOG(debug) <<
"CbmMcbm2018MuchPar::GetPadYRpc => Index out of bounds: " << ((febid *
kuNbChanPerAsic) + channelid)
283 <<
" VS " <<
fChannelsToPadYRpc.GetSize() <<
" (" << febid <<
" and " << channelid <<
")";
298 LOG(error) <<
"CbmMcbm2018MuchPar::GetFebId => Index out of bounds: " << uAsicIdx <<
" VS " <<
GetNrOfFebsInGemA()
338 if (SectorIndex < 0 || SectorIndex <= 97) {
339 LOG(debug) <<
"CbmMcbm2018MuchPar::GetRealX => Index out of bounds: ";
343 return fRealX[SectorIndex];
350 if (SectorIndex < 0 || SectorIndex <= 97) {
351 LOG(debug) <<
"CbmMcbm2018MuchPar::GetRealX => Index out of bounds: ";
360 Int_t PadIndex = Channel + 97 * Sector;
361 if (Channel < 0 || Sector < 0)
return -2;
362 if (
fRealX.GetSize() <= PadIndex) {
363 LOG(info) <<
"CbmMcbm2018MuchPar::GetRealX => Index out of bounds: " << Channel <<
" " << Sector <<
" " << PadIndex;
371 Int_t PadIndex = Channel + 97 * Sector;
372 if (Channel < 0 || Sector < 0)
return -2;
374 LOG(info) <<
"CbmMcbm2018MuchPar::GetRealPadSize => Index out of bounds: " << Channel <<
" " << Sector <<
" "
ClassImp(CbmConverterManager)
Int_t ElinkIdxToFebIdx(UInt_t uElink)
virtual ~CbmMcbm2018MuchPar()
void putParams(FairParamList *)
CbmMcbm2018MuchPar(const char *name="CbmMcbm2018MuchPar", const char *title="Much parameters", const char *context="Default")
Double_t GetRealPadSize(Int_t)
static const UInt_t kuNbElinksPerCrob
TArrayI fChannelsToPadYRpc
TArrayI fnFebsIdsArrayGemB
Short_t GetPadXA(UShort_t febid, UShort_t channelid)
TArrayI fnFebsIdsArrayGemA
const Int_t kiCrobMapElinkFebIdx[kuNbElinksPerCrob]
Map from eLink index to ASIC index within CROB ( 0 to kuNbFebsPerCrob * kuNbAsicPerFeb )
UInt_t GetNrOfFebsInRpc()
Short_t GetPadXB(UShort_t febid, UShort_t channelid)
UInt_t ElinkIdxToAsicIdxFebMuch(UInt_t uElink)
TArrayI fChannelsToPadXRpc
UInt_t fuNrOfDpbs
Map from eLink index to ASIC index within CROB ( 0 to kuNbFebsPerCrob * kuNbAsicPerFeb )
static const UInt_t kuNbCrobsPerDpb
Constants.
UInt_t GetDpbId(UInt_t uDpbIdx)
Short_t GetPadXRpc(UShort_t febid, UShort_t channelid)
Short_t GetPadYRpc(UShort_t febid, UShort_t channelid)
Short_t GetPadYB(UShort_t febid, UShort_t channelid)
Short_t GetPadYA(UShort_t febid, UShort_t channelid)
static const UInt_t kuNbFebsPerCrob
TArrayI fnFebsIdsArrayRpc
UInt_t GetNrOfFebsInGemB()
Bool_t IsCrobActive(UInt_t uDpbIdx, UInt_t uCrobIdx)
Bool_t IsFebActive(UInt_t uFebInSystIdx)
static const UInt_t kuNbChanPerAsic
UInt_t GetNrOfFebsInGemA()
Bool_t getParams(FairParamList *)
const UInt_t kuCrobMapElinkFebMuch[kuNbElinksPerCrob]