From f150304643a5ccdc35e1369c41ee5dfb0a7116b8 Mon Sep 17 00:00:00 2001 From: Alexandre Abadie Date: Wed, 2 Dec 2020 14:04:07 +0100 Subject: [PATCH] boards/common/qn908x: cleanup Makefile.include - include serial.inc.mk is not needed as it's handled in the main Makefile.include - the default serial ports are already defined in serial.inc.mk - use PROGRAMMER to specify the default programmer (openocd) and don't include openocd.inc.mk - FLASHFILE is already defined as ELFILE in openocd.inc.mk --- boards/common/qn908x/Makefile.include | 20 +++++--------------- 1 file changed, 5 insertions(+), 15 deletions(-) diff --git a/boards/common/qn908x/Makefile.include b/boards/common/qn908x/Makefile.include index 9944453daa..e731a314a6 100644 --- a/boards/common/qn908x/Makefile.include +++ b/boards/common/qn908x/Makefile.include @@ -1,3 +1,8 @@ +# This board uses OpenOCD. Note that support for QN908x in OpenOCD at the time +# of writing has not been merged in the tree and is only available at +# http://openocd.zylin.com/#/c/5584/ . +PROGRAMMER ?= openocd + # Using dap or jlink depends on which firmware the OpenSDA debugger is running #DEBUG_ADAPTER ?= dap DEBUG_ADAPTER ?= jlink @@ -9,18 +14,3 @@ OPENOCD_CONFIG ?= $(RIOTBOARD)/common/qn908x/dist/openocd.cfg # verify the image, which needs to have the WDT disabled but it is normally # enabled after a 'reset halt' command. OPENOCD_PRE_FLASH_CMDS += "-c qn908x disable_wdog" - -# Set default port depending on operating system -PORT_LINUX ?= /dev/ttyACM0 -PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.usbmodem*))) - -# OpenOCD is able to handle .elf files and is the preferred way. -FLASHFILE ?= $(ELFFILE) - -# Setup serial terminal -include $(RIOTMAKE)/tools/serial.inc.mk - -# This board uses OpenOCD. Note that support for QN908x in OpenOCD at the time -# of writing has not been merged in the tree and is only available at -# http://openocd.zylin.com/#/c/5584/ . -include $(RIOTMAKE)/tools/openocd.inc.mk