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
* SPDX-FileCopyrightText: 2023 Gunar Schorcht
3
* SPDX-FileCopyrightText: 2026 Technische Universität Hamburg
4
* SPDX-License-Identifier: LGPL-2.1-only
5
*/
6
7
#pragma once
8
21
26
35
#define BTN0_PIN GPIO0
36
38
#define BTN0_MODE GPIO_IN_PU
39
41
#ifndef BTN0_INT_FLANK
42
# define BTN0_INT_FLANK GPIO_FALLING
43
#endif
44
46
#define BUTTON0_PIN BTN0_PIN
47
54
#define BTN1_PIN GPIO41
55
57
#define BTN1_MODE GPIO_IN_PU
58
60
#ifndef BTN1_INT_FLANK
61
# define BTN1_INT_FLANK GPIO_FALLING
62
#endif
63
65
#define BUTTON1_PIN BTN1_PIN
67
76
#if MODULE_GC9A01
77
# define LCD_DC GPIO3
78
# define LCD_CS GPIO9
79
# define LCD_RST GPIO14
80
# define LCD_BACKLIGHT GPIO46
81
82
# define GC9A01_PARAM_CS LCD_CS
83
# define GC9A01_PARAM_DCX LCD_DC
84
# define GC9A01_PARAM_RST LCD_RST
85
# define GC9A01_PARAM_NUM_LINES 240
86
# define GC9A01_PARAM_RGB_CHANNELS 240
87
# define GC9A01_PARAM_INVERTED 1
88
# define GC9A01_PARAM_RGB 0
89
# ifndef GC9A01_PARAM_ROTATION
90
# define GC9A01_PARAM_ROTATION GC9A01_ROTATION_VERT
91
# endif
92
# ifndef GC9A01_PARAM_SPI_CLK
93
# define GC9A01_PARAM_SPI_CLK SPI_CLK_1MHZ
94
# endif
95
96
# define BACKLIGHT_ON gpio_set(LCD_BACKLIGHT)
97
# define BACKLIGHT_OFF gpio_clear(LCD_BACKLIGHT)
98
#endif
100
110
#if MODULE_CST816S
111
# define CST816S_PARAM_I2C_DEV I2C_DEV(0)
112
# define CST816S_PARAM_IRQ GPIO5
113
# define CST816S_PARAM_RESET GPIO13
114
#endif
116
127
#define POWER_LCD_3V3_PIN GPIO1
129
#define POWER_EXTERNAL_5V_PIN GPIO2
131
137
#define WS281X_PARAM_PIN GPIO48
139
#define WS281X_PARAM_NUMOF (5U)
141
147
#define LED0_PIN GPIO40
148
#define LED0_ACTIVE (0)
150
151
/* include common board definitions as last step */
152
#include "board_common.h"
153
154
#ifdef __cplusplus
155
extern
"C"
{
156
#endif
157
158
#ifdef __cplusplus
159
}
160
#endif
161
Generated on Tue Jun 23 2026 15:19:58 by
1.13.2