cancel
Showing results for 
Search instead for 
Did you mean: 

Connection to ST link GDB server failed, corrupted data, cannot update through STM32Programmer

NymerisV
Associate II

Hi, I am having several days problems with connecting ST-Link to gdb server to debug. I am using ST-Link V3, V2 (genuine ones).

Everything was working fine until I connected Copy of a ST-Link debugger (I didn't know it is copy, it has original logo on the top, but I took off the cover and there was not original STM32F1 MCU, just some knock off). So I tried to update this Fake ST-Link debugger and I didn't succeed, and I tried to update it also via STM32Programmer and also through ST-Link update button in VS Code. After all of this I think it messed up my GDB server directory on my mac but I deleted all ST software and installed again but still without change. It prints GDB server failed or USB error... Than I have read that ST stopped supporting those fake debuggers so I than connected my two original V2 debuggers, but without change. I even bought new original ST-Link V3MINIE and still the same, now it prints this :

""""Error connecting to device STLINK-V3 (error 0x21); check the USB connection and refresh the device list
     [out] libusb: info [darwin_claim_interface] no interface found; setting configuration: 1
     libusb: error [darwin_claim_interface] could not set configuration
     libusb: info [darwin_claim_interface] no interface found; setting configuration: 1
     libusb: error [darwin_claim_interface] could not set configuration
     Error connecting to device ST-LINK/V2-1 (error 0x1); check the USB connection and refresh the device list"""""""
 
If anyone can give me an advice I would be grateful.
thanks in advance.
2 REPLIES 2
TDK
Guru

If you open STM32CubeProgrammer, does it detect the ST-Link chip? If not, what information or error message is displayed?

Try power cycling the computer and the programmer. Try different ports and different USB cables.

If you feel a post has answered your question, please click "Accept as Solution".

https://community.st.com/t5/stm32-mcus/how-to-solve-connection-errors-when-connecting-and-programming/tac-p/786977

https://community.st.com/t5/stm32-mcus/how-to-solve-debugger-connection-issues/ta-p/49693

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

 

A complex system that works is invariably found to have evolved from a simple system that worked.
A complex system designed from scratch never works and cannot be patched up to make it work.