Main goal

The Advanced Subevent Debug Block (ASDB) is being proposed in strict accordance to the existing HADES subevent header structure. It enhances the features foreseen there instead of creating a new and possibly not backward compatible own structure.

Subevents created with the new ASDB will be backward compatible to existing unpackers.

Rules of Engagement

Each TRB endpoint inside the HADES setup (i.e. each module with an own subEvtId) can send an arbitrary number of ASDB together with the "real" physics data, which is enclosed in the "real" subevent. The unpacker must be able to cope with the situation that one module sends more than one ASDB. The number of ASDB sent with one subevent is up to the module designer's choice, and depends on the needs of the module (like error situation, problems found, ...)


According to the subevent header structure the ASDB consists at least of four 32bit words.

asdbEvtSize asdbEvtDecoding asdbEvtId asdbEvtTrigNr

All fields maintain their original definitions as given for the subevent header, with only one change: one bit in the most significant byte of the subEvtId is set in addition. This changes the subEvtId for the unpacker, so an ASDB will not be processed by the normal unpackers.

  • asdbEvtSize: this 32bit word carries the length of the ASDB block in bytes.

  • asdbEvtDecoding: contains necessary information on the binary structure of the subevent.

  • asdbEvtId: tells about the origin of the subevent, namely the detector subsystem and the module number there.

  • asdbEvtTrigNr: the full 24bit information as transmitted by TRB LVL1 triggers is stored there, as well as the trigger type

asdbEvtSize definition

The size of the ASDB is set here in units of bytes. It is strongly recommended to minimize the size of debug information if possible, as the ASDBs will go to event builder and tape.

asdbEvtDecoding definition

The ASDB data decoding is given here. As a rule the MSB is set to zero, while the LSB is always unequal zero. By this mean the endianess of data can be recognized.

  • D[31:24]: must be zero.

  • D[23:16]: word length of data inside the ASDB. 0 => byte, 1 => word, 2 => longword, ...

  • D[15:8]: actual decoding type

  • D[7:0]: actual decoding type, must not be zero.

asdbEvtId definition

The source of information (i.e. the detector subsystem and the module within this subsystem) is given here. The numbering scheme for the detector subsystems is identical to the subEvtHeader.

  • D[31]: error bit. "0" means OK, "1" means error

  • D[30:28]: reserved

  • D[27:25]: version information (if needed)

  • D[24]: ASDB bit, used to distinguish between normal subevents and ASDBs.

  • D[23:0]: subEvtIds as given by the normal subEvtHeader definitions

asdbTrigNr definition

One missing information in the subEvtHeader structure is the trigger type, which can be thought of as an additional part of the trigger tag. Therefore I propose to include this part of information inside this header word.

  • D[31:28]: reserved

  • D[27:24]: trigger type, as distributed by the TRB LVL1 packets

  • D[15:8]: trigger tag, as distributed by the TRB LVL1 packets

  • D[7:0]: trigger random number, as distributed by the TRB LVL1 packets

-- MichaelBoehmer - 02 Oct 2008
Topic revision: r2 - 2008-10-02, MichaelBoehmer
Copyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding Foswiki Send feedback | Imprint | Privacy Policy (in German)