@geastack/targets 0.1.100 → 0.1.101
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.
- package/package.json +7 -7
- package/targets/cmake/geatsc-generated-archive-build.mjs +32 -1
- package/targets/esp32/app_project.cmake +2 -2
- package/targets/esp32/chip_bindings/audio/echo_cancellation.cpp +392 -28
- package/targets/esp32/chip_bindings/audio/echo_cancellation.h +18 -2
- package/targets/esp32/chip_bindings/audio/es8311.cpp +117 -13
- package/targets/esp32/chip_bindings/displays/co5300.cpp +68 -28
- package/targets/esp32/components/gea_framework/CMakeLists.txt +17 -1
- package/targets/esp32/components/gea_framework/idf_component.yml +4 -0
- package/targets/esp32/components/gea_vpx/CMakeLists.txt +1 -1
- package/targets/esp32/connectivity/wifi.cpp +800 -543
- package/targets/esp32/display.cpp +121 -26
- package/targets/esp32/gea_framework.cmake +22 -28
- package/targets/esp32/host_sources.cmake +1 -0
- package/targets/esp32/services/comparison_benchmark.h +137 -0
- package/targets/esp32/services/comparison_gesture.h +133 -0
- package/targets/esp32/services/comparison_input_trace.h +64 -0
- package/targets/esp32/services/comparison_upload_capture.h +125 -0
- package/targets/esp32/services/debugger.h +634 -0
- package/targets/esp32/services/device_control.cpp +965 -20
- package/targets/esp32/services/frame_scheduler.cpp +128 -4
- package/targets/esp32/services/heap.cpp +125 -0
- package/targets/esp32/services/opus_benchmark.h +1 -1
- package/targets/esp32/services/storage_service.cpp +119 -104
- package/targets/esp32-p4-m5stack-tab5/dependencies.lock +27 -16
- package/targets/esp32-s3-m5stack-stopwatch/README.md +14 -9
- package/targets/esp32-s3-m5stack-stopwatch/dependencies.lock +54 -1
- package/targets/esp32-s3-m5stack-stopwatch/main/CMakeLists.txt +10 -7
- package/targets/esp32-s3-m5stack-stopwatch/main/buttons.cpp +80 -0
- package/targets/esp32-s3-m5stack-stopwatch/main/idf_component.yml +18 -0
- package/targets/esp32-s3-m5stack-stopwatch/main/include/board.h +38 -17
- package/targets/esp32-s3-m5stack-stopwatch/main/panel_reset.cpp +132 -129
- package/targets/esp32-s3-m5stack-stopwatch/main/power.cpp +253 -0
- package/targets/esp32-s3-m5stack-stopwatch/main/touch.cpp +158 -88
- package/targets/esp32-s3-m5stack-stopwatch/sdkconfig.defaults +13 -0
- package/targets/esp32-s3-touch-amoled-1.8/main/CMakeLists.txt +30 -3
- package/targets/esp32-s3-touch-amoled-2.06/dependencies.lock +10 -148
- package/targets/esp32-s31-espressif-mosaico/README.md +34 -0
- package/targets/esp32-s31-espressif-mosaico/dependencies.lock +49 -1
- package/targets/esp32-s31-espressif-mosaico/main/CMakeLists.txt +23 -1
- package/targets/esp32-s31-espressif-mosaico/main/board_power.cpp +117 -0
- package/targets/esp32-s31-espressif-mosaico/main/camera.cpp +326 -0
- package/targets/esp32-s31-espressif-mosaico/main/idf_component.yml +11 -0
- package/targets/esp32-s31-espressif-mosaico/main/include/board.h +23 -0
- package/targets/esp32-s31-espressif-mosaico/main/nand_mount.cpp +172 -0
- package/targets/esp32-s31-espressif-mosaico/partitions.csv +7 -3
- package/targets/esp32-s31-espressif-mosaico/sdkconfig.defaults +24 -0
|
@@ -7,6 +7,7 @@
|
|
|
7
7
|
#include <algorithm>
|
|
8
8
|
#include <atomic>
|
|
9
9
|
#include <cstdint>
|
|
10
|
+
#include <mutex>
|
|
10
11
|
|
|
11
12
|
#include "driver/i2c_master.h"
|
|
12
13
|
#include "esp_attr.h"
|
|
@@ -29,119 +30,188 @@ bool moveQueued = false;
|
|
|
29
30
|
std::uint32_t lastPoll = 0;
|
|
30
31
|
std::uint32_t lastReport = 0;
|
|
31
32
|
std::atomic<bool> reportPending{false};
|
|
33
|
+
std::atomic<bool> injectedGestureActive{false};
|
|
34
|
+
std::mutex streamMutex;
|
|
35
|
+
std::mutex cacheMutex;
|
|
32
36
|
|
|
33
|
-
void IRAM_ATTR touchInterrupt(void
|
|
34
|
-
|
|
35
|
-
reportPending.store(true, std::memory_order_relaxed);
|
|
37
|
+
void IRAM_ATTR touchInterrupt(void*) {
|
|
38
|
+
reportPending.store(true, std::memory_order_relaxed);
|
|
36
39
|
}
|
|
37
40
|
|
|
38
|
-
void notify(Phase phase, bool touching, int x, int y)
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
41
|
+
void notify(Phase phase, bool touching, int x, int y) {
|
|
42
|
+
Touchscreen::Observer currentObserver;
|
|
43
|
+
Touchscreen::PointerObserver currentPointerObserver;
|
|
44
|
+
{
|
|
45
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
46
|
+
currentObserver = observer;
|
|
47
|
+
currentPointerObserver = pointerObserver;
|
|
48
|
+
}
|
|
49
|
+
if (currentPointerObserver) {
|
|
50
|
+
currentPointerObserver(phase, touching, x, y, 0);
|
|
51
|
+
} else if (currentObserver) {
|
|
52
|
+
currentObserver(phase, touching, x, y);
|
|
53
|
+
}
|
|
42
54
|
}
|
|
43
55
|
|
|
44
|
-
void update(Phase phase, bool touching, int x, int y)
|
|
45
|
-
{
|
|
56
|
+
void update(Phase phase, bool touching, int x, int y) {
|
|
57
|
+
{
|
|
58
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
46
59
|
pressed = touching;
|
|
47
60
|
cachedX = x;
|
|
48
61
|
cachedY = y;
|
|
49
62
|
latestX = x;
|
|
50
63
|
latestY = y;
|
|
51
64
|
if (phase == Phase::Move) {
|
|
52
|
-
|
|
53
|
-
|
|
65
|
+
if (moveQueued) {
|
|
66
|
+
return;
|
|
67
|
+
}
|
|
68
|
+
moveQueued = true;
|
|
54
69
|
}
|
|
55
|
-
|
|
70
|
+
}
|
|
71
|
+
// The observer may consume a dropped/coalesced Move immediately.
|
|
72
|
+
notify(phase, touching, x, y);
|
|
56
73
|
}
|
|
57
74
|
|
|
58
|
-
}
|
|
75
|
+
} // namespace
|
|
59
76
|
|
|
60
77
|
namespace gea::platform::touch {
|
|
61
78
|
|
|
62
|
-
void Touchscreen::setObserver(Observer next) {
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
const auto handle = static_cast<i2c_master_bus_handle_t>(bus.nativeHandle());
|
|
76
|
-
esp_err_t err = i2c_master_probe(handle, config.device_address, 100);
|
|
77
|
-
if (err == ESP_OK) err = i2c_master_bus_add_device(handle, &config, &device);
|
|
78
|
-
if (err != ESP_OK) {
|
|
79
|
-
ESP_LOGE(kTag, "CST820 not found: %s", esp_err_to_name(err));
|
|
80
|
-
return false;
|
|
81
|
-
}
|
|
82
|
-
gpio_config_t interrupt = {};
|
|
83
|
-
interrupt.pin_bit_mask = 1ULL << board::touch.interrupt;
|
|
84
|
-
interrupt.mode = GPIO_MODE_INPUT;
|
|
85
|
-
interrupt.pull_up_en = GPIO_PULLUP_ENABLE;
|
|
86
|
-
interrupt.intr_type = GPIO_INTR_NEGEDGE;
|
|
87
|
-
ESP_ERROR_CHECK(gpio_config(&interrupt));
|
|
88
|
-
err = gpio_install_isr_service(0);
|
|
89
|
-
if (err != ESP_OK && err != ESP_ERR_INVALID_STATE) ESP_ERROR_CHECK(err);
|
|
90
|
-
ESP_ERROR_CHECK(gpio_isr_handler_add(board::touch.interrupt, touchInterrupt, nullptr));
|
|
91
|
-
reportPending.store(true, std::memory_order_relaxed);
|
|
92
|
-
ESP_LOGI(kTag, "touch ready (address=0x15, INT=GPIO%d)", board::touch.interrupt);
|
|
79
|
+
void Touchscreen::setObserver(Observer next) {
|
|
80
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
81
|
+
observer = next;
|
|
82
|
+
}
|
|
83
|
+
|
|
84
|
+
void Touchscreen::setPointerObserver(PointerObserver next) {
|
|
85
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
86
|
+
pointerObserver = next;
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
bool Touchscreen::init() {
|
|
90
|
+
board::startButtons();
|
|
91
|
+
if (device) {
|
|
93
92
|
return true;
|
|
93
|
+
}
|
|
94
|
+
board::resetTouchPanel();
|
|
95
|
+
const auto bus = i2c::Bus::primary();
|
|
96
|
+
if (!bus.available()) {
|
|
97
|
+
return false;
|
|
98
|
+
}
|
|
99
|
+
i2c_device_config_t config = {};
|
|
100
|
+
config.dev_addr_length = I2C_ADDR_BIT_LEN_7;
|
|
101
|
+
config.device_address = 0x15;
|
|
102
|
+
config.scl_speed_hz = 100000;
|
|
103
|
+
const auto handle = static_cast<i2c_master_bus_handle_t>(bus.nativeHandle());
|
|
104
|
+
esp_err_t err = i2c_master_probe(handle, config.device_address, 100);
|
|
105
|
+
if (err == ESP_OK) {
|
|
106
|
+
err = i2c_master_bus_add_device(handle, &config, &device);
|
|
107
|
+
}
|
|
108
|
+
if (err != ESP_OK) {
|
|
109
|
+
ESP_LOGE(kTag, "CST820 not found: %s", esp_err_to_name(err));
|
|
110
|
+
return false;
|
|
111
|
+
}
|
|
112
|
+
gpio_config_t interrupt = {};
|
|
113
|
+
interrupt.pin_bit_mask = 1ULL << board::touch.interrupt;
|
|
114
|
+
interrupt.mode = GPIO_MODE_INPUT;
|
|
115
|
+
interrupt.pull_up_en = GPIO_PULLUP_ENABLE;
|
|
116
|
+
interrupt.intr_type = GPIO_INTR_NEGEDGE;
|
|
117
|
+
ESP_ERROR_CHECK(gpio_config(&interrupt));
|
|
118
|
+
err = gpio_install_isr_service(0);
|
|
119
|
+
if (err != ESP_OK && err != ESP_ERR_INVALID_STATE) {
|
|
120
|
+
ESP_ERROR_CHECK(err);
|
|
121
|
+
}
|
|
122
|
+
ESP_ERROR_CHECK(gpio_isr_handler_add(board::touch.interrupt, touchInterrupt, nullptr));
|
|
123
|
+
reportPending.store(true, std::memory_order_relaxed);
|
|
124
|
+
ESP_LOGI(kTag, "touch ready (address=0x15, INT=GPIO%d)", board::touch.interrupt);
|
|
125
|
+
return true;
|
|
94
126
|
}
|
|
95
127
|
|
|
96
|
-
void Touchscreen::poll(int nowMs)
|
|
97
|
-
{
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
128
|
+
void Touchscreen::poll(int nowMs) {
|
|
129
|
+
if (injectedGestureActive.load(std::memory_order_acquire) || !device) {
|
|
130
|
+
return;
|
|
131
|
+
}
|
|
132
|
+
// Serialize a poll already in progress with the control task's injected
|
|
133
|
+
// Down. During its gesture, leave the hardware IRQ latch untouched.
|
|
134
|
+
const std::lock_guard<std::mutex> guard(streamMutex);
|
|
135
|
+
if (injectedGestureActive.load(std::memory_order_acquire)) {
|
|
136
|
+
return;
|
|
137
|
+
}
|
|
138
|
+
const auto now = static_cast<std::uint32_t>(nowMs);
|
|
139
|
+
if (now - lastPoll < 10) {
|
|
140
|
+
return;
|
|
141
|
+
}
|
|
142
|
+
// Avoid waking the controller or blocking animation when it has no report.
|
|
143
|
+
// While held, poll too so a lost release interrupt cannot stick the pointer.
|
|
144
|
+
const bool pending = reportPending.exchange(false, std::memory_order_relaxed);
|
|
145
|
+
if (!pressed && !pending && gpio_get_level(board::touch.interrupt) != 0) {
|
|
146
|
+
return;
|
|
147
|
+
}
|
|
148
|
+
lastPoll = now;
|
|
149
|
+
const std::uint8_t reg = 0x00;
|
|
150
|
+
std::uint8_t report[7] = {};
|
|
151
|
+
if (i2c_master_transmit_receive(device, ®, 1, report, sizeof(report), 10) != ESP_OK) {
|
|
152
|
+
// The controller sleeps after idle. A missed final report followed by
|
|
153
|
+
// NACKs must not leave a finger permanently held in the runtime.
|
|
154
|
+
if (pressed && now - lastReport >= 60) {
|
|
155
|
+
update(Phase::Up, false, cachedX, cachedY);
|
|
113
156
|
}
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
157
|
+
return;
|
|
158
|
+
}
|
|
159
|
+
lastReport = now;
|
|
160
|
+
// The CST820 report is not the CST92xx protocol. Decode the factory
|
|
161
|
+
// firmware's seven-byte report, including its explicit lift event.
|
|
162
|
+
const unsigned event = report[3] >> 6;
|
|
163
|
+
const bool touching = (report[2] & 0x0F) != 0 && (event == 0 || event == 2);
|
|
164
|
+
if (!touching) {
|
|
165
|
+
if (pressed) {
|
|
166
|
+
update(Phase::Up, false, cachedX, cachedY);
|
|
122
167
|
}
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
168
|
+
return;
|
|
169
|
+
}
|
|
170
|
+
const int x = std::clamp(((report[3] & 0x0F) << 8) | report[4], 0, display::kWidth - 1);
|
|
171
|
+
const int y = std::clamp(((report[5] & 0x0F) << 8) | report[6], 0, display::kHeight - 1);
|
|
172
|
+
if (!pressed) {
|
|
173
|
+
update(Phase::Down, true, x, y);
|
|
174
|
+
} else if (x != cachedX || y != cachedY) {
|
|
175
|
+
update(Phase::Move, true, x, y);
|
|
176
|
+
}
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
int Touchscreen::read(int* x, int* y) {
|
|
180
|
+
return readCached(x, y);
|
|
127
181
|
}
|
|
128
182
|
|
|
129
|
-
int Touchscreen::
|
|
130
|
-
|
|
131
|
-
{
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
183
|
+
int Touchscreen::readCached(int* x, int* y) {
|
|
184
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
185
|
+
if (x) {
|
|
186
|
+
*x = cachedX;
|
|
187
|
+
}
|
|
188
|
+
if (y) {
|
|
189
|
+
*y = cachedY;
|
|
190
|
+
}
|
|
191
|
+
return pressed ? 1 : 0;
|
|
135
192
|
}
|
|
136
|
-
|
|
137
|
-
{
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
193
|
+
|
|
194
|
+
void Touchscreen::consumeLatestMove(int* x, int* y) {
|
|
195
|
+
const std::lock_guard<std::mutex> guard(cacheMutex);
|
|
196
|
+
moveQueued = false;
|
|
197
|
+
if (x) {
|
|
198
|
+
*x = latestX;
|
|
199
|
+
}
|
|
200
|
+
if (y) {
|
|
201
|
+
*y = latestY;
|
|
202
|
+
}
|
|
141
203
|
}
|
|
142
|
-
|
|
143
|
-
{
|
|
144
|
-
|
|
204
|
+
|
|
205
|
+
void Touchscreen::injectEvent(Phase phase, bool touching, int x, int y) {
|
|
206
|
+
const std::lock_guard<std::mutex> guard(streamMutex);
|
|
207
|
+
if (phase == Phase::Down) {
|
|
208
|
+
injectedGestureActive.store(true, std::memory_order_release);
|
|
209
|
+
}
|
|
210
|
+
update(phase, touching, x, y);
|
|
211
|
+
if (phase == Phase::Up) {
|
|
212
|
+
// Publish the Up before letting hardware reports resume the stream.
|
|
213
|
+
injectedGestureActive.store(false, std::memory_order_release);
|
|
214
|
+
}
|
|
145
215
|
}
|
|
146
216
|
|
|
147
|
-
}
|
|
217
|
+
} // namespace gea::platform::touch
|
|
@@ -31,3 +31,16 @@ CONFIG_BOOTLOADER_LOG_LEVEL=3
|
|
|
31
31
|
CONFIG_COMPILER_OPTIMIZATION_ASSERTIONS_ENABLE=y
|
|
32
32
|
CONFIG_COMPILER_OPTIMIZATION_ASSERTION_LEVEL=2
|
|
33
33
|
CONFIG_HEAP_TRACING_OFF=y
|
|
34
|
+
|
|
35
|
+
# Shared network runtime: DTLS/SRTP and device certificate generation.
|
|
36
|
+
CONFIG_MBEDTLS_SSL_PROTO_DTLS=y
|
|
37
|
+
CONFIG_MBEDTLS_SSL_DTLS_SRTP=y
|
|
38
|
+
CONFIG_MBEDTLS_SSL_DTLS_HELLO_VERIFY=y
|
|
39
|
+
CONFIG_MBEDTLS_SSL_DTLS_CLIENT_PORT_REUSE=y
|
|
40
|
+
CONFIG_MBEDTLS_SSL_DTLS_CONNECTION_ID=y
|
|
41
|
+
CONFIG_MBEDTLS_X509_CREATE_C=y
|
|
42
|
+
CONFIG_MBEDTLS_X509_CRT_WRITE_C=y
|
|
43
|
+
CONFIG_MBEDTLS_X509_CSR_WRITE_C=y
|
|
44
|
+
|
|
45
|
+
# Native audio/worklet thread-local cleanup needs more than IDF's 1536-byte idle stack.
|
|
46
|
+
CONFIG_FREERTOS_IDLE_TASK_STACKSIZE=3072
|
|
@@ -311,6 +311,15 @@ set(GEATSC_COMPILE_OPTIONS
|
|
|
311
311
|
# ESP32-S31 Mosaico) has no such option and gcc refuses the whole archive.
|
|
312
312
|
${GEA_XTENSA_LITERALS}
|
|
313
313
|
)
|
|
314
|
+
# RISC-V (the S31 Mosaico): binutils' relaxation deletes bytes symbol by symbol,
|
|
315
|
+
# and while any `-Wl,--wrap` is active (the board wraps gpio/panic/usb calls)
|
|
316
|
+
# each deletion rescans every earlier global of the object -- quadratic in an
|
|
317
|
+
# object's globals. The generated archive's objects carry up to ~16k globals and
|
|
318
|
+
# 2 MB of text, which made the final link take ~27 minutes against 7 seconds
|
|
319
|
+
# without relaxation. Not relaxing the generated code costs ~3% of its size.
|
|
320
|
+
if(CONFIG_IDF_TARGET_ARCH_RISCV)
|
|
321
|
+
list(APPEND GEATSC_COMPILE_OPTIONS -mno-relax)
|
|
322
|
+
endif()
|
|
314
323
|
set(GEATSC_COMPILE_DEFINITIONS "")
|
|
315
324
|
if(NOT CMAKE_SCRIPT_MODE_FILE)
|
|
316
325
|
# RTC contains the decode/conversion workers, not generated app templates.
|
|
@@ -429,9 +438,15 @@ else()
|
|
|
429
438
|
)
|
|
430
439
|
endif()
|
|
431
440
|
|
|
432
|
-
#
|
|
433
|
-
|
|
434
|
-
if(
|
|
441
|
+
# RTC is independently excludable for apps that only need HTTP/Wi-Fi.
|
|
442
|
+
set(_GEA_BOARD_RTC_ENABLED 1)
|
|
443
|
+
if(DEFINED ENV{GEA_EMBEDDED_CAPABILITY_RTC}
|
|
444
|
+
AND NOT "$ENV{GEA_EMBEDDED_CAPABILITY_RTC}" STREQUAL "")
|
|
445
|
+
set(_GEA_BOARD_RTC_ENABLED "$ENV{GEA_EMBEDDED_CAPABILITY_RTC}")
|
|
446
|
+
elseif(DEFINED CACHE{GEA_EMBEDDED_CAPABILITY_RTC})
|
|
447
|
+
set(_GEA_BOARD_RTC_ENABLED "$CACHE{GEA_EMBEDDED_CAPABILITY_RTC}")
|
|
448
|
+
endif()
|
|
449
|
+
if(GEA_EMBEDDED_CAPABILITY_NETWORK AND _GEA_BOARD_RTC_ENABLED)
|
|
435
450
|
set(GEA_BOARD_NETWORK_SOURCES "${GEA_HOST}/host/rtc_esp.cpp")
|
|
436
451
|
else()
|
|
437
452
|
set(GEA_BOARD_NETWORK_SOURCES "")
|
|
@@ -645,6 +660,17 @@ file(GLOB_RECURSE _GEATSC_DIST_SRCS CONFIGURE_DEPENDS
|
|
|
645
660
|
"${GEA_COMPILER}/dist/targets/cpp/runtime/*.cpp"
|
|
646
661
|
"${GEA_PLUGIN}/dist/*.js"
|
|
647
662
|
)
|
|
663
|
+
# GEA_GEATSC_REUSE_GENERATED=1 keeps the C++ geatsc already wrote (and the
|
|
664
|
+
# runtime header copied beside it) instead of re-running geatsc: it re-runs on
|
|
665
|
+
# any compiler source change, so a board build otherwise follows every
|
|
666
|
+
# in-flight compiler edit -- including ones that do not compile this app yet.
|
|
667
|
+
if(DEFINED ENV{GEA_GEATSC_REUSE_GENERATED} AND "$ENV{GEA_GEATSC_REUSE_GENERATED}" STREQUAL "1" AND EXISTS "${GEATSC_SOURCE_LIST}")
|
|
668
|
+
message(STATUS "geatsc: reusing the generated sources in ${GENERATED_APP_DIR}")
|
|
669
|
+
add_custom_command(
|
|
670
|
+
OUTPUT ${_GEATSC_BUILD_STAMP}
|
|
671
|
+
COMMAND ${CMAKE_COMMAND} -E touch ${_GEATSC_BUILD_STAMP}
|
|
672
|
+
)
|
|
673
|
+
else()
|
|
648
674
|
add_custom_command(
|
|
649
675
|
OUTPUT ${_GEATSC_BUILD_STAMP}
|
|
650
676
|
COMMAND node ${_GEA_VITE_GEATSC_SCRIPT}
|
|
@@ -687,6 +713,7 @@ add_custom_command(
|
|
|
687
713
|
COMMENT "Compiling ${GEA_EMBEDDED_APP}: TSX -> JS via vite-plugin-gea -> C++ via geatsc"
|
|
688
714
|
VERBATIM
|
|
689
715
|
)
|
|
716
|
+
endif()
|
|
690
717
|
add_custom_target(geatsc_build ALL DEPENDS ${_GEATSC_BUILD_STAMP})
|
|
691
718
|
gea_geatsc_add_generated_archive(
|
|
692
719
|
TARGET ${COMPONENT_LIB}
|
|
@@ -6,7 +6,7 @@ dependencies:
|
|
|
6
6
|
require: private
|
|
7
7
|
version: '>=5.0'
|
|
8
8
|
source:
|
|
9
|
-
registry_url: https://components.espressif.com
|
|
9
|
+
registry_url: https://components.espressif.com/
|
|
10
10
|
type: service
|
|
11
11
|
version: 1.7.19~2
|
|
12
12
|
espressif/cmake_utilities:
|
|
@@ -19,106 +19,6 @@ dependencies:
|
|
|
19
19
|
registry_url: https://components.espressif.com
|
|
20
20
|
type: service
|
|
21
21
|
version: 0.5.3
|
|
22
|
-
espressif/dl_fft:
|
|
23
|
-
component_hash: 965be7152132b365061abf5fc5fc7b85e525f73b94a204cdda61cfe9572c0d77
|
|
24
|
-
dependencies:
|
|
25
|
-
- name: idf
|
|
26
|
-
require: private
|
|
27
|
-
version: '>=5.0'
|
|
28
|
-
source:
|
|
29
|
-
registry_url: https://components.espressif.com
|
|
30
|
-
type: service
|
|
31
|
-
version: 0.8.0
|
|
32
|
-
espressif/esp-dl:
|
|
33
|
-
component_hash: 3148b2692a2943d7e35401dc10a181b6ba83515ec70ef51499ac5d2593eef3e2
|
|
34
|
-
dependencies:
|
|
35
|
-
- name: espressif/dl_fft
|
|
36
|
-
registry_url: https://components.espressif.com
|
|
37
|
-
require: private
|
|
38
|
-
version: '>=0.8.0'
|
|
39
|
-
- name: espressif/esp_new_jpeg
|
|
40
|
-
registry_url: https://components.espressif.com
|
|
41
|
-
require: private
|
|
42
|
-
version: ^1
|
|
43
|
-
- name: idf
|
|
44
|
-
require: private
|
|
45
|
-
version: '*'
|
|
46
|
-
source:
|
|
47
|
-
registry_url: https://components.espressif.com
|
|
48
|
-
type: service
|
|
49
|
-
targets:
|
|
50
|
-
- esp32
|
|
51
|
-
- esp32c2
|
|
52
|
-
- esp32c3
|
|
53
|
-
- esp32c5
|
|
54
|
-
- esp32c6
|
|
55
|
-
- esp32p4
|
|
56
|
-
- esp32s2
|
|
57
|
-
- esp32s3
|
|
58
|
-
- esp32s31
|
|
59
|
-
version: 3.3.13
|
|
60
|
-
espressif/esp-sr:
|
|
61
|
-
component_hash: 698154c0a94f6c8ac3e1ac669ec3ea741e6f848022b0f89030eddb23f3a31e14
|
|
62
|
-
dependencies:
|
|
63
|
-
- name: espressif/cjson
|
|
64
|
-
registry_url: https://components.espressif.com
|
|
65
|
-
require: private
|
|
66
|
-
version: ^1.7.19
|
|
67
|
-
- name: espressif/dl_fft
|
|
68
|
-
registry_url: https://components.espressif.com
|
|
69
|
-
require: private
|
|
70
|
-
version: '>=0.6.0'
|
|
71
|
-
- name: espressif/esp-dl
|
|
72
|
-
registry_url: https://components.espressif.com
|
|
73
|
-
require: private
|
|
74
|
-
version: ~3.3.12
|
|
75
|
-
- name: espressif/esp-dsp
|
|
76
|
-
registry_url: https://components.espressif.com
|
|
77
|
-
require: private
|
|
78
|
-
rules:
|
|
79
|
-
- if: target in [esp32, esp32s2, esp32c3, esp32c5, esp32c6]
|
|
80
|
-
version: 1.8.0
|
|
81
|
-
- name: idf
|
|
82
|
-
require: private
|
|
83
|
-
version: '>=5.0'
|
|
84
|
-
source:
|
|
85
|
-
registry_url: https://components.espressif.com/
|
|
86
|
-
type: service
|
|
87
|
-
version: 2.5.5
|
|
88
|
-
espressif/esp_audio_codec:
|
|
89
|
-
component_hash: a5b9275af74247e3ce536d16a7080e4d77207a185b63e1bea368eb4d57176c2b
|
|
90
|
-
dependencies:
|
|
91
|
-
- name: idf
|
|
92
|
-
require: private
|
|
93
|
-
version: '>=4.4'
|
|
94
|
-
source:
|
|
95
|
-
registry_url: https://components.espressif.com/
|
|
96
|
-
type: service
|
|
97
|
-
version: 2.6.2
|
|
98
|
-
espressif/esp_codec_dev:
|
|
99
|
-
component_hash: 4779f31a3ba3f9b38aee1afe6ccb9ba8f6108dc3a6e77d39d7d714e9a215371b
|
|
100
|
-
dependencies:
|
|
101
|
-
- name: idf
|
|
102
|
-
require: private
|
|
103
|
-
version: '>=4.0'
|
|
104
|
-
source:
|
|
105
|
-
registry_url: https://components.espressif.com/
|
|
106
|
-
type: service
|
|
107
|
-
version: 1.6.2
|
|
108
|
-
espressif/esp_h264:
|
|
109
|
-
component_hash: 3d60078419ceac61cd87579664ae6a5a9b9a42d6f2edf4e23d753af8d2a67da9
|
|
110
|
-
dependencies:
|
|
111
|
-
- name: idf
|
|
112
|
-
require: private
|
|
113
|
-
version: '>=4.4'
|
|
114
|
-
source:
|
|
115
|
-
registry_url: https://components.espressif.com/
|
|
116
|
-
type: service
|
|
117
|
-
targets:
|
|
118
|
-
- esp32s3
|
|
119
|
-
- esp32s31
|
|
120
|
-
- esp32p4
|
|
121
|
-
version: 1.4.1
|
|
122
22
|
espressif/esp_io_expander:
|
|
123
23
|
component_hash: 7b7f91270172e46ca4597e3874f48d8412e280e8c295559f5922ec38656e3e5f
|
|
124
24
|
dependencies:
|
|
@@ -161,68 +61,30 @@ dependencies:
|
|
|
161
61
|
registry_url: https://components.espressif.com/
|
|
162
62
|
type: service
|
|
163
63
|
version: 1.0.1~1
|
|
164
|
-
espressif/
|
|
165
|
-
component_hash:
|
|
166
|
-
dependencies: []
|
|
167
|
-
source:
|
|
168
|
-
registry_url: https://components.espressif.com
|
|
169
|
-
type: service
|
|
170
|
-
version: 1.0.0
|
|
171
|
-
espressif/esp_new_jpeg:
|
|
172
|
-
component_hash: e1e7e6991193c41ed6c9fc386702aa7821433319e7aa9c3147cd3236310cd69c
|
|
173
|
-
dependencies: []
|
|
174
|
-
source:
|
|
175
|
-
registry_url: https://components.espressif.com/
|
|
176
|
-
type: service
|
|
177
|
-
targets:
|
|
178
|
-
- esp32
|
|
179
|
-
- esp32s2
|
|
180
|
-
- esp32s3
|
|
181
|
-
- esp32s31
|
|
182
|
-
- esp32p4
|
|
183
|
-
- esp32c2
|
|
184
|
-
- esp32c3
|
|
185
|
-
- esp32c5
|
|
186
|
-
- esp32c6
|
|
187
|
-
- esp32c61
|
|
188
|
-
- esp32h4
|
|
189
|
-
version: 1.0.2
|
|
190
|
-
espressif/esp_peer:
|
|
191
|
-
component_hash: 97aac8b5a27e3901ca5c415a3b9ac083209e02b942af1f5911a754319331e0ca
|
|
64
|
+
espressif/esp_lcd_sh8601:
|
|
65
|
+
component_hash: 18245cd23204eefb67f61b362405f78364fa13b13cdedda5f7546d89701c506b
|
|
192
66
|
dependencies:
|
|
193
|
-
- name: espressif/
|
|
67
|
+
- name: espressif/cmake_utilities
|
|
194
68
|
registry_url: https://components.espressif.com
|
|
195
69
|
require: private
|
|
196
|
-
version:
|
|
197
|
-
source:
|
|
198
|
-
registry_url: https://components.espressif.com/
|
|
199
|
-
type: service
|
|
200
|
-
version: 1.5.5
|
|
201
|
-
espressif/esp_websocket_client:
|
|
202
|
-
component_hash: dc00233af846f3a744ada283a300e0d586040aadc3ee67361645ecdce4523672
|
|
203
|
-
dependencies:
|
|
70
|
+
version: 0.*
|
|
204
71
|
- name: idf
|
|
205
72
|
require: private
|
|
206
|
-
version: '>=5.
|
|
73
|
+
version: '>=5.3'
|
|
207
74
|
source:
|
|
208
75
|
registry_url: https://components.espressif.com/
|
|
209
76
|
type: service
|
|
210
|
-
version:
|
|
77
|
+
version: 2.0.1~1
|
|
211
78
|
idf:
|
|
212
79
|
source:
|
|
213
80
|
type: idf
|
|
214
81
|
version: 6.0.2
|
|
215
82
|
direct_dependencies:
|
|
216
|
-
- espressif/
|
|
217
|
-
- espressif/esp_audio_codec
|
|
218
|
-
- espressif/esp_codec_dev
|
|
219
|
-
- espressif/esp_h264
|
|
83
|
+
- espressif/cjson
|
|
220
84
|
- espressif/esp_lcd_co5300
|
|
221
85
|
- espressif/esp_lcd_panel_io_additions
|
|
222
|
-
- espressif/
|
|
223
|
-
- espressif/esp_peer
|
|
224
|
-
- espressif/esp_websocket_client
|
|
86
|
+
- espressif/esp_lcd_sh8601
|
|
225
87
|
- idf
|
|
226
|
-
manifest_hash:
|
|
88
|
+
manifest_hash: bf7fec51668e63dfcd2244456e1c0b928f5bd1ef4c46f9bb547535aad1d8290c
|
|
227
89
|
target: esp32s3
|
|
228
90
|
version: 3.0.0
|
|
@@ -63,3 +63,37 @@ The panel's TE line is wired on GPIO43, so apps that ask for vsync
|
|
|
63
63
|
|
|
64
64
|
Not yet wired: the BQ27220 fuel gauge (the board reports no battery reading),
|
|
65
65
|
the magnetometers and the SPI NAND.
|
|
66
|
+
|
|
67
|
+
## Camera module
|
|
68
|
+
|
|
69
|
+
The optional camera plugs into the **left expansion slot**. The official
|
|
70
|
+
`mosaico_module_camera` driver detects the included SC101IOT module and the
|
|
71
|
+
older OV3640 module. Gea downloads its pinned BSP dependencies only for apps
|
|
72
|
+
whose compiler analysis reaches the `Camera` binding. The BSP owns the separate
|
|
73
|
+
expansion I2C1 bus on GPIO0/1; Gea continues to own the onboard I2C0 bus, panel,
|
|
74
|
+
touch and audio. The Type-C USB-OTG console works while DVP capture is active.
|
|
75
|
+
|
|
76
|
+
`Camera.open()` starts continuous UYVY capture on a native worker. The worker
|
|
77
|
+
returns each borrowed camera buffer immediately after downsampling, and JPEG
|
|
78
|
+
encoding runs at most once every two seconds. `Camera.captureFrame()` consumes
|
|
79
|
+
the newest JPEG data URL without waiting; it returns an empty string when no
|
|
80
|
+
fresh image is ready. There is one pending image, so a disconnected consumer
|
|
81
|
+
cannot accumulate frames.
|
|
82
|
+
|
|
83
|
+
Images are rotated counter-clockwise by 90 degrees to correct the module's
|
|
84
|
+
mounting orientation, then fit inside **320 × 240 pixels** at JPEG quality 70.
|
|
85
|
+
The encoder uses whole 16-pixel blocks: the SC101IOT's 1280 × 720 default becomes
|
|
86
|
+
an upright **128 × 240** image; the OV3640's 1024 × 768 default becomes
|
|
87
|
+
**176 × 240**. Encoded images are capped at 96 KiB before base64 encoding.
|
|
88
|
+
Still captures and preview use the same bounded snapshots. Video recording,
|
|
89
|
+
zoom and manual sensor tuning are not implemented by this backend.
|
|
90
|
+
|
|
91
|
+
`Camera.close()` stops the worker, releases the module lease and capture
|
|
92
|
+
buffers, deletes the JPEG encoder and clears the pending image. Sensor reads
|
|
93
|
+
time out after 100 ms and encoding after 500 ms. The worker join waits at most 1500 ms;
|
|
94
|
+
if the SDK stalls, it logs the failure and retains the live resources so that a
|
|
95
|
+
later close/open can safely retry.
|
|
96
|
+
|
|
97
|
+
The pinned official camera component applies its ESP-IDF DVP and SC101IOT
|
|
98
|
+
stability patches during configuration. Check configuration output for patch
|
|
99
|
+
warnings: a failed patch application means those workarounds are absent.
|
|
@@ -1,4 +1,14 @@
|
|
|
1
1
|
dependencies:
|
|
2
|
+
espressif/cjson:
|
|
3
|
+
component_hash: e788323270d90738662d66fffa910bfe1fba019bba087f01557e70c40485b469
|
|
4
|
+
dependencies:
|
|
5
|
+
- name: idf
|
|
6
|
+
require: private
|
|
7
|
+
version: '>=5.0'
|
|
8
|
+
source:
|
|
9
|
+
registry_url: https://components.espressif.com/
|
|
10
|
+
type: service
|
|
11
|
+
version: 1.7.19~2
|
|
2
12
|
espressif/cmake_utilities:
|
|
3
13
|
component_hash: 351350613ceafba240b761b4ea991e0f231ac7a9f59a9ee901f751bddc0bb18f
|
|
4
14
|
dependencies:
|
|
@@ -9,6 +19,13 @@ dependencies:
|
|
|
9
19
|
registry_url: https://components.espressif.com
|
|
10
20
|
type: service
|
|
11
21
|
version: 0.5.3
|
|
22
|
+
espressif/dhara:
|
|
23
|
+
component_hash: 46b686fd0599aed21fee222c249744f05eed28d8e62446bcc83b6b50bcc390e0
|
|
24
|
+
dependencies: []
|
|
25
|
+
source:
|
|
26
|
+
registry_url: https://components.espressif.com
|
|
27
|
+
type: service
|
|
28
|
+
version: 1.1.0
|
|
12
29
|
espressif/esp_codec_dev:
|
|
13
30
|
component_hash: 4779f31a3ba3f9b38aee1afe6ccb9ba8f6108dc3a6e77d39d7d714e9a215371b
|
|
14
31
|
dependencies:
|
|
@@ -109,6 +126,34 @@ dependencies:
|
|
|
109
126
|
- esp32h4
|
|
110
127
|
- esp32s31
|
|
111
128
|
version: 2.3.0
|
|
129
|
+
espressif/spi_nand_flash:
|
|
130
|
+
component_hash: aa7bae693eee90b2e5e7cd63e67d41f5c30e61a501873b5c2d02838b1b9df6b8
|
|
131
|
+
dependencies:
|
|
132
|
+
- name: espressif/dhara
|
|
133
|
+
registry_url: https://components.espressif.com
|
|
134
|
+
require: private
|
|
135
|
+
version: 1.*
|
|
136
|
+
- name: idf
|
|
137
|
+
require: private
|
|
138
|
+
version: '>=5.0'
|
|
139
|
+
source:
|
|
140
|
+
registry_url: https://components.espressif.com/
|
|
141
|
+
type: service
|
|
142
|
+
version: 1.4.4
|
|
143
|
+
espressif/spi_nand_flash_fatfs:
|
|
144
|
+
component_hash: c72443b207b655172127f15b497c84ff98ef881557581378b37b4d845bf74472
|
|
145
|
+
dependencies:
|
|
146
|
+
- name: espressif/spi_nand_flash
|
|
147
|
+
registry_url: https://components.espressif.com
|
|
148
|
+
require: private
|
|
149
|
+
version: '*'
|
|
150
|
+
- name: idf
|
|
151
|
+
require: private
|
|
152
|
+
version: '>=5.0'
|
|
153
|
+
source:
|
|
154
|
+
registry_url: https://components.espressif.com/
|
|
155
|
+
type: service
|
|
156
|
+
version: 1.1.2
|
|
112
157
|
espressif/tinyusb:
|
|
113
158
|
component_hash: 16c8d774dab1f484d3e0c0f61105624d2424bbae864efd19818baf7b451b41e7
|
|
114
159
|
dependencies:
|
|
@@ -130,12 +175,15 @@ dependencies:
|
|
|
130
175
|
type: idf
|
|
131
176
|
version: 6.2.0
|
|
132
177
|
direct_dependencies:
|
|
178
|
+
- espressif/cjson
|
|
133
179
|
- espressif/esp_codec_dev
|
|
134
180
|
- espressif/esp_lcd_co5300
|
|
135
181
|
- espressif/esp_lcd_panel_io_additions
|
|
136
182
|
- espressif/esp_lcd_touch_cst9220
|
|
137
183
|
- espressif/esp_tinyusb
|
|
184
|
+
- espressif/spi_nand_flash
|
|
185
|
+
- espressif/spi_nand_flash_fatfs
|
|
138
186
|
- idf
|
|
139
|
-
manifest_hash:
|
|
187
|
+
manifest_hash: a6fdc7e010a8befa9c59a7ccd4b58665dba6209368539d6ae58315d28881a0da
|
|
140
188
|
target: esp32s31
|
|
141
189
|
version: 3.0.0
|