App 2.18.0: install from a USB stick

Settings -> App -> "Install from USB stick" (car build only). It looks
in the top folder of every mounted volume (found from the app's own
folder on it, since the head unit has no file picker) for
NilsMG4-unstable-<version>.apk, takes the newest one newer than the
installed version, checks it against its .sha256 sidecar and the
package name, and installs it with the same PackageInstaller session
as the over-the-air update. The stable build gets a stub and no button.

Tested on the emulator: 2.18.0 installed a 2.18.1 from the storage's
top folder without a confirmation, as the system user, so the OTA
install step should not need one either.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01QLJfZQZeAKAwSqViTmLzki
This commit is contained in:
2026-10-18 20:59:45 +02:00
co-authored by Claude Opus 5.5
parent 0fd024cc2e
commit 69d284f81b
11 changed files with 209 additions and 4 deletions
+11
View File
@@ -62,6 +62,17 @@ At start the app only checks, and shows "Update available" when there is one. It
downloads or installs on its own, and the upload service never checks: installing restarts
the app, which must not happen mid-drive on its own.
## Installing from a USB stick
For development, without the forge: copy `NilsMG4-unstable-<version>.apk` **and** its `.sha256`
from `build/car/` to the top folder of a USB stick, plug it in, and press **Install from USB
stick** on the Settings tab. The app takes the newest such file that is newer than the installed
version, checks it against the `.sha256`, checks the package, and installs it with the same
installer session as an over-the-air update. The car build only; the stable build has no button.
On the Android 9 emulator (car build, system user) this installed without asking, from the
storage's top folder; on the car the stick's top folder is used the same way.
## When it says something else
| Message | Meaning |