feat: user definable callback on state transition

This commit is contained in:
CarlWachter
2024-11-03 13:25:22 +01:00
parent 7152baca2a
commit 9f4d99191d
2 changed files with 16 additions and 0 deletions

View File

@@ -71,6 +71,9 @@ namespace sta
HeapStats_t stats;
vPortGetHeapStats(&stats);
// Execute the user-defined callback.
sta::tacos::onStateTransition(transition.from, transition.to, transition.lockout);
// Start all new tasks and stop all the tasks that aren't supposed to be running.
updateThreads();
}