1source [find interface/stlink.cfg]
2
3transport select hla_swd
4
5source [find target/stm32f4x.cfg]
6
7adapter speed 1000
8
9reset_config srst_only
10
11$_TARGETNAME configure -event gdb-attach {
12	echo "Debugger attaching: halting execution"
13	reset halt
14	gdb_breakpoint_override hard
15}
16
17$_TARGETNAME configure -event gdb-detach {
18	echo "Debugger detaching: resuming execution"
19	resume
20}
21