@geastack/targets 0.1.107 → 0.1.109

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/build-config.json +120 -1
  2. package/package.json +6 -6
  3. package/targets/esp32/chip_bindings/audio/ns4168.cpp +326 -0
  4. package/targets/esp32/chip_bindings/displays/rgb_panel.cpp +2485 -105
  5. package/targets/esp32/chip_bindings/displays/sh8601.cpp +12 -2
  6. package/targets/esp32/chip_bindings/expanders/elecrow_board_control.cpp +169 -0
  7. package/targets/esp32/chip_bindings/expanders/io_expander.h +4 -0
  8. package/targets/esp32/chip_bindings/imu/qmi8658.cpp +10 -3
  9. package/targets/esp32/chip_bindings/power/axp2101.cpp +58 -0
  10. package/targets/esp32/chip_bindings/rtc/bm8563.cpp +129 -0
  11. package/targets/esp32/chip_bindings/touch/cst9217.cpp +26 -23
  12. package/targets/esp32/connectivity/wifi.cpp +30 -2
  13. package/targets/esp32/gea_board_buttons.cmake +13 -0
  14. package/targets/esp32/gpio.cpp +124 -1
  15. package/targets/esp32/gpio_pins.h +17 -0
  16. package/targets/esp32/services/buttons.cpp +185 -0
  17. package/targets/esp32/services/buttons.h +46 -0
  18. package/targets/esp32/services/device_control.cpp +98 -6
  19. package/targets/esp32/services/heap.cpp +25 -1
  20. package/targets/esp32-s3-elecrow-crowpanel-advance-7.0.json +182 -0
  21. package/targets/esp32-s3-touch-amoled-1.75c/CMakeLists.txt +11 -0
  22. package/targets/esp32-s3-touch-amoled-1.75c/main/CMakeLists.txt +54 -0
  23. package/targets/esp32-s3-touch-amoled-1.75c/main/Kconfig.projbuild +12 -0
  24. package/targets/esp32-s3-touch-amoled-1.75c/main/gea-dependencies.json +42 -0
  25. package/targets/esp32-s3-touch-amoled-1.75c/main/idf_component.yml +10 -0
  26. package/targets/esp32-s3-touch-amoled-1.75c/main/include/board.h +113 -0
  27. package/targets/esp32-s3-touch-amoled-1.75c/partitions.csv +9 -0
  28. package/targets/esp32-s3-touch-amoled-1.75c/sdkconfig.defaults +279 -0
  29. package/targets/esp32-s3-touch-amoled-1.8/main/CMakeLists.txt +13 -1
  30. package/targets/esp32-s3-touch-amoled-1.8/main/app_main.cpp +2 -0
  31. package/targets/esp32-s3-touch-amoled-2.06/main/CMakeLists.txt +44 -2
  32. package/targets/esp32-s3-touch-amoled-2.06/main/app_main.cpp +13 -0
  33. package/targets/esp32-s3-touch-amoled-2.06/main/sdcard_mount.cpp +56 -0
  34. package/targets/esp32-s3-touch-amoled-2.06/sdkconfig.defaults +5 -3
  35. package/targets/esp32-s3-touch-lcd-3.49/CMakeLists.txt +11 -0
  36. package/targets/esp32-s3-touch-lcd-3.49/main/CMakeLists.txt +82 -0
  37. package/targets/esp32-s3-touch-lcd-3.49/main/Kconfig.projbuild +12 -0
  38. package/targets/esp32-s3-touch-lcd-3.49/main/gea-dependencies.json +42 -0
  39. package/targets/esp32-s3-touch-lcd-3.49/main/idf_component.yml +8 -0
  40. package/targets/esp32-s3-touch-lcd-3.49/main/include/axs15231b_panel_init.h +9 -0
  41. package/targets/esp32-s3-touch-lcd-3.49/main/include/board.h +160 -0
  42. package/targets/esp32-s3-touch-lcd-3.49/main/panel_reset.cpp +93 -0
  43. package/targets/esp32-s3-touch-lcd-3.49/main/power.cpp +60 -0
  44. package/targets/esp32-s3-touch-lcd-3.49/main/touch.cpp +327 -0
  45. package/targets/esp32-s3-touch-lcd-3.49/partitions.csv +7 -0
  46. package/targets/esp32-s3-touch-lcd-3.49/sdkconfig.defaults +279 -0
  47. package/targets.json +70 -1
