fPedestal(),
fGain(0),
fBadChannels(0),
-fIsBad(kFALSE){
+ fIsBad(kFALSE),
+fSSDADCpereV(0.),
+ fKeVperADC(0)
+{
// Default Constructor
for(Int_t i=0;i<fgkChipsPerModule;i++){
fIsChipBad[i]=kFALSE;
}
+ SetSSDADCpereV();
+ SetKeVperADC();
}
//______________________________________________________________________
AliITSCalibrationSSD::AliITSCalibrationSSD(const char *dataType):
fPedestal(0),
fGain(0),
fBadChannels(0),
-fIsBad(kFALSE){
+fIsBad(kFALSE) ,
+fSSDADCpereV(0.),
+fKeVperADC(0){
// constructor
SetDataType(dataType);
for(Int_t i=0;i<fgkChipsPerModule;i++){
fIsChipBad[i]=kFALSE;
}
+ SetSSDADCpereV();
+ SetKeVperADC();
}
//______________________________________________________________________
AliITSCalibrationSSD::~AliITSCalibrationSSD(){
// destructor
delete [] fDetPar;
+ if(fNoise)delete fNoise;
+ if(fPedestal)delete fPedestal;
+ if(fGain)delete fGain;
+ if(fBadChannels)delete fBadChannels;
}
//______________________________________________________________________
void AliITSCalibrationSSD::SetDetParam(Double_t *par){
//______________________________________________________________________
void AliITSCalibrationSSD::FillBadChipMap() {
+ // reset
+ fIsBad=kFALSE;
+ for(Int_t i=0;i<fgkChipsPerModule;i++){
+ fIsChipBad[i]=kFALSE;
+ }
+
+
Int_t mc=0;
- Int_t cc[12];
+ Int_t cc[fgkChipsPerModule];
// P-side
- for(Int_t i=0; i<6; i++){
+ for(Int_t i=0; i<fgkChipsPerModule/2; i++){
cc[i]=0;
for(Int_t j=0; j<ChannelsPerChip(); j++) {
if(IsPChannelBad(i*ChannelsPerChip()+j)) cc[i]++;
}
// N-side
- for(Int_t i=6; i<11; i++){
+ for(Int_t i=fgkChipsPerModule/2; i<fgkChipsPerModule; i++){
cc[i]=0;
for(Int_t j=0; j<ChannelsPerChip(); j++) {
if(IsNChannelBad(1535-i*ChannelsPerChip()-j)) cc[i]++;
if(cc[i]==ChannelsPerChip()) { SetChipBad(i); mc++; }
}
- if(mc==ChannelsPerChip()) fIsBad=kTRUE;
+ if(mc==fgkChipsPerModule) fIsBad=kTRUE;
}