Skip to main content
Visitor II
September 27, 2011
Question

Error in Initializing ST-Link device

  • September 27, 2011
  • 16 replies
  • 4148 views
Posted on September 27, 2011 at 05:06

Hi, 

Just started playing around with my STM32 discovery board, and had a problem right away. I'm using atollic trueStudio IDE and trying to load a demo project(the one in firmware package), to my microcontroller. The thing is everytime I hit debug button It shows this in console:

Starting server with the following options: 

        Persistant Mode            : Disabled 

        LogFile Name               : debug_log.txt

        Logging Level              : 1

        Listen Port Number         : 61234

        Status Refresh Delay       : 15s

        Verbose Mode               : Disabled 

        SWD Debug                  : Enabled 

Error in Initializing ST-Link device

I spent entire day searching web, if I could find a solution but no success yet. I found this page(

http://www.atollic.com/index.php/kb/3-debugging/28-kb_st_link_connection_error

) on atollic website, have followed the steps but still no luck. So these are the things which I have already tried:

- checked USB cable

- tried running ST-LINK GDB server, same error

- checked the driver installation, and updated to latest version

- no disk letter issue, st link is using G: and it is vacant

I have followed the user manual steps exactly still unsure what's wrong with my board. Any help appreciated.

#debugging #st-link-gdbserver #driver
    This topic has been closed for replies.

    16 replies

    Visitor II
    October 21, 2015
    Posted on October 21, 2015 at 10:01

    hye clive... can i know what is BOOT0 high? how 2 do it?

    Graduate II
    October 21, 2015
    Posted on October 21, 2015 at 15:13

    It's a pin on the device, pull it high with a pull-up resistor to the supply.

    Visitor II
    November 21, 2018

    Hello, I had the same problem and I find a solution.

    What I did is: I opened the Atollic directory then I searched for "stlinkv2usbdriver" directory. In it I find an application "dpinst_amd64.exe" (for my case). I Executed it. I opened my project with TrueSTUDIO. I builded it then I pressed "debug as ...". At this point, the IDE proposed to me to upgrade the STLink. So, I upgrade it. Then, I was able to run my program.

    I hope it will help someone.

    Source of the solution: https://youtu.be/vVlYypB7rew?t=327

    Visitor II
    November 25, 2019

    I had the same problem with debugging.

    Finally I figured out that it can be solved simply by changing the port number in debug setting.

    I choose another random port number and it perfectly works .

    Visitor II
    January 3, 2020

    Hi All,

    I had the same problem and the solution in my case was as simple as using the proper USB Cable which came with the ST-Utility. Earlier i was using the cable that was used to charge my phone (a spare one).

    March 6, 2020

    I just found this thread - I had the same problem.

    What worked for me was to allow st-link gdb server and stm32cube IDE in Windows Firewall. If the network access is denied, the USB device can't be detected in Windows.

    0690X00000DYrlKQAT.png