docs/hardware.md shrinks to a router: which guide for which device, and the two platform flavours. Everything the guides were still reaching into it for moved home — the bridge's environment knobs into uconsole.md, and the verified/unverified lists into each manual's closing section, split by device (the PicoCalc's gains the MX1.25 pin order and the 5 V path, both inferred rather than measured on a Lyra). The PicoCalc manual gets the Wi-Fi kick back — it works and stays; only the join script is going. The uConsole manual opens on the same kind of disclaimer as the PicoCalc's, minus the hardware-handling parts: a LoRa transmitter, a Linux shell, the guide may be wrong or stale, your call. Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
33 lines
4.2 KiB
Markdown
33 lines
4.2 KiB
Markdown
# scripts
|
||
|
||
Device-side helpers that put MeshTerm on real hardware: bringing up a ClockworkPi PicoCalc
|
||
(Luckfox Lyra, Calculinux) and building its console font, giving that handheld a real
|
||
MeshCore radio over UART, and fronting an SPI-attached LoRa chip as if it were a companion
|
||
device. They run **on the device**, most of them as root, and they are meant to be read
|
||
before they are run.
|
||
|
||
**Start with the manual for your device**: [`docs/picocalc.md`](../docs/picocalc.md) walks a
|
||
stock PicoCalc from the shopping list to a working radio, and [`docs/uconsole.md`](../docs/uconsole.md)
|
||
installs the SPI bridge on a uConsole. Each manual ends on what has only ever been proven
|
||
on one bench, and each script's header says what it assumes about the machine and why each
|
||
step is the way it is. The table below is the index.
|
||
|
||
| File | Runs on | What it does |
|
||
| --- | --- | --- |
|
||
| [`calculinux-setup.sh`](calculinux-setup.sh) | the Lyra (root) | One-time bring-up: python packages, the Wi-Fi boot-scan kick, a boot clock sync (there is no RTC), the deploy user, the checkout, the venv and `pip install -e .`, the login PATH, and the console font. Idempotent. |
|
||
| [`calculinux-console-font-6x12.sh`](calculinux-console-font-6x12.sh) | the Lyra (root) | Just the console font: builds, installs and persists the 512-glyph **meshterm** PSF (braille, node marks, rounded frame corners, the list cursor) and restores the stock 16-slot palette. Calls the 6×8 build below when it sits alongside. Run it alone after a MeshTerm update. |
|
||
| [`calculinux-console-font-6x8.sh`](calculinux-console-font-6x8.sh) | the Lyra (root) | The shorter-cell companion font, **meshterm8** (6×8 → 53×40), for anyone who wants more rows than the 6×12 default gives. Its base bitmap is the kernel's `font_6x8`, so this one file and the PSF it builds are **GPL-2.0-only** ([`LICENSE.GPL-2.0`](LICENSE.GPL-2.0)); it reads the donor/alias/keeper tables out of the script above rather than keeping a second copy. Pick between the two fonts from MeshTerm's Preferences page. |
|
||
| [`calculinux-wifi-set.sh`](calculinux-wifi-set.sh) | the Lyra (sudo) | Interactive Wi-Fi join: prompts for an SSID and passphrase, writes iwd's credentials, connects now. This is how a network *becomes* known to the boot kick. |
|
||
| [`calculinux-radio-bridge.sh`](calculinux-radio-bridge.sh) | the Lyra (root) | **Unfinished, unsupported.** An early UART-to-TCP pump, superseded by `xiao-radio/lyra-setup.sh`; its header describes routing it does not contain. See the manual before reading it. |
|
||
| [`meshterm-spi-bridge`](meshterm-spi-bridge) | the radio host (your user) | Runs a mesh node in software over an SPI-attached SX1262 (uConsole AIO, Waveshare HATs) and serves the companion protocol on `127.0.0.1:5000`. Setup menu, preflight, optional `systemd --user` service. Runs on `openhop_core` (preferred) or its predecessor `pymc_core`; see the manual for the venv it wants on a bookworm uConsole. |
|
||
| [`xiao-radio/`](xiao-radio/) | see below | Everything for the XIAO nRF52840 + Wio-SX1262 radio wired to the Lyra's UART1. |
|
||
| [`xiao-radio/build-firmware.sh`](xiao-radio/build-firmware.sh) | dev machine | Clones and patches MeshCore, builds the `Xiao_nrf52_companion_radio_serial` environment, emits the `.uf2`. |
|
||
| [`xiao-radio/flash.py`](xiao-radio/flash.py) | dev machine | Flashes the `.uf2` to the XIAO over its UF2 bootloader, refusing the wrong board or SoftDevice; prints the serial-DFU command when the bootloader offers no drive. |
|
||
| [`xiao-radio/meshcore-uart1.patch`](xiao-radio/meshcore-uart1.patch) | — | The two firmware hunks: the companion on nRF52 `Serial1`, and I²C moved off the UART pads. Not upstream yet. |
|
||
| [`xiao-radio/lyra-setup.sh`](xiao-radio/lyra-setup.sh) | the Lyra (root) | Boot-persistent UART1 → GP4/GP5 mux service, `dialout` membership, and a default MeshTerm serial profile for `/dev/ttyS1`. |
|
||
| [`xiao-radio/uart1-mux.py`](xiao-radio/uart1-mux.py) | the Lyra (root) | The matrix-IO register poke that routes UART1 to the header pads, run once per boot by the service above. |
|
||
|
||
The PicoCalc scripts and the SPI bridge belong to different machines and share nothing but
|
||
MeshTerm. On the Lyra, only one program may hold `/dev/ttyS1` — MeshTerm directly, or a pump
|
||
in front of it, never both.
|