This commit aligns iis2dlpc sensor driver to latest multi
instance sensor driver model.
In particular:
1. make use of some few DT helpers:
- get bus devices with DEVICE_DT_GET
- get SPI information with SPI_CONFIG_DT_INST
- get drdy gpios with GPIO_DT_SPEC_GET
2. make use of the stmemsc common routines and move ctx
handler inside struct config, so that the bus_init
routines can be totally avoided.
Signed-off-by: Armando Visconti <armando.visconti@st.com>
13 lines
351 B
CMake
13 lines
351 B
CMake
# ST Microelectronics IIS2DLPC 3-axis accelerometer driver
|
|
#
|
|
# Copyright (c) 2020 STMicroelectronics
|
|
#
|
|
# SPDX-License-Identifier: Apache-2.0
|
|
#
|
|
zephyr_library()
|
|
|
|
zephyr_library_sources_ifdef(CONFIG_IIS2DLPC iis2dlpc)
|
|
zephyr_library_sources_ifdef(CONFIG_IIS2DLPC_TRIGGER iis2dlpc_trigger.c)
|
|
|
|
zephyr_library_include_directories(../stmemsc)
|