New class which will deal with the writing of DDL raw data and the endianess issue
[u/mrichter/AliRoot.git] / MUON / AliMUONDDLTracker.h
CommitLineData
f6762c71 1#ifndef ALIMUONDDLTRACKER_H
2#define ALIMUONDDLTRACKER_H
3/* Copyright(c) 1998-1999, ALICE Experiment at CERN, All rights reserved. *
4 * See cxx source for full Copyright notice */
5
692de412 6/*$Id$*/
7
8/// \ingroup rec
9/// \class AliMUONDDLTracker
10/// \brief MUON DDL tracker
f6762c71 11
12#include <TObject.h>
69be760c 13#include "AliRawDataHeader.h"
14
f6762c71 15
16class AliMUONDDLTracker : public TObject {
17
18public:
19 AliMUONDDLTracker();
20 virtual ~AliMUONDDLTracker(){;}
21
69be760c 22 // Block header
23 Int_t GetTotalBlkLength() const {return fTotalBlkLength;}
24 Int_t GetBlkLength() const {return fBlkLength;}
25 Int_t GetDspId() const {return fDSPId;}
26 Int_t GetBlkTriggerWord(Int_t n) const {return fBlkTriggerWord[n];}
17323043 27 Int_t GetPadding() const {return fPadding;}
28 Int_t GetBlkHeaderLength() const {return fgkBlkHeaderLength;}
69be760c 29
30 void SetTotalBlkLength(Int_t l) {fTotalBlkLength = l;}
31 void SetBlkLength(Int_t l) {fBlkLength = l;}
32 void SetDSPId(Int_t d) {fDSPId = d;}
33 void SetBlkTriggerWord(Int_t w, Int_t n) {fBlkTriggerWord[n] = w;}
34
35 // DSP header
36 Int_t GetTotalDspLength() const {return fTotalDspLength;}
37 Int_t GetDspLength() const {return fDspLength;}
38 Int_t GetDspId1() const {return fDSPId1;}
39 Int_t GetDspTriggerWord(Int_t n) const {return fDspTriggerWord[n];}
40 Int_t GetEventWord() const {return fEventWord;}
41
42 void SetTotalDspLength(Int_t l) {fTotalDspLength = l;}
43 void SetDspLength(Int_t l) {fDspLength = l;}
44 void SetDSPId1(Int_t d) {fDSPId1 = d;}
45 void SetDspTriggerWord(Int_t w, Int_t n) {fDspTriggerWord[n] = w;}
46 void SetEventWord(Int_t w) {fEventWord = w;}
17323043 47 Int_t GetDspHeaderLength() const {return fgkDspHeaderLength;}
f6762c71 48
69be760c 49 Int_t* GetBlkHeader() {return &fTotalBlkLength;}
50 Int_t* GetDspHeader() {return &fTotalDspLength;}
f6762c71 51
85fec35d 52 AliRawDataHeader GetHeader() const {return fHeader;}
53 Int_t GetHeaderSize() const {return sizeof(AliRawDataHeader)/4;} // in words
f6762c71 54
17323043 55 Int_t GetEoD() const {return fgkEndOfDDL;}
f6762c71 56
57 private:
f6762c71 58
69be760c 59 // block header
60 Int_t fTotalBlkLength; // total length of block structure
61 Int_t fBlkLength; // length of raw data
62 Int_t fDSPId; // Dsp id
63 Int_t fBlkTriggerWord[4]; // counter trigger word
64 Int_t fPadding; // padding dummy word for 64 bits transfer
c8f4be1a 65 static const Int_t fgkBlkHeaderLength; // header length in word
69be760c 66
67 // Dsp header
68 Int_t fTotalDspLength; // total length of block structure
69 Int_t fDspLength; // length of raw data
70 Int_t fDSPId1; // Dsp id ??
71 Int_t fDspTriggerWord[4]; // counter trigger word ?
72 Int_t fEventWord; // nb word odd = 1, even = 0
c8f4be1a 73 static const Int_t fgkDspHeaderLength; // header length
69be760c 74
c8f4be1a 75 static const Int_t fgkEndOfDDL; // end of DDL
69be760c 76
77
78 AliRawDataHeader fHeader; // header of DDL
79
80
f6762c71 81 ClassDef(AliMUONDDLTracker,1) // MUON DDL Tracker
82};
83#endif