eeros_architecture:control_system:executor
Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision | ||
eeros_architecture:control_system:executor [2018/03/19 18:00] – external edit 127.0.0.1 | eeros_architecture:control_system:executor [2021/02/10 11:58] – [Add More Time Domains] ursgraf | ||
---|---|---|---|
Line 6: | Line 6: | ||
As the following figure shows each harmonic is run by its own thread of execution. | As the following figure shows each harmonic is run by its own thread of execution. | ||
{{ : | {{ : | ||
- | In this example we have the safety system as the main task. It has the fastest execution period together with the time domain 1. The time domain 2 runs with the same period but only after time domain 1 has finished. Time domain 3 has a harmonic relationship to the main task of 2. | + | In this example we have the safety system as the main task. It has the fastest execution period together with the time domain 1. The time domain 2 runs with the same period but only after time domain 1 has finished. Time domain 3 has a harmonic relationship to the main task with a ratio of 2. |
| | ||
===== Initialize the Executor ====== | ===== Initialize the Executor ====== | ||
Line 44: | Line 44: | ||
IMPORTANT Please make sure to run an application using the executor with root privileges. This is necessary for the executor to be able to create threads with realtime priorities. | IMPORTANT Please make sure to run an application using the executor with root privileges. This is necessary for the executor to be able to create threads with realtime priorities. | ||
+ | ===== Add More Time Domains ====== | ||
+ | The picture at the top of this page shows another two time domains. Time domain 2 runs after time domain 1. It can be created and added to time domain 1 as follows | ||
+ | <code cpp> | ||
+ | eeros:: | ||
+ | eeros:: | ||
+ | eeros:: | ||
+ | eeros:: | ||
+ | per1.after.push_back(per2); | ||
+ | executor.add(per1); | ||
+ | </ | ||
+ | Time domain 3 runs concurrently to time domain 1. It can therefore be created simply with |
eeros_architecture/control_system/executor.txt · Last modified: 2021/02/10 15:28 by ursgraf