1 #ifndef ALIMUONPAYLOADTRACKER_H
2 #define ALIMUONPAYLOADTRACKER_H
3 /* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
9 /// \class AliMUONPayloadTracker
10 /// \brief Class for decoding the payload for tracker raw data
12 // Author Christian Finck
18 class AliMUONDDLTracker;
19 class AliMUONBusStruct;
20 class AliMUONDspHeader;
21 class AliMUONBlockHeader;
24 class AliMUONPayloadTracker: public TObject {
26 AliMUONPayloadTracker();
27 virtual ~AliMUONPayloadTracker();
29 /// Return maximum number of block per DDL in DATE file
30 Int_t GetMaxBlock() const {return fMaxBlock;}
31 /// Return maximum number of Dsp per block in DATE file
32 Int_t GetMaxDsp() const {return fMaxDsp;}
33 /// Return maximum number of Buspatch per Dsp in DATE file
34 Int_t GetMaxBus() const {return fMaxBus;}
36 // check input before assigment
37 void SetMaxBlock(Int_t blk);
39 /// \brief Set maximum number of Dsp per block in DATE file
40 /// does not check, done via BusPatchManager
41 void SetMaxDsp(Int_t dsp) {fMaxDsp = dsp;}
42 /// \brief Set maximum number of Buspatch per Dsp in DATE file
43 /// does not check, done via BusPatchManager
44 void SetMaxBus(Int_t bus) {fMaxBus = bus;}
48 Bool_t Decode(UInt_t* buffer, Int_t datasize);
50 /// Return pointer for local structure
51 AliMUONBusStruct* GetBusPatchInfo() const {return fBusStruct;}
52 /// Return pointer for buspatch structure
53 AliMUONDDLTracker* GetDDLTracker() const {return fDDLTracker;}
55 /// Get number of parity errors
56 Int_t GetParityErrors() const {return fParityErrors;} // for online
57 /// Get number of glitch errors
58 Int_t GetGlitchErrors() const {return fGlitchErrors;}
59 /// Get number of padding word errors
60 Int_t GetPaddingErrors() const {return fPaddingErrors;}
63 AliMUONLogger* GetErrorLogger() const {return fLog;}
66 void DisableWarnings() {fWarnings = kFALSE;}
70 AliMUONPayloadTracker(const AliMUONPayloadTracker& stream);
72 AliMUONPayloadTracker& operator = (const AliMUONPayloadTracker& stream);
74 Bool_t CheckDataParity();
75 void AddErrorMessage(const Char_t* msg);
77 Int_t fBusPatchId; ///< entry of buspatch structure
78 Int_t fDspId; ///< entry of Dsp header
79 Int_t fBlkId; ///< entry of Block header
81 Int_t fMaxDDL; ///< maximum number of DDL in DATE file
82 Int_t fMaxBlock; ///< maximum number of block per DDL in DATE file
83 Int_t fMaxDsp; ///< maximum number of Dsp per block in DATE file
84 Int_t fMaxBus; ///< maximum number of Buspatch per Dsp in DATE file
86 AliMUONDDLTracker* fDDLTracker; //!< pointer for buspatch structure
87 AliMUONBusStruct* fBusStruct; //!< pointer for local structure
88 AliMUONBlockHeader* fBlockHeader; //!< pointer for block structure
89 AliMUONDspHeader* fDspHeader; //!< pointer for dsp structure
91 AliMUONLogger* fLog; //!< Map of errors msg;
92 Int_t fParityErrors; //!< number of parity errors;
93 Int_t fGlitchErrors; //!< number of glitch errors;
94 Int_t fPaddingErrors; //!< number of padding word errors;
95 Bool_t fWarnings; //!< flag to enable/disable warnings
97 ClassDef(AliMUONPayloadTracker, 4) // base class for reading MUON raw digits