From 2cc8176f1da4b42d16717080fd9a7588b997ea96 Mon Sep 17 00:00:00 2001 From: Marian Buschsieweke Date: Fri, 12 Aug 2022 19:16:43 +0200 Subject: [PATCH] boards/im880b: refactor code Using the common STM32 board makefile provides all supported programmers for STM32 boards. This allows e.g. to flash with stm32flash via `make BOARD=im880b PROGRAMMER=stm32flash flash`. --- boards/im880b/Makefile.include | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/boards/im880b/Makefile.include b/boards/im880b/Makefile.include index c1aa8c243817..9c20d05dc93a 100644 --- a/boards/im880b/Makefile.include +++ b/boards/im880b/Makefile.include @@ -1,16 +1,8 @@ # this board uses shared STM32 configuration snippets INCLUDES += -I$(RIOTBOARD)/common/stm32/include -# define the default port depending on the host OS -PORT_LINUX ?= /dev/ttyUSB0 -PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.SLAB_USBtoUART*))) - CFLAGS+=-DSX127X_TX_SWITCH CFLAGS+=-DSX127X_RX_SWITCH -# this board uses openocd -PROGRAMMER ?= openocd -# openocd programmer is supported -PROGRAMMERS_SUPPORTED += openocd - -OPENOCD_DEBUG_ADAPTER ?= stlink +# Setup of programmer and serial is shared between STM32 based boards +include $(RIOTMAKE)/boards/stm32.inc.mk