mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
boards: include common dfu logic where applicable
This commit is contained in:
parent
23a3dcf828
commit
f56470925b
@ -1,9 +1,10 @@
|
||||
INCLUDES += -I$(RIOTBOARD)/common/blxxxpill/include
|
||||
|
||||
# For older versions of the DFU bootloader, set DFU_USB_ID to 1d50:6017 and
|
||||
# uncomment the DFU_FLAGS line
|
||||
# For older versions of the DFU bootloader, set DFU_USB_ID to 1d50:6017
|
||||
DFU_USB_ID ?= 1eaf:0003
|
||||
#DFU_FLAGS ?= -s 0x08002000:leave
|
||||
DFU_ALT ?= 2
|
||||
|
||||
ROM_OFFSET ?= 0x2000
|
||||
|
||||
STLINK_VERSION ?= 2
|
||||
|
||||
|
@ -5,15 +5,9 @@ INCLUDES += -I$(RIOTBOARD)/common/stm32/include
|
||||
PORT_LINUX ?= /dev/ttyUSB0
|
||||
PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.SLAB_USBtoUART*)))
|
||||
|
||||
# set the default id
|
||||
ID ?= 0483:df11
|
||||
|
||||
FLASHER = dfu-util
|
||||
DEBUGGER = # dfu-util has no debugger
|
||||
RESET ?= # dfu-util has no support for resetting the device
|
||||
|
||||
FLASHFILE ?= $(BINFILE)
|
||||
FFLAGS = -d $(ID) -a 0 -s 0x08000000:leave -D $(FLASHFILE)
|
||||
# this board is flashed using DFU
|
||||
DFU_USB_ID = 0483:df11
|
||||
include $(RIOTMAKE)/tools/dfu.inc.mk
|
||||
|
||||
# setup serial terminal
|
||||
include $(RIOTMAKE)/tools/serial.inc.mk
|
||||
|
@ -9,5 +9,6 @@ PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.SLAB_USBtoUART*)))
|
||||
include $(RIOTMAKE)/tools/serial.inc.mk
|
||||
|
||||
# this board is flashed using DFU
|
||||
DFU_ARGS += --alt 0 -s 0x8000000
|
||||
DFU_USB_ID = 1d50:607f
|
||||
FFLAGS_OPTS = --reset
|
||||
include $(RIOTMAKE)/tools/dfu.inc.mk
|
||||
|
@ -3,15 +3,13 @@ PORT_LINUX ?= /dev/ttyUSB0
|
||||
PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.SLAB_USBtoUART*)))
|
||||
|
||||
include $(RIOTMAKE)/tools/serial.inc.mk
|
||||
FLASHER = dfu-util
|
||||
DEBUGGER = # spark core has no debugger
|
||||
RESET ?= # dfu-util has no support for resetting the device
|
||||
|
||||
FLASHFILE ?= $(BINFILE)
|
||||
FFLAGS = -d 1d50:607f -a 0 -s 0x08005000:leave -D $(FLASHFILE)
|
||||
|
||||
# Skip the space needed by the embedded bootloader
|
||||
ROM_OFFSET ?= 0x5000
|
||||
|
||||
# this board is flashed using DFU
|
||||
DFU_USB_ID = 1d50:607f
|
||||
include $(RIOTMAKE)/tools/dfu.inc.mk
|
||||
|
||||
# this board uses openocd
|
||||
include $(RIOTMAKE)/tools/openocd.inc.mk
|
||||
|
@ -46,13 +46,5 @@ ifeq (dfu-util,$(PROGRAMMER))
|
||||
ifeq (,$(DFU_USB_ID))
|
||||
$(error DFU_USB_ID is not set)
|
||||
endif
|
||||
# Skip the space needed by the embedded bootloader
|
||||
ROM_OFFSET ?= 0x2000
|
||||
FLASHER = dfu-util
|
||||
DEBUGGER = # no debugger
|
||||
RESET ?= # dfu-util has no support for resetting the device
|
||||
|
||||
FLASHFILE ?= $(BINFILE)
|
||||
DFU_FLAGS ?= -a 2
|
||||
FFLAGS = -d $(DFU_USB_ID) $(DFU_FLAGS) -D $(FLASHFILE)
|
||||
include $(RIOTMAKE)/tools/dfu.inc.mk
|
||||
endif
|
||||
|
Loading…
Reference in New Issue
Block a user