epic-drich-beam-test-analysis
ePIC dRICH beam test analysis framework
Loading...
Searching...
No Matches
alcor_data.h File Reference

Data structures and utilities for ALCOR hit-level data handling. More...

#include "TTree.h"
#include "utility.h"

Go to the source code of this file.

Classes

struct  alcor_data_struct
 Plain data container for a single ALCOR hit. More...
 
class  alcor_data
 First-level I/O helper class from the ALCOR decoder. More...
 

Macros

#define _ALCOR_CC_TO_NS_   3.125
 
#define _ALCOR_ROLLOVER_TO_CC_   32768
 

Enumerations

enum  alcor_hit_struct { alcor_hit = 1 , trigger_tag = 9 , start_spill = 7 , end_spill = 15 }
 Encodes the logical type of an ALCOR hit. More...
 
enum  hit_mask {
  _HITMASK_streaming_ring_trigger_ = 1 , _HITMASK_ring_tag_first = 2 , _HITMASK_ring_tag_second = 3 , _HITMASK_hough_ring_tag_first = 11 ,
  _HITMASK_hough_ring_tag_second = 12 , _HITMASK_cross_talk = 28 , _HITMASK_afterpulse = 29 , _HITMASK_part_lane = 30 ,
  _HITMASK_dead_lane = 31
}
 Bit positions used inside alcor_data_struct::hit_mask. More...
 

Detailed Description

Data structures and utilities for ALCOR hit-level data handling.

This header defines:

  • A base, retro compatible data struct (alcor_data_struct) that reads data from ALCOR decoder
  • Enumerations describing hit types and bit-level hit masks.
  • A lightweight wrapper class (alcor_data) that provides:
    • Safe accessors and mutators
    • Derived quantities (indices, global time, etc.)
    • Utility predicates (hit type checks)
    • ROOT I/O helpers

The design intentionally separates storage (struct) from logic (class) to keep ROOT I/O simple while allowing richer semantics at the analysis level.

Todo:
Implement bit-wise manipulation for global index encoding. global index is a 32-bit integer, which count be used to contain: device (10-bit) [0-1023] fifo (7-bit) [0-127] channel (6-bit) [0-63] tdc (2-bit) [0-3] unused (7-bit)

Enumeration Type Documentation

◆ alcor_hit_struct

Encodes the logical type of an ALCOR hit.

Let the user know if the hit in the stream is a simple hit, start or end of spill signal or a trigger hit

◆ hit_mask

enum hit_mask

Bit positions used inside alcor_data_struct::hit_mask.

Each enumerator corresponds to a single bit index.