You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mynewt.apache.org by ut...@apache.org on 2019/12/05 09:10:45 UTC
[mynewt-core] 02/06: bsp: b-l072z-lrwan1: move scripts to stlink
This is an automated email from the ASF dual-hosted git repository.
utzig pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/mynewt-core.git
commit cd7231d4843061483227233021498386e6309114
Author: Fabio Utzig <ut...@apache.org>
AuthorDate: Mon Dec 2 07:35:28 2019 -0300
bsp: b-l072z-lrwan1: move scripts to stlink
---
hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_debug.sh | 7 ++-----
hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_download.sh | 7 ++-----
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_debug.sh b/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_debug.sh
index 032eeb9..8445f23 100755
--- a/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_debug.sh
+++ b/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_debug.sh
@@ -27,11 +27,8 @@
# - RESET set if target should be reset when attaching
# - NO_GDB set if we should not start gdb to debug
#
-. $CORE_PATH/hw/scripts/openocd.sh
+. $CORE_PATH/hw/scripts/stlink.sh
FILE_NAME=$BIN_BASENAME.elf
-CFG="-s $BSP_PATH -f b-l072z-lrwan1.cfg"
-# Exit openocd when gdb detaches.
-EXTRA_JTAG_CMD="$EXTRA_JTAG_CMD; stm32l0.cpu configure -event gdb-detach {if {[stm32l0.cpu curstate] eq \"halted\"} resume;shutdown}"
-openocd_debug
+stlink_debug
diff --git a/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_download.sh b/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_download.sh
index 5df97ee..5d6d649 100755
--- a/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_download.sh
+++ b/hw/bsp/b-l072z-lrwan1/b-l072z-lrwan1_download.sh
@@ -29,14 +29,11 @@
# - FLASH_OFFSET contains the flash offset to download to
# - BOOT_LOADER is set if downloading a bootloader
-. $CORE_PATH/hw/scripts/openocd.sh
-
-CFG="-s $BSP_PATH -f b-l072z-lrwan1.cfg"
+. $CORE_PATH/hw/scripts/stlink.sh
if [ "$MFG_IMAGE" ]; then
FLASH_OFFSET=0x08000000
fi
common_file_to_load
-openocd_load
-openocd_reset_run
+stlink_load