change the priority of a task in FreeRTOS at runtime using STM32CubeIDE and STM32 HAL libraries
How can I change the priority of a task in FreeRTOS at runtime using STM32CubeIDE and STM32 HAL libraries? My task priority isn't updating. Here's my code:
What could be the issue?
@Middleware & OS
Solution:Jump to solution
If you table is in a form of matrix u can use the example below 👇
```
replace with your 2d table 👇
lookup_table = [
[10, 20, 30],...
3 Replies
Hi @Boss lady , make sure that xTaskHandle is the correct handle to the task whose priority you want to change. This handle should have been obtained when creating the task or by using a function like xTaskCreate(), also add error handling to aid easy debugging of your code.
Solution
If you table is in a form of matrix u can use the example below 👇
Okay, I have verified that the
xTaskHandle
is correct based on the priority I want to change, for the error handling can you give me a code snippet or guide to follow