Skip to main content
Visitor II
April 30, 2021
Solved

ST-Link_CLI.exe can't find STM32MCU for USB3.0 at Win10

  • April 30, 2021
  • 4 replies
  • 4018 views

I'm using ST-Link_CLI.exe command line to programming our product in test jig, the previous tester is using Win7, it seems works reliable, but now update to Win10 and get problem with power up the tester.

When powerup the tester, the PC can detect the ST-Link, but can't detect the STM32MCU, I must unplug the USB and plug in it again, then it can detect the STM32MCU, it will be very annoying to unplug and plug the USB for every unit. I update the ST-Link to latest firmware, it still the same.

I use "STM32 ST-Link Utility" to check , the Win 7 PC works stable when power off/on, but Win 10 PC very often can't connect to my STM32MCU (40 % possibility).

My Win 10 "STM32 ST-Link Utility" is the latest version:

ST-Link Utility: V4.6.0.0

STLinkUSBDriver.dll V5.1.2.0

ST-LINK_CLI.exe V3.6.0.0

I'm using "ST-LINK_CLI" and "STLinkUSBDriver.dll" for my tester coding, should I add something extra for Win10? There is "en.stsw-link009", should I add this to Win 10?

Regards

Sam

    This topic has been closed for replies.
    Best answer by Peter BENSCH

    It looks like your question is answered, so please mark this topic as answered by choosing Select as Best for the favourite answer. This will help other users find that answer faster.

    Regards

    /Peter

    4 replies

    Technical Moderator
    May 3, 2021

    Regardless of the fact that there are many users who work with Windows 10 and USB3 without any problems, the ST-Link Utility is not recommended for new designs anymore, please upgrade to the multiplatform tool STM32CubeProgrammer. It also comes with a CLI, the commands of which are very similar to those of the predecessor and require little or no adaptation.

    If the problem is resolved, please mark this topic as answered by selecting Select as best. This will help other users find that answer faster.

    Good luck!

    /Peter

    New.FishAuthor
    Visitor II
    May 3, 2021

    Hi Peter,

    Thanks for your reply.

    I was using "ST -Link Utility" for long time, didn't realize "STMCubeProgrammer", when was it available?

    "STMCubeProgrammer" is installed in my PC, I can find "STM32_Programmer_CLI.exe", "STLinkUSBDriver.dll" and " "FlashLoader",

    but I can't find the "Command line usage" document, is it exactly same as "ST -Link Utility" which described in "UM0892 Usewr Manual for ST-Link utility"?

    Regards

    Samuel

    Technical Moderator
    May 3, 2021

    The description for CLI can either be found in UM2237, section 3, or you get it directly by starting STM32_Programmer_CLI.exe (under Windows, Linux/MacOSX may differ) without argument.

    Regards

    /Peter

    New.FishAuthor
    Visitor II
    May 4, 2021

    Hi Peter,

    Finally two ST-Link can program my board now in my Win10 PC.

    I try to copy my files to another old test PC runs win32 bit win10 OS, but I get problem to install "STM32 CubeProgrammer",

    it keep give me error message:

    This application was configured to use a bundled Java Runtime Environment

    but the runtime is missing or corrupted.

    I install the latest "Java", but it still get same error, how to fix it?

    Technical Moderator
    May 4, 2021

    The UM2237 mentioned above also lists under system requirement:

    There is no need to install any Java™ SE Run Time Environment since version 2.6.0.

    The STM32CubeProgrammer runs with a bundled JRE available inside the downloaded package and no longer with the one installed on your machine.

    Please reinstall (not copy) STM32CubeProgrammer again on that machine.

    Regards

    /Peter

    New.FishAuthor
    Visitor II
    May 5, 2021

    Hi Peter,

    I download 32-bit STM32CubeProgrammer for my old PC which runs 32-bit Win10, problem fixed.

    As general, STM32CubeProgrammer is reliable than ST-Link Utility, but it still lost communication occasionally.

    Here is the condition for my testing:

    1. Two ST-Link/V2 with firmware V2J37S7 permanently connected to STM32F417, STMF09
    2. Turn off/turn on the power supply for the MCU, make connection, it can't connect sometimes, and must unplug the USB to restore the communication.
    3. Only my new PC lost communication, my old Win10 PC reliable.
    4. Connect to PC USB port is reliable. Connect via USB hub will lost communication, the one lost communication is USB3.0, another one works reliable but I can't works out USB2.0 or USB3.0

    Hope those information will help ST to improve the STM32CubeProgrammer .

    Regards

    Samuel

    Technical Moderator
    May 5, 2021

    It looks like your question is answered, so please mark this topic as answered by choosing Select as Best for the favourite answer. This will help other users find that answer faster.

    Regards

    /Peter