Add ADXL345 accelerometer driver. From Alan Carvalho de Assis
This commit is contained in:
parent
6655ca399a
commit
ee9e8f0a20
@ -86,7 +86,7 @@ ifeq ($(CONFIG_NSH_LIBRARY),y)
|
|||||||
CSRCS += kl_nsh.c
|
CSRCS += kl_nsh.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
ifeq ($(CONFIG_INPUT_ADXL345),y)
|
ifeq ($(CONFIG_SENSORS_ADXL345),y)
|
||||||
CSRCS += kl_adxl345.c
|
CSRCS += kl_adxl345.c
|
||||||
endif
|
endif
|
||||||
|
|
||||||
|
@ -57,11 +57,7 @@
|
|||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
/* Configuration ************************************************************/
|
/* Configuration ************************************************************/
|
||||||
|
|
||||||
#ifdef CONFIG_INPUT_ADXL345
|
#ifdef CONFIG_SENSORS_ADXL345
|
||||||
#ifndef CONFIG_INPUT
|
|
||||||
# error "ADXL345 support requires CONFIG_INPUT"
|
|
||||||
#endif
|
|
||||||
|
|
||||||
#ifndef CONFIG_KL_SPI0
|
#ifndef CONFIG_KL_SPI0
|
||||||
# error "ADXL345 support requires CONFIG_KL_SPI0"
|
# error "ADXL345 support requires CONFIG_KL_SPI0"
|
||||||
#endif
|
#endif
|
||||||
@ -286,4 +282,4 @@ int adxl345_archinitialize(int minor)
|
|||||||
return OK;
|
return OK;
|
||||||
}
|
}
|
||||||
|
|
||||||
#endif /* CONFIG_INPUT_ADXL345 */
|
#endif /* CONFIG_SENSORS_ADXL345 */
|
||||||
|
@ -70,7 +70,7 @@
|
|||||||
|
|
||||||
int nsh_archinitialize(void)
|
int nsh_archinitialize(void)
|
||||||
{
|
{
|
||||||
#if defined(CONFIG_INPUT_ADXL345)
|
#if defined(CONFIG_SENSORS_ADXL345)
|
||||||
int ret;
|
int ret;
|
||||||
|
|
||||||
ret = adxl345_archinitialize(0);
|
ret = adxl345_archinitialize(0);
|
||||||
|
Loading…
Reference in New Issue
Block a user