feat(train): Halkyon Train's shell, Todo's copied and renamed (ADR 0030, D12)
apps/train with halkyon_train_server, _client and _flutter, as Todo's:
halkyon_base configured by trainBase(), its own register alone and a
member of the instance's where the operator names one, the app on
halkyon_app's gates with Train's frame, account sheet and About, texts
in British English and German that speak of workouts, app.halkyon.train
on Android, iOS, Linux, macOS and Windows.
Where it differs from Todo: development ports of its own (8180 to 8190),
so it runs beside Learn's server; one initial migration with the schema
Todo's migrations end at (the same tables, compared line by line), not
Todo's seventeen; and Todo's icon as a placeholder until the icon tool
of ADR 0031 draws Train's bike. The workspace, the licences, the READMEs
and AGENTS.md name it.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-10-28 10:26:49 +01:00
|
|
|
# Halkyon Train
|
|
|
|
|
|
|
|
|
|
Running, cycling and rowing, as a Halkyon app (what it is to do: ADR 0030). For now a
|
|
|
|
|
shell on the shared packages: people choose an instance, sign in (with SimpleLogin or
|
|
|
|
|
a password), switch between the accounts on their devices, sign out and delete their
|
|
|
|
|
account; the home is empty until Train's first model.
|
|
|
|
|
|
|
|
|
|
| Package | What it is |
|
|
|
|
|
|---|---|
|
|
|
|
|
| [`halkyon_train_server`](halkyon_train_server/) | The server: Serverpod with the `halkyon_base` module |
|
|
|
|
|
| [`halkyon_train_client`](halkyon_train_client/) | Its client, generated by Serverpod |
|
|
|
|
|
| [`halkyon_train_flutter`](halkyon_train_flutter/) | The app, on `halkyon_app` and `halkyon_ui` (Android, iOS, Linux, macOS, Windows) |
|
|
|
|
|
|
|
|
|
|
Run it with `serverpod start` in `halkyon_train_server`, which starts the server (and its
|
|
|
|
|
embedded PostgreSQL) on ports of its own, 8180 to 8190, and the app; or the app alone
|
|
|
|
|
against an instance with `flutter run --dart-define=SERVER_URL=https://…/` in
|
|
|
|
|
`halkyon_train_flutter`. Tests: `dart run melos run test:dart --scope=halkyon_train_server`
|
|
|
|
|
and `dart run melos run test:flutter --scope=halkyon_train_flutter` at the repository's
|
|
|
|
|
root, or `dart run tool/check.dart` for everything.
|
|
|
|
|
|
2026-10-28 10:42:47 +01:00
|
|
|
The app's icon is [Lucide](https://lucide.dev)'s `bike` (ISC licence, ADR 0031), drawn
|
|
|
|
|
by the repository's `tool/app_icons.py`. Licences: the server under the SSPL, the client
|
feat(train): setting up and keeping the Polar Loop (ADR 0030, D34–D36)
On Android, the Loop through Polar's BLE SDK 8.3.0 (from JitPack, asked
for Polar's group alone, its files pinned by SHA-256 in Gradle's
verification metadata): LoopBridge.kt over app.halkyon.train/loop, the
first-time use's figures mapped and checked in LoopSetup.kt, tested on
the JVM. PolarLoop per person remembers the band in loop.json, connects
while the app is open, sets its clock at each connection, keeps what it
tells (battery, charging, firmware), offers a changed profile and sends
it only when asked (D35: first-time use writes a new user identifier
each time), and lets the band go by a factory reset after asking. The
setup sheet finds Loops nearest first and asks only for what the
profile lacks; Polar's defaults (60, 220 less the age, a VO2max from
Polar's fitness tables) go to the band alone.
Polar's SDK is not free software (D36, correcting D32): the app's AGPL
gains a section 7 permission for linking it, LICENSE.md names it, and
its licence and bundled notices join the licence list on Android.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Signed-off-by: Tizian 「ティツィアーン」 <raisondetredev@pm.me>
2026-10-28 18:58:02 +01:00
|
|
|
and the app under the AGPL, the app's with a permission for linking Polar's BLE SDK, which
|
|
|
|
|
isn't free software, for the Polar Loop (ADR 0030, D36;
|
|
|
|
|
[`LICENSE.md`](../../LICENSE.md)).
|