-#ifndef ALI_ITS_ONLINECALIBRATIONSPD_H
-#define ALI_ITS_ONLINECALIBRATIONSPD_H
+#ifndef ALIITSONLINECALIBRATIONSPD_H
+#define ALIITSONLINECALIBRATIONSPD_H
///////////////////////////////////////////////////////////////////////
// Author: Henrik Tydesjo //
-// This class is used as a container to keep the dead and noisy //
-// pixels online. Each object corresponds to one module. //
+// This class is used as a container to keep the dead,noisy,active //
+// pixels online. Each object corresponds to one DDL (eq). //
// Note: This class should not be used directly. //
// Use it via AliITSOnlineCalibrationSPDhandler instead. //
///////////////////////////////////////////////////////////////////////
+/* $Id$ */
+
#include <TObject.h>
#include <TArrayI.h>
AliITSOnlineCalibrationSPD();
virtual ~AliITSOnlineCalibrationSPD() {}
- void SetModuleNr(UInt_t mod) {fModuleNr=mod;}
- UInt_t GetModuleNr() const {return fModuleNr;}
- void SetDeadList(TArrayI deadlist) {fDeadChannels=deadlist;}
- void SetNoisyList(TArrayI noisylist) {fNoisyChannels=noisylist;}
- void SetNrDead(UInt_t nr) {fNrDead=nr;}
- void SetNrNoisy(UInt_t nr) {fNrNoisy=nr;}
-
- void AddDead(UInt_t col, UInt_t row);
- Int_t GetNrDead() const {return fNrDead;}
- Int_t GetDeadColAt(UInt_t index) const; //returns -1 if out of bounds
- Int_t GetDeadRowAt(UInt_t index) const; //returns -1 if out of bounds
- void ClearDead() {fDeadChannels.Reset(); fNrDead=0;}
- Bool_t IsPixelDead(Int_t col, Int_t row) const ;
- void AddNoisy(UInt_t col, UInt_t row);
- Int_t GetNrNoisy() const {return fNrNoisy;}
- Int_t GetNoisyColAt(UInt_t index) const; //returns -1 if out of bounds
- Int_t GetNoisyRowAt(UInt_t index) const; //returns -1 if out of bounds
- void ClearNoisy() {fNoisyChannels.Reset(); fNrNoisy=0;}
- Bool_t IsPixelNoisy(Int_t col, Int_t row) const ;
+ void SetEqNr(UInt_t eq) {fEqNr=eq;}
+ UInt_t GetEqNr() const {return fEqNr;}
+ void SetBadList(TArrayI badlist) {fBadChannels=badlist;}
+ void SetNrBad(UInt_t nr) {fNrBad=nr;}
+
+ UInt_t GetNrBad() const {return fNrBad;}
+ Int_t GetKeyAt(UInt_t index) const; //returns -1 if out of bounds
+
+ void ClearBad() {fBadChannels.Reset(); fNrBad=0;}
+
+ void ActivateALL();
+ void ActivateEq(Bool_t setval = kTRUE);
+ void ActivateHS(UInt_t hs, Bool_t setval = kTRUE);
+ void ActivateChip(UInt_t hs, UInt_t chip, Bool_t setval = kTRUE);
+
+ Bool_t IsActiveEq() const;
+ Bool_t IsActiveHS(UInt_t hs) const;
+ Bool_t IsActiveChip(UInt_t hs, UInt_t chip) const;
+
+ void UnSetDeadALL();
+ void SetDeadEq(Bool_t setval = kTRUE);
+ void SetDeadHS(UInt_t hs, Bool_t setval = kTRUE);
+ void SetDeadChip(UInt_t hs, UInt_t chip, Bool_t setval = kTRUE);
+
+ Bool_t IsDeadEq() const;
+ Bool_t IsDeadHS(UInt_t hs) const;
+ Bool_t IsDeadChip(UInt_t hs, UInt_t chip) const;
private:
- UInt_t fModuleNr; // module nr
- UInt_t fNrDead; // nr of dead pixels
- TArrayI fDeadChannels; // index 0 is nr of dead, then pairs of col and row
- UInt_t fNrNoisy; // nr of noisy pixels
- TArrayI fNoisyChannels; // index 0 is nr of noisy, then pairs of col and row
+ UInt_t fEqNr; // eq nr
+ UInt_t fNrBad; // nr of bad (single) pixels
+ TArrayI fBadChannels; // array of keys for the bad (single) pixels
+ Bool_t fActiveEq; // active bit for each equipment
+ Bool_t fActiveHS[6]; // active bit for each half-stave
+ Bool_t fActiveChip[60]; // active bit for each chip
+ Bool_t fDeadEq; // dead bit for each equipment
+ Bool_t fDeadHS[6]; // dead bit for each half-stave
+ Bool_t fDeadChip[60]; // dead bit for each chip
- ClassDef(AliITSOnlineCalibrationSPD,1)
+ ClassDef(AliITSOnlineCalibrationSPD,3)
};
#endif