]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONRegionalTriggerBoard.cxx
Corrected Doxygen warnings:
[u/mrichter/AliRoot.git] / MUON / AliMUONRegionalTriggerBoard.cxx
index 586153be5688ac7b06e5b1aca962612cfeeecb41..2b6ae117c247717a60f9bc52e9601b0224b3a70f 100644 (file)
 /* $Id$ */
 
 //*-- Author: Rachid Guernane (LPCCFd)
+//    DIMUON REGIONAL TRIGGER IMPLEMENTATION
+//    ENTRY ARE LOCAL BOARD RESPONSES
+//    OUTPUT IS 12-BIT WORD
+//    ALGORITHM IS SIMILAR TO THE GLOBAL ONE
 
 #include "AliMUONRegionalTriggerBoard.h"
 
@@ -42,7 +46,10 @@ AliMUONRegionalTriggerBoard::AliMUONRegionalTriggerBoard(const char *name, Int_t
 //___________________________________________
 void AliMUONRegionalTriggerBoard::Response()
 {
-   Int_t t[16];
+/*   
+  RESPONSE IS GIVEN FOLLOWING THE REGIONAL ALGORITHM
+*/
+  Int_t t[16];
 
    for (Int_t i=0;i<16;i++) t[i] = fLocalResponse[i] & fMask[i];
 
@@ -54,13 +61,11 @@ void AliMUONRegionalTriggerBoard::Response()
       
       for (Int_t j=0;j<rank;j++)
       {
-         UShort_t athres = Algo(t[2*j],t[2*j+1],"APT",i);
+         UShort_t lthres = Algo(t[2*j],t[2*j+1],"LPT",i);
 
-         UShort_t lthres = Algo(t[2*j],t[2*j+1],"LPT",i); lthres <<= 4;
+         UShort_t hthres = Algo(t[2*j],t[2*j+1],"HPT",i); hthres <<= 4;
 
-         UShort_t hthres = Algo(t[2*j],t[2*j+1],"HPT",i); hthres <<= 8;
-
-         t[ip] = athres | lthres | hthres;
+         t[ip] = lthres | hthres;
 
          ip++;
       }
@@ -68,17 +73,20 @@ void AliMUONRegionalTriggerBoard::Response()
       rank /= 2; 
    }
 
-   fResponse = t[0]; // 12-bit [H4:L4:A4]
+   fResponse = t[0]; // 8-bit [H4:L4]
 }
 
 //___________________________________________
 UShort_t AliMUONRegionalTriggerBoard::Algo(UShort_t i, UShort_t j, char *thres, Int_t level)
 {
-   TBits a(12), b(12); a.Set(12,&i); b.Set(12,&j);
+// IMPLEMENTATION OF THE REGIONAL ALGORITHM
+// SIMILAR TO THE GLOBAL ALGORITHM EXCEPT FOR THE
+// INPUT LAYER
+  TBits a(8), b(8); a.Set(8,&i); b.Set(8,&j);
 
    TBits trg1(2), trg2(2), trg(2);
 
-   if (!strcmp(thres,"APT"))
+   if (!strcmp(thres,"LPT"))
    {
       if (!level)
       {         
@@ -91,7 +99,7 @@ UShort_t AliMUONRegionalTriggerBoard::Algo(UShort_t i, UShort_t j, char *thres,
          trg2[0] = b[2]; trg2[1] = b[3];
       }
    }
-   else if (!strcmp(thres,"LPT"))
+   else
    {
       if (!level)
       {         
@@ -101,20 +109,7 @@ UShort_t AliMUONRegionalTriggerBoard::Algo(UShort_t i, UShort_t j, char *thres,
       else
       {
          trg1[0] = a[6]; trg1[1] = a[7]; 
-         trg2[0] = b[6]; trg2[1] = b[7];
-      }
-   }
-   else
-   {
-      if (!level)
-      {         
-         trg1[0] = a[4]; trg1[1] = a[5]; 
-         trg2[0] = b[4]; trg2[1] = b[5];
-      }
-      else
-      {
-         trg1[0] = a[10]; trg1[1] = a[11]; 
-         trg2[0] = b[10]; trg2[1] = b[11];         
+         trg2[0] = b[6]; trg2[1] = b[7];         
       }
    }
        
@@ -126,20 +121,15 @@ UShort_t AliMUONRegionalTriggerBoard::Algo(UShort_t i, UShort_t j, char *thres,
    }
    else
    {
-      if (!strcmp(thres,"APT"))
+       if (!strcmp(thres,"LPT"))
       {
          trgLS1[0] = a[1]; trgUS1[0] = a[0]; 
          trgLS2[0] = b[1]; trgUS2[0] = b[0];
       }
-      else if (!strcmp(thres,"LPT"))
-      {
-         trgLS1[0] = a[5]; trgUS1[0] = a[4]; 
-         trgLS2[0] = b[5]; trgUS2[0] = b[4];
-      }
       else
       {
-         trgLS1[0] = a[9]; trgUS1[0] = a[8]; 
-         trgLS2[0] = b[9]; trgUS2[0] = b[8];         
+         trgLS1[0] = a[5]; trgUS1[0] = a[4]; 
+         trgLS2[0] = b[5]; trgUS2[0] = b[4];         
       }
    }
 
@@ -161,10 +151,14 @@ UShort_t AliMUONRegionalTriggerBoard::Algo(UShort_t i, UShort_t j, char *thres,
 
    return rv;
 }
+
 //___________________________________________
-void AliMUONRegionalTriggerBoard::Scan(Option_t*)
+void AliMUONRegionalTriggerBoard::Scan(Option_t*) const
 {
-   for (Int_t i=0; i<16; i++) 
+/*  
+  SCAN LOCAL BOARD ENTRIES 
+*/
+  for (Int_t i=0; i<16; i++) 
    {
       TBits b;
       b.Set(6,&fLocalResponse[i]);
@@ -178,6 +172,7 @@ void AliMUONRegionalTriggerBoard::Scan(Option_t*)
 //___________________________________________
 void AliMUONRegionalTriggerBoard::Mask(Int_t index, UShort_t mask)
 {
+// MASK ENTRY index
   if ( index>=0 && index < 16 ) 
   {
     fMask[index]=mask;