2025-06-20 3:22 AM
Hi,
I am trying to deploy a model onto the N6 disco board with modelzoo's github repo.
I have trained my model and am now trying to deploy it to the board via running stm32ai_main.py.
I get the following error log that I have not been able to solve on my own. I have cloned the repo with the recursive flag set as I have seen on this forum:
PS C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services> c:; cd 'c:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services'; & 'c:\Users\Haris\AppData\Local\Programs\Python\Python310\python.exe' 'c:\Users\Haris\.vscode\extensions\ms-python.debugpy-2025.8.0-win32-x64\bundled\libs\debugpy\launcher' '56023' '--' 'c:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\object_detection\stm32ai_main.py'
1 physical GPUs, 1 logical GPUs
[INFO] : Setting upper memory limit to 16GBytes on gpu[0]
[INFO] : Running `deployment` operation mode
[INFO] : Using provided class names from dataset.class_names
[INFO] : ClearML config check
[INFO] : The random seed for this simulation is 127
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
[INFO] : Generating C header file for Getting Started...
loading model.. model_path="C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/src/experiments_outputs/2025_06_20_11_02_18/quantized_models/quantized_model.tflite"
loading conf file.. "C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/stmaic_STM32N6570-DK.conf" config="None"
"Debug" configuration is used
[INFO] : Selected board : "STM32N6570-DK Getting Started Image Classification (STM32CubeIDE)" (stm32_cube_ide/Debug/stm32n6)
[INFO] : Compiling the model and generating optimized C code + Lib/Inc files: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/src/experiments_outputs/2025_06_20_11_02_18/quantized_models/quantized_model.tflite
[INFO] : Establishing a connection to STM32Cube.AI Developer Cloud to launch the model benchmark on STM32 target...
[INFO] : To create an account, go to https://stedgeai-dc.st.com/home. Enter your credentials:
Username: *****@*****.gr
Password:
[INFO] : Successfully connected!
[INFO] : Optimized C code + Lib/Inc files generation done.
[INFO] : Building the STM32 c-project..
deploying the c-project.. "STM32N6570-DK Getting Started Image Classification (STM32CubeIDE)" (stm32_cube_ide/Debug/stm32n6)
updating.. Debug
-> s:copying file.. "network.c" to C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Model\STM32N6570-DK\network.c
-> s:copying file.. "network_ecblobs.h" to C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Model\STM32N6570-DK\network_ecblobs.h
-> s:copying file.. "network_atonbuf.xSPI2.raw" to C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Model\STM32N6570-DK\network_atonbuf.xSPI2.raw
-> s:removing dir.. C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Middlewares\AI_Runtime\Inc
-> s:copying dir.. "Inc" to C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Middlewares\AI_Runtime\Inc
-> u:copying file.. "app_config.h" to C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Application\STM32N6570-DK\Inc\app_config.h
all the files are not be updated, 5/7!
-> ['ARMCortexM55', 'll_aton']
-> updating cproject file "C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Application\STM32N6570-DK\STM32CubeIDE" with "NetworkRuntime1000_CM55_GCC.a"
building.. Debug
[returned code = 13 - FAILED]
$ cwd: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/Application/STM32N6570-DK/STM32CubeIDE
$ args: stm32cubeide --launcher.suppressErrors -nosplash -application org.eclipse.cdt.managedbuilder.core.headlessbuild -import C:\Users\Haris\Desktop\zooooo\stm32ai-modelzoo-services\application_code\image_classification\STM32N6\Application\STM32N6570-DK\STM32CubeIDE -data C:\Users\Haris\AppData\Local\Temp\tmpx7ccxe6f -cleanBuild "STM32N6570-DK_GettingStarted_ImageClassification/Debug"
Create.
Opening 'STM32N6570-DK_GettingStarted_ImageClassification'.
11:44:35 **** Clean-only build of configuration Debug for project STM32N6570-DK_GettingStarted_ImageClassification ****
make -j8 clean
make: *** No rule to make target 'clean'. Stop.
"make -j8 clean" terminated with exit code 2. Build might be incomplete.
11:44:35 Build Failed. 1 errors, 0 warnings. (took 209ms)
11:44:35 **** Clean-only build of configuration Debug for project STM32N6570-DK_GettingStarted_ImageClassification ****
make -j8 clean
make: *** No rule to make target 'clean'. Stop.
"make -j8 clean" terminated with exit code 2. Build might be incomplete.
11:44:35 Build Failed. 1 errors, 0 warnings. (took 125ms)
Stm32cubeide:
An error has occurred. See the log file
C:\Users\Haris\AppData\Local\Temp\tmpx7ccxe6f\.metadata\.log.
flashing.. Debug STM32N6570-DK
[returned code = 1 - FAILED]
$ cwd: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/Application/STM32N6570-DK/STM32CubeIDE
$ args: STM32_SigningTool_CLI -s -bin Debug/STM32N6570-DK_GettingStarted_ImageClassification.bin -nk -t ssbl -hv 2.3 -o Debug/STM32N6570-DK_GettingStarted_ImageClassification_signed.bin
'STM32_SigningTool_CLI' is not recognized as an internal or external command,
operable program or batch file.
[returned code = 1 - FAILED]
$ cwd: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/Application/STM32N6570-DK/STM32CubeIDE
$ args: STM32_Programmer_CLI -c port=swd mode=HOTPLUG sn=005000243333511831363730 --extload C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr -w Debug/STM32N6570-DK_GettingStarted_ImageClassification_signed.bin 0x70100000
-------------------------------------------------------------------
STM32CubeProgrammer v2.17.0
-------------------------------------------------------------------
Warning: The external loader file does not exist:
C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr
[returned code = 1 - FAILED]
$ cwd: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/Application/STM32N6570-DK/STM32CubeIDE
$ args: STM32_Programmer_CLI -c port=swd mode=HOTPLUG sn=005000243333511831363730 --extload C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr -w ../../../Model/STM32N6570-DK/network_atonbuf.xSPI2.bin 0x70380000
-------------------------------------------------------------------
STM32CubeProgrammer v2.17.0
-------------------------------------------------------------------
Warning: The external loader file does not exist:
C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr
[returned code = 1 - FAILED]
$ cwd: C:/Users/Haris/Desktop/zooooo/stm32ai-modelzoo-services/application_code/image_classification/STM32N6/Application/STM32N6570-DK/STM32CubeIDE
$ args: STM32_Programmer_CLI -c port=swd mode=HOTPLUG sn=005000243333511831363730 mode=HOTPLUG --extload C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr -w ../../../Binary/ai_fsbl.hex
-------------------------------------------------------------------
STM32CubeProgrammer v2.17.0
-------------------------------------------------------------------
Warning: The external loader file does not exist:
C:\ST\STM32CubeIDE_1.16.1\STM32CubeIDE\plugins\com.st.stm32cube.ide.mcu.externaltools.cubeprogrammer.win32_2.1.400.202404281720\tools\bin\ExternalLoader/MX66UW1G45G_STM32N6570-DK.stldr
[INFO] deployment complete
[INFO] : Please on STM32N6570-DK toggle the boot switches to the left and power cycle the board.
Thanks
2025-06-20 4:49 AM
Hello @dogg,
Can you try to deploy your model not using the cloud, but doing it locally.
It may have changed (I will ask) but it was not supported before for the N6.
Also please make sure to use the last version of X Cube AI / St Edge AI Core (10.1.0 or 2.1.0)
With something like this in the yaml:
tools:
stedgeai:
version: 10.1.0
optimization: balanced
on_cloud: False # Not Available For STM32N6
path_to_stedgeai: C:/Users/<XXXXX>/STM32Cube/Repository/Packs/STMicroelectronics/X-CUBE-AI/<*.*.*>/Utilities/windows/stedgeai.exe
path_to_cubeIDE: C:/ST/STM32CubeIDE_<*.*.*>/STM32CubeIDE/stm32cubeide.exe
Also, I see this in your error message:
'STM32_SigningTool_CLI' is not recognized as an internal or external command,
The STM32_SigningTool_CLI is installed when you install STM32CubeProgrammer, so I believe that you should have it. Could you open a terminal and type STM32_SigningTool_CLI.exe to see if you have it?
Have a good day,
Julian