cancel
Showing results for 
Search instead for 
Did you mean: 

The mcu stops working when i disconnet jtag

ASale.1
Associate

Hi everyone. I wrote a program in assembly for stm32f407 and loaded it to mcu using uvision and stlink. The mcu works properly in debug mode( at debug state the reset pin has high voltage) ​but when i disconnect the usb, mcu stops (and reset pin voltage falls to 1.25) I connected the reset pin to high voltage using a resistor and mcu worked again as expected while the cable was not connected. Is something wrong?

4 REPLIES 4
TDK
Guru

NRST has an internal pullup, so adding an external pullup shouldn't be necessary.

Your title says when you disconnect JTAG, but your post says when you disconnect USB. Please clarify what exactly is connected. Don't attach an unpowered programmer to the board while the board is powered.

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

Sometimes when you disconnect STlink power it holds reset down/active.

S.Ma
Principal

Check groundings, power rails after unplug.

Check that the target MCU does not rely on STLink MCO generated clock, nor the pull-ups on any UART RX pin.

Check your reset control HW if it is driven by STLink

YAY.1
Senior

Can you try again, while connected 3.3 volt to nrst pin ?

If you use adapter, it can be broken.Can you control that ?

Can you give codes ?