cancel
Showing results for 
Search instead for 
Did you mean: 

FreeRTOS Middleware can not enable MPU function?

Wshuo.1
Associate II

我正在使用STM32L431RCT6,我的 HAL 版本是最后一个。我想使用 FreeRTOS 的最后一个 API 让我的项目更稳定:

 

BaseType_t xTaskGenericNotify( TaskHandle_t xTaskToNotify, uint32_t ulValue, eNotifyAction eAction, uint32_t *pulPreviousNotificationValue ) PRIVILEGED_FUNCTION;
#define xTaskNotify( xTaskToNotify, ulValue, eAction ) xTaskGenericNotify( ( xTaskToNotify ), ( ulValue ), ( eAction ), NULL )
#define xTaskNotifyAndQuery( xTaskToNotify, ulValue, eAction, pulPreviousNotifyValue ) xTaskGenericNotify( ( xTaskToNotify ), ( ulValue ), ( eAction ), ( pulPreviousNotifyValue ) )

 

但是我无法设置 ENABLE_MPU==Enabled,我不知道为什么:

Wshuo1_0-1728564635757.png

我的另一个配置是:

Wshuo1_1-1728564960228.pngWshuo1_2-1728564976868.pngWshuo1_3-1728564986038.pngWshuo1_4-1728564996489.pngWshuo1_5-1728565014455.png

我需要设置哪些选项才能启用此选项?

2 REPLIES 2
STTwo-32
ST Employee

Hello @Wshuo.1 

After clicking on the Enable_MPU message you can see the following message "Use of Memory Protection Unit with FreeRTOS (not yet available, as requires support of FreeRTOS Native API)."

STTwo32_0-1728568055330.png

PS: Next time please use the English language. here is the translation of the  post:

I'm using STM32L431RCT6 and my HAL version is the last one. I want to use the last API of FreeRTOS to make my project more stable:

BaseType_t xTaskGenericNotify( TaskHandle_t xTaskToNotify, uint32_t ulValue, eNotifyAction eAction, uint32_t *pulPreviousNotificationValue ) PRIVILEGED_FUNCTION;
#define xTaskNotify( xTaskToNotify, ulValue, eAction ) xTaskGenericNotify( ( xTaskToNotify ), ( ulValue ), ( eAction ), NULL )
#define xTaskNotifyAndQuery( xTaskToNotify, ulValue, eAction, pulPreviousNotifyValue ) xTaskGenericNotify( ( xTaskToNotify ), ( ulValue ), ( eAction ), ( pulPreviousNotifyValue ) )

But I can't set ENABLE_MPU==Enabled, I don't know why:

STTwo32_1-1728568256302.png

My other configuration is:

STTwo32_2-1728568279198.pngSTTwo32_3-1728568303079.png

STTwo32_4-1728568317135.png

STTwo32_5-1728568334453.png

STTwo32_6-1728568349413.png

What options do I need to set to enable this option?

 

Best Regards.

STTwo-32

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.

Sarra.S
ST Employee

Hello @Wshuo.1

I have already submitted a request to add support for the FreeRTOS memory protection unit MPU in CubeMX, as another user previously requested here

So the internal ticket (Ticket 190405) is still under investigation and I will keep you updated. 

 

To give better visibility on the answered topics, please click on Accept as Solution on the reply which solved your issue or answered your question.