43   using namespace KM3NETDAQ;
 
   47   Long64_t               numberOfSlices;
 
   59     JParser<> zap(
"Auxiliary program to write time slices with random data.");
 
   63     zap[
'a'] = 
make_field(detectorFile,        
"detector.");
 
   68     zap[
'T'] = 
make_field(TCLB_ns,             
"CLB state-machine time jitter")                                    = 256;     
 
   69     zap[
'N'] = 
make_field(recycling,           
"number of recycles / time interval for sampling data")             = make_pair(0, 0.0);
 
   75   catch(
const exception &error) {
 
   76     FATAL(error.what() << endl);
 
   80   gRandom->SetSeed(seed);
 
   87   if (pmtParameters.getQE() != 1.0) {
 
   89     WARNING(
"Correct background rates with global efficiency " << pmtParameters.getQE() << endl);
 
   91     rates_Hz.correct(pmtParameters.getQE());
 
   94   DEBUG(
"PMT parameters: " << endl << pmtParameters << endl);
 
   95   DEBUG(
"K40 rates:      " << endl << rates_Hz      << endl);
 
  106   JPMTParametersMap::Throw(
false);
 
  111   if (runbyrun.is_valid()) {
 
  113     NOTICE(
"Using run-by-run:" << endl << runbyrun << endl);
 
  115     if (!runbyrun.hasNext()) {
 
  116       FATAL(
"Run-by-run simulation yields no input." << endl);
 
  119     if (rates_Hz.getSinglesRate() != 0.0) {
 
  120       WARNING(
"Run-by-run simulation discards singles rate [Hz] " << rates_Hz.getSinglesRate() << endl);
 
  134     NOTICE(
"Using fixed rates [Hz]: " << rates_Hz << endl);
 
  147   JTimer timerco(
"constructor");
 
  148   JTimer timerrc(
"recycle");
 
  163   for ( ; counter != numberOfSlices; ) {
 
  165     STATUS(
"slice: " << setw(10) << counter << 
'\r'); 
DEBUG(endl);    
 
  167     int frame_index = counter + 1;
 
  169     if (runbyrun.hasNext()) {
 
  171       summaryRouter.update(runbyrun.next());
 
  173       summaryRouter.correct(dynamic_cast<const JPMTDefaultSimulatorInterface&>(simbad.getPMTSimulator()));
 
  175       frame_index = summaryRouter.getFrameIndex();
 
  176       run         = summaryRouter.getRunNumber();
 
  193     for (
size_t i = 1; i <= recycling.first && counter != numberOfSlices; ++i) {
 
  195       STATUS(
"slice: " << setw(10) << counter << 
'\r'); 
DEBUG(endl);    
 
  199       timeslice.recycle(recycling.second);
 
  209     timerco.print(cout, 
true);
 
  210     timerrc.print(cout, 
true);
 
  211     timerIO.print(cout, 
true);
 
Auxiliary class to select summary data (KM3NETDAQ::JDAQSummaryslice) from the specified raw data file...
 
Utility class to parse command line options. 
 
Default implementation of the simulation of K40 background. 
 
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
 
Data structure for UTC time. 
 
unsigned int JTDC_t
leading edge [ns] 
 
double getTimeOfFrame(const int frame_index)
Get start time of frame in ns since start of run for a given frame index. 
 
K40 simulation based on run-by-run information. 
 
void setDAQLongprint(const bool option)
Set DAQ print option. 
 
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object 
 
Auxiliary class for CPU timing and usage. 
 
Auxiliary class for map of PMT parameters. 
 
Router for fast addressing of summary data in JDAQSummaryslice data structure as a function of the op...
 
PMT simulation based on run-by-run information. 
 
virtual const char * what() const override
Get error message. 
 
void load(const std::string &file_name, JDetector &detector)
Load detector from input file. 
 
then usage $script< input_file >< detector_file > fi set_variable OUTPUT_DIR set_variable SELECTOR JDAQTimesliceL1 set_variable DEBUG case set_variable DEBUG
 
do set_variable DETECTOR_TXT $WORKDIR detector
 
Timeslice with random data. 
 
Auxiliary class for K40 rates.