board.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 2020 Freie Universität Berlin
3  * Copyright (C) 2023 HAW Hamburg
4  *
5  * This file is subject to the terms and conditions of the GNU Lesser
6  * General Public License v2.1. See the file LICENSE in the top level
7  * directory for more details.
8  */
9 
22 #ifndef BOARD_H
23 #define BOARD_H
24 
25 #include "cpu.h"
26 #include "board_common.h"
27 #include "periph/gpio.h"
28 
29 #ifdef __cplusplus
30 extern "C" {
31 #endif
32 
37 #define LED0_PIN GPIO_PIN(1, 9)
38 #define LED1_PIN GPIO_PIN(1, 10)
39 
40 #define LED_PORT (NRF_P1)
41 #define LED0_MASK (1 << 9)
42 #define LED1_MASK (1 << 10)
43 #define LED_MASK (LED0_MASK | LED1_MASK)
44 
45 #define LED0_ON (LED_PORT->OUTSET = LED0_MASK)
46 #define LED0_OFF (LED_PORT->OUTCLR = LED0_MASK)
47 #define LED0_TOGGLE (LED_PORT->OUT ^= LED0_MASK)
48 
49 #define LED1_ON (LED_PORT->OUTSET = LED1_MASK)
50 #define LED1_OFF (LED_PORT->OUTCLR = LED1_MASK)
51 #define LED1_TOGGLE (LED_PORT->OUT ^= LED1_MASK)
58 #define BTN0_PIN GPIO_PIN(1, 2)
59 #define BTN0_MODE GPIO_IN_PU
66 #define BMX280_PARAM_I2C_DEV I2C_DEV(0)
73 #define LIS3MDL_PARAM_I2C I2C_DEV(0)
74 #define LIS3MDL_PARAM_ADDR (0x1C)
81 #define SHT3X_PARAM_I2C_DEV I2C_DEV(0)
82 #define SHT3X_PARAM_I2C_ADDR (SHT3X_I2C_ADDR_1)
89 #define LSM6DSXX_PARAM_I2C I2C_DEV(0)
90 #define LSM6DSXX_PARAM_ADDR (0x6A)
97 #ifndef WS281X_PARAM_PIN
98 #define WS281X_PARAM_PIN GPIO_PIN(0, 16)
99 #endif
100 #ifndef WS281X_PARAM_NUMOF
101 #define WS281X_PARAM_NUMOF (1U)
102 #endif
105 #ifdef __cplusplus
106 }
107 #endif
108 
109 #endif /* BOARD_H */
Low-level GPIO peripheral driver interface definitions.