board/nucloe-f334: use unified openocd script
This commit is contained in:
parent
a5a1ffe6ba
commit
d076bc13e3
@ -23,11 +23,12 @@ export AS = $(PREFIX)as
|
||||
export LINK = $(PREFIX)gcc
|
||||
export SIZE = $(PREFIX)size
|
||||
export OBJCOPY = $(PREFIX)objcopy
|
||||
export DBG = $(PREFIX)gdb
|
||||
export TERMPROG = $(RIOTBASE)/dist/tools/pyterm/pyterm
|
||||
export FLASHER = $(RIOTBOARD)/$(BOARD)/dist/flash.sh
|
||||
export DEBUGGER = $(RIOTBOARD)/$(BOARD)/dist/debug.sh
|
||||
export DEBUGSERVER = $(RIOTBOARD)/$(BOARD)/dist/debug-server.sh
|
||||
export RESET = $(RIOTBOARD)/$(BOARD)/dist/reset.sh
|
||||
export FLASHER = $(RIOTBASE)/dist/tools/openocd/openocd.sh
|
||||
export DEBUGGER = $(RIOTBASE)/dist/tools/openocd/openocd.sh
|
||||
export DEBUGSERVER = $(RIOTBASE)/dist/tools/openocd/openocd.sh
|
||||
export RESET = $(RIOTBASE)/dist/tools/openocd/openocd.sh
|
||||
|
||||
# unwanted (CXXUWFLAGS) and extra (CXXEXFLAGS) flags for c++
|
||||
export CXXUWFLAGS +=
|
||||
@ -42,10 +43,12 @@ export ASFLAGS += -ggdb -g3 $(CPU_USAGE) $(FPU_USAGE) -mlittle-endian
|
||||
export LINKFLAGS += -ggdb -g3 -std=gnu99 $(CPU_USAGE) $(FPU_USAGE) -mlittle-endian -static -lgcc -mthumb -mno-thumb-interwork -nostartfiles
|
||||
# $(LINKERSCRIPT) is specified in cpu/Makefile.include
|
||||
export LINKFLAGS += -T$(LINKERSCRIPT)
|
||||
export OFLAGS = -O binary
|
||||
export FFLAGS = $(HEXFILE)
|
||||
export DEBUGGER_FLAGS = $(RIOTBOARD)/$(BOARD)/dist/gdb.conf $(ELFFILE)
|
||||
export OFLAGS = -O ihex
|
||||
export TERMFLAGS += -p "$(PORT)"
|
||||
export FFLAGS = flash
|
||||
export DEBUGGER_FLAGS = debug
|
||||
export DEBUGSERVER_FLAGS = debug-server
|
||||
export RESET_FLAGS = reset
|
||||
|
||||
# use the nano-specs of the NewLib when available
|
||||
#ifeq ($(shell $(LINK) -specs=nano.specs -E - 2>/dev/null >/dev/null </dev/null ; echo $$?),0)
|
||||
|
||||
10
boards/nucleo-f334/dist/debug-server.sh
vendored
10
boards/nucleo-f334/dist/debug-server.sh
vendored
@ -1,10 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
echo "##"
|
||||
echo "## Starting debug server"
|
||||
echo "##"
|
||||
|
||||
openocd -f board/st_nucleo_f334r8.cfg \
|
||||
-c "init" \
|
||||
-c "targets" \
|
||||
-c "reset halt"
|
||||
11
boards/nucleo-f334/dist/debug.sh
vendored
11
boards/nucleo-f334/dist/debug.sh
vendored
@ -1,11 +0,0 @@
|
||||
#!/bin/sh
|
||||
|
||||
if [ ! -f "$2" ]; then
|
||||
echo "ELF-file $2 does not exist"
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "##"
|
||||
echo "## Debugging $2"
|
||||
echo "##"
|
||||
arm-none-eabi-gdb -tui -command="$1" $2
|
||||
13
boards/nucleo-f334/dist/flash.sh
vendored
13
boards/nucleo-f334/dist/flash.sh
vendored
@ -1,13 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo "##"
|
||||
echo "## Flashing $1"
|
||||
echo "##"
|
||||
|
||||
openocd -f board/st_nucleo_f334r8.cfg \
|
||||
-c "init" \
|
||||
-c "targets" \
|
||||
-c "reset halt" \
|
||||
-c "program $1 0x8000000 verify" \
|
||||
-c "reset run"\
|
||||
-c "shutdown"
|
||||
1
boards/nucleo-f334/dist/gdb.conf
vendored
1
boards/nucleo-f334/dist/gdb.conf
vendored
@ -1 +0,0 @@
|
||||
tar extended-remote :3333
|
||||
1
boards/nucleo-f334/dist/openocd.cfg
vendored
Normal file
1
boards/nucleo-f334/dist/openocd.cfg
vendored
Normal file
@ -0,0 +1 @@
|
||||
source [find board/st_nucleo_f334r8.cfg]
|
||||
10
boards/nucleo-f334/dist/reset.sh
vendored
10
boards/nucleo-f334/dist/reset.sh
vendored
@ -1,10 +0,0 @@
|
||||
#!/bin/bash
|
||||
|
||||
echo "##"
|
||||
echo "## Resetting $1"
|
||||
echo "##"
|
||||
|
||||
openocd -f board/st_nucleo_f334r8.cfg \
|
||||
-c "init" \
|
||||
-c "reset run"\
|
||||
-c "shutdown"
|
||||
Loading…
x
Reference in New Issue
Block a user