#include <TCMakerChannelAdjacencyAlgorithm.hpp>
◆ add_window_to_record()
void TCMakerChannelAdjacencyAlgorithm::add_window_to_record |
( |
TAWindow | window | ) |
|
|
private |
◆ configure()
void TCMakerChannelAdjacencyAlgorithm::configure |
( |
const nlohmann::json & | config | ) |
|
|
virtual |
Reimplemented from triggeralgs::TriggerCandidateMaker.
Definition at line 83 of file TCMakerChannelAdjacencyAlgorithm.cpp.
84{
86
87 if (config.is_object()) {
88 if (config.contains("trigger_on_adc"))
90 if (config.contains("trigger_on_n_channels"))
92 if (config.contains("adc_threshold"))
94 if (config.contains("n_channels_threshold"))
96 if (config.contains("window_length"))
98 }
99
100
102 TLOG_DEBUG(TLVL_VERY_IMPORTANT) <<
"[TCM:CA] Not triggering! All trigger flags are false!";
104 }
105
106 return;
107}
uint16_t m_n_channels_threshold
timestamp_t m_window_length
bool m_trigger_on_n_channels
virtual void configure(const nlohmann::json &config)
#define TLOG_DEBUG(lvl,...)
◆ construct_tc()
Definition at line 110 of file TCMakerChannelAdjacencyAlgorithm.cpp.
111{
113
121
122
123
124
129 }
130 }
131
132 return tc;
133}
std::vector< TriggerActivity > inputs
TAWindow m_current_window
TriggerCandidate::Type m_tc_type_out
Configurable TC type output.
std::vector< TriggerPrimitive > inputs
std::vector< dunedaq::trgdataformats::TriggerActivityData > inputs
◆ process()
TA processing function that creates & fills TCs.
- Parameters
-
input_ta[in] | Input TA for the triggering algorithm |
output_tc[out] | Output vector of TCs to fill by the algorithm |
Implements triggeralgs::TriggerCandidateMaker.
Definition at line 26 of file TCMakerChannelAdjacencyAlgorithm.cpp.
28{
29
30
34 }
35
36
37
39 TLOG_DEBUG(TLVL_DEBUG_HIGH) <<
"[TCM:CA] Window not yet complete, adding the activity to the window.";
41 }
42
43 else {
45 << "[TCM:CA] TAWindow is at required length but specified threshold not met, shifting window along.";
47 }
48
49
50
51
52
58 <<
" len(tc.inputs) " << tc.
inputs.size();
59
60 for (
const auto& ta : tc.
inputs) {
61 TLOG_DEBUG(TLVL_DEBUG_ALL) <<
"[TCM:CA] [TA] ta.time_start=" << ta.time_start <<
" ta.time_end=" << ta.time_end
62 << " ta.adc_integral=" << ta.adc_integral;
63 }
64
65 output_tc.push_back(tc);
67 }
68
69
70
71
72
76 }
77
79 return;
80}
void clear()
Clear all inputs.
void add(const TriggerActivity &input_ta)
Add the input TA's contribution to the total ADC, increase the hit count of all of the channels which...
void reset(TriggerActivity const &input_ta)
Reset window content on the input.
uint16_t n_channels_hit()
void move(TriggerActivity const &input_ta, timestamp_t const &window_length)
Find all of the TAs in the window that need to be removed if the input_ta is to be added and the size...
uint64_t m_activity_count
TriggerCandidate construct_tc() const
◆ m_activity_count
uint64_t triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_activity_count = 0 |
|
private |
◆ m_adc_threshold
uint32_t triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_adc_threshold = 1200000 |
|
private |
◆ m_current_window
TAWindow triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_current_window |
|
private |
◆ m_n_channels_threshold
uint16_t triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_n_channels_threshold = 600 |
|
private |
◆ m_trigger_on_adc
bool triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_trigger_on_adc = false |
|
private |
◆ m_trigger_on_n_channels
bool triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_trigger_on_n_channels = false |
|
private |
◆ m_window_length
timestamp_t triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_window_length = 80000 |
|
private |
◆ m_window_record
std::vector<TAWindow> triggeralgs::TCMakerChannelAdjacencyAlgorithm::m_window_record |
|
private |
The documentation for this class was generated from the following files: