63{
67
69
71 JLimit_t& numberOfEvents = inputFile.getLimit();
80
81 try {
82
83 JParser<> zap(
"Auxiliary program to trigger time slice data.");
84
93 zap[
'm'] =
make_field(merge,
"Allow merging of files w/o Monte Carlo headers");
95
97 }
98 catch(const exception &error) {
100 }
101
102
104
106
109 }
110
114
116
117 try {
119 }
122 }
123
124
125
126 if (parameters.disableHighRateVeto) {
127
128 NOTICE(
"Disabling high-rate veto of all PMTs." <<
endl);
129
131 }
132
134
136
137
138
140
146
147 const JBuildL1_t buildL1(parameters);
148 const JBuildL2_t buildL2(parameters.L2);
149 const JBuildL2_t buildSN(parameters.SN);
150 const JBuildL2_t buildNB(parameters.NB);
151
162
164
169
170
172
174
177
179
181
183
184 for ( ; in.hasNext() && counter != inputFile.getLimit(); ++counter) {
185
187
189
191
193
194 timesliceRouter.configure(*timeslice);
195
197
198
204
206
207 if (moduleRouter.hasModule(
super_frame->getModuleID())) {
208
209
210
212
213 const JModule&
module = moduleRouter.getModule(super_frame->getModuleID());
215
217
218
219
220 buffer.applyHighRateVeto(parameters.highRateVeto_Hz);
221
222
223
225
227
229
230
231
232 if (parameters.triggerNB.enabled) {
233
234 JSuperFrame2D_t::iterator __end =
partition(buffer.begin(), buffer.end(), parameters.triggerNB.pmts);
235
236 if (buffer.begin() != __end) {
237
241
242 JSuperFrame1D_t zbuf;
243
245
247 }
248 }
249
250
251
253
257
259
261
262
263
265
269
271
273
274
275
277
278 {
279 JTimeslice_t::value_type tv(
super_frame->getDAQChronometer(),
282
284
285 if (!tv.empty()) {
287 }
288 }
289
291 }
292 }
293
294
295
296 if (parameters.triggerNB.enabled) {
297
299
301
303
304 if (parameters.triggerNB.write()) {
305
307 getTriggerMask(triggerNB.getTriggerBit()),
309 timesliceRouter,
310 moduleRouter,
311 parameters.TMaxLocal_ns,
312 parameters.triggerNB.DMax_m,
313 getTimeRange(parameters.triggerNB));
314
316 }
317 }
318
320 }
321
323
326
330
332
334
336
338
340
342
344 timesliceRouter,
345 moduleRouter,
346 parameters.TMaxLocal_ns,
347 getTimeRange(parameters));
348
350
352 }
353
354 if (parameters.writeL0()) {
355
357
359
361 }
362
363 if (parameters.writeL1()) {
364
366
368
370 }
371
372 if (parameters.writeL2()) {
373
375
377
379 }
380
381 if (parameters.writeSN()) {
382
384
386
388 }
389
390 if (parameters.writeSummary()) {
391
393
395
397 }
398 }
400
402
403 const double factor = 1.0 / (
double) counter;
404
406 p->print(
cout, factor);
407 }
408
411 }
412
414
416
418}
#define DEBUG(A)
Message macros.
#define make_field(A,...)
macro to convert parameter to JParserTemplateElement object
Router for direct addressing of module data in detector data structure.
Data structure for a composite optical module.
Auxiliary class for CPU timing and usage.
static void disable()
Disable timers.
Template definition of a multi-dimensional oscillation probability interpolation table.
General purpose class for object reading from a list of file names.
Auxiliary class to build KM3NETDAQ::JDAQEvent for a triggered event.
const JDAQChronometer & getDAQChronometer() const
Get DAQ chronometer.
Auxiliary class to set DAQ system clock parameters.
void set(const JDAQClock_t clock)
Set clock type.
void load(const std::string &file_name, JDetector &detector)
Load detector from input file.
double getMaximalDistance(const JDetector &detector, const bool option=false)
Get maximal distance between modules in detector.
This name space includes all other name spaces (except KM3NETDAQ, KM3NET and ANTARES).
KM3NeT DAQ data structures and auxiliaries.
double getFrameTime()
Get frame time duration.
void setDAQLongprint(const bool option)
Set DAQ print option.
double getRTS()
Get TDC dynamic range.
static const int HIGH_RATE_VETO_DISABLE
Enable (disable) use of high-rate veto test if this status bit is 0 (1);.
Match of two events considering overlap in time and position.
Transmission with position.
Empty structure for specification of parser element that is initialised (i.e. does not require input)...
Auxiliary class to select ROOT class based on class name.
Auxiliary class for defining the range of iterations of objects.
static counter_type max()
Get maximum counter value.
Router for fast addressing of hits in KM3NETDAQ::JDAQTimeslice data structure as a function of the op...