cancel
Showing results for 
Search instead for 
Did you mean: 

how to setting priority of rtos task in stm32cubeide's GUI

Slee.13
Associate II

I am using stm32f405 mcu and stm32cubeide.

I'm beginner with cmsis v2 of rtos.

i'm setting deferred interrupt task. so I want to set priority of deferred task.

but I can't select "osPriorityISR".

please help me.

0693W00000Y9PRpQAN.png0693W00000Y9PRfQAN.png 

1 ACCEPTED SOLUTION

Accepted Solutions
KnarfB
Principal III

It is not neccessary to set a specific priority for a task. Only the priority order between tasks is important for scheduling.

In your case, the docs https://www.keil.com/pack/doc/CMSIS/RTOS2/html/group__CMSIS__RTOS__ThreadMgmt.html say:

"Reserved for ISR deferred thread. This highest priority might be used by the RTOS implementation but must not be used for any user thread."

So, you should not use osPriorityISR for your tasks. The prio naming may be misleading.

You can cross-check with the sources, osPriorityISR is not used in the STM32 FreeRTOS based implementation, except for some out-of-bounds error checking.

hth

KnarfB

View solution in original post

2 REPLIES 2
KnarfB
Principal III

It is not neccessary to set a specific priority for a task. Only the priority order between tasks is important for scheduling.

In your case, the docs https://www.keil.com/pack/doc/CMSIS/RTOS2/html/group__CMSIS__RTOS__ThreadMgmt.html say:

"Reserved for ISR deferred thread. This highest priority might be used by the RTOS implementation but must not be used for any user thread."

So, you should not use osPriorityISR for your tasks. The prio naming may be misleading.

You can cross-check with the sources, osPriorityISR is not used in the STM32 FreeRTOS based implementation, except for some out-of-bounds error checking.

hth

KnarfB

thank you for your answer.

Can I ask you a question one more?

I want to use ISR deferred thread. How can I use it in stm32cubeide with cmsis v2?