Modern Apps git
git clone https://git.maproj.org/Modern-Apps.git
cov/c3 ▾

Modern-Apps.git / things / AGENTS.md

AGENTS.md2.1 KiBRenderedCodeRaw
1# AGENTS.md — things/ (':things')
2
3> Scoped supplement. Global rules in root `AGENTS.md` apply. Stay inside `things/` + allowed shared modules. Do not root-scan.
4
5_Install: ./install things (dev by default)._
6<!-- last-reviewed: 2026-10-16 -->
7- Gradle: :things / dir: things/
8- Package roots present: ui, platform
9- Entry files: MainActivity.kt, Route.kt, Navigation.kt
10- Deps: (none declared — BLE + Health Connect only)
11- Metadata: metadata_data/things.md (present)
12- Rust: no / screenshotTest: yes
13
14## Overview
15**Purpose:** BLE hyd ration tracker — pairs a smart water bottle, totals sips against a daily goal. No account, no cloud; readings stay on the phone. (Scale BLE files are legacy/experimental alongside.)
16**Key features:** Scan/pair/disconnect, live per-sip history, goal progress; Health Connect bridge helper; permissions-gated onboarding.
17**Entry points:** `Route` → `MainActivity.kt` → `Navigation.kt` → `ui/HomePage.kt` → `platform/DeviceController.kt` → `platform/BleManager.kt`.
18**Gotchas:** BLE behavior is device- and radio-state-dependent — test scan/pair/drop/reconnect on hardware, not the emulator.
19
20## Key files
21### Root — entry + navigation
22- com/vayunmathur/things/MainActivity.kt
23- com/vayunmathur/things/Navigation.kt
24- com/vayunmathur/things/Route.kt
25### platform/ — BLE + device control
26- com/vayunmathur/things/platform/BleManager.kt
27- com/vayunmathur/things/platform/DeviceController.kt
28- com/vayunmathur/things/platform/DeviceService.kt
29- com/vayunmathur/things/platform/ScaleBleManager.kt
30- com/vayunmathur/things/platform/ScaleBleConnection.kt
31- com/vayunmathur/things/platform/ScaleBleProtocol.kt
32- com/vayunmathur/things/platform/BodyComposition.kt
33- com/vayunmathur/things/platform/HealthConnectHelper.kt
34### ui/ — home, devices, permissions
35- com/vayunmathur/things/ui/HomePage.kt
36- com/vayunmathur/things/ui/DevicesPage.kt
37- com/vayunmathur/things/ui/PermissionsPage.kt
38- com/vayunmathur/things/ui/PermissionsRationaleActivity.kt
39
40## Verify (this module only)
41```
42./gradlew :things:compileDevKotlin
43./gradlew :things:lint
44./gradlew :things:checkMetadata
45```