]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - EMCAL/AliCaloConstants.h
From Andrea Dainese: protection in AliAODTrack::PropagateToDCA for usage in case...
[u/mrichter/AliRoot.git] / EMCAL / AliCaloConstants.h
index c5bd789db5c4ab7e473dcb0aa498a626ba4b4a53..be71ce1e42d4b4ae36df06ac769d311537cc672a 100644 (file)
@@ -4,7 +4,7 @@
 
 /**************************************************************************
  * This file is property of and copyright by                              *
- * the Relativistic Heavy Ion Group (RHIG), Yale University, US, 2009     *
+ * the Relativistic Heavy Ion Group (RHIG), Yale University, US, 2010     *
  *                                                                        *
  * Primary Author: Per Thomas Hille  <perthomas.hille@yale.edu>           *
  *                                                                        *
  * provided "as is" without express or implied warranty.                  *
  **************************************************************************/
 
+
+//
+// Constants used by the HLT
+// ALICE Offlinw
+// and by EMCAL standalone debug tools
+//
+//
 namespace CaloConstants
 {
+  const int MAXHOSTS=20; // related to the emcal debug online display
+  const int TIMEBINS     = 256;       // number of sampling bins of the raw RO signal (we typically use 15-50; max is 1k+) 
+  const double TIMEBINWITH = 100E-9 ;   // each sample is 100 ns
+  const double TIMEBINMAX  =  TIMEBINS*TIMEBINWITH; 
+  //  const double TAU = 2.35;
+  //  const int  ORDER = 2;
+  
+  const int OVERFLOWCUT = 950;
+  const double HGLGFACTOR = 16;
+  
+  // const double ECENTRALHIT = 0.85; //Percentage of total enegry contain in a single tower for a central hit 
+
+  namespace ALTROConstants
+  {
+    const int ALTROMAXSAMPLES = 1008;    // The maximum number of samples of the ALTRO
+    const int ALTROMAXPRESAMPLES = 15;   // Maximum number of presamles from the ALTRO chip     
+    const int NALTROS        =   4;      // Number of ALTROs per frontend card
+    const int NALTROCHANNELS =  16;      // Number of readout channels per ALTRO chip
+    const int MINHARDWAREADDRESS = -2;   // Smallest possible HW address ( in offline )
+    //    const int MAXHARDWAREADDRESS = 4096; // Max harware address,  ( its to high ) 
+    const int MAXBINVALUE = 1023;        // Max possible ALTRO ADC value ( 10 bit )
+    const int NGAINS         =   2;      // Number of gains ( high + low )
+    const int HIGHGAIN    =   1;         // Mnemonic for High Gain
+    const int LOWGAIN     =   0;         // Mnemonic for Low Gain
+    const int HG = HIGHGAIN;             // Abbrevation for HIGHGAIN
+    const int LG = LOWGAIN;              // Abbrevation for LOWGAIN
+  }
+
+  //FEE constants common to PHOS EMCAL
+  const int CSPSPERFEE       =   32;    // Charge Sensitive Preamplifiers (CSPs) per FEE
+  const int NBRANCHES        =    2;    // Branches per RCU   
+  //  const int MAXHWADDRESSES   = 4096;    // Highest possible harware address
+  
+  namespace EMCALConstants
+  {
+    const int MAXHWADDR = 3279;
+    const int MAXCHANNELS = 1408;
+    const double ECENTRALHIT = 0.845678; //Percentage of total enegry contain in a single tower for a central hit  
+    const int NZROWSMOD      =  48;   // Number of columns per module
+    const int NXCOLUMNSMOD   =  24;   // Number of rows per module 
+    const int NROWSMOD     = NZROWSMOD;   // Number of rows per module
+    const int NCOLUMNSMOD  = NXCOLUMNSMOD;   // Number of columns per module 
+    
+    const int NRCUSPERSECTOR = 4;     // Number of RCUs per sector
+    const int NMODULES    =    10;    // Number of modules of the EMCAL detector
+    const int NRCUSPERMODULE =  2 ;   // Number of RCUs per Module
+    const int NFEECS         =  9;    // Number of Frontend cards per branch*/
+    const int NZROWSRCU     =   48;   // Number of Rows per RCU
+    const int NXCOLUMNSRCU  =   16;   // Number of columns per RCU
+    const int ORDER  = 2; // Order of shaping stages of the signal conditioning unit
+    const double TAU = 2.35;  // approximate shaping time
+    
+  }
+
+  namespace PHOSConstants
+  {
+    const int MAXHWADDR = 4096; 
+    //    const int MAXHARDWAREADDRESS = 4096; // Max harware address,  ( its to high )  
+    const int NZROWSMOD      =  56;   // Number of rows per module       
+    const int NXCOLUMNSMOD   =  64;   // Number of columns per module
+    const int NMODULES    =     5;    // Number of modules of the PHOS detector
+    const int NRCUSPERMODULE =  4 ;   // Number of RCUs per Module
+    const int NFEECS         =  14;   // Number of Frontend cards per branch
+  }
+
+  
   namespace FitAlgorithm
   {
-    enum fitAlgorithm { kLMS = 0, kCrude = 1, kPeakFinder = 2, kNeuralNet = 3, kFastFit= 4,
-                       kLogFit = 5, kStandard = 6,  kNONE = 7};
-  };
+    enum fitAlgorithm { kStandard = 0, kCrude = 1, kPeakFinder = 2, kNeuralNet = 3, kFastFit= 4, kFakeAltro = 9, kNONE = 8}; // possible return values
+  }
 
+  
+  
   namespace ReturnCodes
   {
-    enum kReturnCode {kFitPar=1, kDummy=-1, kCrude=-9, kNoFit=-99, kInvalid=-9999};// possible return values
-  };
+    enum kReturnCode {kFitPar=1, kDummy=-1, kCrude=-9, kNoFit=-99, kInvalid=-9999};  // possible return values
+  }
 
   namespace PeakFinderConstants
   {
-    const int  MAXSTART = 3;
-    const int  SAMPLERANGE = 15;
-  };
-};
-
+    const int  MAXSTART = 3;      //  Start max 3 samples into the digitized array
+    const int  SAMPLERANGE = 15;  //  Use maximum 15 samples for the Peak-Finder
+  }
+}
 
 //For easier notation
-namespace Algo = CaloConstants::FitAlgorithm;
-namespace Ret  = CaloConstants::ReturnCodes; 
-namespace PF   = CaloConstants::PeakFinderConstants;
+namespace ALTRO =   CaloConstants::ALTROConstants;       // For easier notation
+namespace Algo  =   CaloConstants::FitAlgorithm;         // For easier notation 
+namespace Ret   =   CaloConstants::ReturnCodes;          // For easier notation
+namespace PF    =   CaloConstants::PeakFinderConstants;  // For easier notation
+namespace CALO  =   CaloConstants;                       // For easier notation
+namespace EMCAL =   CaloConstants::EMCALConstants;       // For easier notation
+namespace PHOS  =   CaloConstants::PHOSConstants;        // For easier notation
+
 
 #endif
+