-
Notifications
You must be signed in to change notification settings - Fork 65
I can not use osSemaphoreRelease(rtcMinuteInterruptSemID) in the RTC alarm IRQ #54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Comments
@KiraVerSace, It is strictly forbidden to use such FreeRTOS API in an IRQ handler |
I determined that the only api I used in the IRQ handle is osSemaphoreRelease(), and the semaphore was created successfully, I use the CMSIS RTOS api here instead of the FreeRTOS api |
|
Here is my program in the header.h file
Here is the code in the cpp file
And here is my IRQ Handle
if I commment this line if I uncomment this line, the system will print |
OK, I debug my code step by step First run to then I step in, and run to in queue.c and run to port.c and into a loop that is STM32FreeRTOS/portable/MemMang/heap_useNewlib_ST.c |
I have slove the problem, cause of the #define RTC_IRQ_PRIO is set to 2, it is not in the freeRTOS control priority, so I set it to 7, between 5 and 15 |
When I use the stm32duino RTC and open the alarm IRQ, I want to release a semaphore in the IRQ, it always failed, then I debug my code, I find thar it was in the assert as blew.
STM32FreeRTOS/portable/MemMang/heap_useNewlib_ST.c
Line 217 in 382c100
I check my code that the semaphore create sucessfully!
could you help me?
The text was updated successfully, but these errors were encountered: