Skip to main content
pawcuu
Associate
March 10, 2022
Question

Connect Under Reset (NRST) in TrueStudio using SWD

  • March 10, 2022
  • 4 replies
  • 5964 views

Hi all,

in my project I reconfigure SWD pins to work as inputs and therefore I can't debug/upload new firmware using software system reset.

And here's my question - how to modify Startup Script (attachment) so that ST-LINK/V2 would upload (or debug) new software using NRST pin (Connect Under Reset in STM32 ST-LINK Utility works like a charm)?

Thanks!

This topic has been closed for replies.

4 replies

TDK
Super User
March 10, 2022

In CubeIDE, the setting is in the run/debug configuration options. TrueSTUDIO is NRND, but is probably similar.

0693W00000Kc7wmQAB.png

"If you feel a post has answered your question, please click ""Accept as Solution""."
pawcuu
pawcuuAuthor
Associate
March 11, 2022

Thanks for answer, however such option is unavailable in TrueSTUDIO.

Pavel A.
Super User
March 11, 2022

It's time to upgrade.

You can use the Atollic toolchain for compatibility, and the new debugger.

TDK
Super User
March 11, 2022

Might be time to update to a supported IDE.

Or you could use the STM32CubeProgrammer CLI to load a new program by adding it as an external tool.

"If you feel a post has answered your question, please click ""Accept as Solution""."
pawcuu
pawcuuAuthor
Associate
March 11, 2022

For now on I would like to stick with TrueStudio.

Could you share how to do so with STM32CubieProgrammer CLI?

Nikita91
Lead II
March 13, 2022

It seems to me that TrueSTUDIO uses Under Reset:

 -------------------------------------------------------------------
 STM32CubeProgrammer v1.3.0 
 -------------------------------------------------------------------
 
Log output file: C:\Users\Moi\AppData\Local\Temp\STM32CubeProgrammer_a13108.log
ST-LINK SN : 0670FF575056716587093335
ST-LINK FW : V2J31M21
Voltage : 3.25V
SWD freq : 4000 KHz
Connect mode: Under Reset <-------------
Reset mode : Hardware reset
Device ID : 0x431
Device name : STM32F411xC/E
Device type : MCU
Device CPU : Cortex-M4
 

Pavel A.
Super User
March 13, 2022

Maybe much simpler is to use the old good ST-Link utility to flash the update.

Configure it to connect under reset. It supports all STM32s known to Atollic.

0693W00000KcQdZQAV.png