2026-04-28 5:37 AM
Hello,
I’m working on a project generated by STM32Cube AI Studio targeting the NUCLEO-N657X0-Q, using an XIP configuration with external XSPI flash ( It was said in another post that the generated projects from STM cube AI Studio follow XIP configuration).
Model location (from generated network.c):
I programmed manually using STM32CubeProgrammer:
I start debugging from the FSBL project.
In Debug Configuration → Startup → Load Image and Symbols, I configured:
So FSBL is loaded/debugged, while App and model are already present in flash.
Additionally, I also tried adding the runtime GCC libraries to the FSBL debug configuration, but this did not change the behavior
Application reaches:
Execution enters:
Execution gets stuck in:
Observed behavior:
Thanks for your assistance
2026-04-28 7:23 AM
To verify that the application is actually running, I added a simple GPIO test:
I also tried UART debugging. USART1 is initialized and I have used USART1 successfully on the same board in other projects. However, in this Cube AI Studio project, printf does not output anything. I noticed that _write() is already defined in aiTestUtility.c, so I did not add a duplicate _write() in main.c.
Can you please provide and explanation/tutorial that would be very helpful
2026-04-29 2:54 AM
Update :
I now understand that not being able to use the virtual com port or leds to debug was because they were not configured in the generated Cube mx project , but i still didnt find a solution to the inference stuck in the aiRun() Loop
2026-04-30 7:45 AM
2026-05-04 4:55 AM
Hello @ayaaaa
On my side, your project is not stuck in the while loop:
I will share with you a NUCLEO-N657X0-Q project with outputs in UART, if it works on your side, I will try to help you to modify the model integrated in it.
Best regards,
Yanis