michalek002a wrote: I need to read and write data to the SD card in real time, while executing the program uninterrupted. In fact, I haven't yet checked what read/write speed I'll have, but I wanted to take precautions.
.
Programs run in blocks of algorithm, blocks/groups of data .... so in some sense they are "intermittent".
With good planning this can be done nicely, e.g. by portioning the data from block to block, and then treating it as immutable. Then the synchronised elements are reduced to a minimum.
Good structuring of data and code is more important than coder tricks with unstructured data.
There are already more resources available on the ESP, it can be programmed in a decent way, in layers/blocks/objects (since the Atmega 8 has an event queue, simple as it is, but it was there).