2015-06-15 23:03:29 +02:00
|
|
|
# define the used CPU
|
|
|
|
export CPU = nrf51
|
|
|
|
export CPU_MODEL = nrf51x22xxaa
|
2014-07-30 15:00:48 +02:00
|
|
|
|
2015-04-22 15:45:34 +02:00
|
|
|
# define the default port depending on the host OS
|
|
|
|
PORT_LINUX ?= /dev/ttyACM0
|
|
|
|
PORT_DARWIN ?= $(shell ls -1 /dev/tty.SLAB_USBtoUART* | head -n 1)
|
2014-07-30 15:00:48 +02:00
|
|
|
|
2015-06-15 23:03:29 +02:00
|
|
|
# define flash and debugging environment
|
2014-08-21 14:51:39 +02:00
|
|
|
export FLASHER = $(RIOTBOARD)/$(BOARD)/dist/flash.sh
|
|
|
|
export DEBUGGER = $(RIOTBOARD)/$(BOARD)/dist/debug.sh
|
|
|
|
export DEBUGSERVER = JLinkGDBServer -device nrf51822 -if SWD
|
|
|
|
export RESET = $(RIOTBOARD)/$(BOARD)/dist/reset.sh
|
2014-07-30 15:00:48 +02:00
|
|
|
|
|
|
|
export OFLAGS = -O binary
|
2014-08-21 14:51:39 +02:00
|
|
|
export HEXFILE = $(ELFFILE:.elf=.bin)
|
2014-08-10 05:20:57 +02:00
|
|
|
export TERMFLAGS += -p "$(PORT)"
|
2014-08-21 14:51:39 +02:00
|
|
|
export FFLAGS = $(BINDIR) $(HEXFILE)
|
|
|
|
export DEBUGGER_FLAGS = $(BINDIR) $(ELFFILE)
|
|
|
|
export RESET_FLAGS = $(BINDIR)
|
2014-07-30 15:00:48 +02:00
|
|
|
|
2015-04-22 15:45:34 +02:00
|
|
|
# setup serial terminal
|
|
|
|
include $(RIOTBOARD)/Makefile.include.serial
|