Commit 9fc01721 authored by Simon Spannagel's avatar Simon Spannagel
Browse files

Merge branch 'eventdefinitionm26_use_skip_time' into 'master'

Using skip_time in EventDefinitionM26

See merge request !415
parents 3310fbfd 6f68fe13
Pipeline #2521031 passed with stages
in 29 minutes and 2 seconds
......@@ -31,7 +31,7 @@ EventDefinitionM26::EventDefinitionM26(Configuration& config, std::vector<std::s
timeshift_ = config_.get<double>("time_shift");
shift_triggers_ = config_.get<int>("shift_triggers");
skip_time_ = config_.get<double>("skip_time");
skip_time_ps_ = static_cast<double>(Units::convert(skip_time_, "ps"));
config_.setDefault<std::string>("eudaq_loglevel", "ERROR");
// Set EUDAQ log level to desired value:
......@@ -129,6 +129,11 @@ unsigned EventDefinitionM26::get_next_event_with_det(const eudaq::FileReaderUP&
LOG(DEBUG) << "Pivot magic, begin: " << Units::display(begin, {"ns", "us", "ms"})
<< ", end: " << Units::display(end, {"ns", "us", "ms"})
<< ", duration = " << Units::display(begin + end, {"ns", "us"});
} else if(det == "tlu" && begin < skip_time_ps_) {
LOG(TRACE) << "Event time below skip time: " << Units::display(begin, {"ns", "us", "ms", "s"}) << "vs. "
<< Units::display(skip_time_, {"ns", "us", "ms", "s"});
continue;
}
return e->GetTriggerN();
}
......
......@@ -53,7 +53,7 @@ namespace corryvreckan {
long double timeshift_{};
int shift_triggers_{};
double skip_time_{};
double skip_time_ps_{};
// EUDAQ2 readers for all required files
eudaq::FileReaderUP readerTime_;
eudaq::FileReaderUP readerDuration_;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment