+
+//_____________________________________________________________________________
+Bool_t
+AliMUONDigitCalibrator::IsValidDigit(Int_t detElemId, Int_t manuId, Int_t manuChannel,
+ Int_t* statusMap) const
+
+{
+ /// Check if a given pad is ok or not.
+
+ // initialize the statusmap to dead by default
+ if (statusMap) *statusMap = AliMUONPadStatusMapMaker::SelfDeadMask();
+
+ // First a protection against bad input parameters
+ AliMpDetElement* de = AliMpDDLStore::Instance()->GetDetElement(detElemId);
+ if (!de) return kFALSE; // not existing DE
+ if (!de->IsExistingChannel(manuId,manuChannel))
+ {
+ // non-existing (might happen when we get parity errors in read-out
+ // that spoils the manuId
+ return kFALSE;
+ }
+ if (!de->IsConnectedChannel(manuId,manuChannel))
+ {
+ // existing (in read-out), but not connected channel
+ return kFALSE;
+ }
+
+ // ok, now we have a valid channel number, so let's see if that pad
+ // behaves or not ;-)
+
+ Int_t sm = StatusMap(detElemId,manuId,manuChannel);
+
+ if (statusMap) *statusMap = sm;
+
+ if ( ( sm & AliMUONPadStatusMapMaker::SelfDeadMask() ) != 0 )
+ {
+ // pad itself is bad (not testing its neighbours at this stage)
+ return kFALSE;
+ }
+
+ return kTRUE;
+}
+
+//_____________________________________________________________________________
+Int_t
+AliMUONDigitCalibrator::PadStatus(Int_t detElemId, Int_t manuId, Int_t manuChannel) const
+{
+ /// Return the status of the given pad
+ return fStatusMaker->PadStatus(detElemId,manuId,manuChannel);
+}
+
+//_____________________________________________________________________________
+Int_t
+AliMUONDigitCalibrator::StatusMap(Int_t detElemId, Int_t manuId, Int_t manuChannel) const
+{
+ /// Return the status map of the given pad
+ return fStatusMapMaker->StatusMap(detElemId,manuId,manuChannel);
+
+}
+