Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
DCAEN1290TDCHit.h
Go to the documentation of this file.
1 // $Id$
2 // $HeadURL$
3 //
4 // File: DCAEN1290TDCHit.h
5 // Created: Mon Jul 7 16:14:54 EDT 2014
6 // Creator: davidl (on Linux gluon104.jlab.org 2.6.32-358.23.2.el6.x86_64)
7 //
8 
9 #ifndef _DCAEN1290TDCHit_
10 #define _DCAEN1290TDCHit_
11 
12 #include <DAQ/DDAQAddress.h>
13 
15 
16  /// Holds TDC hit from CAEN VX1290A
17 
18  public:
20 
21  DCAEN1290TDCHit(uint32_t rocid=0, uint32_t slot=0, uint32_t channel=0, uint32_t itrigger=0, uint32_t edge=0, uint32_t tdc_num=0, uint32_t event_id=0, uint32_t bunch_id=0, uint32_t time=0):DDAQAddress(rocid, slot, channel, itrigger),edge(edge),tdc_num(tdc_num),event_id(event_id),bunch_id(bunch_id),time(time){}
22 
23  uint32_t edge; // 0=leading edge, 1=trailing edge
24  uint32_t tdc_num; // TDC chip (0-3)
25  uint32_t event_id; // event ID (from TDC header word)
26  uint32_t bunch_id; // bunch ID (from TDC header word)
27  uint32_t time; // from Pulse Time Data word
28 
29  // This method is used primarily for pretty printing
30  // the second argument to AddString is printf style format
31  void toStrings(vector<pair<string,string> > &items)const{
33  AddString(items, "edge", "%d", edge);
34  AddString(items, "tdc_num", "%d", tdc_num);
35  AddString(items, "event_id", "%d", event_id);
36  AddString(items, "bunch_id", "%d", bunch_id);
37  AddString(items, "time", "%d", time);
38  }
39 };
40 
41 #endif // _DCAEN1290TDCHit_
42 
JOBJECT_PUBLIC(DCAEN1290TDCHit)
Holds TDC hit from CAEN VX1290A.
void toStrings(vector< pair< string, string > > &items) const
Definition: DDAQAddress.h:47
void toStrings(vector< pair< string, string > > &items) const
This class holds the Crate, Slot, Channel address for a digitized value from the DAQ system...
Definition: DDAQAddress.h:26
DCAEN1290TDCHit(uint32_t rocid=0, uint32_t slot=0, uint32_t channel=0, uint32_t itrigger=0, uint32_t edge=0, uint32_t tdc_num=0, uint32_t event_id=0, uint32_t bunch_id=0, uint32_t time=0)
uint32_t channel
Definition: DDAQAddress.h:34
uint32_t rocid
Definition: DDAQAddress.h:32
uint32_t itrigger
Definition: DDAQAddress.h:35
uint32_t slot
Definition: DDAQAddress.h:33