/// \author Laurent Aphecetche, Christian Finck Subatech
/// \author Bogdan Vulpescu, LPC Clermont-Ferrand
+using std::endl;
+using std::cout;
+using std::ofstream;
/// \cond CLASSIMP
ClassImp(AliMUONTriggerIO)
/// \endcond
Bool_t trigx = kFALSE;
// read two lut addresses at once, 32768/2=16384 times
- fread(buffer,fgkLocalLutSize,1,flut);
+ if (fread(buffer,fgkLocalLutSize,1,flut) == 0) {
+ AliWarning("Error reading the LUT file");
+ return;
+ }
// create the 32767 addresses for the 4-bits lpt and hpt half-bytes
for (UShort_t ilut = 0; ilut < fgkLocalLutSize*2; ilut += 2)
ReadLocalLUT(lut,fRegionalTrigger.LocalBoardId(i),flut);
}
+ //
+ // 1st/2nd cut code pt cut [GeV/c]
+ //
+ // 0 0.5 (a.k.a. Apt)
+ // 1 1.0 (a.k.a. Lpt)
+ // 2 1.7 (a.k.a. Hpt)
+ // 3 4.2 (a.k.a. infinity)
+ // 4 free
+ // .
+ // .
+ // .
+ //15 default (for backward compatibility)
+
+ UChar_t lutCode = 0xFF;
+
+ if (!fread(&lutCode,1,1,flut)) {
+ AliWarning("No LUT info in the file (old version)");
+ }
+ AliInfo(Form("LUT code: 0x%02x",lutCode));
+
fclose(flut);
-
+
+ lut.SetLutCode(lutCode);
+
return kTRUE;
}
{
/// Fill the various masks store from files
- if ( !regionalFile || strlen(regionalFile)==0 )
+ if ( !regionalConfig || !regionalFile || strlen(regionalFile)==0 )
{
AliError("Must have a regional file name to proceeed");
return kFALSE;