mirror of
https://github.com/firewalkwithm3/qmk_firmware.git
synced 2024-11-22 11:30:30 +08:00
40bc5a8192
* Enable CLI flashing via mdloader * remove flag * Update qmk flash help
23 lines
571 B
Makefile
23 lines
571 B
Makefile
# Hey Emacs, this is a -*- makefile -*-
|
|
##############################################################################
|
|
# Architecture or project specific options
|
|
#
|
|
|
|
MDLOADER_CLI ?= mdloader
|
|
|
|
define EXEC_MDLOADER
|
|
$(MDLOADER_CLI) --first --download $(BUILD_DIR)/$(TARGET).bin --restart
|
|
endef
|
|
|
|
mdloader: bin
|
|
$(call EXEC_MDLOADER)
|
|
|
|
flash: bin
|
|
ifneq ($(strip $(PROGRAM_CMD)),)
|
|
$(UNSYNC_OUTPUT_CMD) && $(PROGRAM_CMD)
|
|
else ifeq ($(strip $(ARM_ATSAM)),SAMD51J18A)
|
|
$(UNSYNC_OUTPUT_CMD) && $(call EXEC_MDLOADER)
|
|
else
|
|
$(PRINT_OK); $(SILENT) || printf "$(MSG_FLASH_ARCH)"
|
|
endif
|