DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
TDEFrameProcessor.hpp
Go to the documentation of this file.
1/*
2 * @file TDEFrameProcessor.hpp TDE specific Task based raw processor
3 *
4 * This is part of the DUNE DAQ , copyright 2020.
5 * Licensing/copyright details are in the COPYING file that you should have
6 * received with this code.
7 */
8#ifndef FDREADOUTLIBS_INCLUDE_FDREADOUTLIBS_TDE_TDEFRAMEPROCESSOR_HPP_
9#define FDREADOUTLIBS_INCLUDE_FDREADOUTLIBS_TDE_TDEFRAMEPROCESSOR_HPP_
10
13
15
17
18#include "logging/Logging.hpp"
21
22#include <atomic>
23#include <functional>
24#include <memory>
25#include <string>
26
28
29namespace dunedaq {
30namespace fdreadoutlibs {
31
32class TDEFrameProcessor : public datahandlinglibs::TaskRawDataProcessorModel<types::TDEFrameTypeAdapter
33>
34{
35
36public:
40 using timestamp_t = std::uint64_t; // NOLINT(build/unsigned)
41
42 explicit TDEFrameProcessor(std::unique_ptr<datahandlinglibs::FrameErrorRegistry>& error_registry, bool post_processing_enabled)
43 : TaskRawDataProcessorModel<types::TDEFrameTypeAdapter
44>(error_registry, post_processing_enabled)
45 {}
46
47 // Override configuration to register pipeline
48 void conf(const appmodel::DataHandlerModule* conf) override;
49
50protected:
55
59 void frame_error_check(frameptr /*fp*/);
60
61 // Internals
65 bool m_problem_reported = false;
66 std::atomic<int> m_ts_error_ctr{ 0 };
67 uint64_t m_clock_frequency; // NOLINT(build/unsigned)
68
69private:
70};
71
72} // namespace fdreadoutlibs
73} // namespace dunedaq
74
75#endif // FDREADOUTLIBS_INCLUDE_FDREADOUTLIBS_TDE_TDEFRAMEPROCESSOR_HPP_
TaskRawDataProcessorModel(std::unique_ptr< FrameErrorRegistry > &error_registry, bool post_processing_enabled)
void conf(const appmodel::DataHandlerModule *conf) override
Set the emulator mode, if active, timestamps of processed packets are overwritten with new ones.
TDEFrameProcessor(std::unique_ptr< datahandlinglibs::FrameErrorRegistry > &error_registry, bool post_processing_enabled)
Including Qt Headers.