board.h
Go to the documentation of this file.
1 /*
2  * SPDX-FileCopyrightText: 2024 Marian Buschsieweke
3  * SPDX-License-Identifier: LGPL-2.1-only
4  */
5 
6 #pragma once
7 
18 #include "board_common.h"
19 #include "periph/gpio.h"
20 
21 #ifdef __cplusplus
22 extern "C" {
23 #endif
24 
29 #define BTN0_PIN GPIO_PIN(PORT_A, 0)
30 #define BTN0_MODE GPIO_IN_PU
31 #define BTN0_INT_FLANK GPIO_FALLING
38 #define LED0_PIN GPIO_PIN(PORT_A, 7)
39 #define LED0_MASK (1 << 7)
40 #define LED0_ON (GPIOA->BC = LED0_MASK)
41 #define LED0_OFF (GPIOA->BOP = LED0_MASK)
42 #define LED0_TOGGLE (GPIOA->OCTL ^= LED0_MASK)
45 #ifdef __cplusplus
46 }
47 #endif
48 
Low-level GPIO peripheral driver interface definitions.