Skip to content

Commit 82ce5c5

Browse files
ABOSTMnashif
authored andcommitted
boards: arm: stm32l562e_dk and nucleo_l552ze_q add openocd support
OpenOCD was partially implemented in board.cmake, it is now functional. Signed-off-by: Alexandre Bourdiol <[email protected]>
1 parent f243679 commit 82ce5c5

File tree

4 files changed

+47
-13
lines changed

4 files changed

+47
-13
lines changed

boards/arm/nucleo_l552ze_q/doc/nucleol552ze_q.rst

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -255,19 +255,17 @@ flashed in the usual way (see :ref:`build_an_application` and
255255
Flashing
256256
========
257257

258-
Nucleo L552ZE Q board includes an ST-LINK/V3E embedded debug tool
259-
interface. This interface is not yet supported by the openocd version.
260-
Instead, support can be enabled on pyocd by adding "pack" support with
261-
the following pyocd command:
258+
Nucleo L552ZE Q board includes an ST-LINK/V2-1 embedded debug tool
259+
interface. Support can be enabled on pyocd by adding "pack" support with the
260+
following pyocd command:
262261

263262
.. code-block:: console
264263
265264
$ pyocd pack --update
266265
$ pyocd pack --install stm32l552ze
267266
268-
Nucleo L552ZE Q board includes an ST-LINK/V2-1 embedded debug tool
269-
interface. This interface is supported by the openocd version
270-
included in the Zephyr SDK since v0.9.2.
267+
Alternatively, this interface is supported by the openocd version
268+
included in the Zephyr SDK since v0.13.1.
271269

272270
Flashing an application to Nucleo L552ZE Q
273271
------------------------------------------
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
source [find interface/stlink.cfg]
2+
3+
transport select hla_swd
4+
5+
source [find target/stm32l5x.cfg]
6+
7+
# use hardware reset
8+
reset_config srst_only srst_nogate
9+
10+
$_TARGETNAME configure -event gdb-attach {
11+
echo "Debugger attaching: halting execution"
12+
reset halt
13+
gdb_breakpoint_override hard
14+
}
15+
16+
$_TARGETNAME configure -event gdb-detach {
17+
echo "Debugger detaching: resuming execution"
18+
resume
19+
}

boards/arm/stm32l562e_dk/doc/index.rst

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -254,18 +254,16 @@ Flashing
254254
========
255255

256256
STM32L562E-DK Discovery board includes an ST-LINK/V3E embedded debug tool
257-
interface. This interface is not yet supported by the openocd version.
258-
Instead, support can be enabled on pyocd by adding "pack" support with
259-
the following pyocd command:
257+
interface. Support can be enabled on pyocd by adding "pack" support with the
258+
following pyocd command:
260259

261260
.. code-block:: console
262261
263262
$ pyocd pack --update
264263
$ pyocd pack --install stm32l562qe
265264
266-
STM32L562E-DK Discovery board includes an ST-LINK/V2-1 embedded debug tool
267-
interface. This interface is supported by the openocd version
268-
included in the Zephyr SDK since v0.9.2.
265+
Alternatively, this interface is supported by the openocd version
266+
included in the Zephyr SDK since v0.13.1.
269267

270268
Flashing an application to STM32L562E-DK Discovery
271269
--------------------------------------------------
Lines changed: 19 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,19 @@
1+
source [find interface/stlink.cfg]
2+
3+
transport select hla_swd
4+
5+
source [find target/stm32l5x.cfg]
6+
7+
# use hardware reset
8+
reset_config srst_only srst_nogate
9+
10+
$_TARGETNAME configure -event gdb-attach {
11+
echo "Debugger attaching: halting execution"
12+
reset halt
13+
gdb_breakpoint_override hard
14+
}
15+
16+
$_TARGETNAME configure -event gdb-detach {
17+
echo "Debugger detaching: resuming execution"
18+
resume
19+
}

0 commit comments

Comments
 (0)