Skip to main content
Explorer
July 16, 2024
Question

Debugging STM32F103C8T6 using the debugger of STM32F446RE nucleo board.

  • July 16, 2024
  • 2 replies
  • 1259 views

Hii everyone,

I want to debug STM32F103C8T6 controller by using the debugger present in the STM32F446RE nucleo board. After setting the parameters , when i go for debugging the following error is coming. Please guide me how i could debug my respective code using the STM32F103C8T6 controller.

Output

STMicroelectronics ST-LINK GDB server. Version 7.7.0

Copyright (c) 2024, STMicroelectronics. All rights reserved.

 

Starting server with the following options:

Persistent Mode : Disabled

Logging Level : 1

Listen Port Number : 61234

Status Refresh Delay : 15s

Verbose Mode : Disabled

SWD Debug : Enabled

 

Device connect error

 

Error in initializing ST-LINK device.

Reason: Failed to connect to device. Please check power and cabling to target.

 

Thank You...

    This topic has been closed for replies.

    2 replies

    Technical Moderator
    July 16, 2024

    Hello @Shaku ,

    Make sure to upgrade ST-Link firmware.

    Check the debug pins connections and GPIO pin used for toggling.

    ShakuAuthor
    Explorer
    July 16, 2024

    Thank you !!!!

    After checking the debug pins and GPIO pin i am getting the same error. I'm also upgrading the ST-Link firmaware but the error is coming continuously.

    Super User
    July 16, 2024

    @Shaku wrote:

    I want to debug STM32F103C8T6 controller by using the debugger present in the STM32F446RE nucleo board


    Have you set all the links on the Nucleo board correctly - to disconnect the STM32F446RE Target from the ST-Link?

    Post a schematic of your connections.

    Post some good, clear photos of your setup.

     


    @Shaku wrote:

     

    Error in initializing ST-LINK device.


    That means the computer isn't even connecting to the ST-Link.

    Does it show up in the Device Manager (or equivalent)?

    AndrewNeil_0-1721121256487.png

    If not, check your cable: are you sure it's a full data cable - not jus a charging cable?

    Try other cables.

    Try other USB ports.

     

    Knowledgebase article:

    https://community.st.com/t5/stm32-mcus/how-to-solve-debugger-connection-issues/tac-p/698105#M956

     

    ShakuAuthor
    Explorer
    July 17, 2024

    Thank you!!!

    I am using it in Linux(ubuntu) OS.

    this is the circuit connection of STM32F103C8T6 with STM32F446RE nucleo board debugger.this is the circuit connection of STM32F103C8T6 with STM32F446RE nucleo board debugger.