diff --git a/boards/ruuvitag/include/board.h b/boards/ruuvitag/include/board.h index 0278f245e8049feff5a8b0bbdac4e94793031a86..a87a972f84bd39238b26a80634929f0b1b481880 100644 --- a/boards/ruuvitag/include/board.h +++ b/boards/ruuvitag/include/board.h @@ -34,10 +34,18 @@ extern "C" { #define LED0_PIN GPIO_PIN(0, 17) #define LED1_PIN GPIO_PIN(0, 19) +/* as a shortcut, we include the two CS pins into the LED_MASK, this will make + * sure both pins are initialized as output and set during board initialization. + * This is needed so that the BMX280 and LIS2DH12 device drivers do not + * interfere... */ +#define CS_PIN_MASK ((1 << 3) | (1 << 8)) + #define LED_PORT NRF_P0 #define LED0_MASK (1 << 17) #define LED1_MASK (1 << 19) -#define LED_MASK (LED0_MASK | LED1_MASK) + +/* mask used in the common board.c file to initialize and set the given pins */ +#define LED_MASK (LED0_MASK | LED1_MASK | CS_PIN_MASK) #define LED0_ON (LED_PORT->OUTCLR = LED0_MASK) #define LED0_OFF (LED_PORT->OUTSET = LED0_MASK)