2014-10-21 17:30:36 +02:00
|
|
|
include ../Makefile.tests_common
|
|
|
|
|
|
|
|
FEATURES_REQUIRED = periph_i2c
|
|
|
|
|
|
|
|
USEMODULE += lsm303dlhc
|
2015-09-03 21:36:13 +02:00
|
|
|
USEMODULE += xtimer
|
2014-10-21 17:30:36 +02:00
|
|
|
|
2015-11-03 15:27:24 +01:00
|
|
|
# define parameters for selected boards
|
|
|
|
ifneq (,$(filter iotlab-m3,$(BOARD)))
|
|
|
|
TEST_LSM303DLHC_ACC_PIN ?= GPIO_PIN\(PORT_B,1\)
|
|
|
|
TEST_LSM303DLHC_MAG_PIN ?= GPIO_PIN\(PORT_B,2\)
|
2014-11-21 12:23:33 +01:00
|
|
|
endif
|
2014-10-21 17:30:36 +02:00
|
|
|
|
2015-11-03 15:27:24 +01:00
|
|
|
# set default device parameters in case they are undefined
|
2016-11-24 09:09:29 +01:00
|
|
|
TEST_LSM303DLHC_I2C ?= I2C_DEV\(0\)
|
2015-11-03 15:27:24 +01:00
|
|
|
TEST_LSM303DLHC_ACC_ADDR ?= 25
|
|
|
|
TEST_LSM303DLHC_MAG_ADDR ?= 30
|
|
|
|
TEST_LSM303DLHC_ACC_PIN ?= GPIO_PIN\(0,0\)
|
|
|
|
TEST_LSM303DLHC_MAG_PIN ?= GPIO_PIN\(0,1\)
|
|
|
|
|
|
|
|
# export parameters
|
|
|
|
CFLAGS += -DTEST_LSM303DLHC_I2C=$(TEST_LSM303DLHC_I2C)
|
|
|
|
CFLAGS += -DTEST_LSM303DLHC_ACC_ADDR=$(TEST_LSM303DLHC_ACC_ADDR)
|
|
|
|
CFLAGS += -DTEST_LSM303DLHC_MAG_ADDR=$(TEST_LSM303DLHC_MAG_ADDR)
|
|
|
|
CFLAGS += -DTEST_LSM303DLHC_ACC_PIN=$(TEST_LSM303DLHC_ACC_PIN)
|
|
|
|
CFLAGS += -DTEST_LSM303DLHC_MAG_PIN=$(TEST_LSM303DLHC_MAG_PIN)
|
|
|
|
|
2014-10-21 17:30:36 +02:00
|
|
|
include $(RIOTBASE)/Makefile.include
|