mirror of
https://github.com/MarekZegare4/MeshCore-Solo.git
synced 2026-10-14 17:41:58 +00:00
feat(ui-lvgl): on-device map download over WiFi
The map's download button fetches the visible area (overview levels up to a chosen zoom) into /sdcard/maps from OpenTopoMap or maps/source.txt, skipping tiles already on the card and rejecting placeholder answers. Settings > WiFi stores the network in NVS (with scan); WiFi is on only while a download runs. HTTP runs on a worker task on core 0; the popup shows link, internal heap and the last TLS/HTTP error. Internal RAM was the blocker (~13 KB free with WiFi + Bluedroid): the L2 LVGL env now allocates the_mesh in PSRAM (MESH_IN_PSRAM, static RAM 210 -> 87 KB) and mbedTLS allocates from PSRAM. Confirmed on hardware. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -172,6 +172,7 @@ fi
|
||||
|
||||
OUT_NAME=meshcore_sim
|
||||
EXPORT_NAME=MeshCoreSim
|
||||
LINK_EXTRA=()
|
||||
if [ "$SIM_UI" = "lvgl" ]; then
|
||||
OUT_NAME=meshcore_sim_lvgl
|
||||
EXPORT_NAME=MeshCoreSimLvgl # distinct factory: web/lvgl.html loads both
|
||||
@@ -183,6 +184,7 @@ if [ "$SIM_UI" = "lvgl" ]; then
|
||||
done
|
||||
DEFINES=("${kept[@]}" -DDISPLAY_CLASS=SimLcdDisplay -DMAX_GROUP_CHANNELS=40 -DUI_ZOOM=1 -DLV_CONF_INCLUDE_SIMPLE)
|
||||
INCLUDES+=("-I$LVGL_DIR")
|
||||
LINK_EXTRA=(-sFETCH=1) # map downloads (LvglPort.h) go through emscripten_fetch
|
||||
fi
|
||||
|
||||
# -funsigned-char: carried over from Phase 1 verbatim -- real ARM cores
|
||||
@@ -292,6 +294,7 @@ fi
|
||||
-sEXIT_RUNTIME=0 \
|
||||
-sEXPORTED_RUNTIME_METHODS=FS,ccall,cwrap,HEAPU8,HEAPF32,HEAP32 \
|
||||
-sEXPORTED_FUNCTIONS=_main,_malloc,_free \
|
||||
${LINK_EXTRA[@]+"${LINK_EXTRA[@]}"} \
|
||||
-o "$OUT_DIR/$OUT_NAME.js"
|
||||
|
||||
echo ""
|
||||
|
||||
Reference in New Issue
Block a user