diff --git a/boards/common/iotlab/include/board_common.h b/boards/common/iotlab/include/board_common.h index b029ef1bbcf199bc60080a8db8d051a50e25f4e1..129b9c66f35bb605562ed1890d31dcfeb11fe2c5 100644 --- a/boards/common/iotlab/include/board_common.h +++ b/boards/common/iotlab/include/board_common.h @@ -55,16 +55,16 @@ extern "C" { /** @} */ /** - * @brief Define the interface to the AT86RF231 radio + * @name Define the interface to the AT86RF231 radio * * {spi bus, spi speed, cs pin, int pin, reset pin, sleep pin} + * @{ */ -#define AT86RF2XX_PARAMS_BOARD {.spi = SPI_DEV(0), \ - .spi_clk = SPI_CLK_5MHZ, \ - .cs_pin = GPIO_PIN(PORT_A, 4), \ - .int_pin = GPIO_PIN(PORT_C, 4), \ - .sleep_pin = GPIO_PIN(PORT_A, 2), \ - .reset_pin = GPIO_PIN(PORT_C, 1)} +#define AT86RF2XX_PARAM_CS GPIO_PIN(PORT_A, 4) +#define AT86RF2XX_PARAM_INT GPIO_PIN(PORT_C, 4) +#define AT86RF2XX_PARAM_SLEEP GPIO_PIN(PORT_A, 2) +#define AT86RF2XX_PARAM_RESET GPIO_PIN(PORT_C, 1) +/** @} */ /** * @name LED pin definitions and handlers diff --git a/boards/common/iotlab/include/l3g4200d_params.h b/boards/common/iotlab/include/l3g4200d_params.h deleted file mode 100644 index 239e8ee834b133eaeb3b8c2bc567a37057b77a46..0000000000000000000000000000000000000000 --- a/boards/common/iotlab/include/l3g4200d_params.h +++ /dev/null @@ -1,59 +0,0 @@ -/* - * Copyright (C) 2015 Freie Universität Berlin - * - * 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 boards_common_iotlab - * @{ - * - * @file - * @brief L3G4200D board specific configuration - * - * @author Hauke Petersen <hauke.petersen@fu-berlin.de> - */ - -#ifndef L3G4200D_PARAMS_H -#define L3G4200D_PARAMS_H - -#include "board.h" -#include "saul_reg.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @brief L3G4200D configuration - */ -static const l3g4200d_params_t l3g4200d_params[] = -{ - { - .i2c = L3G4200D_I2C, - .addr = L3G4200D_ADDR, - .int1_pin = L3G4200D_INT, - .int2_pin = L3G4200D_DRDY, - .mode = L3G4200D_MODE_200_25, - .scale = L3G4200D_SCALE_500DPS, - }, -}; - -/** - * @brief Additional meta information to keep in the SAUL registry - */ -static const saul_reg_info_t l3g4200d_saul_info[] = -{ - { - .name = "l3g4200d", - }, -}; - -#ifdef __cplusplus -} -#endif - -#endif /* L3G4200D_PARAMS_H */ -/** @} */ diff --git a/boards/common/iotlab/include/lsm303dlhc_params.h b/boards/common/iotlab/include/lsm303dlhc_params.h deleted file mode 100644 index 0f7117d6b91f25be5bcda619eef43dee4a1407e7..0000000000000000000000000000000000000000 --- a/boards/common/iotlab/include/lsm303dlhc_params.h +++ /dev/null @@ -1,62 +0,0 @@ -/* - * Copyright (C) 2015 Freie Universität Berlin - * - * 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 boards_common_iotlab - * @{ - * - * @file - * @brief LSM303DLHC board specific configuration - * - * @author Hauke Petersen <hauke.petersen@fu-berlin.de> - */ - -#ifndef LSM303DLHC_PARAMS_H -#define LSM303DLHC_PARAMS_H - -#include "board.h" -#include "saul_reg.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @brief LSM303DLHC configuration - */ -static const lsm303dlhc_params_t lsm303dlhc_params[] = -{ - { - .i2c = LSM303DLHC_I2C, - .acc_addr = LSM303DLHC_ACC_ADDR, - .acc_pin = LSM303DLHC_INT1, - .acc_rate = LSM303DLHC_ACC_SAMPLE_RATE_10HZ, - .acc_scale = LSM303DLHC_ACC_SCALE_4G, - .mag_addr = LSM303DLHC_MAG_ADDR, - .mag_pin = LSM303DLHC_DRDY, - .mag_rate = LSM303DLHC_MAG_SAMPLE_RATE_15HZ, - .mag_gain = LSM303DLHC_MAG_GAIN_450_400_GAUSS, - }, -}; - -/** - * @brief Additional meta information to keep in the SAUL registry - */ -static const saul_reg_info_t lsm303dlhc_saul_info[] = -{ - { - .name = "lsm303dlhc", - }, -}; - -#ifdef __cplusplus -} -#endif - -#endif /* LSM303DLHC_PARAMS_H */ -/** @} */ diff --git a/boards/iotlab-a8-m3/include/board.h b/boards/iotlab-a8-m3/include/board.h index cf9086163b6e99108c61237da04aaa21c7dd7fbf..3529db086bf86b889a33a8147fb71b7d929568c3 100644 --- a/boards/iotlab-a8-m3/include/board.h +++ b/boards/iotlab-a8-m3/include/board.h @@ -34,22 +34,16 @@ extern "C" { * @name Define the interface for the L3G4200D gyroscope * @{ */ -#define L3G4200D_I2C I2C_0 -#define L3G4200D_ADDR 0x68 -#define L3G4200D_DRDY GPIO_PIN(PORT_C,9) -#define L3G4200D_INT GPIO_PIN(PORT_C,6) +#define L3G4200D_PARAM_INT2 GPIO_PIN(PORT_C, 9) +#define L3G4200D_PARAM_INT1 GPIO_PIN(PORT_C, 6) /** @} */ /** * @name Define the interface to the LSM303DLHC accelerometer and magnetometer * @{ */ -#define LSM303DLHC_I2C I2C_0 -#define LSM303DLHC_ACC_ADDR (0x19) -#define LSM303DLHC_MAG_ADDR (0x1e) -#define LSM303DLHC_INT1 GPIO_PIN(PORT_B,12) -#define LSM303DLHC_INT2 GPIO_PIN(PORT_B,2) -#define LSM303DLHC_DRDY GPIO_PIN(PORT_A,11) +#define LSM303DLHC_PARAM_ACC_PIN GPIO_PIN(PORT_B, 12) +#define LSM303DLHC_PARAM_MAG_PIN GPIO_PIN(PORT_A, 11) /** @} */ #ifdef __cplusplus diff --git a/boards/iotlab-m3/include/board.h b/boards/iotlab-m3/include/board.h index 908598988998fdc6a5e44e4e05477e97dcb63ea4..595583a687a129c80fa2d0e8ebfc88bb8c6fc18a 100644 --- a/boards/iotlab-m3/include/board.h +++ b/boards/iotlab-m3/include/board.h @@ -39,47 +39,32 @@ extern "C" { * @{ */ #define EXTFLASH_SPI SPI_DEV(1) -#define EXTFLASH_CS GPIO_PIN(PORT_A,11) -#define EXTFLASH_WRITE GPIO_PIN(PORT_C,6) -#define EXTFLASH_HOLD GPIO_PIN(PORT_C,9) -/** @} */ - -/** - * @name Define the interface to the ISL29020 light sensor - * @{ - */ -#define ISL29020_I2C I2C_0 -#define ISL29020_ADDR 0x44 +#define EXTFLASH_CS GPIO_PIN(PORT_A, 11) +#define EXTFLASH_WRITE GPIO_PIN(PORT_C, 6) +#define EXTFLASH_HOLD GPIO_PIN(PORT_C, 9) /** @} */ /** * @name Define the interface to the LPS331AP pressure sensor * @{ */ -#define LPS331AP_I2C I2C_0 -#define LPS331AP_ADDR 0x5c +#define LPS331AP_PARAM_ADDR (0x5C) /** @} */ /** * @name Define the interface for the L3G4200D gyroscope * @{ */ -#define L3G4200D_I2C I2C_0 -#define L3G4200D_ADDR 0x68 -#define L3G4200D_DRDY GPIO_PIN(PORT_C,0) -#define L3G4200D_INT GPIO_PIN(PORT_C,5) +#define L3G4200D_PARAM_INT2 GPIO_PIN(PORT_C, 0) +#define L3G4200D_PARAM_INT1 GPIO_PIN(PORT_C, 5) /** @} */ /** * @name Define the interface to the LSM303DLHC accelerometer and magnetometer * @{ */ -#define LSM303DLHC_I2C I2C_0 -#define LSM303DLHC_ACC_ADDR (0x19) -#define LSM303DLHC_MAG_ADDR (0x1e) -#define LSM303DLHC_INT1 GPIO_PIN(PORT_B,12) -#define LSM303DLHC_INT2 GPIO_PIN(PORT_B,1) -#define LSM303DLHC_DRDY GPIO_PIN(PORT_B,2) +#define LSM303DLHC_PARAM_ACC_PIN GPIO_PIN(PORT_B, 12) +#define LSM303DLHC_PARAM_MAG_PIN GPIO_PIN(PORT_B, 2) /** @} */ #ifdef __cplusplus diff --git a/boards/iotlab-m3/include/isl29020_params.h b/boards/iotlab-m3/include/isl29020_params.h deleted file mode 100644 index 66c3a2ca387e972580b4074bf2c5e37ade16155e..0000000000000000000000000000000000000000 --- a/boards/iotlab-m3/include/isl29020_params.h +++ /dev/null @@ -1,57 +0,0 @@ -/* - * Copyright (C) 2015 Freie Universität Berlin - * - * 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 boards_iotlab-m3 - * @{ - * - * @file - * @brief ISL29020 board specific configuration - * - * @author Hauke Petersen <hauke.petersen@fu-berlin.de> - */ - -#ifndef ISL29020_PARAMS_H -#define ISL29020_PARAMS_H - -#include "board.h" -#include "saul_reg.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @brief ISL29020 parameter configuration - */ -static const isl29020_params_t isl29020_params[] = -{ - { - .i2c = ISL29020_I2C, - .addr = ISL29020_ADDR, - .range = ISL29020_RANGE_16K, - .mode = ISL29020_MODE_AMBIENT, - }, -}; - -/** - * @brief Additional meta information to keep in the SAUL registry - */ -static const saul_reg_info_t isl29020_saul_info[] = -{ - { - .name = "isl29020", - }, -}; - -#ifdef __cplusplus -} -#endif - -#endif /* ISL29020_PARAMS_H */ -/** @} */ diff --git a/boards/iotlab-m3/include/lps331ap_params.h b/boards/iotlab-m3/include/lps331ap_params.h deleted file mode 100644 index 3a8c9e5710dba1e06df6f1848331772571b07e35..0000000000000000000000000000000000000000 --- a/boards/iotlab-m3/include/lps331ap_params.h +++ /dev/null @@ -1,56 +0,0 @@ -/* - * Copyright (C) 2015 Freie Universität Berlin - * - * 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 boards_iotlab-m3 - * @{ - * - * @file - * @brief LPS331AP board specific configuration - * - * @author Hauke Petersen <hauke.petersen@fu-berlin.de> - */ - -#ifndef LPS331AP_PARAMS_H -#define LPS331AP_PARAMS_H - -#include "board.h" -#include "saul_reg.h" - -#ifdef __cplusplus -extern "C" { -#endif - -/** - * @brief LPS331AP configuration - */ -static const lps331ap_params_t lps331ap_params[] = -{ - { - .i2c = LPS331AP_I2C, - .addr = LPS331AP_ADDR, - .rate = LPS331AP_RATE_7HZ, - }, -}; - -/** - * @brief Additional meta information to keep in the SAUL registry - */ -static const saul_reg_info_t lps331ap_saul_info[] = -{ - { - .name = "lps331ap", - }, -}; - -#ifdef __cplusplus -} -#endif - -#endif /* LPS331AP_PARAMS_H */ -/** @} */