Your AirPods already
know the angle.
Nothing here is clever. The sensor has been in your ears the whole time; the only interesting decisions are what to measure, what to ignore, and when to say something.
Signal
- 01
Read one angle, not six
Motion-capable AirPods carry a 6-axis IMU that Apple ships for spatial audio. Pitch and roll are fused against gravity, so they're absolute and never drift. Yaw is integrated from the gyroscope alone and wanders continuously. Posture uses pitch and nothing else — that's what makes “how far is my head tilted down” mean the same thing an hour later.
- 02
Smooth it, frame-rate independently
About 25 samples a second arrive, and the rate wobbles. The filter uses α = 1 − exp(−dt/τ) rather than a fixed α, so its 0.8-second time constant stays put even when the sample rate doesn't. A single 40-millisecond spike — a sneeze, a laugh — never reaches the state machine.
- 03
Measure against a baseline you set
Calibration samples three seconds and keeps the median, not the mean, so one head-turn mid-calibration barely moves it. Everything after that is measured relative to your posture, not to some idea of correct posture.
Decision
Two guards, doing different jobs.
A slouch has to clear 12° below baseline to register, and then hold for 25 seconds before it's worth interrupting for. Coming back only counts once you're 5° inside the limit.
That last number is hysteresis, and it solves a different problem from the grace period. Hysteresis stops the state flickering while you hover exactly at the limit. The grace period stops a deliberate look down at your keyboard counting at all. Drop either one and it becomes unusable in a different way.
Nagging
It gets quieter the longer you ignore it.
Every other app in this category alerts forever at a fixed interval. None of them model what happens when you ignore the alert, which is exactly why they end up muted.
Ignoring a nudge usually means you're deep in something. So each one you ignore doubles the wait before the next, up to a ceiling you set. Sitting up resets it completely — which makes good posture the only thing that restores full strength, rather than a timer quietly expiring.
Drawn to scale on a linear time axis, so the doubling is the shape of the figure rather than a claim underneath it. The cost is real: on a bad day it fades to a nudge every half hour and mostly lets you get on with it.
Cost
0.13% of one CPU.
The analyzer runs at the full sample rate, but the interface is only told about changes it would actually render — degrees rounded to a half, the clock to a second, the percentage to a percent. A still head produces an identical snapshot and therefore no work at all. Pausing tears the sensor down rather than quietly ignoring its output, because a subscribed app keeps both the AirPods and the Bluetooth link awake.
- CPU idle
- 0.13% — window open or closed
- Memory
- 85 MB resident
- App size
- 776 KB, 352 KB zipped
- Dependencies
- None. Nothing linked outside the system libraries
- Network
- No networking code exists in the app
Honestly
It measures your head, not your spine.
Head pitch tracks the screen-slump well, because that's what hunching does to your neck. It cannot tell leaning back in a well-aligned chair from sitting bolt upright, and a long look down at a notebook reads as a slouch until the grace period filters it out. It's a nudge, not a measurement of your health.