Commit 69c7f1e6 authored by Dan Kalowsky's avatar Dan Kalowsky Committed by Anas Nashif
Browse files

boards: nucleo: Adding flash support



Adding an openocd.cfg to control flashing of the Nucleo-F103RB board

Change-Id: Ia730244bdc2d31d074fe72c41d3e58e7830c8df0
Signed-off-by: default avatarDan Kalowsky <daniel.kalowsky@intel.com>
Signed-off-by: default avatarAnas Nashif <anas.nashif@intel.com>
parent 6f6e65bf
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
FLASH_SCRIPT = openocd.sh

OPENOCD_LOAD_CMD = "flash write_image erase ${O}/${KERNEL_BIN_NAME} ${CONFIG_FLASH_BASE_ADDRESS}"
OPENOCD_VERIFY_CMD = "verify_image ${O}/${KERNEL_BIN_NAME} ${CONFIG_FLASH_BASE_ADDRESS}"

export FLASH_SCRIPT OPENOCD_LOAD_CMD OPENOCD_VERIFY_CMD
+12 −0
Original line number Diff line number Diff line
source [find board/st_nucleo_f103rb.cfg]

$_TARGETNAME configure -event gdb-attach {
        echo "Debugger attaching: halting execution"
        reset halt
        gdb_breakpoint_override hard
}

$_TARGETNAME configure -event gdb-detach {
        echo "Debugger detaching: resuming execution"
        resume
}