Hall-D Software  alpha
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
Df250WindowRawData.h
Go to the documentation of this file.
1 // $Id$
2 // $HeadURL$
3 //
4 // File: Df250WindowRawData.h
5 // Created: Tue Aug 7 15:24:27 EDT 2012
6 // Creator: davidl (on Darwin harriet.jlab.org 11.4.0 i386)
7 //
8 
9 #ifndef _Df250WindowRawData_
10 #define _Df250WindowRawData_
11 
12 #include <DAQ/DDAQAddress.h>
13 
15 
16  /// Holds window raw data samples for one event in
17  /// one channel of a single f250 Flash ADC module.
18 
19  public:
21 
22  Df250WindowRawData(uint32_t rocid=0, uint32_t slot=0, uint32_t channel=0, uint32_t itrigger=0):DDAQAddress(rocid, slot, channel, itrigger),invalid_samples(false),overflow(false){}
23 
24  vector<uint16_t> samples;// from Window Raw Data words 2-N (each word contains 2 samples)
25  bool invalid_samples; // true if any sample's "not valid" bit set
26  bool overflow; // true if any sample's "overflow" bit set
27 
28  // This method is used primarily for pretty printing
29  // the second argument to AddString is printf style format
30  void toStrings(vector<pair<string,string> > &items)const{
32  AddString(items, "Nsamples", "%d", samples.size());
33  AddString(items, "invalid_samples", "%d", invalid_samples);
34  AddString(items, "overflow", "%d", overflow);
35  }
36 
37 };
38 
39 #endif // _Df250WindowRawData_
40 
void toStrings(vector< pair< string, string > > &items) const
Definition: DDAQAddress.h:47
vector< uint16_t > samples
JOBJECT_PUBLIC(Df250WindowRawData)
Holds window raw data samples for one event in one channel of a single f250 Flash ADC module...
This class holds the Crate, Slot, Channel address for a digitized value from the DAQ system...
Definition: DDAQAddress.h:26
uint32_t channel
Definition: DDAQAddress.h:34
Df250WindowRawData(uint32_t rocid=0, uint32_t slot=0, uint32_t channel=0, uint32_t itrigger=0)
uint32_t rocid
Definition: DDAQAddress.h:32
void toStrings(vector< pair< string, string > > &items) const
uint32_t itrigger
Definition: DDAQAddress.h:35
uint32_t slot
Definition: DDAQAddress.h:33