42 lines
1.6 KiB
C
42 lines
1.6 KiB
C
#pragma once
|
||
|
||
#define BOARD_NAME "esp32-32e"
|
||
|
||
// ══════════════════════════════════════════════════════════
|
||
// TODO: Set these to match YOUR display + wiring.
|
||
// Defaults below are for a common ILI9341 320×240 SPI TFT.
|
||
// The actual pin mapping must also be set in tft_user_setup.h
|
||
// (which gets copied into the vendored TFT_eSPI library).
|
||
// ══════════════════════════════════════════════════════════
|
||
|
||
#define DISPLAY_WIDTH 320
|
||
#define DISPLAY_HEIGHT 240
|
||
#define DISPLAY_ROTATION 1 // landscape
|
||
|
||
// Backlight GPIO (directly wired)
|
||
#define PIN_LCD_BL 22
|
||
|
||
// Touch — if using XPT2046 via TFT_eSPI, set TOUCH_CS in tft_user_setup.h
|
||
// If using capacitive touch (e.g. FT6236), configure I2C pins here:
|
||
// #define TOUCH_SDA 21
|
||
// #define TOUCH_SCL 22
|
||
|
||
// ── Style Constants (CSS-like) ────────────────────────────────────────
|
||
// Spacing - scaled for 320x240
|
||
#define STYLE_SPACING_X 4
|
||
#define STYLE_SPACING_Y 4
|
||
#define STYLE_HEADER_HEIGHT 20
|
||
#define STYLE_TILE_GAP 4
|
||
#define STYLE_TILE_PADDING 6
|
||
#define STYLE_TILE_RADIUS 4
|
||
|
||
// Colors
|
||
#define STYLE_COLOR_BG TFT_BLACK
|
||
#define STYLE_COLOR_HEADER 0x1A1A
|
||
#define STYLE_COLOR_FG TFT_WHITE
|
||
#define STYLE_COLOR_ALERT TFT_RED
|
||
#define STYLE_COLOR_TILE_1 0x0280
|
||
#define STYLE_COLOR_TILE_2 0x0400
|
||
#define STYLE_COLOR_TILE_3 0x0440
|
||
#define STYLE_COLOR_TILE_4 0x0100
|