I am not that familiar with TouchGFX but are there any specific requirements from TouchGFX regarding an RTOS? I think such an instruction would be part of TouchGFX. Usually there could be some kind of porting layer that, e.g. enables TouchGFX to be used from different threads.