Commit Graph
3994 Commits
Author SHA1 Message Date
Jakub d25fda5f32 refactor(ui): extract PopupMenu::beginConfirm() for destructive-action popups
Found while re-reviewing this session's own commits: five screens each
hand-built the same 2-row Action/Cancel confirm popup, defaulting the
highlight to Cancel -- NearbyScreen's contact-delete, AdminScreen's
OTA-start, and the three just added (Trail's reset, Messages' channel
delete, RadioPresetPicker's preset delete). The plan that added those
three had already flagged this exact duplication without acting on it, so
it just tripled instead of getting fixed.

One PopupMenu::beginConfirm(title, action_label, cancel_label="Cancel")
replaces all five call sites, and makes "defaults to Cancel" a property of
the popup itself rather than something each new confirm has to remember.
Also drops two small redundancies spotted along the way: NearbyScreen's
_confirm.active = true, dead since begin() already sets it, and
RadioPresetPicker's deleting = false being set twice in a row (once inside
openConfirm(), once again by its only caller).

No behavior change; verified against the actual PopupMenu/menu-level state
machines in each of the five call sites before touching them.
2026-08-31 20:09:59 +02:00
Jakub 691e2ab506 fix(ui): confirm destructive actions, retire last Hold-Enter-cancel, de-dup labels
Continuing the consistency review: sweep for the same three defect shapes
elsewhere in ui-new/ (own read pass plus two parallel research agents),
verified against source before acting.

Three destructive actions fired on a single Enter with no way back, unlike
contact-delete's existing confirm-defaulted-to-Cancel popup: Trail's "Reset
trail" (wipes the whole recorded route, no undo short of a prior manual
Save -- reuses Trail's own multi-level menu machinery, alongside its
GPS-off confirm), Messages' channel Delete, and RadioPresetPicker's saved-
preset delete (shared by Settings > Radio and Tools > Repeater, so one fix
covers both). All three now confirm the same way, defaulting to Cancel.

KeyboardWidget was the one place Hold-Enter still doubled as Cancel: Shift,
Backspace and a Latin letter's accent popup already have real, kept
meanings under a hold, but every other special-row cell (Space, OK/Done,
the {} placeholder) fell through to a bare CANCELLED, closing the keyboard
exactly like the real Cancel key. Now a no-op there too, matching the "only
Back closes it" rule already applied to popups and screens.

MessagesScreen defined the same two label arrays (Notif states, melody
slots) four times over, once per context-menu handler. Hoisted to one
pair of static class members -- constexpr wasn't enough to get the linker
to emit them on this toolchain, so they follow the same declare-in-class/
define-out-of-class shape NearbyScreen::FILTER_LABELS already uses.

Alert text: "Advert sent!"/"Advert failed.." and "Sent!" were the only
toasts anywhere with trailing punctuation; normalized to the plain style
every other confirmation uses. Unpinning from the Favourites Dial reported
the freed slot number from the Messages screens but not from Nodes or the
dial's own tile menu; now consistent everywhere pinning already was.

DiagnosticsScreen's Live/System/Font tab renderers hand-rolled the same
scroll-clamp/loop/indicator skeleton drawList() already bundles; switched
both to drawList (passing the screen's own _scroll as its `sel` too, since
neither tab has a row cursor -- makes drawList's internal clamp a no-op and
leaves clampScroll() as the only thing bounding it, unchanged). Pure
internal tidy, no behavior change.
2026-08-31 19:52:43 +02:00
Jakub f40748ba61 fix(ui): unify the four navigate views, add Set as target everywhere
Continuing the consistency pass: the four screens that show the
distance/bearing "navigate to a point" view (Nodes, Waypoints, Trail's
Track back, and navigating to a location shared in a message) had drifted
apart in three ways.

Only two of the four passed an EtaTracker to navview::draw(), so only
Nodes and Track back showed the closing-speed/ETA line -- navigating to a
waypoint or a shared location left it off for no reason. All four get one
now. They also left the view on three different key sets (Back alone,
Back+LEFT/RIGHT, Back+Enter); Back is now the only way out of any of them,
so a stray sideways nudge can't drop you out of a running track-back.
Messages' renderNav() also switched from reading node_prefs directly to
the shared useImperial() helper the other three already used.

Set as target -- the row Nodes and Waypoints both offer for a coordinate
-- was missing from the message-location Options menu; added alongside
Navigate and Save waypoint.

