]> git.uio.no Git - u/mrichter/AliRoot.git/blob - PMD/AliPMDRawStream.h
Removing TClonesArray deletions (C.Cheshkov)
[u/mrichter/AliRoot.git] / PMD / AliPMDRawStream.h
1 #ifndef ALIPMDRAWSTREAM_H
2 #define ALIPMDRAWSTREAM_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 ///////////////////////////////////////////////////////////////////////////////
9 ///
10 /// This class provides access to PMD digits in raw data.
11 ///
12 ///////////////////////////////////////////////////////////////////////////////
13
14 #include <TObject.h>
15
16 class AliRawReader;
17 class AliCDBManager;
18 class AliCDBStorage;
19 class AliCDBEntry;
20 class AliPMDMappingData;
21
22
23 class AliPMDRawStream: public TObject {
24   public :
25     AliPMDRawStream(AliRawReader* rawReader);
26     virtual ~AliPMDRawStream();
27
28     Int_t DdlData(TObjArray *pmdddlcont);
29
30     enum {kDDLOffset = 0xC00};      // offset for DDL numbers
31
32     enum EPMDRawStreamError {
33       kDDLIndexMismatch = 1,
34       kNoMappingFile = 2,
35       kParityError = 3
36     };
37
38   private :
39     AliPMDRawStream(const AliPMDRawStream& stream);
40     AliPMDRawStream& operator = (const AliPMDRawStream& stream);
41
42     void             GetRowCol(Int_t imodule, Int_t pbusid, 
43                                UInt_t mcmno, UInt_t chno,
44                                Int_t startRowBus[], Int_t endRowBus[],
45                                Int_t startColBus[], Int_t endColBus[],
46                                Int_t &row, Int_t &col) const;
47     void             ConvertDDL2SMN(Int_t iddl, Int_t imodule,
48                                     Int_t &smn, Int_t &detector) const;
49     void             TransformH2S(Int_t smn, Int_t &row, Int_t &col) const;
50     Int_t            ComputeParity(UInt_t data1);
51     UInt_t           GetNextWord();
52     void             Ddl0Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
53                                  Int_t startRowBus[], Int_t endRowBus[],
54                                  Int_t startColBus[], Int_t endColBus[]);
55     void             Ddl1Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
56                                  Int_t startRowBus[], Int_t endRowBus[],
57                                  Int_t startColBus[], Int_t endColBus[]);
58     void             Ddl2Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
59                                  Int_t startRowBus[], Int_t endRowBus[],
60                                  Int_t startColBus[], Int_t endColBus[]);
61     void             Ddl3Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
62                                  Int_t startRowBus[], Int_t endRowBus[],
63                                  Int_t startColBus[], Int_t endColBus[]);
64     void             Ddl4Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
65                                  Int_t startRowBus[], Int_t endRowBus[],
66                                  Int_t startColBus[], Int_t endColBus[]);
67     void             Ddl5Mapping(Int_t moduleNo[],    Int_t mcmperBus[],
68                                  Int_t startRowBus[], Int_t endRowBus[],
69                                  Int_t startColBus[], Int_t endColBus[]);
70
71     AliPMDMappingData *GetMappingData() const;
72
73     AliRawReader*    fRawReader;    // object for reading the raw data
74     UChar_t*         fData;         // pointer to the data
75     Int_t            fPosition;
76
77     AliPMDMappingData  *fMapData;   //! Mapping data
78
79     ClassDef(AliPMDRawStream, 8)    // class for reading PMD raw digits
80 };
81
82 #endif