DUNE-DAQ
DUNE Trigger and Data Acquisition software
Loading...
Searching...
No Matches
MasterNodeInterface.cpp
Go to the documentation of this file.
1
10
11#include <string>
12
13namespace dunedaq {
14namespace timing {
15
16//-----------------------------------------------------------------------------
18 : TimingNode(node)
19{}
20//-----------------------------------------------------------------------------
21
22//-----------------------------------------------------------------------------
24//-----------------------------------------------------------------------------
25
26//-----------------------------------------------------------------------------
27void
28MasterNodeInterface::apply_endpoint_delay(const ActiveEndpointConfig& ept_config, bool measure_rtt) const
29{
30 std::string lEptIdD = ept_config.id;
31 uint32_t ept_address = ept_config.adr; // NOLINT(build/unsigned)
32 uint32_t coarse_Delay = ept_config.cdelay; // NOLINT(build/unsigned)
33 uint32_t fine_delay = ept_config.fdelay; // NOLINT(build/unsigned)
34 uint32_t phase_delay = ept_config.pdelay; // NOLINT(build/unsigned)
35 apply_endpoint_delay(ept_address, coarse_Delay, fine_delay, phase_delay, measure_rtt);
36}
37//-----------------------------------------------------------------------------
38
39//-----------------------------------------------------------------------------
40void
41MasterNodeInterface::enable_periodic_fl_cmd(uint32_t channel, double rate, bool poisson, uint32_t clock_frequency_hz) const // NOLINT(build/unsigned)
42{
43 enable_periodic_fl_cmd(0x8+channel, channel, rate, poisson, clock_frequency_hz);
44}
45//-----------------------------------------------------------------------------
46
47//-----------------------------------------------------------------------------
48void
49MasterNodeInterface::enable_periodic_fl_cmd(uint32_t command, uint32_t channel, double rate, bool poisson, uint32_t clock_frequency_hz) const // NOLINT(build/unsigned)
50{
51
52 getNode<FLCmdGeneratorNode>("scmd_gen").enable_periodic_fl_cmd(command, channel, rate, poisson, clock_frequency_hz);
53}
54//-----------------------------------------------------------------------------
55
56//-----------------------------------------------------------------------------
57void
58MasterNodeInterface::disable_periodic_fl_cmd(uint32_t channel) const // NOLINT(build/unsigned)
59{
60 getNode<FLCmdGeneratorNode>("scmd_gen").disable_fake_trigger(channel);
61}
62//------------------------------------------------------------------------------
63
64} // namespace timing
65} // namespace dunedaq
virtual void apply_endpoint_delay(uint32_t address, uint32_t coarse_delay, uint32_t fine_delay, uint32_t phase_delay, bool measure_rtt=false, bool control_sfp=true) const =0
Apply delay to endpoint.
virtual void enable_periodic_fl_cmd(uint32_t channel, double rate, bool poisson, uint32_t clock_frequency_hz) const
Configure fake trigger generator.
virtual void disable_periodic_fl_cmd(uint32_t channel) const
Clear fake trigger configuration.
Base class for timing nodes.
Including Qt Headers.