Spike C: BRouter AIDL enrichment of a real komoot GPX #6
Labels
No labels
area:companion
area:docs
area:shared
area:tooling
area:watchapp
blocker
kind:chore
kind:feature
kind:spike
kind:test
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set
Reference
robert/PedalPebble#6
Loading…
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Goal
BRouter is the preferred offline cue-sheet backend. Confirm it can turn a komoot GPX (geometry only, no turn data) into usable turn instructions before Phase 3 depends on it.
Acceptance criteria
IBRouterServicebound successfully from a scratch Android applonlatswith a bike profile andturnInstructionModesetTL,TR,KR, ...) present and positioned at the correct junctionsNotes
AIDL definition: http://brouter.de/brouter/IBRouterService.aidl - docs at https://zod.github.io/brouter/developers/android_service.html . OsmAnd's BRouter adapter is a working reference implementation.
Update — 2026-09-01: BRouter is a router, not a map-matcher
This spike passed on "the returned GPX carries usable voice hints". That is necessary and nowhere
near sufficient, and 19 issues rest on it (D25).
Given via points, BRouter computes its own route between them, under its own profile. It does not
snap a track to OSM the way GraphHopper's or Valhalla's matching endpoints do. Three consequences:
route the rider is not on — the worst failure a navigation device has, because it is confidently
wrong rather than obviously broken.
declines. BRouter detours, silently, and the cues follow the detour.
points, BRouter routes once per leg under a running-time cap. NFR-P5 was filed as "needs a number";
it is not a number problem, it is an unvalidated feasibility problem.
Added criteria:
least three real routes including one urban and one rural
than shown
chosen from evidence and NFR-P5 gets a real number
behaviour
maxRunningTime/ timeout behaviour on a long route recordedAPI and #27 changes shape entirely
right tool
The 20 m divergence check ships in
BRouterEnricherregardless of what this spike finds. It is theonly thing between a bad enrichment and a rider being told to turn where there is no turn.
Labelled
blocker. It gates twelve issues and was not marked.Update — 2026-09-02: divergence is per leg, and the stakes are lower than they were
Per-leg rejection (D41). The 20 m threshold above reads as a whole-route check, and NFR-P8 stated
it as one. Applied that way, one bad 50 m stretch discards the cue sheet for a 100 km route and
drops the rider to the geometric heuristic for the entire ride — a worse outcome than the failure it
protects against.
marked unenriched, so the watch shows no turn rather than a wrong one
here — a route where most legs fail is not a good route with a few gaps
Lower stakes (D40, D42). Two things moved out from under this spike:
reaches BRouter-quality cues with no BRouter install at all. This spike now decides the komoot
path, not navigation as a whole.
the mid-ride critical path. Its blocked-by edges to the re-routing work can be dropped.
Keeps
blocker: import-time enrichment for geometry-only routes still rests on it.