]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONPayloadTracker.cxx
Protection if the compiler is not gcc
[u/mrichter/AliRoot.git] / MUON / AliMUONPayloadTracker.cxx
index 0642c26df95db24e270e504f81b8235d4291a33d..6fdf9285e42ce9cac91e15ae6af4137d51401f88 100644 (file)
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
-///
+// $Id$
+
+//-----------------------------------------------------------------------------
 /// \class AliMUONPayloadTracker
 /// Decodes rawdata from buffer and stores in TClonesArray.
 /// First version implement for Tracker
 ///
 /// \author Christian Finck
+//-----------------------------------------------------------------------------
 
 #include "AliMUONPayloadTracker.h"
 
@@ -47,7 +50,8 @@ AliMUONPayloadTracker::AliMUONPayloadTracker()
     fBlockHeader(new AliMUONBlockHeader()),
     fDspHeader(new AliMUONDspHeader()),
     fParityErrBus(),
-    fGlitchErrors(0)
+    fGlitchErrors(0),
+    fPaddingErrors(0)
 {
   ///
   /// create an object to decode MUON payload
@@ -125,7 +129,8 @@ Bool_t AliMUONPayloadTracker::Decode(UInt_t* buffer, Int_t totalDDLSize)
 
       if (fDspHeader->GetErrorWord()) {
        fDspHeader->Print("");
-       if (fDspHeader->GetErrorWord() == (0x000000B1 |  fBlockHeader->GetDspId())){
+       if ( fDspHeader->GetErrorWord() == (0x000000B1 |  fBlockHeader->GetDspId())
+            ||  fDspHeader->GetErrorWord() == (0x00000091 |  fBlockHeader->GetDspId()) ){
          // an event with a glitch in the readout  has been detected
          // it means that somewhere a 1 byte word has been randomly inserted
          // all the readout sequence is shifted  untill the next event 
@@ -194,9 +199,10 @@ Bool_t AliMUONPayloadTracker::Decode(UInt_t* buffer, Int_t totalDDLSize)
       if (fDspHeader->GetPaddingWord() == 1) {
        if (buffer[index++] != fDspHeader->GetDefaultPaddingWord())
 
-           AliError(Form("Error in padding word for iBlock %d, iDsp %d, iBus %d\n", 
+           AliWarning(Form("Error in padding word for iBlock %d, iDsp %d, iBus %d\n", 
                          iBlock, iDsp, iBusPatch));
 
+       fPaddingErrors++;
       }
 
       index = indexDsp + totalDspSize;
@@ -226,6 +232,7 @@ void AliMUONPayloadTracker::ResetDDL()
   ///
   fDDLTracker->GetBlkHeaderArray()->Delete();
   fGlitchErrors = 0;
+  fPaddingErrors = 0;
   fParityErrBus.Reset();
 
 }
@@ -274,7 +281,7 @@ Bool_t AliMUONPayloadTracker::CheckDataParity()
 //______________________________________________________
 void AliMUONPayloadTracker::AddParityErrBus(Int_t buspatch)
 {
-// adding bus with at least on parity error
+/// adding bus with at least on parity error
     fParityErrBus.Set(fParityErrBus.GetSize() + 1);
     fParityErrBus.AddAt(buspatch, fParityErrBus.GetSize() - 1);
 }