2026-01-07 6:26 AM - edited 2026-01-09 4:51 AM
static void NN_RunInference(void) {
LL_ATON_RT_RetValues_t ret;
do {
ret = LL_ATON_RT_RunEpochBlock(&NN_Instance_od_yolo_x_person);
if (ret == LL_ATON_RT_WFE) {
LL_ATON_OSAL_WFE(); // <-- Blocks here
}
} while (ret != LL_ATON_RT_DONE);
LL_ATON_RT_Reset_Network(&NN_Instance_od_yolo_x_person);
}Solved! Go to Solution.
2026-01-09 5:32 AM - edited 2026-01-09 5:35 AM
The problem fixed by adding the code below.
void HAL_CACHEAXI_MspInit(CACHEAXI_HandleTypeDef *hcacheaxi)
{
__HAL_RCC_CACHEAXIRAM_MEM_CLK_ENABLE();
__HAL_RCC_CACHEAXI_CLK_ENABLE();
__HAL_RCC_CACHEAXI_FORCE_RESET();
__HAL_RCC_CACHEAXI_RELEASE_RESET();
}
void HAL_CACHEAXI_MspDeInit(CACHEAXI_HandleTypeDef *hcacheaxi)
{
__HAL_RCC_CACHEAXIRAM_MEM_CLK_DISABLE();
__HAL_RCC_CACHEAXI_CLK_DISABLE();
__HAL_RCC_CACHEAXI_FORCE_RESET();
}I compared it with other projects, and it looks like I forgot to implement something for enabling the CACHEXI.
I found npu_cache_init() calls HAL_CACHEAXI_Init() and the latter one internally calls HAL_CACHEAXI_MspInit(),
but HAL_CACHEAXI_MspInit() is not implemented in my code.
2026-01-08 11:23 PM - edited 2026-01-09 4:52 AM
Update: I initially used STEdgeAI 3.0. I later switched to STEdgeAI 2.2, but the issue persisted.
2026-01-09 4:50 AM - edited 2026-01-09 4:50 AM
.text.NPU0_IRQHandler
0x340322d8 0x124 CMakeFiles/Firmware_Appli.dir/.../ll_aton/ll_aton_runtime.c.obj
0x340322d8 NPU0_IRQHandlerThe furthest I’ve been able to debug is that NPU0_IRQHandler (expanded by ATON_STD_IRQHandler macro in ll_aton_runtime.c) never fires.
2026-01-09 5:32 AM - edited 2026-01-09 5:35 AM
The problem fixed by adding the code below.
void HAL_CACHEAXI_MspInit(CACHEAXI_HandleTypeDef *hcacheaxi)
{
__HAL_RCC_CACHEAXIRAM_MEM_CLK_ENABLE();
__HAL_RCC_CACHEAXI_CLK_ENABLE();
__HAL_RCC_CACHEAXI_FORCE_RESET();
__HAL_RCC_CACHEAXI_RELEASE_RESET();
}
void HAL_CACHEAXI_MspDeInit(CACHEAXI_HandleTypeDef *hcacheaxi)
{
__HAL_RCC_CACHEAXIRAM_MEM_CLK_DISABLE();
__HAL_RCC_CACHEAXI_CLK_DISABLE();
__HAL_RCC_CACHEAXI_FORCE_RESET();
}I compared it with other projects, and it looks like I forgot to implement something for enabling the CACHEXI.
I found npu_cache_init() calls HAL_CACHEAXI_Init() and the latter one internally calls HAL_CACHEAXI_MspInit(),
but HAL_CACHEAXI_MspInit() is not implemented in my code.