]> git.uio.no Git - u/mrichter/AliRoot.git/blob - HLT/PHOS/AliHLTPHOSRawAnalyzerComponent.h
Bug fix. Incorrect usage of types was corrected.
[u/mrichter/AliRoot.git] / HLT / PHOS / AliHLTPHOSRawAnalyzerComponent.h
1 #ifndef ALIHLTPHOSRAWANALYZERCOMPONENT_H
2 #define ALIHLTPHOSRAWANALYZERCOMPONENT_H
3
4 /* Copyright(c) 2006, ALICE Experiment at CERN, All rights reserved. *
5  * See cxx source for full Copyright notice                          */
6
7 #include "AliHLTProcessor.h"
8 #include "AliHLTPHOSRawAnalyzer.h"
9 #include "AliRawReaderMemory.h"
10 #include "AliCaloRawStream.h"
11 #include "AliHLTPHOSDefinitions.h"
12 #include "AliHLTPHOSCommonDefs.h"
13
14 class AliHLTPHOSRcuCellEnergyDataStruct;
15
16 class AliHLTPHOSRawAnalyzerComponent: public AliHLTProcessor
17 {
18  public:
19
20   AliHLTPHOSRawAnalyzerComponent();
21   ~AliHLTPHOSRawAnalyzerComponent();
22   AliHLTPHOSRawAnalyzerComponent(const AliHLTPHOSRawAnalyzerComponent & );
23   AliHLTPHOSRawAnalyzerComponent & operator = (const AliHLTPHOSRawAnalyzerComponent &)
24    {
25       return *this;
26    };
27
28   virtual int DoInit( int argc, const char** argv );
29   virtual int Deinit();
30   virtual int DoDeinit();
31   void DumpData(int gain);
32   void DumpData();
33   void DumpChannelData(Double_t *data); 
34   //  void SetEquippmentID(AliHLTUInt32_t id);
35   void SetEquippmentID(AliHLTUInt16_t id);
36   //  int GetEquippmentID();
37   AliHLTUInt16_t  GetEquippmentID();
38   //  void SetCoordinates( AliHLTUInt32_t equippmentID);
39   void SetCoordinates(AliHLTUInt16_t equippmentID);
40
41   virtual const char* GetComponentID() = 0;
42   virtual void GetInputDataTypes(std::vector<AliHLTComponentDataType, std::allocator<AliHLTComponentDataType> >&);
43   virtual AliHLTComponentDataType GetOutputDataType();
44   virtual void GetOutputDataSize(unsigned long& constBase, double& inputMultiplier);
45   virtual AliHLTComponent* Spawn() = 0;
46   virtual int DoEvent(const AliHLTComponentEventData&, const AliHLTComponentBlockData*, AliHLTComponentTriggerData&, AliHLTUInt8_t*, AliHLTUInt32_t&, std::vector<AliHLTComponentBlockData, std::allocator<AliHLTComponentBlockData> >&);
47
48  protected:
49   AliHLTPHOSRawAnalyzer *analyzerPtr; 
50
51  private:
52   void Reset();
53   void ResetDataPtr();
54   void ResetDataPtr(int sampleCnt);
55   void ResetDataPtr(int startindex, int sampleCnt);
56   static int fEventCount;
57
58
59   //  AliHLTUInt32_t fEquippmentID;
60   //  AliHLTUInt16_t fRcuX;
61   //  AliHLTUInt16_t fRcuZ;
62   //  AliHLTUInt16_t fRcuZOffset;
63   //  AliHLTUInt16_t fRcuXOffset;
64   //  AliHLTUInt16_t fModuleID;
65
66   // Int_t fEquippmentID;
67
68   //  Int_t fRcuX;
69   //  Int_t fRcuZ;
70   //  Int_t fRcuZOffset;
71   //  Int_t fRcuXOffset;
72   //  Int_t fModuleID;
73   AliHLTUInt16_t fEquippmentID;
74
75   AliHLTUInt8_t  fRcuX;
76   AliHLTUInt8_t  fRcuZ;
77   AliHLTUInt8_t  fRcuZOffset;
78   AliHLTUInt8_t  fRcuXOffset;
79   AliHLTUInt8_t  fModuleID;
80
81
82
83   Double_t fTmpChannelData[ALTRO_MAX_SAMPLES];
84   Double_t fMaxValues[N_MODULES][N_ROWS_MOD][N_COLUMNS_MOD][N_GAINS];
85   AliCaloRawStream *fPHOSRawStream;
86   AliRawReaderMemory *fRawMemoryReader;
87   AliHLTPHOSRcuCellEnergyDataStruct* fOutPtr;
88   static const AliHLTComponentDataType inputDataTypes[];
89 };
90 #endif