Toggle navigation
Documentation
The friendly Operating System for the Internet of Things
Loading...
Searching...
No Matches
board.h
Go to the documentation of this file.
1
/*
2
* Copyright (C) 2019 Freie Universität Berlin
3
*
4
* This file is subject to the terms and conditions of the GNU Lesser
5
* General Public License v2.1. See the file LICENSE in the top level
6
* directory for more details.
7
*/
8
19
#ifndef BOARD_H
20
#define BOARD_H
21
22
#include "cpu.h"
23
24
#ifdef __cplusplus
25
extern
"C"
{
26
#endif
27
32
#define LED0_PIN GPIO_PIN(0, 11)
33
#define LED1_PIN GPIO_PIN(0, 12)
34
#define LED2_PIN GPIO_PIN(1, 9)
35
#define LED3_PIN GPIO_PIN(0, 13)
36
37
#define LED0_MASK (1 << 11)
38
#define LED1_MASK (1 << 12)
39
#define LED2_MASK (1 << 9)
40
#define LED3_MASK (1 << 13)
41
#define LED_MASK_P0 (LED0_MASK | LED1_MASK | LED3_MASK)
42
#define LED_MASK_P1 (LED2_MASK)
43
44
#define LED0_ON (NRF_P0->OUTCLR = LED0_MASK)
45
#define LED0_OFF (NRF_P0->OUTSET = LED0_MASK)
46
#define LED0_TOGGLE (NRF_P0->OUT ^= LED0_MASK)
47
48
#define LED1_ON (NRF_P0->OUTCLR = LED1_MASK)
49
#define LED1_OFF (NRF_P0->OUTSET = LED1_MASK)
50
#define LED1_TOGGLE (NRF_P0->OUT ^= LED1_MASK)
51
52
#define LED2_ON (NRF_P1->OUTCLR = LED2_MASK)
53
#define LED2_OFF (NRF_P1->OUTSET = LED2_MASK)
54
#define LED2_TOGGLE (NRF_P1->OUT ^= LED2_MASK)
55
56
#define LED3_ON (NRF_P0->OUTCLR = LED3_MASK)
57
#define LED3_OFF (NRF_P0->OUTSET = LED3_MASK)
58
#define LED3_TOGGLE (NRF_P0->OUT ^= LED3_MASK)
65
#define BTN0_PIN GPIO_PIN(0, 7)
66
#define BTN0_MODE GPIO_IN_PU
73
#define SSD1673_SPI SPI_DEV(0)
74
#define SSD1673_CS GPIO_PIN(0, 17)
75
#define SSD1673_BUSY GPIO_PIN(0, 14)
76
#define SSD1673_RESET GPIO_PIN(0, 15)
77
#define SSD1673_DC_INPUT GPIO_PIN(0, 16)
84
#define HDC1010_PARAM_I2C I2C_DEV(0)
85
#define HDC1010_PARAM_ADDR (0x43)
86
#define HDC1010_PIN_DRDY GPIO_PIN(0, 22)
93
#define MMA8X5X_PARAM_I2C I2C_DEV(0)
94
#define MMA8X5X_PARAM_ADDR (0x1d)
95
#define MMA8X5X_PARAM_PIN_INT1 GPIO_PIN(0, 24)
96
#define MMA8X5X_PARAM_PIN_INT2 GPIO_PIN(0, 25)
103
#define ADPS9960_PARAM_I2C I2C_DEV(0)
104
#define ADPS9960_PARAM_ADDR (0x29)
105
#define ADPS9960_PARAM_PIN_INT GPIO_PIN(0, 23)
108
#ifdef __cplusplus
109
}
110
#endif
111
112
#endif
/* BOARD_H */
Generated on Sat Nov 23 2024 19:57:22 by
1.9.8