Do you handle xHigherPriorityTaskWoken (naming in the example) to properly call portYIELD_FROM_ISR ?On the other hand consider using task notifications as a faster alternative, since xEventGroupSetBitsFromISR uses the timer task which then signals/wa...
Also try FREERTOS.configCHECK_FOR_STACK_OVERFLOW=2 and ensure that you have configASSERT defined. (sorry, I’m not familiar with cube)BTW what’s the stack size(s) you’re using for your task(s) ?
A stack overflow might cause this kind of internal data corruption. Did you enable stack checking ? See https://www.freertos.org/Stacks-and-stack-overflow-checking.html
Have a look into the (linker) generated map file to see which symbols (functions/data) are linked into this RAM sections to get an idea.And as @Tesla DeLorean mentioned find out why your app is not running.
Indeed your current main loop will be a task when migrating to FreeRTOS. Also it's probably reasonable to migrate also your ISR (handlers). You might add a separate ISR handler task which just post-processes the/all HW events (e.g using so called Fre...