LArSoft  v07_13_02
Liquid Argon Software toolkit - http://larsoft.org/
LArRawInputDriverJP250L.h
Go to the documentation of this file.
1 
16 
17 #include <fstream>
18 #include <string>
19 #include <vector>
20 
21 #include "TFile.h"
22 #include "TTree.h"
23 
25 namespace lris {
26  class LArRawInputDriverJP250L;
27 }
28 
32  public:
33  // Required constructor
36  art::SourceHelper const &pm);
37 
38  // Required by FileReaderSource:
39  void closeCurrentFile();
40  void readFile(std::string const &name,
41  art::FileBlock* &fb);
42  bool readNext(art::RunPrincipal* const &inR,
43  art::SubRunPrincipal* const &inSR,
44  art::RunPrincipal* &outR,
45  art::SubRunPrincipal* &outSR,
46  art::EventPrincipal* &outE);
47 
48  private:
49 
50  // --- data members:
52 
53  // added by E.Iwai
54  TTree* m_eventTree;
55  unsigned int m_nEvent;
56  unsigned int m_current;
57  unsigned short m_runID;
58  unsigned int m_unixtime;
59  unsigned short m_nChannels;
60  unsigned short m_nSamples;
61  unsigned short* m_data;
62 
63 }; // LArRawInputDriverJP250L
unsigned int m_unixtime
unix timestamp of the start of the run
unsigned int m_nEvent
number of triggers in the TTree
void readFile(std::string const &name, art::FileBlock *&fb)
unsigned short m_runID
run ID, has to start from 1
LArRawInputDriverJP250L(fhicl::ParameterSet const &pset, art::ProductRegistryHelper &helper, art::SourceHelper const &pm)
TTree * m_eventTree
TTree containing information from each trigger.
TFile fb("Li6.root")
unsigned short * m_data
the ADC of each time sample for each channel
bool readNext(art::RunPrincipal *const &inR, art::SubRunPrincipal *const &inSR, art::RunPrincipal *&outR, art::SubRunPrincipal *&outSR, art::EventPrincipal *&outE)
unsigned short m_nChannels
number of channels in the detector
unsigned short m_nSamples
number of time samples per channel
Conversion of binary data to root files.
art::SourceHelper const & principalMaker_
unsigned int m_current
current entry in the TTree