mirror of
https://github.com/RIOT-OS/RIOT.git
synced 2026-01-01 01:41:18 +01:00
Merge pull request #17470 from aabadie/pr/make/drivers_saul_auto
drivers: only build saul interface if saul module is used + add saul_drivers test application
This commit is contained in:
commit
2bddacee71
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,7 +1 @@
|
||||
SRC := hm330x.c
|
||||
|
||||
ifneq (,$(filter saul,$(USEMODULE)))
|
||||
SRC += hm330x_saul.c
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_disp_dev.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = ina2xx
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -37,6 +37,7 @@
|
||||
#define LIS2DH12_H
|
||||
|
||||
#include <stdint.h>
|
||||
#include <stdbool.h>
|
||||
|
||||
#include "saul.h"
|
||||
#include "lis2dh12_registers.h"
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = isl29020
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,2 +1 @@
|
||||
MODULE = jc42
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = l3g4200d
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = lis3dh
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = lis3mdl
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = lsm303dlhc
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = opt3001
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = pir
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -27,11 +27,14 @@
|
||||
*/
|
||||
static hm330x_t hm330x_devs[HM330X_NUMOF];
|
||||
|
||||
#if IS_ACTIVE(MODULE_SAUL)
|
||||
/**
|
||||
* @brief Number of logical saul devices per physical sensor
|
||||
*/
|
||||
#if IS_USED(MODULE_HM3302)
|
||||
#define HM330X_SAUL_DEV_NUM (6)
|
||||
#else
|
||||
#define HM330X_SAUL_DEV_NUM (3)
|
||||
#endif
|
||||
|
||||
/**
|
||||
* @brief Memory for the SAUL registry entries
|
||||
@ -50,17 +53,16 @@ static saul_reg_t saul_entries[HM330X_NUMOF * HM330X_SAUL_DEV_NUM];
|
||||
extern const saul_driver_t hm330x_saul_driver_mc_pm_1;
|
||||
extern const saul_driver_t hm330x_saul_driver_mc_pm_2p5;
|
||||
extern const saul_driver_t hm330x_saul_driver_mc_pm_10;
|
||||
#if IS_USED(MODULE_HM3302)
|
||||
extern const saul_driver_t hm330x_saul_driver_nc_pm_1;
|
||||
extern const saul_driver_t hm330x_saul_driver_nc_pm_2p5;
|
||||
extern const saul_driver_t hm330x_saul_driver_nc_pm_10;
|
||||
/** @} */
|
||||
#endif
|
||||
/** @} */
|
||||
|
||||
void auto_init_hm330x(void)
|
||||
{
|
||||
#if IS_ACTIVE(MODULE_SAUL)
|
||||
assert(HM330X_INFO_NUM == HM330X_NUMOF);
|
||||
#endif
|
||||
|
||||
for (unsigned int i = 0; i < HM330X_NUMOF; i++) {
|
||||
LOG_DEBUG("[auto_init_saul] initializing hm330x #%u\n", i);
|
||||
@ -70,19 +72,19 @@ void auto_init_hm330x(void)
|
||||
i);
|
||||
continue;
|
||||
}
|
||||
#if IS_ACTIVE(MODULE_SAUL)
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM)].driver = &hm330x_saul_driver_mc_pm_1;
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM) + 1].driver = &hm330x_saul_driver_mc_pm_2p5;
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM) + 2].driver = &hm330x_saul_driver_mc_pm_10;
|
||||
#if IS_USED(MODULE_HM3302)
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM) + 3].driver = &hm330x_saul_driver_nc_pm_1;
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM) + 4].driver = &hm330x_saul_driver_nc_pm_2p5;
|
||||
saul_entries[(i * HM330X_SAUL_DEV_NUM) + 5].driver = &hm330x_saul_driver_nc_pm_10;
|
||||
#endif
|
||||
/* the physical device is the same for all logical SAUL instances */
|
||||
for (unsigned x = 0; x < HM330X_SAUL_DEV_NUM; x++) {
|
||||
saul_entries[i * HM330X_SAUL_DEV_NUM + x].dev = &(hm330x_devs[i]);
|
||||
saul_entries[i * HM330X_SAUL_DEV_NUM + x].name = hm330x_saul_info[i].name;
|
||||
saul_reg_add(&saul_entries[i * HM330X_SAUL_DEV_NUM + x]);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
}
|
||||
@ -251,14 +251,14 @@ void saul_init_devs(void)
|
||||
extern void auto_init_scd30(void);
|
||||
auto_init_scd30();
|
||||
}
|
||||
if (IS_USED(MODULE_SHT2X)) {
|
||||
extern void auto_init_sht2x(void);
|
||||
auto_init_sht2x();
|
||||
}
|
||||
if (IS_USED(MODULE_SDP3X)) {
|
||||
extern void auto_init_sdp3x(void);
|
||||
auto_init_sdp3x();
|
||||
}
|
||||
if (IS_USED(MODULE_SDS011)) {
|
||||
extern void auto_init_sds011(void);
|
||||
auto_init_sds011();
|
||||
}
|
||||
if (IS_USED(MODULE_SEESAW_SOIL)) {
|
||||
extern void auto_init_seesaw_soil(void);
|
||||
auto_init_seesaw_soil();
|
||||
@ -267,6 +267,10 @@ void saul_init_devs(void)
|
||||
extern void auto_init_sgp30(void);
|
||||
auto_init_sgp30();
|
||||
}
|
||||
if (IS_USED(MODULE_SHT2X)) {
|
||||
extern void auto_init_sht2x(void);
|
||||
auto_init_sht2x();
|
||||
}
|
||||
if (IS_USED(MODULE_SHT3X)) {
|
||||
extern void auto_init_sht3x(void);
|
||||
auto_init_sht3x();
|
||||
@ -275,10 +279,6 @@ void saul_init_devs(void)
|
||||
extern void auto_init_shtc1(void);
|
||||
auto_init_shtc1();
|
||||
}
|
||||
if (IS_USED(MODULE_SDS011)) {
|
||||
extern void auto_init_sds011(void);
|
||||
auto_init_sds011();
|
||||
}
|
||||
if (IS_USED(MODULE_SI1133)) {
|
||||
extern void auto_init_si1133(void);
|
||||
auto_init_si1133();
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,7 +1 @@
|
||||
SRC := sgp30.c
|
||||
|
||||
ifneq (,$(filter saul,$(USEMODULE)))
|
||||
SRC += sgp30_saul.c
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = shtc1
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,7 +1 @@
|
||||
SRC := sm_pwm_01c.c
|
||||
|
||||
ifneq (,$(filter saul,$(USEMODULE)))
|
||||
SRC += sm_pwm_01c_saul.c
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -55,12 +55,10 @@ const saul_driver_t sm_pwm_01c_saul_driver_mc_pm_10 = {
|
||||
.read = read_mc_pm_10,
|
||||
.write = saul_notsup,
|
||||
.type = SAUL_SENSE_PM,
|
||||
.subtype = SAUL_SENSE_PM_10,
|
||||
};
|
||||
|
||||
const saul_driver_t sm_pwm_01c_saul_driver_mc_pm_2p5 = {
|
||||
.read = read_mc_pm_2p5,
|
||||
.write = saul_notsup,
|
||||
.type = SAUL_SENSE_PM,
|
||||
.subtype = SAUL_SENSE_PM_2p5,
|
||||
};
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_touch_dev.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = tsl2561
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1,3 +1 @@
|
||||
MODULE = tsl4531x
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
@ -1 +1 @@
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
include $(RIOTMAKE)/driver_with_saul.mk
|
||||
|
||||
12
makefiles/driver_with_disp_dev.mk
Normal file
12
makefiles/driver_with_disp_dev.mk
Normal file
@ -0,0 +1,12 @@
|
||||
MODULE ?= $(shell basename $(CURDIR))
|
||||
DISP_DEV_INTERFACE ?= $(MODULE)_disp_dev.c
|
||||
|
||||
# by default include all .c files except <module>_disp_dev.c
|
||||
SRC = $(filter-out $(DISP_DEV_INTERFACE),$(wildcard *.c))
|
||||
|
||||
# only include <module>_disp_dev.c if saul module is used
|
||||
ifneq (,$(filter disp_dev,$(USEMODULE)))
|
||||
SRC += $(DISP_DEV_INTERFACE)
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
12
makefiles/driver_with_saul.mk
Normal file
12
makefiles/driver_with_saul.mk
Normal file
@ -0,0 +1,12 @@
|
||||
MODULE ?= $(shell basename $(CURDIR))
|
||||
SAUL_INTERFACE ?= $(MODULE)_saul.c
|
||||
|
||||
# by default include all .c files except <module>_saul.c
|
||||
SRC = $(filter-out $(SAUL_INTERFACE),$(wildcard *.c))
|
||||
|
||||
# only include <module>_saul.c if saul module is used
|
||||
ifneq (,$(filter saul,$(USEMODULE)))
|
||||
SRC += $(SAUL_INTERFACE)
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
12
makefiles/driver_with_touch_dev.mk
Normal file
12
makefiles/driver_with_touch_dev.mk
Normal file
@ -0,0 +1,12 @@
|
||||
MODULE ?= $(shell basename $(CURDIR))
|
||||
TOUCH_DEV_INTERFACE ?= $(MODULE)_touch_dev.c
|
||||
|
||||
# by default include all .c files except <module>_touch_dev.c
|
||||
SRC = $(filter-out $(TOUCH_DEV_INTERFACE),$(wildcard *.c))
|
||||
|
||||
# only include <module>_touch_dev.c if saul module is used
|
||||
ifneq (,$(filter touch_dev,$(USEMODULE)))
|
||||
SRC += $(TOUCH_DEV_INTERFACE)
|
||||
endif
|
||||
|
||||
include $(RIOTBASE)/Makefile.base
|
||||
52
tests/saul_drivers/Makefile
Normal file
52
tests/saul_drivers/Makefile
Normal file
@ -0,0 +1,52 @@
|
||||
BOARD ?= stm32f4discovery
|
||||
include ../Makefile.tests_common
|
||||
|
||||
# Only build on a subset of boards (one per arch supported and
|
||||
# with enough features provided)
|
||||
BOARD_WHITELIST ?= \
|
||||
atmega256rfr2-xpro \
|
||||
esp32-wroom-32 \
|
||||
stm32f4discovery \
|
||||
#
|
||||
|
||||
# Get the list of drivers with a SAUL interface (without saul periph)
|
||||
DRIVERS_DIR = $(RIOTBASE)/drivers
|
||||
DRIVERS_WITH_SAUL_PATHS = $(filter-out $(wildcard $(DRIVERS_DIR)/saul/*_saul.c),$(wildcard $(DRIVERS_DIR)/*/*_saul.c))
|
||||
DRIVERS ?= $(subst _saul.c,,$(notdir $(DRIVERS_WITH_SAUL_PATHS)))
|
||||
USEMODULE += $(DRIVERS)
|
||||
|
||||
# Somes drivers with submodules needs special care to select a precise driver variant
|
||||
ifneq (,$(filter adcxx1c,$(DRIVERS)))
|
||||
USEMODULE += adc081c
|
||||
endif
|
||||
ifneq (,$(filter apds99xx,$(DRIVERS)))
|
||||
USEMODULE += apds9960
|
||||
endif
|
||||
ifneq (,$(filter bme680,$(DRIVERS)))
|
||||
USEMODULE += bme680_i2c
|
||||
endif
|
||||
ifneq (,$(filter lm75,$(DRIVERS)))
|
||||
USEMODULE += tmp1075
|
||||
endif
|
||||
ifneq (,$(filter lpsxxx,$(DRIVERS)))
|
||||
USEMODULE += lps22hh
|
||||
endif
|
||||
ifneq (,$(filter mhz19,$(DRIVERS)))
|
||||
USEMODULE += mhz19_uart
|
||||
endif
|
||||
ifneq (,$(filter mpu9x50,$(DRIVERS)))
|
||||
USEMODULE += mpu9150
|
||||
endif
|
||||
ifneq (,$(filter pcf857x,$(DRIVERS)))
|
||||
USEMODULE += pcf8575
|
||||
endif
|
||||
ifneq (,$(filter si70xx,$(DRIVERS)))
|
||||
USEMODULE += si7021
|
||||
endif
|
||||
ifneq (,$(filter tmp00x,$(DRIVERS)))
|
||||
USEMODULE += tmp006
|
||||
endif
|
||||
|
||||
USEMODULE += saul_default
|
||||
|
||||
include $(RIOTBASE)/Makefile.include
|
||||
9
tests/saul_drivers/README.md
Normal file
9
tests/saul_drivers/README.md
Normal file
@ -0,0 +1,9 @@
|
||||
saul_drivers
|
||||
============
|
||||
|
||||
This application is only used by the CI to check the build of drivers that
|
||||
provide a SAUL interface.
|
||||
All such drivers are added automatically to the build along with the
|
||||
`saul_default` module. This will check:
|
||||
- the build of the saul interface,
|
||||
- the build of driver auto initialization.
|
||||
24
tests/saul_drivers/main.c
Normal file
24
tests/saul_drivers/main.c
Normal file
@ -0,0 +1,24 @@
|
||||
/*
|
||||
* Copyright (C) 2022 Inria
|
||||
*
|
||||
* This file is subject to the terms and conditions of the GNU Lesser
|
||||
* General Public License v2.1. See the file LICENSE in the top level
|
||||
* directory for more details.
|
||||
*/
|
||||
|
||||
/**
|
||||
* @ingroup tests
|
||||
* @{
|
||||
*
|
||||
* @file
|
||||
* @brief Build test application for drivers providing a SAUL interface
|
||||
*
|
||||
* @author Alexandre Abadie <alexandre.abadie@inria.fr>
|
||||
*
|
||||
* @}
|
||||
*/
|
||||
|
||||
int main(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
Loading…
x
Reference in New Issue
Block a user