mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2024-12-29 04:50:03 +01:00
76 lines
1.8 KiB
Makefile
76 lines
1.8 KiB
Makefile
APPLICATION = driver_at86rf2xx
|
|
include ../Makefile.tests_common
|
|
|
|
FEATURES_REQUIRED = periph_spi periph_gpio
|
|
|
|
BOARD_INSUFFICIENT_RAM := stm32f0discovery
|
|
BOARD_BLACKLIST := nucleo-f334
|
|
# nucleo-f334: not enough GPIO pins defined
|
|
|
|
ifneq (,$(filter samr21-xpro,$(BOARD)))
|
|
DRIVER ?= ng_at86rf233
|
|
USE_BOARD_PARAMETERS:=true
|
|
endif
|
|
ifneq (,$(filter iot-lab_M3,$(BOARD)))
|
|
DRIVER ?= ng_at86rf231
|
|
USE_BOARD_PARAMETERS:=true
|
|
endif
|
|
|
|
ifneq (,$(DRIVER))
|
|
USEMODULE += $(DRIVER)
|
|
else
|
|
# default to ng_at86rf231
|
|
USEMODULE += ng_at86rf231
|
|
endif
|
|
|
|
ifneq (true,$(USE_BOARD_PARAMETERS))
|
|
# This adds . to include path so generic ng_at86rf2xx_params.h gets picked
|
|
# up. All boards actually having such a device on board should define
|
|
# USE_BOARD_PARAMETERS=true above to skip this step, as the board provides
|
|
# this header.
|
|
CFLAGS += -I$(CURDIR)
|
|
|
|
ifneq (,$(ATRF_SPI))
|
|
CFLAGS += -DATRF_SPI=$(ATRF_SPI)
|
|
else
|
|
CFLAGS += -DATRF_SPI=SPI_0 # set default
|
|
endif
|
|
ifneq (,$(ATRF_CS))
|
|
CFLAGS += -DATRF_CS=$(ATRF_CS)
|
|
else
|
|
CFLAGS += -DATRF_CS=GPIO_0 # set default
|
|
endif
|
|
ifneq (,$(ATRF_INT))
|
|
CFLAGS += -DATRF_INT=$(ATRF_INT)
|
|
else
|
|
CFLAGS += -DATRF_INT=GPIO_1 # set default
|
|
endif
|
|
ifneq (,$(ATRF_SLEEP))
|
|
CFLAGS += -DATRF_SLEEP=$(ATRF_SLEEP)
|
|
else
|
|
CFLAGS += -DATRF_SLEEP=GPIO_2 # set default
|
|
endif
|
|
ifneq (,$(ATRF_RESET))
|
|
CFLAGS += -DATRF_RESET=$(ATRF_RESET)
|
|
else
|
|
CFLAGS += -DATRF_RESET=GPIO_3 # set default
|
|
endif
|
|
ifneq (,$(ATRF_SPI_SPEED))
|
|
CFLAGS += -DATRF_SPI_SPEED=$(ATRF_SPI_SPEED)
|
|
endif
|
|
|
|
endif # USE_BOARD_PARAMETERS=false
|
|
|
|
USEMODULE += auto_init_ng_netif
|
|
USEMODULE += ng_netif
|
|
USEMODULE += ng_nomac
|
|
USEMODULE += ng_pktdump
|
|
USEMODULE += uart0
|
|
USEMODULE += shell
|
|
USEMODULE += shell_commands
|
|
USEMODULE += ps
|
|
|
|
CFLAGS += -DDEVELHELP
|
|
|
|
include $(RIOTBASE)/Makefile.include
|