X-Git-Url: http://git.uio.no/git/?a=blobdiff_plain;f=ITS%2FAliITSTrigger.cxx;h=423d2248e9e40d5bfa0ca16470886671a5452ff9;hb=5c47990a8bb39eca2daf2f33033ff12555fa8e1f;hp=93d14cfaa565e24f5674f8c15ff423c9b9385a35;hpb=698b2e52352c222f688d9eb10d094fc9566e537c;p=u%2Fmrichter%2FAliRoot.git diff --git a/ITS/AliITSTrigger.cxx b/ITS/AliITSTrigger.cxx index 93d14cfaa56..423d2248e9e 100644 --- a/ITS/AliITSTrigger.cxx +++ b/ITS/AliITSTrigger.cxx @@ -16,6 +16,7 @@ /* $Id$ */ +#include #include "AliLog.h" #include "AliRun.h" @@ -30,29 +31,31 @@ //______________________________________________________________________ ClassImp(AliITSTrigger) //////////////////////////////////////////////////////////////////////// -// -// Version 1 -// Modified by D. Elia, C. Jorgensen -// March 2006 -// -// Version 0 -// Written by J. Conrad, E. Lopez Torres -// October 2005 -// -// AliITSTrigger: implementation of the SPD Fast-OR based triggers. -// +// // +// Version 1 // +// Modified by D. Elia, C. Jorgensen // +// March 2006 // +// // +// Version 0 // +// Written by J. Conrad, E. Lopez Torres // +// October 2005 // +// // +// AliITSTrigger: implementation of the SPD Fast-OR based triggers. // +// // //////////////////////////////////////////////////////////////////////// //______________________________________________________________________ AliITSTrigger::AliITSTrigger() - : AliTriggerDetector() -{ - SetName("ITS"); - CreateInputs(); + : AliTriggerDetector(), +fGlobalFOThreshold(1), +fHighMultFOThreshold(190){ + + //standard constructor + SetName("ITS"); - // set parameters to define trigger condition thresholds - fGlobalFOThreshold = 1; - fHighMultFOThreshold = 150; + // set parameters to define trigger condition thresholds + //fGlobalFOThreshold = 1; + //fHighMultFOThreshold = 150; } //______________________________________________________________________ @@ -63,8 +66,8 @@ void AliITSTrigger::CreateInputs() // Do not create inputs again!! if( fInputs.GetEntriesFast() > 0 ) return; - fInputs.AddLast( new AliTriggerInput( "ITS_SPD_GFO_L0", "Global, Fast OR all detectors", 0x01 ) ); - fInputs.AddLast( new AliTriggerInput( "ITS_SPD_HMULT_L0", "High Multiplicity", 0x02 ) ); + fInputs.AddLast( new AliTriggerInput( "SPD_GFO_L0", "SPD", 0 ) ); + fInputs.AddLast( new AliTriggerInput( "SPD_HMULT_L0", "SPD", 0 ) ); } @@ -107,16 +110,19 @@ void AliITSTrigger::MultiplicityTriggers(TObjArray* digDet, TTree* treeD, AliITS { // simple FO triggers that only cares about the multiplicity + const Int_t nChipsInModule = 5; Int_t startSPD = geom->GetStartSPD(); Int_t lastSPD = geom->GetLastSPD(); Int_t totalNumberOfFO = 0; + Int_t totalNumberOfFOLay1 = 0; Int_t ndigitsInChip[5]; // loop over modules (ladders) for (Int_t moduleIndex=startSPD; moduleIndexGetEvent(moduleIndex); TClonesArray* digits = (TClonesArray*) (digDet->At(0)); // SPD only. + Int_t lay,stav,det; geom->GetModuleId(moduleIndex,lay,stav,det); // get number of digits in this module Int_t ndigitsInModule = digits->GetEntriesFast(); @@ -128,13 +134,14 @@ void AliITSTrigger::MultiplicityTriggers(TObjArray* digDet, TTree* treeD, AliITS for( Int_t iDig=0; iDigAt(iDig); Int_t column = dp->GetCoord1(); - Int_t isChip = Int_t(column/32.); + Int_t isChip = nChipsInModule - Int_t(column/32.) - 1; ndigitsInChip[isChip]++; } // get number of FOs in the module for( Int_t ifChip=0; ifChip<5; ifChip++ ) { if( ndigitsInChip[ifChip] >= 1 ) { - totalNumberOfFO++; + totalNumberOfFO++; + if(lay==1) totalNumberOfFOLay1++; } } // end of loop over modules @@ -142,10 +149,10 @@ void AliITSTrigger::MultiplicityTriggers(TObjArray* digDet, TTree* treeD, AliITS // produce input trigger condition if (totalNumberOfFO>=fGlobalFOThreshold) - SetInput( "ITS_SPD_GFO_L0" ); + SetInput( "SPD_GFO_L0" ); - if (totalNumberOfFO>=fHighMultFOThreshold) - SetInput( "ITS_SPD_HMULT_L0" ); + if (totalNumberOfFOLay1>=fHighMultFOThreshold) + SetInput( "SPD_HMULT_L0" ); return;