Dan Vybiral eeefa47fa2 touch: fix seven review findings in the segmented-store scheduler
An adversarial review pass over the refactor surfaced these; the first
is a silent-permanent-loss bug:

- CRITICAL: the finished-job check ran AFTER the failure branch had
  already reset s_hist_flush_ok, so a FAILED worker job read as ok and
  got committed — advancing the durability watermark over records that
  never reached disk. The completion check now runs strictly first, and
  a failed job just drops its descriptor (data stays pending).
- A message deleted while its APPEND job was in flight resurrected on
  reboot: segMarkSeqDirty skipped it (seq above the watermark = 'never
  reaches disk') but the in-flight job then put it on disk. After a
  committed append the ring's tombstones inside the newly-flushed range
  now get their compaction marks.
- segCommitJob cleared compact_dirty unconditionally, erasing marks for
  deletes that landed WHILE the compact job was writing (its snapshot
  predates them). A redirty flag keeps the segment dirty for a
  follow-up pass.
- The sync drain shared the worker's job descriptor, snapshot buffer
  and req flag: a worker stalled past the 9 s idle-wait cap could read
  a torn buffer, and the raised req let the worker steal and
  double-execute a job the drain was running inline. segBuildJob is now
  pure (fills a caller buffer + local SegJob); only the async path arms
  the worker statics, and the drain owns a separate buffer.
- An in-session FAT32 format erased all segments while the table (and
  watermark) still claimed them — old records permanently lost and the
  next append targeted a missing file. The format path now runs the
  same resync as a card swap (retable + re-land off-thread).
- uiSegAppendRecords with create=true used FILE_APPEND, so a stale
  same-key file (crash residue) got a second header mid-file; create
  now opens truncating.

Builds verified: all five SD-relevant touch envs.

Signed-off-by: Dan Vybiral <dan.vybiral@greencode.cz>
2026-07-26 23:37:43 +02:00
2026-07-19 13:58:05 +02:00
2026-07-22 22:48:39 +02:00

WADAMESH

A real touchscreen UI for your mesh radio. · open source · GPL-3.0

Touch-UI MeshCore companion-radio firmware for the LilyGo T-Deck / T-Deck Plus and Heltec V4 + TFT (ESP32-S3).

An LVGL touch UI — map, chat, contacts, channels, settings — split out of meshcomod. The app depends on a MeshCore fork via PlatformIO lib_deps.

Boards

See DEVICES.md for the full support matrix, install paths and per-board status.

  • LilyGo T-Deck / T-Deck Plus — env LilyGo_TDeck_companion_radio_touch (stable)
  • Heltec V4 + TFT + CHSC6x touch — env heltec_v4_tft_companion_radio_usb_tcp_touch (stable)
  • Tanmatsu (ESP32-P4) — built from tanmatsu/ (ESP-IDF), ships via the Tanmatsu app store
  • Elecrow ThinkNode M9 — env ThinkNode_M9_companion_radio_touch (beta)
  • RAK WisMesh Tap V2 (RAK3312) — env rak_tap_v2_companion_radio_touch (beta)

Architecture

This repo holds only the app: the companion_radio glue, the ui-touch LVGL UI, the two boards' glue/variants, and platformio.ini. The MeshCore core is not vendored here — it's pulled as a library via lib_deps from the ALLFATHER-BV/meshcomod monorepo (the same repo as the non-touch firmware), pinned by a lean source-only core-* git tag. The touch-app files this repo owns (TouchPrefsStore, WifiRuntimeStore, the transports, …) are dropped from the lib via -DMC_VENDORED_TOUCH_APP so they aren't compiled twice. The build is byte-identical to the original in-tree meshcomod firmware.

Build

PlatformIO pulls the core fork and all libraries automatically:

pio run -e heltec_v4_tft_companion_radio_usb_tcp_touch   # Heltec V4 TFT
pio run -e LilyGo_TDeck_companion_radio_touch            # LilyGo T-Deck
# or just `pio run` to build both

Flash with the NVS-preserving 4-component chain (bootloader / partitions / boot_app0 / firmware at 0x0 / 0x8000 / 0xe000 / 0x10000) so saved Wi-Fi credentials survive — not a merged image, which 0xFF-pads and wipes NVS.

Contributing

Contributions are welcome — see CONTRIBUTING.md. One topic per PR; inbound contributions are accepted under the project's GPL-3.0 license.

License

GPL-3.0-or-later — see LICENSE. wadamesh is copyleft: anyone who distributes a build or a fork must also make their source available under the GPL. This keeps the UI open and concentrates community effort instead of fragmenting it into closed forks.

wadamesh incorporates and depends on MeshCore (MIT, © Scott Powell / rippleradios.com) and other third-party components — see NOTICE for the full list and their licenses. MeshCore-derived files keep their MIT notices; the combined work is distributed under the GPL (MIT is GPL-compatible). The MeshCore fork that wadamesh builds against stays MIT on purpose, so its Wi-Fi/BLE hooks remain upstreamable to MeshCore.

S
Description
No description provided
Readme GPL-3.0
519 MiB
Languages
C 51.4%
C++ 40.7%
HTML 2.6%
Lua 2.5%
Python 1.8%
Other 0.9%