Loading...
Searching...
No Matches
board.h
Go to the documentation of this file.
1/*
2 * Copyright (C) 2024 Marian Buschsieweke
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 "board_common.h"
23#include "periph/gpio.h"
24
25#ifdef __cplusplus
26extern "C" {
27#endif
28
33#define BTN0_PIN GPIO_PIN(PORT_A, 0)
34#define BTN0_MODE GPIO_IN_PU
35#define BTN0_INT_FLANK GPIO_FALLING
42#define LED0_PIN GPIO_PIN(PORT_A, 7)
43#define LED0_MASK (1 << 7)
44#define LED0_ON (GPIOA->BC = LED0_MASK)
45#define LED0_OFF (GPIOA->BOP = LED0_MASK)
46#define LED0_TOGGLE (GPIOA->OCTL ^= LED0_MASK)
49#ifdef __cplusplus
50}
51#endif
52
53#endif /* BOARD_H */
Low-level GPIO peripheral driver interface definitions.