@@ -0,0 +1,182 @@
1
+ {
2
+ "id": "esp32-s3-elecrow-crowpanel-advance-7.0",
3
+ "extends": "esp32-s3",
4
+ "adapter": "esp32-idf",
5
+ "mcu": "esp32s3",
6
+ "_comment": "Elecrow CrowPanel Advance 7.0-HMI (SKU DIS02170A): an ESP32-S3-WROOM-1-N16R8 (16MB quad flash, 8MB octal PSRAM) behind a 7-inch 800x480 IPS parallel RGB panel with a GT911 capacitive touch controller. One firmware serves every board revision: the slow control lines sit behind a PCA9557 on V1.0-V1.2 and an STC8H1K28 board-control MCU on V1.3+, and the binding probes which at boot. Sources: Elecrow's V1.0-V1.5 schematics and V1.5 driver guide (Elecrow-RD/CrowPanel-Advance-7-HMI-ESP32-S3-AI-Powered-IPS-Touch-Screen-800x480) and the factory firmware.",
7
+ "flashSize": "16MB",
8
+ "_flashMode": "The WROOM-1 module routes all four flash data lines, and QIO measured about 2.5 fps faster than DIO on the svg-charts demo.",
9
+ "flashMode": "qio",
10
+ "_console": "The USB-C port goes through a CH340K USB-UART bridge to UART0 (TXD0/RXD0), with the usual DTR/RTS auto-download circuit. The native USB-Serial/JTAG pins are not brought out.",
11
+ "console": {
12
+ "transport": "uart",
13
+ "uart": 0,
14
+ "baud": 115200
15
+ },
16
+ "_psram": "N16R8 is 8MB octal PSRAM; the RGB framebuffer (800x480x2 = 768KB) lives there. 80MHz by default. An app can raise it to 120MHz (ESP-IDF's experimental octal mode) with gea.targets.esp32.psram.speed, plus flashFreq 40 because the two share the MSPI clock: every framebuffer write and every instruction-cache miss (code runs from PSRAM) speeds up -- Neon Drift goes from about 40 to about 50 fps -- but ESP-IDF's live re-tuning from the temperature sensor refuses this module's flash, so the timing is the one tuned at power-up.",
17
+ "_psramXip": "Code and rodata run from PSRAM: flash and PSRAM share the MSPI bus, so instruction-cache misses from flash (cold code on every touch) held off the RGB scanout's PSRAM reads and the image drifted.",
18
+ "psram": {
19
+ "mode": "octal",
20
+ "speed": 80,
21
+ "xip": true
22
+ },
23
+ "_buses": "One I2C bus on GPIO15/16 carries the GT911 (0x5d), the PCA9557 expander (0x18) and the BM8563 RTC (0x51), and is also brought out on the HY2.0 I2C connector.",
24
+ "buses": {
25
+ "i2c": {
26
+ "sda": 15,
27
+ "scl": 16
28
+ }
29
+ },
30
+ "chips": {
31
+ "display": {
32
+ "driver": "rgb_panel",
33
+ "interface": "rgb",
34
+ "width": 800,
35
+ "height": 480,
36
+ "_timing": "Elecrow's current examples drive the panel at 18MHz (their maintenance baseline; older code used 16 and 21) with 8/4/8 porches on both axes, PCLK idle high. Gea runs it at 15MHz (36.6Hz): scanout reads the framebuffer out of PSRAM continuously, and at 18MHz a repaint's PSRAM traffic on top of it starved the bounce-buffer refills -- the picture tore on every touch and scroll.",
37
+ "pclkHz": 15000000,
38
+ "_restartInVsync": "No driver restart at every VSYNC: it runs in the VSYNC interrupt, which waits out a bounce refill in progress, and under scroll load a late one landed inside the next frame and shifted it sideways (the screen shook while scrolling). rgb_panel.cpp restarts the DMA itself, only at a VSYNC that finds it still parked in the blanking, so a slip is realigned on the next on-time frame.",
39
+ "restartInVsync": false,
40
+ "hsyncPulseWidth": 4,
41
+ "hsyncBackPorch": 8,
42
+ "hsyncFrontPorch": 8,
43
+ "vsyncPulseWidth": 4,
44
+ "vsyncBackPorch": 8,
45
+ "vsyncFrontPorch": 8,
46
+ "pclkActiveNeg": true,
47
+ "_scanFramebuffers": "Two scanout buffers, not three: code and rodata run from PSRAM (see _psramXip), which leaves about 4.3MB of heap, and the third 768KB buffer is what the factory demo's full-screen menu backdrop needs.",
48
+ "scanFramebuffers": 2,
49
+ "_bounceRows": "24-row bounce buffers, not the default 30: a refill's time and its window both scale with the rows, so the overrun margin is the same, and the 19KB this frees lets the SRAM staging strip grow from 8 to 16 rows. Large repaints (a tab switch, a page's first scroll) raster through that strip so their PSRAM writes cannot starve the refill, and every strip re-walks the display list, so its height sets their cost.",
50
+ "bounceRows": 24,
51
+ "_pins": "data0-4 = B3-B7, data5-10 = G2-G7, data11-15 = R3-R7 (the panel's low bits are tied off). The backlight is board-control line 1; the panel's RESET is an RC network, not a GPIO.",
52
+ "pins": {
53
+ "de": 42,
54
+ "hsync": 40,
55
+ "vsync": 41,
56
+ "pclk": 39,
57
+ "data0": 21,
58
+ "data1": 47,
59
+ "data2": 48,
60
+ "data3": 45,
61
+ "data4": 38,
62
+ "data5": 9,
63
+ "data6": 10,
64
+ "data7": 11,
65
+ "data8": 12,
66
+ "data9": 13,
67
+ "data10": 14,
68
+ "data11": 7,
69
+ "data12": 17,
70
+ "data13": 18,
71
+ "data14": 3,
72
+ "data15": 46
73
+ }
74
+ },
75
+ "touch": {
76
+ "driver": "gt911",
77
+ "interface": "i2c",
78
+ "_pins": "Reset is board-control line 2 (PCA9557 IO2 on V1.0, the STC's touch-recover command 250 on V1.3+). The schematic routes the GT911's INT to GPIO1, but no edge ever reaches it on a V1.3+ board, so touch is polled, as Elecrow's own firmware does (LovyanGFX pin_int = -1). Without INT the binding cannot pin the address across reset and probes both 0x5d and 0x14.",
79
+ "pins": {}
80
+ },
81
+ "audio": {
82
+ "driver": "ns4168",
83
+ "interface": "i2s",
84
+ "_pins": "Speaker: NS4168 on IO5 BCLK, IO6 LRCLK, IO4 SDIN. Microphone: an INMP441 (I2S: IO19 SCK, IO2 WS, IO20 SD) on V1.0, a PDM part (IO19 CLK, IO20 DATA) on V1.3+; 'auto' picks by the board controller found at boot. IO4-IO6 are shared with the microSD slot and the wireless socket, IO19/IO20 with the socket too; the function-select DIP switch picks which one they reach.",
85
+ "pins": {
86
+ "bclk": 5,
87
+ "ws": 6,
88
+ "dout": 4,
89
+ "micBclk": 19,
90
+ "micWs": 2,
91
+ "micDin": 20
92
+ },
93
+ "_expander": "Amplifier shutdown is board-control line 4 and mute line 3 (high = off). On V1.0 they are PCA9557 IO4/IO3; on V1.3+ pulling shutdown low sends the STC's speaker-enable command 248, and there is no documented command for mute or for turning the amplifier off.",
94
+ "expander": {
95
+ "shutdown": 4,
96
+ "mute": 3
97
+ },
98
+ "microphone": "auto"
99
+ },
100
+ "rtc": {
101
+ "driver": "bm8563",
102
+ "interface": "i2c",
103
+ "_battery": "A BM8563 (PCF8563-compatible; a PCF8563 on V1.5) at 0x51, backed by a CR1220 cell, so the system clock is restored from it at boot."
104
+ },
105
+ "expander": {
106
+ "driver": "elecrow_board_control",
107
+ "interface": "i2c",
108
+ "address": 24,
109
+ "_outputs": "Lines use PCA9557 numbering: 1 backlight, 2 touch reset, 3 amplifier mute, 4 amplifier shutdown. On an STC board each maps to its command (backlight 0-245 with brightness, 250 touch recovery, 248 speaker on). initialOutputs 0x14 / initialDirections 0xe1 apply to the PCA9557: touch out of reset, mute low, shutdown high, backlight off until the panel scans.",
110
+ "initialDirections": 225,
111
+ "initialOutputs": 20,
112
+ "outputs": {
113
+ "backlight": 1,
114
+ "touchReset": 2
115
+ }
116
+ }
117
+ },
118
+ "_storage": "The TF slot is wired for SPI (IO5 SCK, IO6 MOSI, IO4 MISO) with its chip select tied active by a resistor, so it has no CS GPIO and cannot run SD_MMC. It shares IO4-IO6 with the speaker; the function-select DIP switch must be on the SD position for the card to answer.",
119
+ "storage": {
120
+ "microSD": {
121
+ "interface": "spi",
122
+ "pins": {
123
+ "sck": 5,
124
+ "mosi": 6,
125
+ "miso": 4
126
+ }
127
+ }
128
+ },
129
+ "_pinSharing": "The function-select DIP switch routes IO4-IO6 to the speaker or the TF slot (or the wireless socket), never both, so the speaker and the card may name the same GPIOs.",
130
+ "pinSharing": [
131
+ [
132
+ "audio",
133
+ "microSD"
134
+ ]
135
+ ],
136
+ "_buzzer": "The passive buzzer is on GPIO8 on V1.0 but driven by the STC (P2.7) on V1.3+, where Elecrow documents no command for it, so the target does not drive it.",
137
+ "_controls": "BOOT is GPIO0, which is free once the board has booted (the wireless-module socket also uses it as BUSY, only when a module is fitted).",
138
+ "controls": {
139
+ "launcherButton": {
140
+ "pin": 0,
141
+ "activeLevel": 0
142
+ }
143
+ },
144
+ "partitions": {
145
+ "nvs": {
146
+ "type": "data",
147
+ "subtype": "nvs",
148
+ "offset": "0x9000",
149
+ "size": "0x6000"
150
+ },
151
+ "otadata": {
152
+ "type": "data",
153
+ "subtype": "ota",
154
+ "offset": "0xf000",
155
+ "size": "0x2000"
156
+ },
157
+ "phy_init": {
158
+ "type": "data",
159
+ "subtype": "phy",
160
+ "offset": "0x11000",
161
+ "size": "0x1000"
162
+ },
163
+ "ota_0": {
164
+ "type": "app",
165
+ "subtype": "ota_0",
166
+ "offset": "0x20000",
167
+ "size": "0x600000"
168
+ },
169
+ "ota_1": {
170
+ "type": "app",
171
+ "subtype": "ota_1",
172
+ "offset": "0x620000",
173
+ "size": "0x600000"
174
+ },
175
+ "storage": {
176
+ "type": "data",
177
+ "subtype": "spiffs",
178
+ "offset": "0xC20000",
179
+ "size": "0x3E0000"
180
+ }
181
+ }
182
+ }
@@ -0,0 +1,11 @@
1
+ cmake_minimum_required(VERSION 3.16)
2
+
3
+ set(EXTRA_COMPONENT_DIRS "${CMAKE_CURRENT_LIST_DIR}/../esp32/components")
4
+ include("${CMAKE_CURRENT_LIST_DIR}/../esp32/app_project.cmake")
5
+ set(GEA_EMBEDDED_APP "tic-tac-toe" CACHE STRING "Example app to build (must match a package.json gea.id)")
6
+ set(PROJECT_VER "${GEA_EMBEDDED_APP}" CACHE STRING "Firmware app id" FORCE)
7
+
8
+ include($ENV{IDF_PATH}/tools/cmake/project.cmake)
9
+ idf_build_set_property(MINIMAL_BUILD ON)
10
+ gea_solve_dependencies_in_build_dir()
11
+ project(gea_embedded)
@@ -0,0 +1,54 @@
1
+ set(GEA_BOARD_COMPONENT_DIR "${CMAKE_CURRENT_LIST_DIR}")
2
+ set(GEA_BOARD_TARGET_DIR "${CMAKE_CURRENT_LIST_DIR}/..")
3
+ set(GEA_EMBEDDED_CPP_BOARD "esp32-s3-touch-amoled-1.75c")
4
+ set(GEA_EMBEDDED_CSS_DEVICE_PIXEL_RATIO "1.5" CACHE STRING "Logical CSS px to physical pixel scale for this board")
5
+ set(GEA_EMBEDDED_ROOT "${CMAKE_CURRENT_LIST_DIR}/../../..")
6
+ cmake_path(ABSOLUTE_PATH GEA_EMBEDDED_ROOT NORMALIZE)
7
+ include("${GEA_EMBEDDED_ROOT}/targets/esp32/gea_framework.cmake")
8
+
9
+ # The 1.75's CO5300 glass: 466x466 visible, six columns in, on the 1.75's
10
+ # measured 80 MHz QSPI clock and its vendor init sequence.
11
+ set(GEA_BOARD_DISPLAY_WIDTH 466)
12
+ set(GEA_BOARD_DISPLAY_HEIGHT 466)
13
+ set(GEA_BOARD_QSPI_PCLK_HZ 80000000)
14
+ set(GEA_BOARD_FRAMEBUFFER_STREAM_FLUSH 1)
15
+ set(GEA_BOARD_PARTIAL_PAD_X 0)
16
+ set(GEA_BOARD_PARTIAL_PAD_Y 0)
17
+ set(GEA_BOARD_EXTRA_REQUIRES esp_codec_dev)
18
+ set(GEA_BOARD_EXTRA_COMPILE_DEFINITIONS
19
+ GEA_BOARD_HAS_SPEAKER=1
20
+ GEA_EMBEDDED_CO5300_WAVESHARE_175_INIT=1
21
+ GEA_EMBEDDED_CO5300_PANEL_X_GAP=6
22
+ GEA_EMBEDDED_CO5300_PANEL_Y_GAP=0
23
+ # The flush pipeline otherwise takes every internal DMA byte left at boot
24
+ # (20 rows x 2), which starves the audio task stack and WiFi. 12 rows
25
+ # leaves ~25 KB internal free.
26
+ GEA_EMBEDDED_DISPLAY_FLUSH_CHUNK_MAX=12
27
+ # Run the runtime on a PSRAM-stacked task and let app_main return, which
28
+ # hands the 32 KB internal main stack back to the heap (BLE, WiFi and the
29
+ # audio task all need internal RAM). Same split as the m5stack stopwatch.
30
+ GEA_EMBEDDED_RUNTIME_TASK_STACK_BYTES=32768
31
+ GEA_EMBEDDED_RUNTIME_TASK_STACK_EXTERNAL=1
32
+ # App native code reads the board name from this string.
33
+ GEA_EMBEDDED_BOARD_ID="${GEA_EMBEDDED_CPP_BOARD}"
34
+ # The QMI8658 reads mirrored along the screen's horizontal axis here.
35
+ GEA_EMBEDDED_IMU_INVERT_X=1
36
+ )
37
+
38
+ set(GEA_BOARD_PLATFORM_SOURCES
39
+ "${CMAKE_CURRENT_LIST_DIR}/../../esp32-s3-touch-amoled-1.8/main/app_main.cpp"
40
+ "${CMAKE_CURRENT_LIST_DIR}/../../esp32-s3-touch-amoled-1.8/main/i2c.cpp"
41
+ "${CMAKE_CURRENT_LIST_DIR}/../../esp32-s3-touch-amoled-1.8/main/launcher_button.cpp"
42
+ # CST9217 glue, shared with the 1.75.
43
+ "${CMAKE_CURRENT_LIST_DIR}/../../esp32-s3-touch-amoled-1.75/main/touch.cpp"
44
+ "${GEA_CHIPS}/displays/co5300/co5300.cpp"
45
+ "${GEA_CHIPS}/power/axp2101/axp2101.cpp"
46
+ "${GEA_CHIPS}/imu/qmi8658/qmi8658.cpp"
47
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/display.cpp"
48
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/chip_bindings/displays/co5300.cpp"
49
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/chip_bindings/power/axp2101.cpp"
50
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/chip_bindings/touch/cst9217.cpp"
51
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/chip_bindings/imu/qmi8658.cpp"
52
+ "${GEA_EMBEDDED_ROOT}/targets/esp32/chip_bindings/audio/es8311.cpp"
53
+ )
54
+ include("${CMAKE_CURRENT_LIST_DIR}/../../esp32-s3-touch-amoled-1.8/main/CMakeLists.txt")
@@ -0,0 +1,12 @@
1
+ menu "Gea Embedded"
2
+
3
+ config GEA_EMBEDDED_PRODUCTION_LOCKDOWN
4
+ bool "Production lockdown"
5
+ default n
6
+ help
7
+ Compile out Gea frame/perf logs, heap diagnostics, and the
8
+ diagnostics server for production firmware. Local development builds
9
+ should leave this disabled so serial monitor and VS Code launch
10
+ tasks show fps and diagnostic logs.
11
+
12
+ endmenu
@@ -0,0 +1,42 @@
1
+ {
2
+ "espressif/esp_h264": {
3
+ "when": [
4
+ "network"
5
+ ],
6
+ "dependency": {
7
+ "version": "==1.4.1"
8
+ }
9
+ },
10
+ "78/esp-opus": {
11
+ "when": [
12
+ "network"
13
+ ],
14
+ "dependency": {
15
+ "version": "==1.0.5"
16
+ }
17
+ },
18
+ "espressif/esp_websocket_client": {
19
+ "when": [
20
+ "network"
21
+ ],
22
+ "dependency": {
23
+ "version": "==1.8.0"
24
+ }
25
+ },
26
+ "espressif/esp_peer": {
27
+ "when": [
28
+ "network"
29
+ ],
30
+ "dependency": {
31
+ "version": "==1.5.6"
32
+ }
33
+ },
34
+ "espressif/esp-sr": {
35
+ "when": [
36
+ "aec"
37
+ ],
38
+ "dependency": {
39
+ "version": "==2.5.5"
40
+ }
41
+ }
42
+ }
@@ -0,0 +1,10 @@
1
+ # Always-required SDK dependencies. Optional SDKs are selected from
2
+ # gea-dependencies.json by the CLI capability analyzer.
3
+ dependencies:
4
+ espressif/esp_lcd_co5300: '==2.2.0'
5
+ waveshare/esp_lcd_touch_cst9217: '==1.0.4'
6
+ esp_lcd_panel_io_additions: '^1'
7
+ # chip_bindings/audio/es8311.cpp
8
+ espressif/esp_codec_dev: '==1.6.2'
9
+ idf:
10
+ version: '>=5.3'
@@ -0,0 +1,113 @@
1
+ #pragma once
2
+
3
+ #include "driver/gpio.h"
4
+ #include "driver/spi_master.h"
5
+
6
+ // Waveshare ESP32-S3-Touch-AMOLED-1.75C: the 1.75's 466x466 CO5300 AMOLED with
7
+ // a CST9217 touch layer, on a 32 MB board without the GPS module. Pin
8
+ // assignments: Waveshare's BSP (Waveshare-ESP32-components,
9
+ // bsp/esp32_s3_touch_amoled_1_75c/include/bsp/esp32_s3_touch_amoled_1_75c.h).
10
+ //
11
+ // It is not the 1.75 rewired with fewer parts: the panel and touch resets moved
12
+ // to GPIO1/GPIO2 (the 1.75's TF-card pins -- this board has no card slot) and
13
+ // the codec master clock to GPIO16.
14
+ namespace gea::platform::board {
15
+
16
+ struct I2cBusConfig {
17
+ gpio_num_t sda;
18
+ gpio_num_t scl;
19
+ };
20
+
21
+ struct Co5300DisplayConfig {
22
+ spi_host_device_t spiHost;
23
+ gpio_num_t cs;
24
+ gpio_num_t pclk;
25
+ gpio_num_t data0;
26
+ gpio_num_t data1;
27
+ gpio_num_t data2;
28
+ gpio_num_t data3;
29
+ gpio_num_t reset;
30
+ gpio_num_t te;
31
+ };
32
+
33
+ struct Cst9217TouchConfig {
34
+ gpio_num_t reset;
35
+ gpio_num_t interrupt;
36
+ bool swapXy;
37
+ bool mirrorX;
38
+ bool mirrorY;
39
+ };
40
+
41
+ struct Es8311AudioConfig {
42
+ int i2sPort;
43
+ gpio_num_t mclk;
44
+ gpio_num_t bclk;
45
+ gpio_num_t ws;
46
+ gpio_num_t dout;
47
+ gpio_num_t din;
48
+ gpio_num_t powerAmplifier;
49
+ // The two microphones are on an ES7210 ADC (I2C 0x40) sharing the I2S
50
+ // bus; the ES8311's own input is not wired to a microphone.
51
+ int es7210Address;
52
+ };
53
+
54
+ struct LauncherButtonConfig {
55
+ gpio_num_t pin;
56
+ int activeLevel;
57
+ };
58
+
59
+ class Esp32S3TouchAmoled175C {
60
+ public:
61
+ // Touch, AXP2101, QMI8658, PCF85063, ES8311 and ES7210 share one bus.
62
+ static constexpr I2cBusConfig i2c{
63
+ .sda = GPIO_NUM_15,
64
+ .scl = GPIO_NUM_14,
65
+ };
66
+
67
+ static constexpr Co5300DisplayConfig display{
68
+ .spiHost = SPI2_HOST,
69
+ .cs = GPIO_NUM_12,
70
+ .pclk = GPIO_NUM_38,
71
+ .data0 = GPIO_NUM_4,
72
+ .data1 = GPIO_NUM_5,
73
+ .data2 = GPIO_NUM_6,
74
+ .data3 = GPIO_NUM_7,
75
+ .reset = GPIO_NUM_1,
76
+ .te = GPIO_NUM_NC,
77
+ };
78
+
79
+ // Orientation from the vendor BSP (waveshare/esp32_s3_touch_amoled_1_75c
80
+ // 3.0.0, bsp_display_new_with_handles): no swap, both axes mirrored.
81
+ static constexpr Cst9217TouchConfig touch{
82
+ .reset = GPIO_NUM_2,
83
+ .interrupt = GPIO_NUM_11,
84
+ .swapXy = false,
85
+ .mirrorX = true,
86
+ .mirrorY = true,
87
+ };
88
+
89
+ static constexpr Es8311AudioConfig audio{
90
+ // I2S_NUM_AUTO, spelled as its value; see the AMOLED 2.06 board.h.
91
+ .i2sPort = -1,
92
+ .mclk = GPIO_NUM_16,
93
+ .bclk = GPIO_NUM_9,
94
+ .ws = GPIO_NUM_45,
95
+ .dout = GPIO_NUM_8,
96
+ .din = GPIO_NUM_10,
97
+ .powerAmplifier = GPIO_NUM_46,
98
+ .es7210Address = 0x40,
99
+ };
100
+ };
101
+
102
+ using Board = Esp32S3TouchAmoled175C;
103
+
104
+ inline constexpr auto i2c = Board::i2c;
105
+ inline constexpr auto display = Board::display;
106
+ inline constexpr auto touch = Board::touch;
107
+ inline constexpr auto audio = Board::audio;
108
+ inline constexpr LauncherButtonConfig launcherButton{
109
+ .pin = GPIO_NUM_0,
110
+ .activeLevel = 0,
111
+ };
112
+
113
+ } // namespace gea::platform::board
@@ -0,0 +1,9 @@
1
+ # Waveshare ESP32-S3-Touch-AMOLED-1.75C, 32 MB flash: two 8 MB OTA slots and a
2
+ # SPIFFS `storage` partition for persistent app data.
3
+ # Name, Type, SubType, Offset, Size
4
+ nvs, data, nvs, 0x9000, 0x6000
5
+ otadata, data, ota, 0xf000, 0x2000
6
+ phy_init, data, phy, 0x11000, 0x1000
7
+ ota_0, app, ota_0, 0x20000, 0x800000
8
+ ota_1, app, ota_1, 0x820000, 0x800000
9
+ storage, data, spiffs, 0x1020000, 0xFE0000