Skip to main content
Visitor II
March 17, 2025
Question

STlink Getting Frequently Disconnected when Switching MOSFETs

  • March 17, 2025
  • 2 replies
  • 391 views

I am developing a PMSM motor controller using STM32F103C8T6. I want to check the variables on live expression while I am running the motor. But as soon as I increase the current draw of motor, the values on the live expression starts to show random values or blank fields. and in the console, it prints "Target is not responding, retrying...". Why might this be happening?

I am having this issue on a custom PCB that I have built. I have made a similar PCB with bigger form factor and this issue is slightly lower in that PCB. What could be the causes of this issue? and what precautions should be taken to prevent this?

2 replies

GMA
Technical Moderator
April 23, 2025

Hello @GladsonT,

You can try decreasing the used Baudrate to be less parasite sensitive.
Check with a scope DC supply or USART signals to check your power board impact on control board.

If you agree with the answer, please accept it by clicking on 'Accept as solution'.Best regards.GMA
Uwe Bonnes
Chief
April 25, 2025

Add more ground connections between target and debugger.