cancel
Showing results for 
Search instead for 
Did you mean: 

STM32N657X0 NUCLEO — Secure LED not blinking, Non-Secure LED not working at all (TrustZone + RIF configuration issue)

MSGokul
Associate II

Hello ST Community,

I am working on the NUCLEO-N657X0-Q board with a TrustZone project configured in STM32CubeMX with three contexts: FSBL, AppSecure (AppS), and AppNonSecure (AppNS). The FSBL is working correctly and jumping to AppS successfully. I followed the wiki article "How to start with RIF on STM32N6 MCUs" as reference. 

https://wiki.st.com/stm32mcu/wiki/Security:How_to_start_with_RIF_on_STM32N6_MCUs

 

The secure LED (configured as output push-pull, pulled low initially) turns ON but never toggles. I have tried both HAL_Delay() and a pure software loop  for (volatile uint32_t i = 0; i < 800000; i++);  inside the while(1) — neither causes the LED to blink. The GPIO write to set it HIGH works, but the toggle never happens. This suggests the secure while(1) loop itself may not be executing, or the app is hanging somewhere before it.

 

The NS LED does not turn ON or toggle at any point. The NS app appears to not execute at all.

 

  • I have configured RISAF for FLEXRAM and CPU AXI RAM0/RAM1 with the appropriate region sizes as described in the wiki.
  • I have configured RIFSC for the GPIO ports used by both LEDs.

    My specific questions are:

    1. Can you suggest me a fix for this issue? 
    2.Is there a recommended way to confirm whether the NS app is actually starting?
    3.What is the correct SAU region configuration for a load-and-run AppS + AppNS setup on STM32N657, specifically: which addresses should be used for the FlexRAM ,RAM1 (secure) and SRAM2 (non secure)

Security:How to start with RIF on STM32N6 MCUs - stm32mcu

 

0 REPLIES 0