Back Midas Rome Roody Rootana
  Rome Analyzer Framework  Not logged in ELOG logo
Entry  08 Mar 2006, Giovanni Signorelli, Bug Report, gAnalyzer->GetEventID() fails if EventID>127-48 
    Reply  02 Apr 2006, Matthias Schneebeli, Bug Report, gAnalyzer->GetEventID() fails if EventID>127-48 
Message ID: 119     Entry time: 08 Mar 2006     Reply to this: 120
Author: Giovanni Signorelli 
Topic: Bug Report 
Subject: gAnalyzer->GetEventID() fails if EventID>127-48 
This bug happened when reading a .MID file containing events with event_id=99.
The ReadMidas task is not able to read the event because it is not recognized.
This event_id, when recovered with GetEventID() method was transformed to a negative value. This probably happened because there is a +48 addition at some place (in SetEventID) and a -48 on GetEventID. This casuses the unsigned char to be recovered as a signed number (lots of FFFF in front of it).

Furthermore it is not writtenanywhere that EventID<0xFF.

I could solve the problem
1) by setting EventID = 16, for instance
2) by modifying ROMEAnalyzer.h as follows
// Event ID
Int_t GetEventID() { return (fEventID-48)&0xFF; }
char GetEventIDChar() { return (fEventID)&0xFF; }
ELOG V3.1.4-2e1708b5