Thanks for the info on the Flash.
Also for pointing me to the example for polling. I had a look at it and interpret it as an idea to communicate between modules that have been started by different threads.
To use the Arduino IDE was my self-imposed guideline for my project. However there are limitations, so I do not always stick to it. So it is fine to follow SDK examples.
I think this topic can be marked as soved.