# MULLE_SERIAL is used to select which specific Mulle board we are compiling for. ifdef MULLE_SERIAL CFLAGS += -DMULLE_SERIAL=$(MULLE_SERIAL) endif # this board uses openocd PROGRAMMER ?= openocd PROGRAMMERS_SUPPORTED += openocd # Default debug adapter choice is to use the Mulle programmer board OPENOCD_DEBUG_ADAPTER ?= mulle # We need special handling of the watchdog if we want to speed up the flash # verification by using the MCU to compute the image checksum after flashing. # wdog-disable.bin is a precompiled binary which will disable the watchdog and # return control to the debugger (OpenOCD) OPENOCD_PRE_VERIFY_CMDS += \ -c 'load_image $(RIOTCPU)/$(CPU)/dist/wdog-disable.bin 0x20000000 bin' \ -c 'resume 0x20000000' OPENOCD_PRE_FLASH_CHECK_SCRIPT = $(RIOTCPU)/$(CPU)/dist/check-fcfield.sh # Fall back to PROGRAMMER_SERIAL for backwards compatibility DEBUG_ADAPTER_ID ?= $(PROGRAMMER_SERIAL) # Define the default port depending on the host OS PORT_LINUX ?= /dev/ttyUSB0 PORT_DARWIN ?= $(firstword $(sort $(wildcard /dev/tty.usbserial*)))