Commit 22cac3e
committed
feat(ios): derive treadmill speed from Apple Watch cadence in Fake Treadmill mode
Adds opt-in setting `applewatch_as_treadmill_speed` (default off) that
derives Speed from Apple Watch step cadence inside cadenceFromAppleWatch()
when fakedevice_treadmill is also enabled. Reuses cadence_sensor_speed_ratio
("Wheel Ratio") for the multiplier and the existing virtual treadmill / RSC
broadcast pipeline. Useful for indoor walking and slow jogging with apps like
Kinomap or Zwift when no physical treadmill is connected.
Dual-gated behind both new toggles so normal treadmill users are unaffected.
When cadence reports exactly zero (user stopped), Speed is also zeroed; a
negative cadence (no fresh sample) leaves Speed unchanged. Settings appended
at the end of qzsettings and settings.qml per src/CLAUDE.md.1 parent 1df45c5 commit 22cac3e
4 files changed
Lines changed: 61 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
612 | 612 | | |
613 | 613 | | |
614 | 614 | | |
| 615 | + | |
| 616 | + | |
| 617 | + | |
| 618 | + | |
| 619 | + | |
| 620 | + | |
| 621 | + | |
| 622 | + | |
615 | 623 | | |
616 | 624 | | |
617 | 625 | | |
| 626 | + | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
| 630 | + | |
| 631 | + | |
618 | 632 | | |
619 | 633 | | |
| 634 | + | |
| 635 | + | |
| 636 | + | |
| 637 | + | |
| 638 | + | |
| 639 | + | |
620 | 640 | | |
621 | 641 | | |
622 | 642 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1081 | 1081 | | |
1082 | 1082 | | |
1083 | 1083 | | |
| 1084 | + | |
1084 | 1085 | | |
1085 | 1086 | | |
1086 | | - | |
| 1087 | + | |
1087 | 1088 | | |
1088 | 1089 | | |
1089 | 1090 | | |
| |||
1989 | 1990 | | |
1990 | 1991 | | |
1991 | 1992 | | |
| 1993 | + | |
1992 | 1994 | | |
1993 | 1995 | | |
1994 | 1996 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2974 | 2974 | | |
2975 | 2975 | | |
2976 | 2976 | | |
| 2977 | + | |
| 2978 | + | |
| 2979 | + | |
| 2980 | + | |
| 2981 | + | |
| 2982 | + | |
| 2983 | + | |
| 2984 | + | |
| 2985 | + | |
2977 | 2986 | | |
2978 | 2987 | | |
2979 | 2988 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1313 | 1313 | | |
1314 | 1314 | | |
1315 | 1315 | | |
| 1316 | + | |
1316 | 1317 | | |
1317 | 1318 | | |
1318 | 1319 | | |
| |||
14497 | 14498 | | |
14498 | 14499 | | |
14499 | 14500 | | |
| 14501 | + | |
| 14502 | + | |
| 14503 | + | |
| 14504 | + | |
| 14505 | + | |
| 14506 | + | |
| 14507 | + | |
| 14508 | + | |
| 14509 | + | |
| 14510 | + | |
| 14511 | + | |
| 14512 | + | |
| 14513 | + | |
| 14514 | + | |
| 14515 | + | |
| 14516 | + | |
| 14517 | + | |
| 14518 | + | |
| 14519 | + | |
| 14520 | + | |
| 14521 | + | |
| 14522 | + | |
| 14523 | + | |
| 14524 | + | |
| 14525 | + | |
| 14526 | + | |
| 14527 | + | |
| 14528 | + | |
14500 | 14529 | | |
14501 | 14530 | | |
14502 | 14531 | | |
| |||
0 commit comments