Repository navigation
PulseStages 0.3.0
Sleep as Android can now show PulseStages' stages: the opt-in setting "Sleep as Android compatibility" starts every
written session one second before the watch app's, so Sleep as Android imports PulseStages' session instead of the
watch app's session without stages. Install it over 0.2.0 like any update (same signing key): the app keeps its data,
and nothing becomes stale until the setting is turned on
(user guide).
Added
- Sleep as Android compatibility (Settings → "Written sessions" → "Sleep as Android compatibility",
write.startBeforeSource, off by default). Sleep as Android imports only the first of overlapping Health Connect
sessions by start time. PulseStages' session started at exactly the source session's start and always lost that tie to
the older source session, so Sleep as Android showed OHealth's nights without stages. With the setting on, every
written session, naps included, starts 1 second before its source session and its first stage is extended back by that
second; the end, zone offsets, record key, title and the notes' keys are unchanged (the params hash in the notes
changes), and the app's screens keep the night's own times. Sleep as Android then imports PulseStages' sessions with
their stages: confirmed on the development phone with Sleep as Android 20261006, where the nights (deleted there
before the sync) showed a full hypnogram with the same phase shares as in PulseStages. It shows whole minutes, so
when the watch app's session starts on a whole minute, the night shows there one minute earlier (3:03 instead of
3:04 for a session starting at 3:03:59). The setting changes the written data and is part of the params hash only
while it is on: the update changes no hash, and turning it on (or off again) makes every written night stale;
"Recompute" rewrites them in place (same record key, next version), never under "Never overwrite". Nights Sleep as
Android already imported stay as they are until they are deleted there and synced again (Sleep as Android →
Settings → Services → "Sync now"; nights of the last 29 days only). English and Russian texts
(user guide,
health-connect.md §8.3, PLAN.md §2). - On-device suite: the shadow pipeline's
policy-start-before-sourcescenario checks that every captured session
starts exactly one second before its night, and the real-write sequence's second version moves the record's start by
that second, so an in-place upsert with another start is checked on the phone
(tools/device-test/README.md).
Changed
- Sleep as Android in the documentation: its import is no longer "not verified". Observed with Sleep as Android
20261006 and confirmed on the development phone, it syncs only when you tap "Sync now" in its Settings → Services
(Health Connect for the last 30 days) or the sync button of its Health Connect screen (up to 5 years back), when it
saves a record and when its own tracking ends (both the last 14 days); it keeps the first of overlapping sessions by
start time, whatever Health Connect's priority list says; it never imports a session that overlaps a record it
already has and never picks up later changes; it drops Health Connect's "unknown" and "sleeping" stages, so a nap
written as asleep / awake, once imported, shows there as a time span without phases (only its awake parts, if any);
and the thin stripes on nights without stages are its own heart-rate awake detection. The user guide's setup
replaces "delete the stage-less session" and "Write awake as light sleep" with the compatibility setting, a
recompute, deleting the imported nights of the last 29 days (cloud icon) in Sleep as Android and syncing again with
"Sync now", and warns against tapping its "Health Connect" row in Settings → Services (a switch: it turns the
integration off and Sleep as Android revokes its Health Connect permissions) and against its Backup → "Download from
Health Connect" (user guide,
health-connect.md §8.3).
Downloads
| File | Use |
|---|---|
PulseStages-0.3.0.apk |
Signed release build for everyday use. Later releases install over it as updates. |
PulseStages-0.3.0-debug.apk |
Debug build for testing, with the demo mode. |
SHA256SUMS.txt |
SHA-256 checksums of both APKs: sha256sum -c --ignore-missing SHA256SUMS.txt |
The two APKs are signed with different keys, so neither can update the other. To switch, uninstall first.
The sessions PulseStages wrote stay in Health Connect; grant its permissions again after the reinstall.
To get every later release installed as an update, add PulseStages to Obtainium
(user guide).
Release signing certificate SHA-256: ce5546e83c03eac9837b93fc2c04d2e37abd1b778c3ef9e01b67cd1602e35be5
Debug signing certificate SHA-256: b557d5d55ea3c6d98e72493b1e82f228465201e7271d93f7ace577ff1c5b35cc (a later debug APK installs over an earlier one only if this value is the same)