Nodes' own Set as target required a full 32-byte public key, which a
name-only live-track entry (someone sharing position on a channel who
isn't a saved contact -- the group-outing case this exists for) never
has. One flag was doing two jobs: "can be pinged" (needs the full key)
and "can be identified" (needs only the 6-byte prefix a person target
actually uses). Split into has_key/has_prefix; Set as target now only
needs a position, resolving to a person target (follows them) when a
prefix is available and a place target (pinned where they were) when it
isn't -- the same distinction Locator's own picker already draws.

Locator's target picker separately still listed the people pinned to the
Favourites Dial as its privileged top tier, which stopped making sense
once pinning and favouriting became separate concepts. It now leads with
favourites instead, matching every other list in the firmware.
2026-08-31 19:25:08 +02:00
Jakub 6d1e71cd3f fix(ui): one rule for value rows, one meaning for Hold Enter
Three interaction inconsistencies found while auditing the favourites work,
all of the same shape: the same gesture meaning different things depending
on which screen you were on.

Value rows in popup menus. Rows like "Notif: ON" or "Sort: Dist" show a
value the user steps through with LEFT/RIGHT, but Enter treated them as
ordinary menu picks and closed the popup, so changing two of them meant
reopening the menu in between. Trail's settings submenu was the lone
exception, working around it by rebuilding and re-selecting after each
Enter. PopupMenu now knows the difference: addValueItem() marks a row, and
Enter on it returns the new VALUE_NEXT instead of SELECTED, leaving the
menu open. Only Back closes a menu now. Applied to the Messages
contact/room/channel menus, Nodes, the Ringtone editor and Trail, which
drops its reopenSettingsAt() workaround. The LEFT/RIGHT cycling bodies
moved into one helper per menu, since Enter and RIGHT now share them.

Nodes' Fav row was the worst case: LEFT/RIGHT did nothing there at all, so
the only way to toggle a favourite was an Enter that dismissed the menu on
every flip. Its label moved to a member buffer (as the Pin row already had)
so it can be retitled in place.

Settings rows Auto-off, Low battery, GPS pwr and Battery ignored Enter,
though their options wrap exactly like the melody/keyboard/clock rows
beside them, where Enter has always stepped forward. They accept it now.
Rows that ramp between fixed ends (Brightness, Volume, TX Pwr, Timezone,
SF/BW/CR) stay LEFT/RIGHT-only -- there is nothing to wrap to.

Hold Enter no longer doubles as Back. It quietly meant "go back" on Tools,
Locator, Live Share, Repeater, Bot, Auto-Advert, GPIO, Compass, the
Dashboard config and the Messages navigate view, while elsewhere the same
long press opens a context menu. It now only ever opens a menu, or does
nothing where there is none. Same for dismissing an open popup, which it
used to do. Checked that this strands nobody: every board that can reach
these screens has a real Back key (back_btn on joystick boards, Esc on
CardKB/TCA8418/T-Deck). Single-button boards produce no KEY_ENTER at all,
so they never leave the home pages in the first place.
2026-08-31 15:43:10 +02:00
JakubandClaude Opus 5 57851627cf feat(ui): make favourites mean one thing across every list
Three names had grown around one idea. "Favourite" was a filter in
Settings, an invisible app-only flag on a contact, a device-settable bit on
a channel, and — on the Nodes screen — a menu row that actually pinned to
the Favourites dial. Nothing marked a favourite on screen, and the dial
only took chat contacts.

A favourite is now the starred flag (ContactInfo::flags bit 0 for contacts
and rooms, ch_fav_bitmask for channels), settable on the device everywhere
via a Fav: ON/OFF row, marked with a star on its row, and sorted to the top
of the list — in Messages, Tools > Nodes and the Locator target picker.
Settings > Contacts > "Favs top" turns the sorting off; it defaults on, and
is stored inverted so an upgraded prefs file reads back as on rather than
off.

MyMesh::setContactFavourite() writes the same bit the app sets and bumps
lastmod, so the two stay in sync. The DMs/Rooms = Fav list filters no
longer depend on having starred someone in the app first.

Pinning is now separate and explicit, and the dial takes contacts, room
servers and channels. Slots carry a kind (NodePrefs::favourite_kinds,
schema 0xC0DE0029) — a channel slot holds an index, so emptiness is decided
by the kind first, since channel 0's payload is all zeroes. Choosing what
to pin reuses the Messages screen's own Direct/Channels/Rooms browse
instead of a second picker built on the dial, which drops that picker, its
key/label tables and the now-unused getRecentDMContacts(). A filled tile
gained Unpin/Replace under Hold Enter.

Fixes a room server being pinnable and then unremovable: the picker's
recent-conversations tier didn't filter by contact type and room posts
share the DM history, opening one from the dial skipped the login
handshake, and Unpin only existed in the chat contact list that rooms never
appear in.

Also: PopupMenu::_visible was written and never read (render recomputes the
cap from display height), which is why menus with more items than the
"visible" argument always worked; Settings' all/fav values and the
dm_show_all comment said things that were not true.

Built for Heltec V3, Wio Tracker L1, Wio Tracker L1 e-ink and T-Echo Card.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-31 15:02:01 +02:00
JakubandClaude Sonnet 5 355816eafd polish(ui): text/icon consistency pass across Tools, Settings, and menus
- RepeaterScreen: drop the redundant "Rpt " prefix on the profile fields
  (Preset/Freq/SF/BW/CR), matching Settings > Radio's own terminology --
  the screen is already dedicated to the repeater's own profile, so the
  prefix disambiguated nothing.
- Channel context menu: "Fav: yes/no" -> "Fav: ON/OFF", matching every
  other toggle in the app.
- Settings (System tab): six labels left as raw concatenated identifiers
  (AutoOff/AutoLock/TimeZone/LowBat/BattDisp/BzrVol) now read like their
  space-separated neighbours (Auto pwr/Pwr save/DM sound/GPS pwr), and
  BzrVol no longer clashes with "Buzzer" one row above it for the same
  feature. Three value-label arrays also had one mismatched-case entry
  fixed to match its siblings: Auto-off's "never" -> "OFF", Batt display's
  "icon" -> "Icon", Sound's "built-in" -> "Built-in".
- ToolsScreen: re-enabled the mini-icons next to each tool, which had
  been commented out ("don't fit visually"). Root cause: the screen's own
  drawIcon() centred against lineStep() (line height + inter-row gap)
  instead of getLineHeight() alone, 2px too generous for a near-full-
  height icon -- now delegates to the already-correct miniIconDraw() used
  elsewhere (e.g. the message-list ack checkmark). Also gave Admin and
  GPIO their own icons (padlock, 3-pin header) instead of both sharing
  System's cog.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 21:37:50 +02:00
JakubandClaude Sonnet 5 b6dce2b7f0 feat(ui): show repeater echo count instead of a checkmark on channel sends
The plain ✓ on your own channel post only said "at least one repeater
heard it" -- now it shows how many distinct repeaters echoed it back,
drawn as tiny 3x5 digit icons (icons.h) rather than the normal font,
since the slot next to the sender name is icon-sized, not text-row-
sized. DM delivery ticks are untouched (no repeater-count concept
there, so they keep the plain checkmark).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 20:45:53 +02:00
JakubandClaude Sonnet 5 ba3c3cc91f fix(mesh): don't mark our own channel post as unread
An app-originated channel send (mirrored into the on-device history)
bumped that channel's unread badge whenever the device's own UI
wasn't already showing that exact channel -- unlike an on-device
compose, which sidesteps this by forcing itself into that channel's
view right before sending. Adds an explicit own_message flag through
addChannelMsg (MessageHistory -> AbstractUITask -> UITask ->
MessagesScreen) so an own post is never counted unread regardless of
what's on screen when it's sent.

Found the same bug in MyMeshBot.h's three auto-reply-into-channel call
sites (Remote Bot's own reply showing as unread on itself) and fixed
those with the same mechanism.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 20:26:57 +02:00
JakubandClaude Sonnet 5 bdd2ed379d feat(mesh): show which repeaters relayed/confirmed a message's path
Extends the existing single-boolean channel relay-echo marker into a
full count + list of distinct confirming repeaters, since each
repeater retransmit already appends its own identity hash to the
packet's path and the echo-matching hash deliberately ignores that
mutable path -- so every distinct repeater's echo of one send now
matches the same tracking slot instead of only the first.

Symmetrically captures the hop path a received DM/channel message
actually took, so a new "Path"/"Relayed by" row in the existing
Hold-Enter Options popup can show the resolved sequence of repeaters
(by contact name, or a hex fallback for an unknown one).

Also fixes a real bug caught during testing: the popup row's own
label ("Path (N hops)"/"Relayed by (N)") was built into a stack-local
buffer handed to PopupMenu, which only stores the pointer -- it
rendered as garbage once the building function returned. Moved to a
persistent member buffer.

Bumps the dev-build fallback version and adds release notes/docs
for this plus the two other 1.27 features already on this branch
(BLE retry backoff, marquee-scroll for selected long text).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 18:04:06 +02:00
JakubandClaude Sonnet 5 389f3f7a36 feat(mesh): mirror app-originated DM/channel sends into on-device history
CMD_SEND_TXT_MSG and CMD_SEND_CHANNEL_TXT_MSG (the phone app's send path)
transmitted over the mesh but never touched the device's own MessagesScreen
history, unlike a message composed on-device (MessagesScreen::afterSend) --
so a DM/channel post sent from the app was invisible if that same
conversation was later opened on the device's own screen. Both handlers now
also call into the same history-store entry points incoming messages use.

Also wires up delivery-status parity with an on-device send, not just the
raw text:
- Channels: arms the existing "relayed into mesh" repeater-echo tracker
  (trackRelaySend()/armChannelRelay()) on the new entry -- sendGroupMessage
  already runs that tracker regardless of who originated the send, this
  just attaches it to the right history entry. Required threading a ring
  position back out through AbstractUITask::addChannelMsg (now returns int)
  and a new armChannelRelay() passthrough.
- DMs: addDMMsg gained ack_tag/ack_deadline_ms/resends params (threaded
  through MessageHistory -> MessagesScreen -> AbstractUITask/UITask) so an
  app-sent DM gets the same pending -> \xe2\x9c\x93/\xe2\x9c\x97 status the on-device compose
  path shows. resends stays 0 deliberately: the app owns its own retry
  decision, so this only drives the on-screen status, never a second,
  independent auto-resend from the device itself.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 17:35:13 +02:00
JakubandClaude Sonnet 5 1bb28296c2 feat(ui): marquee-scroll selected long names/labels instead of static ellipsis
Selecting a row whose ellipsized text overflows now animates a "swing"
marquee: holds at the start, scrolls to reveal the full tail, holds
there, then scrolls back and repeats. Unselected/non-overflowing text
is unchanged (still a static "..."). E-ink gets slower, coarser steps
(fewer, cheaper partial refreshes) than OLED; unchanged frames are
already skipped by the display's CRC diff, so idle holds are free.

Wired into every screen with a selectable row: home favourites, DM/
channel lists and message bodies, Settings, popup menus, Bot, Admin,
Nearby, Waypoints, Locator, Live Share, and the alarm screen.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 17:17:55 +02:00
JakubandClaude Sonnet 5 12cf81b13f fix(ble): back off BLE send retries instead of hammering a marginal link
At the edge of BLE range the phone repeatedly drops and reconnects, and
each queued outgoing frame's write can block the main loop up to 100ms
(Bluefruit's notify() waits on a free HVN packet slot). The fixed 250ms
retry throttle re-triggered that blocking wait constantly during a bad
link, making the device feel almost unresponsive. Retries now back off
exponentially (250ms -> 2s cap) on repeated failure and reset on the
next successful send.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 15:39:57 +02:00
JakubandClaude Sonnet 5 fe0093d07b merge: sync with upstream/main (companion-v1.17.1 + FAQ wipe/reset fix)
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
v1.26
2026-08-30 13:31:49 +02:00
JakubandClaude Sonnet 5 7151af044a docs: add release-notes bullet for the 1.17.1 splash-screen version fix
Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-30 13:30:08 +02:00
JakubandClaude Sonnet 5 5933ff3178 fix(version): splash screen showed 1.17, not the actual 1.17.1 upstream base
release-notes.md's v1.25 section already documents "Updated upstream
base to companion-v1.17.1", and that merge (68527e7b) is confirmed in
main's history -- but every MESHCORE_VERSION string, including
UITask.cpp's fallback default for boards that don't set it explicitly
(Heltec v3/v4, ThinkNode, Mesh Pocket, T-Echo), was still hardcoded to
the pre-bump "1.17". Bumped every occurrence to "1.17.1" to match what
actually shipped.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 19:23:08 +02:00
JakubandClaude Sonnet 5 5323cd9e6b merge: 1.26 into main
Scope/repeater-scope filtering, magnetic Hall-sensor screen lock,
solo build configs restructured into their own solo/<board>/ folder
(one _solo_dual build per board), ProMicro + CardKB support (PR #31,
tchellow), new Build Flags reference doc, book-order fullscreen message
paging, and a confirmed "Start OTA" admin action -- plus a full
pre-merge documentation audit.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 19:06:58 +02:00
JakubandClaude Sonnet 5 9e90758900 docs: fix pre-merge audit gaps (missing boards, Ext. KB row)
Full documentation audit before merging 1.26 into main turned up:
- README's Supported Devices table was missing GAT562 Mesh Watch13
  (a CI-built, shipping firmware with zero end-user docs -- pre-existing
  gap, not introduced by this branch) and ProMicro (added to the build
  table by an earlier commit but never to the device list up top).
  Building-from-source's env table was also missing Watch13.
- settings_screen.md's Keyboard table never documented the Ext. KB
  (Full/Compact) setting, despite external_keyboard.md already
  describing it in detail.
- nrf52_power_management.md's board-support table only listed 5 of the
  13 boards that actually have a PowerMgtConfig implementation wired up
  (grep-verified against every variants/*/*.cpp defining `power_config`)
  -- added the other 8, and fixed one board's listed name (RAK 3401,
  not "RAK WisMesh Tag") to match its actual getManufacturerName().

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 19:02:22 +02:00
JakubandClaude Sonnet 5 7d09210b9c feat(admin): add confirmed "Start OTA" action for remote nodes
start ota was already sendable via Admin's Custom-command row (and
CLI-reachable directly), but had no dedicated menu entry. Adds a row to
the Actions tab that confirms first (Start/Cancel, defaulting to
Cancel) before sending -- unlike Reboot, OTA parks the remote in BLE
DFU mode for the duration of the update, disruptive enough to warrant
the extra step.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 18:52:32 +02:00
JakubandClaude Sonnet 5 77f4ac48d6 docs: credit tchellow in README Contributors
PR #31 (ProMicro CardKB support) landed a few commits back but the
Contributors list was never updated.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 18:44:12 +02:00
JakubandClaude Sonnet 5 433548dfee docs: list ProMicro solo build, document CARDKB_I2C, update release notes
- README's env table and external_keyboard.md's device-support table both
  get a ProMicro row -- missed when the PR #31 merge landed since neither
  was in scope for that commit.
- external_keyboard.md and build_flags.md now cover CARDKB_I2C alongside
  ENV_PIN_SDA/ENV_PIN_SCL: the PR generalised CardKB bus selection to a
  single macro after build_flags.md was first written, so the doc only had
  the older (still valid, but no longer the only) form.
- release-notes.md: added the ProMicro solo build and the new Build Flags
  reference page to v1.26's What's New.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 10:24:44 +02:00
JakubandClaude Sonnet 5 f952bf237f chore(solo): move PR #31's new ProMicro solo env into solo/promicro/
Merged after the fact, so it followed the old convention (solo env inside
variants/promicro/platformio.ini alongside the shared board configs). Moved
to match every other board post-restructuring -- extends still points at
Promicro, defined in variants/promicro/platformio.ini.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-29 10:22:03 +02:00
Jakub ca1192c491 merge: PR #31 (CardKB via shared I2C bus for ProMicro) into 1.26 2026-08-29 10:14:15 +02:00
tchellow 8fdb03bd9a Rebase onto main, move CARDKB_I2C out of class body, resolve via platformio.ini 2026-08-28 10:55:52 -03:00
JakubandClaude Sonnet 5 b71b46fd84 fix(ui): debounce the Hall sensor poll against reed-switch contact bounce
pollHallSensor() acted on the raw pin reading immediately, unlike every other
physical-input path in this file (MomentaryButton, pollCardKB()'s own
last-raw edge check). A cheap mechanical reed switch -- one of the two
sensor types the docs explicitly recommend wiring here, alongside a
solid-state Hall IC -- can chatter for a few ms while the magnet crosses the
trigger distance, so a poll every loop() tick during that window could flip
_locked and fire _display->turnOff()/turnOn() repeatedly in that short span:
wasted work on any panel, and a real cost on e-ink where each is a slow
full-panel operation.

A raw reading now has to hold steady for HALL_DEBOUNCE_MS (25ms, same
threshold as MomentaryButton's ISR_DEBOUNCE_MS) before it replaces
_hall_magnet_present and triggers the lock/unlock actions.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-27 10:22:50 +02:00
JakubandClaude Sonnet 5 a389a733d7 refactor(solo): move solo build configs into their own solo/ folder; one build per board; document all build flags
Solo's `_solo_dual` env for each board lived inside variants/<board>/, mixed
in with the shared upstream board configs (repeater, room server, plain
companion) that every MeshCore fork carries. Split them out into their own
top-level solo/<board>/ folder -- each still `extends` the board base defined
in its original variants/<board>/platformio.ini, just no longer interleaved
with it file-wise.

- platformio.ini: extra_configs picks up solo/*/platformio.ini alongside
  variants/*/platformio.ini.
- build-solo-firmwares.yml: env-discovery grep now scans solo/ instead of
  variants/ (the release matrix is unchanged -- same 8 envs, same names).
- pr-build-check.yml: solo/** added to the trigger paths.
- GAT562 30S Mesh Kit: dropped the separate solo_ble env -- solo_dual is a
  strict superset (BLE still works, plus USB), and every other board only
  ever had one solo build to begin with.
- GAT562 Mesh Watch13: renamed solo_ble -> solo_dual (added DUAL_SERIAL=1) to
  match. No comment anywhere recorded whether this board's USB data lines
  are actually broken out to a connector -- DUAL_SERIAL compiles and works
  over BLE regardless, so worst case the USB half goes unused.
- Removed a dead AUTO_SHUTDOWN_MILLIVOLTS from the three solo envs that set
  it (Heltec V3/V4, T-Echo Lite+KeyShield): that macro is only ever read in
  the old ui-tiny UITask, never ui-new, which every solo build (these
  included) uses -- it did nothing on any of them. Left alone everywhere
  else it's set (non-solo companion envs elsewhere use ui-tiny/ui-orig, or
  the flag is legitimately read); out of scope here.
- Added docs/solo_features/build_flags.md: every optional -D flag a solo
  build understands (GPIO, CardKB/joystick, Hall-sensor cover lock, buzzer/
  vibration, GPS switch, display/battery tuning), verified against the code
  rather than the existing per-board comments, with what's already baked
  into every solo build kept separate from what's opt-in.
- README: doc index + Building from source section link to the new page;
  path references to the moved solo files updated to solo/<board>/.

All 8 solo_dual envs rebuilt clean after the move; native test suite (40
cases) unaffected.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-27 00:49:37 +02:00
JakubandClaude Sonnet 5 58e6bfcec5 feat(ui): optional magnetic flip-cover screen lock via user-wired Hall sensor
No board in this repo has one built in, and no default pin is assumed
anywhere -- whoever wires a Hall-effect or reed sensor to a free GPIO sets
PIN_HALL_SENSOR (and HALL_ACTIVE_HIGH, for a sensor that pulls the pin high
rather than low on presence) as a build_flag on their own env. Entirely
opt-in and a no-op elsewhere, same pattern as PIN_GPIO1..4/ADC_MULTIPLIER/
CARDKB_ENABLE.

Level-triggered polling (like pollCardKB()) rather than an edge interrupt --
a magnet held near the sensor reads the same way every tick, so the new
pollHallSensor() only acts on the two transitions. Closing locks and blanks
the display with no wake grace (the cover is physically over the screen, so
there's nothing to show); opening unlocks and wakes it, with no key combo
either way. Both are independent of the Auto-lock setting, which is a
timeout, not a physical event.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-26 13:48:33 +02:00
JakubandClaude Opus 5 13fb4a189f feat(ui): page the fullscreen message view in reading order
LEFT went to the newer message and RIGHT to the older one, which reads
backwards against the page metaphor the "<" / ">" markers set up. Swap it:
LEFT turns back to the older message, RIGHT forward to the newer one, and
the markers follow (they were keyed to the opposite flags).

PREV/NEXT are named in message order, not screen order -- MessagesScreen's
_hist_sel counts newest-first, so PREV is the older message -- so only the
key mapping and the two marker conditions change; the caller side is
untouched. Applies to both the DM and channel fullscreen views, which share
handleInput(). AdminScreen's reply view treats every non-NONE result as
"close", so it is unaffected.

Docs and release notes updated to match.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-24 12:13:41 +02:00
Liam CottleandGitHub 0679dbeffc Merge pull request #3282 from recrof/patch-3
FAQ: Fixed instructions on wiping and resetting nrf52 devices
2026-08-24 19:49:40 +12:00
tchellow 55203c2ddd Add CardKB support for ProMicro via shared I2C bus 2026-08-23 21:44:17 -03:00
Rastislav VysokyandGitHub acac4af3ec FAQ: Fixed instructions on wiping and resetting nrf52 devices 2026-08-23 20:13:12 +02:00
JakubandClaude Opus 5 51c06b78c1 fix(companion): prefs schema corruption, broken multi-scope, stale relay filter, cursor row
Follow-up review of f589b9b2 -- five defects in that commit's own changes.

- repeat_scope_only + repeat_extra_scopes were read/written in the MIDDLE of
  the prefs stream, beside their repeat_* siblings. loadPrefsInt()'s rd() is a
  plain sequential reader gated only on file.available(), with no per-field
  versioning, so on any pre-existing file those 25 bytes were taken from the
  fields that follow, shifting EVERY later field: repeater profile (incl. a
  float freq), track_shared_loc, all of loc_share_*, trail, bot, GPIO modes.
  Moved to the struct/file tail, sentinel bumped to 0xC0DE0027 with 0xC0DE0026
  marked burned. sizeof stays 2752 (confirmed by build); the tripwire procedure
  now spells out the append-only rule that "in struct order" left implicit.
- rebuildRepeatScopes() called getAutoKeyFor() with id 0 for every entry, but
  that cache is keyed on the id alone and ignores the name on a hit -- so every
  extra scope after the first silently got the first one's key, making the
  comma-separated list do nothing. Distinct id per scope now.
- interference_threshold had no load clamp, so an upgrader read 0x23 (35) out
  of the old file's sentinel tail instead of 0.
- CMD_SET_DEFAULT_FLOOD_SCOPE wrote default_scope_key without rebuilding the
  relay filter, so setting or clearing the scope from the app left the repeater
  filtering on the previous key until reboot. The on-device path already did.
- The keyboard preview derived the cursor's row a second time from byte
  offsets, disagreeing with the cursor_line the scroll window already computes:
  it pinned the cursor to the end of a full line (drawing '_' one character
  past the display width) at every wrap boundary. Use cursor_line directly.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-21 11:02:05 +02:00
JakubandClaude Sonnet 5 f589b9b2d1 feat(companion): on-device scope + repeater scope filtering; fix CAD, UTF-8 truncation, Public channel, Nodes list, keyboard cursor
- Settings > Radio > Scope: type a community/region name on-device (derives
  the shared key the same "#name" -> SHA256 way as DEFAULT_FLOOD_SCOPE_NAME),
  previously only settable from a connected app.
- Tools > Repeater > Scope only + Extra scopes: only relay flood traffic
  matching the device's own scope or a comma-separated list of additional
  scopes, without changing what scope the device's own messages send under.
  No-op while unconfigured.
- getCADEnabled()/getInterferenceThreshold() were hardcoded off on
  companion_radio; CAD now auto-enables whenever RX power-save (duty-cycle)
  is active, since the noise floor isn't kept fresh during duty-cycle sleep.
- Message truncation to fit the send frame could split a multi-byte UTF-8
  character in half; now stops at the last complete character.
- The default "Public" channel was unconditionally re-added at every boot
  before the saved channel list was loaded, so deleting it never stuck.
  Only seeded now on a genuinely fresh device (no channel file yet).
- Tools > Nodes read contacts from the wrong starting offset, landing on
  internally-reserved bookkeeping slots instead of real contacts -- showed
  as blank "Unknown" rows and silently dropped that many real contacts off
  the end of the list.
- resetContacts() only cleared the first few reserved slots, not the whole
  contact table, contrary to its own comment; only reachable today via
  private-key import, fixed to match stated intent regardless.
- Keyboard's multi-line text preview could render the cursor on an empty
  line below short typed text instead of right after it.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-21 10:40:50 +02:00
MarekZegare4 7e10e0359c docs: bump release notes to companion-v1.17.1 upstream base v1.25 2026-08-14 16:20:53 +02:00
MarekZegare4 3d2ba72b17 fix(test): add missing Arduino.h include in ported companion NodePrefs test
Upstream's version transitively pulls Stream in via NodePrefs.h ->
ConfigSerializer.h -> Arduino.h. Our fork's companion NodePrefs.h is a
plain, manually-serialized struct (no ConfigSerializer), so that chain
doesn't exist here and Stream was undeclared. Include it directly,
matching every other file in this codebase that needs Stream.

The test body itself stays #if 0 (upstream: "cannot be set yet"), so
this only fixes the build, not test coverage.
2026-08-14 16:19:14 +02:00
MarekZegare4 68527e7ba0 Merge upstream companion-v1.17.1 into power-saving
Pulls in real fixes: scoped-reply routing, RX boosted-gain restored
correctly after AGC reset, T-Echo Lite/Card SPI pin corrections
(unused pins now map to NRFX_SPIM_PIN_NOT_USED via 0 instead of -1)
and TCXO voltage fix, Heltec T096/T1 and MeshPocket pin fixes,
T-beam Supreme S3 display fix, LR2021 preamble/IRQ timeout handling.

None of the touched variants overlap with our active Heltec V3/V4,
Cardputer ADV, GAT562, or WioTracker builds.

# Conflicts:
#	examples/companion_radio/MyMesh.cpp
#	examples/companion_radio/MyMesh.h
#	examples/companion_radio/NodePrefs.h
#	src/helpers/radiolib/CustomSX1262Wrapper.h
#	src/helpers/radiolib/RadioLibWrappers.cpp
#	src/helpers/ui/SH1106Display.cpp
#	variants/lilygo_techo_lite/platformio.ini
#	variants/lilygo_techo_lite/variant.h
2026-08-14 15:58:23 +02:00
Scott Powell d929643524 * version 1.17.1 2026-08-14 22:19:19 +10:00
Huw DuddyandGitHub 24bdc24b39 Merge pull request #3206 from meshcore-dev/nrf-combine-rng-entropy
combine radio's entropy with CC310 RNG
2026-08-14 22:09:26 +10:00
MarekZegare4 fc92dd8ea6 fix(heltec): drop broken -U/-D pin override, real build was failing
PlatformIO's SCons flag processing mishandles a two-token "-U MACRO"
in build_flags: it drops the macro name and leaves a bare -U that
swallows the next flag (-Iinclude) as its argument, producing
"macro names must be identifiers" for every companion_radio source
file. The -U was unnecessary anyway -- this whole project builds
with -w, so a later -D silently wins with no warning to suppress.

Verified with a real pio build (not available earlier this session):
Heltec_v3/v4, Cardputer ADV, and T-Echo Lite KeyShield solo envs all
compile clean now.
2026-08-14 11:21:16 +02:00
Scott Powell fcb9bdf209 * combine radio's entropy with CC310 RNG 2026-08-14 17:46:43 +10:00
Huw DuddyandGitHub 50a51a6479 Merge pull request #3203 from meshcore-dev/companion-fem-pref-fix
commenting out the load/save of the fem_ properties
2026-08-14 16:44:59 +10:00
Scott Powell e78bff0041 * unit test no longer valid 2026-08-14 16:42:54 +10:00
Scott Powell 890a2e2cff * commenting out the load/save of the fem_ properties, until they can be set 2026-08-14 16:30:12 +10:00
MarekZegare4 64d4b2982b fix(ui): wake display on T-Echo KeyShield Home key, drop dead code
Home key toggles the keyboard backlight but wasn't going through
checkDisplayOn() like every other TCA8418 key, so it couldn't wake a
sleeping display or extend the auto-off timer.

Also: removed a no-op #elif branch in ST7789Display.cpp (same values as
the #else it duplicated), and ENABLE_SCREENSHOT on the Cardputer ADV
solo env, which does nothing since ST7789Display has no getBuffer().
2026-08-14 01:07:06 +02:00
MarekZegare4 55cb5d25d3 fix(gps): hold GPS awake during waypoint nav/avg/track-back and message-location navigate
These views run the same live bearing/distance readout as Compass/Nearby's
navigate mode, which already held GPS awake -- these three didn't, so
duty-cycling could leave them stuck on a stale fix until the next scheduled
wake (up to the configured sleep interval).
2026-08-14 00:40:50 +02:00
ripplebizandGitHub b09cb27a1f Merge pull request #3106 from ViezeVingertjes/fix/scoped-reply-routing
Fix replies dropped when flood.max.unscoped is low
2026-08-13 15:00:37 +10:00
ripplebizandGitHub abd3546d75 Merge pull request #3189 from oltaco/nrf52-unused-pin-sweep
Fix unused pin definitions on some NRF52 boards
2026-08-13 13:48:59 +10:00
MarekZegare4 cc591e8cee chore: bump dev-fallback version to v1.25-dev, fix stale comment casing 2026-08-12 23:58:03 +02:00
MarekZegare4andClaude Sonnet 5 b572c0ba57 docs: trim wording across README and solo_features docs
Cut restated points, hedge phrases and over-explained asides throughout
-- same information, fewer words per sentence. Also fixed a stale gap
in README's "Building from source" env table (Cardputer ADV and
T-Echo Lite + KeyShield were missing).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-12 23:51:22 +02:00
MarekZegare4andClaude Sonnet 5 3290fa2f57 fix(heltec): joystick press drives Enter, PRG becomes Back
Swaps which physical input plays which role on the Heltec V3/V4 wired
joystick: the stick's own fifth "press" contact now drives Enter (your
thumb's already on the stick when you'd confirm something), and the
onboard PRG button -- previously Enter -- becomes Back instead, so it
no longer needs a separate wired button of its own.

Pure pin reassignment in the solo_dual envs, no UITask.cpp changes:
PIN_USER_BTN (Enter) is undef'd and redefined from the base env's PRG
default to the joystick's press pin, and PIN_BACK_BTN takes PRG's old
GPIO0. Scoped to just these two envs -- Wio Tracker L1/GAT562/MeshTiny
share the same UI_HAS_JOYSTICK code path with PRG already correctly
wired as their one true physical button, so their behaviour is
untouched.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-12 23:36:34 +02:00
MarekZegare4andClaude Sonnet 5 e47233f557 docs: finish syncing OFF/ON casing into the solo docs
Follow-up to the UI casing unification -- the docs quoting these same
option values (Settings' Auto-lock/Buzzer/Full refresh/Low battery/GPS
pwr/Resend rows, Tools' Auto-pause/Mark avg/Auto-save/Auto-Advert/
Heartbeat/GPIO rows, and the clock alarm's Repeat cycle) still showed
the old lowercase/Title-case spellings the screens themselves no
longer use.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-12 23:23:00 +02:00