add dfu generate target for fomu

This commit is contained in:
hathach
2020-04-16 22:11:00 +07:00
parent 33888519dd
commit bb2669fbc0
2 changed files with 100 additions and 1 deletions
+5 -1
View File
@@ -14,7 +14,7 @@ BSP_DIR = hw/bsp/fomu
# All source paths should be relative to the top level.
LD_FILE = hw/bsp/$(BOARD)/fomu.ld
SRC_S += hw/bsp/fomu/crt0-vexriscv.S
SRC_S += hw/bsp/$(BOARD)/crt0-vexriscv.S
INC += \
$(TOP)/$(BSP_DIR)/include
@@ -27,5 +27,9 @@ CHIP_FAMILY = eptri
FREERTOS_PORT = RISC-V
# flash using dfu-util
$(BUILD)/$(BOARD)-firmware.dfu: $(BUILD)/$(BOARD)-firmware.bin
@echo "Create $@"
python $(TOP)/hw/bsp/$(BOARD)/dfu.py -b $^ -D 0x1209:0x5bf0 $@
flash: $(BUILD)/$(BOARD)-firmware.dfu
dfu-util -D $^