Where to implement complex application logic and state machines with physical interactions
I'm developing a device with embeded display running using TouchGFX which has set of valves and actuators and sensors. I have to control those valves and actuators based on user inputs and sensor readings. User inputs are given by the user from multiple scrreens. Also the display has no touch, screen navigation and option selection should implement using physical buttons.
My question is in which thread those application logic and state machines of of all physical components should be handled. From wheres shoud I do the decision making. In DefaultTask or TouchGFX task ? i.e. in main.c or Model.cpp ?
Thank you
