feat(steps): hybrid step counting + serial/device fixes + ASK product icon - #27
Merged
Conversation
…ders, and fix test flakiness
Steps - Compose REAL 100 Hz pedometer counts with the bounded 1 Hz estimate, never double-counting: live windows are recorded in a new live_coverage table (db v13, device-time), and the derivation excludes those minutes from the 1 Hz estimate, summing real + estimate per day. - Guided calibration walk (StepCalibrationScreen): a short open-road walk teaches the personal cadence/refEnmo via the live pedometer so the off- workout estimate anchors to the user. Entry from the Steps detail. - Drop the active-minutes metric (replaced by the steps hybrid); purge stale active_min / bogus steps series in the v12/v13 migrations. - Today tile + Steps screen show the hybrid number (est. tag) + live in-flight session; bump kAlgoVersion. Device identity - Serial now comes from the HELLO body (fixed offset, via protocol fix) and a cleanDeviceLabel guard keeps any '?*' junk out of the persisted/displayed label. (+ device_label_test.dart) iOS - AccessorySetupKit pairing sheet shows the real strap render (compressed StrapProduct.imageset) instead of the Apple Watch SF Symbol. pubspec: protocol/analytics pinned to their feature branches (see PR note). flutter analyze clean; 74 tests green.
The serial-offset (protocol) and step-hybrid (analytics) PRs are merging to main; pin edge to main rather than the feature branches.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Bundles several local-first edge improvements. Also carries the unmerged local-notifications work (that branch had no PR) so it lands on main too.
pubspec.yamlpins the local packages to their feature branches:openstrap_protocol→fix/hello-serial-offset(fix(hello): read serial at fixed offset, not a content scan protocol#3)openstrap_analytics→feat/step-estimate-rework(feat(steps): hybrid step count — 100 Hz real + bounded 1 Hz estimate analytics#9)Before merging this PR: merge #3 and #9, then flip both refs back to
main.Steps — hybrid (real 100 Hz + bounded 1 Hz estimate, no double-count)
live_coveragetable (db v13). The derivation excludes those minutes from the 1 Hz estimate and sumsreal + estimateper day — a minute is counted by 100 Hz or estimated by 1 Hz, never both.StepCalibrationScreen): a short open-road walk teaches the personal cadence/refEnmovia the live pedometer, anchoring the estimate to the user. Entry from the Steps detail ("Calibrate steps", ~250-step target).active_min/ bogusstepsseries purged in the v12/v13 migrations.est.tag) plus the in-flight live session;kAlgoVersionbumped.Device identity
cleanDeviceLabelguard keeps any?*junk out of the persisted/displayed label. (+device_label_test.dart)iOS
StrapProduct.imageset, 2 MB → 140 KB) instead of the generic Apple Watch SF Symbol.Notifications (from the folded-in branch)
Tests
flutter analyzeclean (2 pre-existing infos); 74 tests green (flutter test --concurrency=1).🤖 Generated with Claude Code