1
0
mirror of https://github.com/RIOT-OS/RIOT.git synced 2025-01-18 12:52:44 +01:00

tests/driver_l3g4200d: simplified Makefile

This commit is contained in:
Hauke Petersen 2015-11-03 15:27:24 +01:00
parent fddfa7487b
commit a67a57ae39

View File

@ -6,29 +6,16 @@ FEATURES_REQUIRED = periph_i2c periph_gpio
USEMODULE += l3g4200d USEMODULE += l3g4200d
USEMODULE += xtimer USEMODULE += xtimer
ifneq (,$(TEST_L3G4200D_I2C)) # set default device parameters in case they are undefined
CFLAGS += -DTEST_L3G4200D_I2C=$(TEST_L3G4200D_I2C) TEST_L3G4200D_I2C ?= I2C_0
else TEST_L3G4200D_ADDR ?= 104
# set random default TEST_L3G4200D_INT ?= GPIO_PIN\(0,0\)
CFLAGS += -DTEST_L3G4200D_I2C=I2C_0 TEST_L3G4200D_DRDY ?= GPIO_PIN\(0,1\)
endif
ifneq (,$(TEST_L3G4200D_ADDR)) # export parameters
CFLAGS += -DTEST_L3G4200D_ADDR=$(TEST_L3G4200D_ADDR) CFLAGS += -DTEST_L3G4200D_I2C=$(TEST_L3G4200D_I2C)
else CFLAGS += -DTEST_L3G4200D_ADDR=$(TEST_L3G4200D_ADDR)
# set random default CFLAGS += -DTEST_L3G4200D_INT=$(TEST_L3G4200D_INT)
CFLAGS += -DTEST_L3G4200D_ADDR=104 CFLAGS += -DTEST_L3G4200D_DRDY=$(TEST_L3G4200D_DRDY)
endif
ifneq (,$(TEST_L3G4200D_INT))
CFLAGS += -DTEST_L3G4200D_INT=$(TEST_L3G4200D_INT)
else
# set random default
CFLAGS += -DTEST_L3G4200D_INT=GPIO_PIN\(0,0\)
endif
ifneq (,$(TEST_L3G4200D_DRDY))
CFLAGS += -DTEST_L3G4200D_DRDY=$(TEST_L3G4200D_DRDY)
else
# set random default
CFLAGS += -DTEST_L3G4200D_DRDY=GPIO_PIN\(0,1\)
endif
include $(RIOTBASE)/Makefile.include include $(RIOTBASE)/Makefile.include