Motion Master 6.0.0-alpha.86
Next-generation motion control software
Loading...
Searching...
No Matches
process_data_cyclic_task.h
Go to the documentation of this file.
1#pragma once
2
3#include "core/cyclic_task.h"
5
6namespace mm::node {
7
15 public:
16 explicit ProcessDataCyclicTask(DeviceManager& deviceManager) : deviceManager_(deviceManager) {}
17
18 // Exchanges the freshest process data; ignores the timing context — skipped
19 // cycles just mean fewer exchanges, which is correct (never a catch-up burst).
20 //
21 // GameLoop enters the cycle before this call, and exchangeProcessData raises the same depth
22 // counter again for callers that invoke it directly. The nesting is what that counter is for.
23 void execute(const mm::core::CycleContext&) noexcept override {
24 deviceManager_.exchangeProcessData();
25 }
26
27 private:
28 DeviceManager& deviceManager_;
29};
30
31} // namespace mm::node
Interface for work executed once per game loop cycle.
Definition cyclic_task.h:44
Owns the fieldbus driver and node collection, and drives PDO exchange.
Definition device_manager.h:287
void exchangeProcessData()
Exchanges one cycle of process data: sends the current outputs, captures inputs.
Definition device_manager.cc:383
Game-loop task that exchanges one cycle of process data.
Definition process_data_cyclic_task.h:14
ProcessDataCyclicTask(DeviceManager &deviceManager)
Definition process_data_cyclic_task.h:16
void execute(const mm::core::CycleContext &) noexcept override
Called once per cycle, after the exchange of process data and device parameters updated.
Definition process_data_cyclic_task.h:23
Definition bus_health_source.h:7
Per-cycle timing context passed to every CyclicTask::execute().
Definition cyclic_task.h:30