Shared variable between loop and software timer

@felixgalindo, the chances of getting a preemptive thread interruption in the middle of an instruction (eg. flag = true) is minute. If you are concerned, specify it as a SINGLE_THREAD_BLOCK() or an ATOMIC_BLOCK().

There was a thread on creating FreeRTOS mutexes where a member successfully created a mutex for the SPI resource:

:slight_smile: