//* ALICE Experiment at CERN, All rights reserved. *
//* See cxx source for full Copyright notice */
-/// @file AliHLCaloConstants.h
+/// @file AliHLTCaloConstants.h
/// @author Svein Lindal
/// @date
/// @brief Class containing constants for PHOS and EMCAL
/// loaded libraries
+
#include "Rtypes.h"
#include "TString.h"
-
#ifndef ALIHLTCALOCONSTANTS_H
#define ALIHLTCALOCONSTANTS_H
-
-
-#define fgkALTROMAXSAMPLES 1008 /**<The maximum number of samples of the ALTRO*/
-#define fgkALTROMAXPRESAMPLES 15 //Constant
-#define fgkNGAINS 2
-#define fgkHIGHGAIN 1
-#define fgkLOWGAIN 0
-#define fkMAXBINVALUE 1023 //Constant
-
+#include "AliCaloConstants.h"
class AliHLTCaloConstants
{
-
public:
-
AliHLTCaloConstants();
virtual ~AliHLTCaloConstants();
- virtual Int_t GetMAXHOSTS() const { return fkMAXHOSTS; } ;
- virtual Int_t GetDEFAULTEVENTPORT() const { return fkDEFAULTEVENTPORT; };
- static Int_t GetALTROMAXSAMPLES() { return fgkALTROMAXSAMPLES; };
- static Int_t GetALTROMAXPRESAMPLES() { return fgkALTROMAXPRESAMPLES; } ;
+ virtual void InitConstants() = 0;
+
+ // Common PHOS / EMCAL stuff
+ static Int_t GetALTROMAXSAMPLES() { return ALTRO::ALTROMAXSAMPLES; };
+ static Int_t GetNGAINS() { return ALTRO::NGAINS; };
+ static Int_t GetHIGHGAIN() { return ALTRO::HIGHGAIN; };
+ static Int_t GetLOWGAIN() { return ALTRO::LOWGAIN; };
+ static Double_t GetHGLGFACTOR() { return CALO::HGLGFACTOR;}; //FR
+ static Int_t GetMAXBINVALUE() { return ALTRO::MAXBINVALUE; };
+ static Int_t GetCSPSPERFEE() { return CALO::CSPSPERFEE; };
+ static Int_t GetNALTROS() { return ALTRO::NALTROS; };
+ static Int_t GetNALTROCHANNELS() { return ALTRO::NALTROCHANNELS; };
+ static Int_t GetNBRANCHES() { return CALO::NBRANCHES; };
+ //static Int_t GetMAXHWADDRESSES() { return CALO::MAXHWADDRESSES; }
+ static Int_t GetMAXHWADDRESSES() { return PHOS::MAXHWADDR; }
+ // Detector specific stuff
+ // PHOS Only, bad move somewher else, PTH
+ virtual Int_t GetNZROWSRCU() const { return 56 ; } ;
+ virtual Int_t GetNXCOLUMNSRCU() const { return 16; } ;
+ // END PHOS Only
+
+ virtual Int_t GetNZROWSMOD() const = 0;
+ virtual Int_t GetNXCOLUMNSMOD() const = 0;
+ virtual Int_t GetNMODULES() const = 0;
+ virtual Int_t GetNRCUSPERMODULE() const = 0;
+ virtual Int_t GetNFEECS() const = 0;
- static Int_t GetNGAINS() { return fgkNGAINS; };
- static Int_t GetHIGHGAIN() { return fgkHIGHGAIN; };
- static Int_t GetLOWGAIN() { return fgkLOWGAIN; };
- static Int_t GetMAXBINVALUE() {return fkMAXBINVALUE; };
-
-
- // virtual Int_t GetNZROWSMOD() const { return fgkNZROWSMOD;}
- virtual Int_t GetNZROWSMOD() const = 0;
-
- virtual Int_t GetNZROWSRCU() const = 0;
- virtual Int_t GetNXCOLUMNSRCU() const = 0;
- virtual Int_t GetNXCOLUMNSMOD() const = 0;
- // virtual Int_t GetNGAINS() const = 0;
- virtual Int_t GetNDATATYPES() const { return fkNDATATYPES; } ;
- virtual Int_t GetPFMAXPATHLENGTH() const = 0;
- virtual Int_t GetPFDEFAULTNSAMPLES() const = 0;
- virtual Int_t GetPFDEFAULTSTARTINDEX() const = 0;
- virtual Double_t GetDEFAULTTAU() const = 0;
- virtual Int_t GetDEFAULTFS() const = 0;
- Int_t GetCSPSPERFEE() const { return fkCSPSPERFEE; };
-
- virtual Int_t GetNMODULES() const = 0;
- virtual Int_t GetNRCUS() const = 0;
- virtual Int_t GetNRCUSPERMODULE() const = 0;
- virtual Int_t GetNRCUSPERTOTAL() const = 0;
- virtual Int_t GetNFEECS() const = 0;
- Int_t GetNALTROS() { return fkNALTROS; };
- Int_t GetNALTROCHANNELS() const { return fkNALTROCHANNELS; };
- Int_t GetNBRANCHES() const { return fkNBRANCHES; };
-
- // EMCAL specific
+ Int_t GetDDLOFFSET() const { return fkDDLOFFSET; }
Float_t GetCELLSTEP() const { return fkCELLSTEP; }
- Float_t GetMAXCELLSTEPETA() const { return fkMAXCELLSTEPETA; } //FR
- Float_t GetMINCELLSTEPETA() const { return fkMINCELLSTEPETA; } //FR
+
+ //EMCAL specific, !! Move somewhere else, PTH
Float_t GetCELLSTEPPHI() const { return fkCELLSTEPPHI; } //FR
Float_t GetCELLHEIGHT() const { return fkCELLHEIGHT; } //FR
Float_t GetCELLANGLE() const { return fkCELLANGLE; } //FR
Float_t GetRADLENGTH() const { return fkRADLENGTH; } //FR
Float_t GetCRITICENERGY() const { return fkCRITICENERGY; } //FR
Float_t GetCJ() const { return fkCJ;} //FR
- virtual Int_t GetDDLOFFSET() const = 0;
TString GetDETNAME() { return fkDETNAME; };
-
-
+
protected:
- TString fkDETNAME;
- Float_t fkCELLSTEP; //Constant
- Float_t fkMAXCELLSTEPETA;
- Float_t fkMINCELLSTEPETA;
+ //EMCAL specific, !! Move somewhere else, PTH
+ // @todo: These variables should be declared constant, doesnt work right now
+ // because the default copy contructor is called somewhere.
+
Float_t fkCELLSTEPPHI;
Float_t fkCELLHEIGHT;
Float_t fkCELLANGLE;
Float_t fkRADLENGTH;
Float_t fkCRITICENERGY;
+
Float_t fkCJ;
+ Float_t fkCELLSTEP; //Constant
+
Int_t fkDDLOFFSET; //Constant
-
+ TString fkDETNAME;
+
private:
- const Int_t fkNALTROS; /**<Number of ALTROs per frontend card*/
- const Int_t fkNALTROCHANNELS; //Constant
- const Int_t fkNBRANCHES; //Constant
- const Int_t fkCSPSPERFEE; //Constant
- const Int_t fkNDATATYPES; //Constant
- const Int_t fkMAXHOSTS; //Constant
- const Int_t fkDEFAULTEVENTPORT; //Constant
- ClassDef(AliHLTCaloConstants, 1);
+ AliHLTCaloConstants(const AliHLTCaloConstants & );
+ AliHLTCaloConstants & operator = (const AliHLTCaloConstants &);
+
+ ClassDef(AliHLTCaloConstants, 1)
};