Loading...
Searching...
No Matches
board.h
Go to the documentation of this file.
1/*
2 * SPDX-FileCopyrightText: 2017 HAW Hamburg
3 * SPDX-License-Identifier: LGPL-2.1-only
4 */
5
6#pragma once
7
20
21#include "cpu.h"
22
23#ifdef __cplusplus
24extern "C" {
25#endif
26
31#define LED0_PIN GPIO_PIN(0, 26)
32
33#define LED_PORT (NRF_P0)
34#define LED0_MASK (1 << 26)
35
36#define LED0_ON (LED_PORT->OUTCLR = LED0_MASK)
37#define LED0_OFF (LED_PORT->OUTSET = LED0_MASK)
38#define LED0_TOGGLE (LED_PORT->OUT ^= LED0_MASK)
40
45#define BTN0_PIN GPIO_PIN(0, 25)
46#define BTN0_MODE GPIO_IN_PU
48
49#ifdef __cplusplus
50}
51#endif
52