StRoot  1
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Groups Pages
StPicoEpdHit.cxx
1 // PicoDst headers
2 #include "StPicoMessMgr.h"
3 #include "StPicoEpdHit.h"
4 
5 //
6 // \class StPicoEpdHit
7 // \author Mike Lisa
8 // \date 06 March 2018
9 // \brief Holds signals for tiles in STAR Event Plane Detector
10 
11 /*************************************************
12  * Hit Class for the STAR Event Plane Detector.
13  * There is one "hit" for each (good) tile in the detector
14  *
15  * Total size of this object is 10 bytes
16  * This object contains only
17  * 1) the id of the tile, compacted into a Short_t
18  * 2) the QT information (ADC, TDC, TAC, hasTac flag, status flag)
19  * compacted into 32 bits (Int_t
20  * 3) the gain-corrected energy loss, in units of the
21  * most probable value (MPV) of a single MIP in the tile,
22  * according to a Landau distribution. Stored as Float_t
23  *
24  * The StPicoEpdHit in the StMuDST is basically the same as
25  * the StMuEpdHit object in the muDst and
26  * the StEpdHit object in StEvent
27  * Except
28  * 1) it does not inherit from StObject, so can be used in "vanilla root"
29  * 2) there is no "Truth ID" which is used for simulations.
30  *
31  * - Mike Lisa March 2018
32  ************************************************/
33 
34 ClassImp(StPicoEpdHit)
35 
36 //_________________
37 StPicoEpdHit::StPicoEpdHit() : TObject(), mId(0), mQTdata(0), mnMIP(0) {
38  /* no-op */
39 }
40 
41 //_________________
42 StPicoEpdHit::StPicoEpdHit(Int_t position, Int_t tile,
43  Int_t EW, Int_t ADC, Int_t TAC,
44  Int_t TDC, Bool_t hasTAC, Float_t nMIP,
45  Bool_t statusIsGood) :
46  TObject(),
47  mId( (100*position + tile)*EW ),
48  mQTdata( (ADC & 0x0FFF) | (TAC & 0x0FFF) << 12 | (TDC & 0x001F) << 24 | hasTAC << 29 | statusIsGood << 30 ),
49  mnMIP(nMIP) {
50  /* no-op */
51 }
52 
53 //_________________
54 StPicoEpdHit::StPicoEpdHit(Short_t id, Int_t QTdata, Float_t nMIP) :
55  TObject(), mId(id), mQTdata(QTdata), mnMIP(nMIP) {
56  /* no-op */
57 }
58 
59 //_________________
61  mId = hit.mId;
62  mQTdata = hit.mQTdata;
63  mnMIP = hit.mnMIP;
64 }
65 
66 //_________________
68  /* no-op */
69 }
70 
71 //_________________
72 void StPicoEpdHit::Print(const Char_t *option __attribute__((unused)) ) const {
73  LOG_INFO << "EPD hit id: " << mId << " QT data: " << mQTdata << " nMIP: " << mnMIP << endm;
74 }
Float_t mnMIP
gain calibrated energy loss in tile, in units of Landau MPV for one MIP
Definition: StPicoEpdHit.h:138
virtual void Print(const Char_t *option="") const
Print EPD hit information.
virtual ~StPicoEpdHit()
Destructor.
StPicoEpdHit()
default constructor. sets all values empty