cancel
Showing results for 
Search instead for 
Did you mean: 

STM32F401RE - ThreadX won't wake up from sleep - Azure RTOS

f4_kiddo
Associate II

Here's the code of my app_threadx.c file.

https://pastebin.com/qj8ZUYg3

I followed the STM32 AZURE RTOS workshop for the H7 MCUs, however, I'm currently developing on a STM32F401RE.

Basically, when I debug the program the function it's called and then go to sleep, despite the fact of it doesn't wake up, so it doesn't work as a thread anymore.

I don't know if there's any timer problem, I've set TIM10 as timebase source because I can't use the SysTick due STM software constraints (to avoid any conflict with the SysTick interrupt handler).

I think it could be a library problem, however I don't know what can I do except these basic things.

Thanks in advance!

2 REPLIES 2

Hello @f4_kiddo​ ,

You can refer to the following example provided under X-Cube-AZRTOS-F4 Package:

I hope this helps.

BeST Regards,

Walid

Thanks, I will report the solution found by @KR51K​ :

I think I found the answer: in my project the Priority Group in "System Core"->"NVIC" was set to "0 bits", so I changed his to "4 bits". and afterwards set the "Preemption Priotity" for the "Time base: TIM6 global interrupt..." from "0" to "15". 

Hope this helps you

Basically this was the only setting that was missing in my project.