I was trying out the Memory Protection Unit (MPU) feature for RT1052 and found it hard faulting with FreeRTOS. We have an in-house, functional MPU + FreeRTOS v10.2.1 solution for Microchip SAME70, so porting to RT1052 was easy.
Some information about the crash:
Fault registers (SCB) dump:
SCB->HFSR = 0x40000000 (Hard fault)
SCB->CFSR = 0x01000000 (Configurable fault) -> Usage fault: Illegal unaligned load or store
SCB->DFSR = 0x00000000 (Debug fault)
SCB->AFSR = 0x00000000 (Auxiliary fault)
SCB->BFAR = 0x00000000 (Bus fault address)
SCB->MMFAR = 0x00000000 (MemManage fault address)
SCB->ABFSR = 0x00000000 (Auxiliary bus fault)
Questions
I reviewed all the NXP MPU demo code, but I don't see any that uses a privileged task.
Is there a sample project in the SDK the uses a privileged task in FreeRTOS?
Hi @cup-a-coffee ,
Sorry for replying late.
As I mentioned before, the SDK library doesn't provide the MPU-enable FreeRTOS demos, and the developers need to port FreeRTOS-MPU demos to RT1052 by themselves.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
-----------------------------------------------------------------------------
Hi @cup-a-coffee ,
Thank you for your interest in NXP Semiconductor products and for the opportunity to serve you.
1)Is there an example project with RT105X + MPU + FreeRTOS v10 support?
-- Regarding the FreeRTOS, the MPU feature is optional, in the SDK library, it doesn't provide the MPU-enable FreeRTOS demos.
2) Do you have any suggestions regarding the crash?
-- According to the information you provided, I'd like to suggest you refer to FreeRTOS-MPU demos in the library first.
Have a great day,
TIC
-------------------------------------------------------------------------------
Note:
- If this post answers your question, please click the "Mark Correct" button. Thank you!
- We are following threads for 7 weeks after the last post, later replies are ignored
Please open a new thread and refer to the closed one, if you have a related question at a later point in time.
------------------------------------------------------------------------------