]> git.uio.no Git - u/mrichter/AliRoot.git/blame - MUON/AliMUONPayloadTracker.h
Update tracking class and macros, and pid class to read correctly the ESDs
[u/mrichter/AliRoot.git] / MUON / AliMUONPayloadTracker.h
CommitLineData
939ae4b2 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 */
5
6/*$Id$*/
7
8/// \ingroup raw
9/// \class AliMUONPayloadTracker
78649106 10/// \brief Class for decoding the payload for tracker raw data
939ae4b2 11///
78649106 12// Author Christian Finck
939ae4b2 13
14#include <TObject.h>
3fe5a267 15#include <TString.h>
16
939ae4b2 17
18class AliMUONDDLTracker;
19class AliMUONBusStruct;
20class AliMUONDspHeader;
21class AliMUONBlockHeader;
3fe5a267 22class AliMUONLogger;
939ae4b2 23
24class AliMUONPayloadTracker: public TObject {
25 public :
26 AliMUONPayloadTracker();
939ae4b2 27 virtual ~AliMUONPayloadTracker();
28
71a2d3aa 29 /// Return maximum number of block per DDL in DATE file
939ae4b2 30 Int_t GetMaxBlock() const {return fMaxBlock;}
71a2d3aa 31 /// Return maximum number of Dsp per block in DATE file
939ae4b2 32 Int_t GetMaxDsp() const {return fMaxDsp;}
71a2d3aa 33 /// Return maximum number of Buspatch per Dsp in DATE file
939ae4b2 34 Int_t GetMaxBus() const {return fMaxBus;}
35
36 // check input before assigment
37 void SetMaxBlock(Int_t blk);
38
71a2d3aa 39 /// \brief Set maximum number of Dsp per block in DATE file
40 /// does not check, done via BusPatchManager
939ae4b2 41 void SetMaxDsp(Int_t dsp) {fMaxDsp = dsp;}
71a2d3aa 42 /// \brief Set maximum number of Buspatch per Dsp in DATE file
43 /// does not check, done via BusPatchManager
939ae4b2 44 void SetMaxBus(Int_t bus) {fMaxBus = bus;}
45
46 void ResetDDL();
47
84ceeb06 48 Bool_t Decode(UInt_t* buffer, Int_t datasize);
939ae4b2 49
71a2d3aa 50 /// Return pointer for local structure
939ae4b2 51 AliMUONBusStruct* GetBusPatchInfo() const {return fBusStruct;}
71a2d3aa 52 /// Return pointer for buspatch structure
939ae4b2 53 AliMUONDDLTracker* GetDDLTracker() const {return fDDLTracker;}
54
1ed3c5c2 55 /// Get number of parity errors
3fe5a267 56 Int_t GetParityErrors() const {return fParityErrors;} // for online
1ed3c5c2 57 /// Get number of glitch errors
58 Int_t GetGlitchErrors() const {return fGlitchErrors;}
ea59383d 59 /// Get number of padding word errors
60 Int_t GetPaddingErrors() const {return fPaddingErrors;}
1ed3c5c2 61
3fe5a267 62 /// Get Error logger
63 AliMUONLogger* GetErrorLogger() const {return fLog;}
64
65 /// set warnings flag
66 void DisableWarnings() {fWarnings = kFALSE;}
67
9f5dcca3 68 private :
71a2d3aa 69 /// Not implemented
70 AliMUONPayloadTracker(const AliMUONPayloadTracker& stream);
71 /// Not implemented
72 AliMUONPayloadTracker& operator = (const AliMUONPayloadTracker& stream);
73
74 Bool_t CheckDataParity();
3fe5a267 75 void AddErrorMessage(const Char_t* msg);
939ae4b2 76
939ae4b2 77 Int_t fBusPatchId; ///< entry of buspatch structure
78 Int_t fDspId; ///< entry of Dsp header
79 Int_t fBlkId; ///< entry of Block header
80
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
85
939ae4b2 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
90
3fe5a267 91 AliMUONLogger* fLog; //!< Map of errors msg;
92 Int_t fParityErrors; //!< number of parity errors;
1ed3c5c2 93 Int_t fGlitchErrors; //!< number of glitch errors;
ea59383d 94 Int_t fPaddingErrors; //!< number of padding word errors;
3fe5a267 95 Bool_t fWarnings; //!< flag to enable/disable warnings
1ed3c5c2 96
3fe5a267 97 ClassDef(AliMUONPayloadTracker, 4) // base class for reading MUON raw digits
939ae4b2 98};
99
100#endif