DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
TPWindow.hpp
Go to the documentation of this file.
1/* @file: TPWindow.hpp
2 *
3 * This is party of the DUNE DAQ Application Framework, copyright 2021.
4 * Licensing/copyright details are in the COPYING file that you should have
5 * received with this code.
6 */
7
8#ifndef TRIGGERALGS_TPWINDOW_HPP_
9#define TRIGGERALGS_TPWINDOW_HPP_
10
12#include "triggeralgs/Types.hpp"
13
14#include <ostream>
15#include <unordered_map>
16#include <vector>
17
18namespace triggeralgs {
19
21{
22public:
23 bool is_empty() const;
24
25 void add(TriggerPrimitive const& input_tp);
26
27 void clear();
28
29 uint16_t n_channels_hit();
30
31 void move(TriggerPrimitive const& input_tp, timestamp_t const& window_length);
32
33 void reset(TriggerPrimitive const& input_tp);
34
35 friend std::ostream& operator<<(std::ostream& os, const TPWindow& window);
36
38 uint32_t adc_integral = 0;
39 std::unordered_map<channel_t, uint16_t> channel_states;
40 std::vector<TriggerPrimitive> inputs;
41};
42} // namespace triggeralgs
43
44#endif // TRIGGERALGS_TPWINDOW_HPP_
void reset(TriggerPrimitive const &input_tp)
Definition TPWindow.cpp:79
std::unordered_map< channel_t, uint16_t > channel_states
Definition TPWindow.hpp:39
void add(TriggerPrimitive const &input_tp)
Definition TPWindow.cpp:20
bool is_empty() const
Definition TPWindow.cpp:14
std::vector< TriggerPrimitive > inputs
Definition TPWindow.hpp:40
void move(TriggerPrimitive const &input_tp, timestamp_t const &window_length)
Definition TPWindow.cpp:45
friend std::ostream & operator<<(std::ostream &os, const TPWindow &window)
Definition TPWindow.cpp:97
timestamp_t time_start
Definition TPWindow.hpp:37
uint16_t n_channels_hit()
Definition TPWindow.cpp:39
dunedaq::trgdataformats::timestamp_t timestamp_t
Definition Types.hpp:16
A single energy deposition on a TPC or PDS channel.