Conflicts resolved by keeping both sides:
docs/cli/README.md, docs/guide/features.md (parts/reactions + relay mark)
meshterm/core/preferences.py (reaction_emoji, message_parts_max + heard_wait_s)
meshterm/services/chat_service.py (reaction check + upstream mute/listed split)
meshterm/ui/chat.py (reaction count + relay mark in the render cache;
each sent part is tracked for the relay mark)
meshterm/ui/tui/session.py: upstream's "e": "reveal" is kept, and the
chat screen takes "reveal" as react, so ^E still reacts in the chat.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_0174TBnQH8S3nYNaxo5zk9Yu
Until MeshTerm connects, nothing can say which LoRa Cap is on a
Cardputer Zero. A radio on the SPI bus answers nothing until the node
runs on it, and the list probes nothing on purpose: a radio is in it
exactly when there is a device file to open. A probe would have to
power the header on every pass of the device screen, and it still could
not tell the older Cap from an empty header, because that answer comes
from the radio itself.
So the row names the slot. It reads "Cap LoRa", the family of the two
boards, in place of a claim that the newer one is attached.
The node names the board. It is the one part that sees which revision
answered, so the parent sends it the model of each revision and the
node reports the one that it found. The rest of the path was already
there: the frame server gives that model to the client, the store keeps
it beside the node name, and the hardware column of the device screen
shows it. A Cap is exact from its first connection onward, with no
probing, no power to the header for a listing, and no new permissions.
board_name is gone. Its one caller wanted the model, which board_models
answers now, and the row takes its name from the table as it always
did.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Making the expander optional took a sentence away from the user. A
Cardputer Zero with no Cap at all reaches the radio library now, where
before it stopped at the expander. The library then said "Something
went wrong, check your wiring", and MeshTerm passed that on.
A board whose expander did not answer is the one place where nothing
has answered anywhere yet. There, a radio that does not start is a
radio that is not attached, and the user reads that instead. The words
of the library stay in the log. A busy line keeps its own kind, because
a line that another program holds has its own correction.
The three ways of finding out that no radio is there (the chip did not
start, it did not answer a register read, it answered as something
else) now give the user one sentence. The log keeps which of the three
it was.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
A user on a Cardputer Zero could not connect his Cap. MeshTerm stopped
at "nothing answers at 0x43 on /dev/i2c-1". His Cap is the Cap LoRa868,
which M5Stack made before the Cap LoRa-1262. The two boards carry the
same SX1262 on the same pins of the same header, and the same GNSS at
the same speed. The newer board adds an antenna switch, and the chip at
0x43 that turns the switch on. The older board has no switch, so it has
no such chip. MeshTerm asked for one on every Cardputer Zero.
A wiring now says whether its expander is required. pi4io_required is
true by default, so every other board keeps the rule that an expander
which does not answer is an absent board. The Cap sets it to false.
An absent expander is then the other revision of the board, and the
node must prove that before it accepts it. After the radio starts, the
node reads the version register of the chip and requires the name of an
SX126x. A bus with nothing on it reads as all ones or all zeros, and
the library can start on such a bus, so a Cap that is absent or badly
seated still reports that no radio answered.
The read of the expander also tells its failures apart now. Only the
errors that mean "nobody is at this address" count as absent. A bus
error or a refused read is a failure of its own, and never becomes the
older board quietly.
The two boards come from M5Stack's own pages, and from two other
Cardputer Zero applications that drive both. The pins, the TCXO, and
DIO2 are the same everywhere, and they agree with the wiring MeshTerm
already had.
One thing is open. The device screen names the row "Cap LoRa-1262"
before anything is connected, because nothing can know which Cap is
attached until the node runs.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
The page had drifted behind the firmware. Three statistics frames arrive
at each open and the panel drew nine rows from them, so the outbound
queue, the firmware error count, and the split of the packet counters
into flood and direct were read and thrown away. The device-query frame
carries the companion protocol version and the contact and channel
capacities, and nothing in MeshTerm had ever asked for them. The
default flood scope was one row named Flood scope, between the two
auto-add rows, with no key beside it. The key of the node itself was
nowhere on the page.
The panel now has four groups, in the order a user asks them in. What
the node is: role, public key with the routed bytes lit, model,
firmware with the protocol version, and place. What MeshTerm does with
it: the scope and the transport key of that scope, the active site with
the outbound paths and kept device routes that apply, and the name of
the radio preset. How it is doing: battery, storage, its own sensor
readings, the clock with its drift, uptime, contacts and channels
against the capacities, the queue, and the errors. What it heard and
sent: the noise floor, the airtime, and the packet counts, split.
A node with no scope says that its floods reach everyone, because an
empty value there is a statement and not an absence. A node whose
stored scope key is not the key of its own name says so in amber: a
flood under that key reaches no repeater that listens for the name, and
nothing else in MeshTerm could show it.
The rows sit in a two-column grid, so a value wider than the panel
wraps under its own column instead of going back to the left edge, and
a 64-digit key stays whole. The gallery draws the panel now, so both
platforms hold it to their readable width.
Two new device reads, both optional and both answered by any firmware:
the scope frame read for its key as well as its name, and the sensor
readings of the node itself, which MeshTerm had never asked any device
for. The device-query frame is no longer read twice at each open, since
the snapshot already merges it.
The scripted face answers with the same three parts: the status, the
readings, and every setting. The settings come from the one definition
that config show answers with, under the keys config get and config set
take, so the two faces cannot drift and no setting is spelled two ways.
Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
A mention in a DM plays the DM sound. The sound keys of this unpushed
work are not retired: they never left this machine.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The first build counted only the relays past the first hops of the
outbound paths. On JP's Public channel, 23 of 23 sent messages came back
only through the two home repeaters: each repeater relays one time, and
the next hop (8 km away) is too far for the companion to hear. So every
message showed the warning mark, and nothing was ever confirmed.
Now each repeater that sends a copy back counts, the same as a DM ack:
spinner, then a check with the number of repeaters, or a cross. The
warning state, the near-relay snapshot of each send, the ^P atom, and
heard_via are removed. heard_relays keeps only the paths; a database with
the first build of the table gets it made again (derived data only).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A channel has no acknowledgement, but the radio hears each repeater that
relays our message, and each copy names the relays that it went through.
The end of our channel message now shows a spinner, then a check and the
number of relays past the near relays (the first hops of the outbound
paths that apply), a warning when only the near relays sent it back, or a
cross when no relay did. A near relay is near by identity, at any place
in a path. Managed nodes play no part: a remote managed repeater counts.
- services/heard_by.py: the verdict, and a tracker that fills in the
background and refreshes on each channel packet. Settled verdicts are
stored (schema 24, heard_relays), with the near relays of each send.
- The picked message names the relays and the near relay that carried it.
- ^P counts the relays past the near relays.
- chat history --channel: a HEARD lane; --json gives heard, heard_by,
heard_via.
- New preference heard_wait_s (Relay wait, 30 s).
- Fix: a copy of our own channel message must carry the time of that
send, so two messages with the same text no longer share copies.
Closes#38
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A message whose body is an MCOimg image (im3:, or im: for v1/v2) now reads
"🎨 image · 24×24 · 16 colours" in the transcript and the Messages preview.
The v3 header gives the size and the palette; the pixels are not decoded yet.
The Base91 text no longer makes false mention chips, links, or QR codes.
Checked against all 51 reference vectors. Refs #37.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A companion, a room server, or a sensor does not relay a trace with the
firmware defaults (allowPacketForward in Mesh.cpp: client repeat is off,
and allowed only on 433.000, 869.495, and 918.000 MHz; disable_fwd is on).
A walk that turned at one of them never came home: the history held 36
companion traces and no reply from a real one.
The route to such a node is the same. Only the walk changes: it turns at
the last relay of the route, and the node is not in the spec. The route
out of a walk that comes home is still the full route to the node, so
the Device route row can offer it for DMs and admin.
- relays_traces() in models states the rule. render_forced_spec takes
relays=False, and forced_outbound reads the route back from a walk.
- services/trace_plan holds the route choice that the trace screen made
inline (radio route, outbound paths, best observed, last trace,
direct), so the CLI uses the same one.
- The trace screen names the relay where the walk turns, in a line under
the route. With no relay to turn at, Trace is dim. A neighbour that
does not relay gets "no relays" offered on the Device route row, with
the packets heard directly as its proof.
- The trace session turns a caller's spec (node page, Message paths) at
the last relay, so the callers do not need the rule. A sender that is
not a contact gets its type from its stored adverts.
- The composer and Explore paths turn the walk at the last hop.
- `meshterm trace -t NAME` with no --path walks the menu's route and says
on stderr where it turns. With no known relay, it is a usage error.
- The connection turns a device-routed trace at the last learned relay.
The simulator now stops a walk at a node that does not relay, as the
mesh does, and the tests that walked through Alice walk repeaters.
The picker keeps one list with no mark, sorted as before (JP's choice).
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Enter on an arrival in the Message paths dialog (^P in a chat) opens a trace
of the route that the row draws, walked from our node:
- A received message is traced back to its sender: the relays in reverse,
out to the sender, and back on the mirror (Trace target).
- A sent direct message is traced out to its recipient on the relays in
order (Trace target).
- A sent channel message came back to our node, so its relays are the full
walk (Trace path).
- A sender with no key turns the trace at the first relay (Trace path).
- A direct-routed copy carries only the rest of its route, so it offers no
trace, and the hint does not show Enter there.
The trace screen opens idle and armed. Nothing transmits until the user
starts a trace. The dialog stays pushed under it as a hub, so Esc from the
trace comes back to the same dialog and highlight. In Trace target, a trace
that comes home lights the Device route row, so the route a message took can
become the radio's route to that contact.
A sender that is not a contact opens on its key, and open_trace takes a
label so that the screen shows its name instead of the hex.
Refs: #34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Explore paths → Probe all walks each candidate once. When the user adopts a
candidate, that trace already measured exactly the adopted route, so the
screen now starts the route with it instead of with no traces. The Device
route row then offers a route that came home at once, with no second
transmission to prove it again.
The session keeps the probe traces by spec (seed_traces). Any later change to
a probed spec starts with them too, because they measured that route.
Refs: #34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Trace target gets a Device route row after Explore paths, for a target that
the radio has as a contact. It says what the radio holds now, and Enter opens
the node page's Device route popup.
A trace that came home walked its route out and back, the best proof that
MeshTerm can have for a route. When its route out is not the radio's route,
the row turns green: "Use this route for DMs and admin — 4/5 came home…".
Nothing interrupts the session. The popup then shows the traced route with
its proof, and offers "Use the traced route" and, with a site, "Use and keep
it" before the usual rows. The popup changes no path of the trace screen, so
its traces and medians stay.
The gallery's Trace specimen draws the green row at both widths, and the
features guide says what it does.
Refs: #34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The Routes tab ends on a "Device route · …" row that says what the radio
holds now: none (it floods), or the hop count and how the radio got it
(learned, set by you, kept at a site). Enter opens one popup that turns its
page:
- The first page draws the route and the kept route (with why a kept route is
not in the radio: its first hop went silent), then the actions: Set the
route…, Keep this route (or Stop keeping it), Forget the route, Discover
routes…. With no site, Keep says that it needs one and opens Outbound paths.
- Set the route… turns to a picker: the suggested route first (an outbound
path, then the best way on), the routes heard, no relays, and Compose…, which
opens the path composer. A picked route replaces a kept route too.
- Discover routes… waits for the cooldown, sends one path discovery, and shows
the route each way. "Use this route" sets the route out.
After a change, the Routes tab is drawn again in place, with the highlight on
the row. Gallery specimens for both pages, and the glossary and features guide
name device, kept, and saved routes and path discovery.
Refs: #34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
meshterm route works on the route that the radio holds to each contact,
with a plain face and a --json face. It has no menu row: the menu works
on a route from the node page of the contact.
- list and show: the spec, the origin (kept, set, learned, flood), the
kept spec, where it is kept (site or fixed device), the drawn route
from our node to the contact, and a kept route skipped because its
first hop is silent.
- set (--keep), forget (--yes), keep, unkeep: each prints the route as
it is afterwards. keep without a site fails with exit 1 and names
meshterm outbound use.
- discover (--use): one path discovery, the route each way.
- sync: the reconcile of the connection, with its counts.
Refs: #34
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The user names the ways out of their node, one or more hops long, in order.
Each site of this computer (Home, Foulab) has its own list, one site is
active, and a fixed device keeps its own list.
- Explore > Outbound paths: the sites with the active mark, the fixed
devices, and a staged editor for each list. Each path shows how well its
first hop hears us (out) and how well we hear it (in). Measure sends one
trace out along a path and back, after the cooldown.
- The path composer has an outbound mode, and puts the active paths first
while the insertion slot is at our node (trace target, trace path, the
TX sweep route).
- MeshTopology.outbound_scenarios: one route through each path. It scores
from the link after the path, lets the user's order win a near tie, and
skips a path whose first hop was silent for outbound_silent_hours. These
routes lead Explore paths, the node page's Routes tab, and the trace auto
route, ahead of a device route that starts on another hop.
- A first link out of our node is scored from what the far end measured,
when a trace gave such readings.
- The site suggestion: when the radio hears the first hop of another site
three times, the main menu asks to use that site and says what it heard.
"Never suggest" sets the new suggest_site preference off.
- CLI: meshterm outbound [show|sites|use|set|remove|fix|unfix], plain and
--json.
Refs: #35
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
core/outbound_store.py keeps, in outbound.json, the sites of this computer
with their outbound paths in order, the active site, and the fixed devices
with their own paths. lookup() gives the fixed device's paths, else the
active site's, else none. The glossary gains outbound path, site, and fixed
device.
Refs: #35
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
The reporter of #28 asked for a way to clear one or all of the stored admin
passwords. Del in the node picker forgets one. This adds the other: a
"Forget passwords" row in the Managed nodes section of the menu, behind the
red typed confirm (type FORGET), which names the nodes it will forget. It
also forgets the password of a node that is no longer a contact, which no
list shows. With nothing stored, it says so and asks nothing.
On the CLI it is `forget-admin-passwords --yes`: without --yes it is a usage
error, and with it the answer lists the nodes it forgot (NAME, LAST_LOGIN,
KEY). It exits 5 when nothing was stored, and works with no device.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A script cannot get the "New password…" offer of the menu. When a saved password
gets no reply, `repeater-admin` and `tx-optimize` now say that the password may
have changed, because a node does not answer a wrong password, and that a new run
with --password repairs it: a password that the node accepts replaces the saved
one. With an explicit --password, the error says only that it can be wrong (#28).
The CLI manual describes both cases.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The menu had no way to make MeshTerm forget an admin password (#28). Now Del on a
managed node in the node picker asks first (amber, Cancel or Forget), then forgets
the password. The list refreshes in place: the node leaves "Managed nodes" and the
highlight stays on it. The footer shows "Del forget" only on a managed row, and the
PicoCalc lane shows its Delete chip.
The first page of the TX optimize dialog has the same rows, so it takes the same
Del. A wizard page can now carry a Del key and an on_delete handler, and a turned
page brings its own Del key, so the second page shows none.
The feature guide also describes the new-password offer of the previous commit.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The CLI sorts on the same ring as the Contacts screen (name, heard, packets,
place, hash). The ring moved to ui/widgets.py so the CLI loads no TUI code, and
ordered_contacts sorts by place (no place last) and by key.
The Archived list reads NAME · ARCHIVED · PLACE · KEY, sorts by place, cuts no
value and pans with ←→, like the Contacts list. The place fill and its live
refresh moved from ContactsScreen into ContactListScreen, so any list that
declares the PLACE lane gets them from places=.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
fields.node adds place (null when unknown) to its machine object, and the plain
face gets a PLACE column before KEY. The command reads stored places only.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A background job finds the place of each node that advertises a location
(Villeray, Montréal; a village; a peak near its summit). The map tiles give
the first answer offline; Nominatim corrects it when online (place_source,
default tiles then Nominatim; nominatim_url). Places are stored in the new
node_places table, a typed place in places.json wins over a found one.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
"Sync their clocks…" now opens a dialog that lists every managed
repeater and room from the start: ○ waiting, a spinner with what it
waits for (the transmit cooldown, the login, the command), then ✓ with
the node's reply or a red ✗ with the reason. Long reasons wrap under
the name. Esc stops the run after the node in progress; the OK chip
closes the dialog once the run is done.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
The bulk row now shows whenever the page has a managed repeater or room
server, and it syncs each one whatever its offset: a repeater with no
battery restarts from its build date at each power cycle, and the page
only learns that at its next advert. Managed companions still have no
clock sync command, so they are never included.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
The Managed nodes section ends on "Sync their clocks…" when a managed
repeater or room server is out of sync or has no sample. One confirm,
then each node in turn: a cancellable transmit-cooldown wait, a quiet
login with its stored password, and "clock sync"; one summary names
each result. "Adverts refused" moves to the end of the page.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
"All clocks" now opens the page, so the shape of every clock comes
before the lists of single nodes; Managed nodes is the first list under
it, then Adverts refused, Out of sync, and Senders with no key.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A room stamps posts with its own clock and sends only posts newer than
the companion's sync_since, so after its clock goes back (often a
reboot) it sends nothing new. When a room's newest stored post is later
than its clock now (from its clock offset), its node page shows
"posts blocked" and offers "Ask for all its posts again…". The repair
removes the room contact and adds the same raw record back, since the
firmware gives only a new contact a sync_since of zero, then logs in
with the stored password. Device.reset_room_sync tries the add twice and
says plainly if the room is left off the device.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A node whose admin password MeshTerm stores is now a "managed node": a
🔑 beside the type mark in the Contacts list, the admin picker (its
first section, renamed from "Remembered admins"), and the node page
header. The menu's "Other nodes" section is now "Managed nodes".
Contacts carry adverts_refused_until: the device's stored advert time
when it is in the future, so the firmware's replay check drops every
new advert. The node page shows it and offers "Accept its adverts
again…", which rewrites the device's own record with only last_advert
lowered (Device.accept_adverts_again). A managed repeater or room gets
"Sync its clock…". The Clock drift page lists refused contacts.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Managed nodes are now the first section and are always listed: a node
with no sample in the window shows its newest offset from all history,
or "no sample". Each table has a header line under its section heading
(NAME / OFFSET / LAST, and OFFSET / # over the histogram, now under
"All clocks"). Older offsets do not count in the histogram or title.
The CLI lists each managed node too, with null fields when it has none.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A new Watch tool, "Clock drift" (meshterm clocks): a histogram of the
clock offsets in log steps on two sides, then the managed nodes, then
each other node out of sync, largest offset first; Enter opens the node
page. Channel senders with no key are listed by name. When most clocks
disagree with ours the same way, a note says our own clock may be wrong.
The CLI lists every sender with offset_s, samples, and flags. A new
clock_report_days preference sets the window. The demo world gets four
wrong clocks.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
ADVERT packets now keep their own time (observations.sent_at, schema 22).
With the arrival times of messages, each advert, DM, and channel message
is a clock sample: the sender time minus ours. A channel sender counts
for the node its name resolves to, or under its name. A node's offset is
the median of its three newest samples. The node page's Info tab shows
"clock 3h 12m behind" in warn past the tolerance, or "in sync".
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
A received message now keeps its arrival time (received_at) beside the
sender time, and whether it waited in the companion's queue. Heard times,
the Messages list order, channel activity, and the packet-log search use
the arrival time, so a DM from a clock a year ahead no longer pins its
contact at "heard now". The transcript shows a corrected time as 12:31?,
and a picked message says what the sender's clock wrote. The CLI history
carries the same mark; its JSON gives both times. clock_tolerance_s
replaces ADVERT_FUTURE_SKEW_S as a preference.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
Bring in the 65 upstream commits since 0.11.1, with ^K lock and the self chip.
Both sides kept their features. React gives way to Lock in two places. On the
PicoCalc lane, Lock keeps the Shift half of F2 and React is ^E only. In the
hint, ^E react is the first atom to go when ^K lock has no room.
The long-message code now refills the compose line with MentionEditor, which
replaced LineEditor upstream.
Passwords, channel secrets, pairing PINs, and private keys reached the DEBUG log and
the runs table in plain text: every chat run stored its channel secret inside the
Conversation repr, and --password, --secret, channel links, and config set device_pin
were stored as typed. meshterm.core.secrets now hides each one as <secret> by its
shape (a secret-named key, record, set operation, or dataclass field; bytes; a Secret;
a remote `password`/`set guest.password` command; name=value in text), and by value
for each secret MeshTerm has read or sent. Both log handlers and the runs table go
through it, always. The remote CLI history keeps `password ` without its value. Schema
v20 hides the secrets that older versions stored.
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Off by default. Each masked value keeps a tidbit (j*********u, DA:xx:xx:xx:7C:7C,
192.xxx.x.180, m******e.local), so two radios stay two radios. The log masks each
line as it is written; diagnostics take --anonymize/--no-anonymize, and the page
toggles with `a` (Shift+F3 on the PicoCalc). Refs #31.
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>
scripts/video.py runs the demo mesh headless in the terminal set of the screenshots, types a tour of less than two minutes, and records the screen 30 times a second. It paints each different screen in parallel, encodes the video with ffmpeg, and writes demo.mp4, its poster, and its play card into the website checkout's src/. The camera stops while the tour waits for something slow, so the video jumps over the wait.
screenshots.py gives the video its app runner, its environment, and an RGB painter. The terminal screenshots stay pixel-identical. The glossary gains "video frame".
Co-Authored-By: Claude Haiku 5.5 <noreply@anthropic.com>