Skip to main content
Explorer
December 26, 2025
Question

STM32CubeProgrammer software for Raspberry Pi (raspian 64 bit ARM)

  • December 26, 2025
  • 4 replies
  • 56 views

I'd like to use a STM32 Nucleo from my raspberry pi  (raspian 64 bit ARM).

From my x86 PC I use this https://www.st.com/en/development-tools/stm32cubeprog.html#st-get-software and download the linux version of the tools: this works.

 

The same version doesn't work on raspberry pi as it's arm64 based: I get an " cannot execute binary file: Exec format error" error. I found no version of stm32cubeprog for raspberry pi arm on the STM web site (I tried macos arm version but get the same error than when setting up the linux version of the tool).

 

Is there a way to get stm32cubeprog to work on raspberry pi  (raspian 64 bit ARM) ? How and where to get binaries? 

    This topic has been closed for replies.

    4 replies

    fghoussenAuthor
    Explorer
    December 26, 2025

    Seems for a given flavor of STM32CubeProgrammer (say linux, latest version) there is no way to ask for x86 or arm binaries. I need STM32CubeProgrammer for linux + arm. How to find it?

    Super User
    December 26, 2025
    Super User
    December 29, 2025

    As @TDK suggests, this is a frequently recurring question:

    STM32CubeProgrammer on Raspberry Pi (or other ARM-based Host).

    Edited to correct link.

     

    There are some suggestions for alternatives in that thread...

    PS: Including using J-Link.

    Super User
    December 30, 2025

    @fghoussen It seems you have found a workaround with stlink-tools and st-flash ?

    fghoussenAuthor
    Explorer
    December 30, 2025

    I had no time yet to test with more complex app, but I got a minimal blinky app (using embedded LED) to be flashed OK from RPi and to run OK (change sleep time when building works as expected) on the STM chip connected to the RPi.

    Here is how I did if this may help other readers:

    >> sudo apt update

    >> sudo apt install openocd

    >> sudo apt install stlink-tools

    >> sudo usermod -aG plugdev $USER # Allow the user to flash. Must be done once + logout / login.

    >> lsusb | grep ST-LINK # Plug the USB cable that is connected to the STM: check the STM is seen.

    Bus 001 Device 003: ID 0483:374b STMicroelectronics ST-LINK/V2.1

    >> st-flash --connect-under-reset write build/zephyr/zephyr.bin 0x08000000

    You need to make sure (from the datasheet) that 0x08000000 is the correct address associated to the bank of your chip.

    HTH