Claude cracks the AirPods protocol: head tracking now works on Linux
A developer used Claude Code to figure out how Linux can tap into the motion sensors in Apple's AirPods. What had been stopping it was one Bluetooth setting. His open-source project MousePods turns the earbuds into a head mouse: turn your head, and the cursor follows.

What it's about
On Linux, Apple's AirPods work like any other Bluetooth headphones. You can listen to music and take calls, though the experience varies a bit from system to system. What you couldn't get at were the built-in motion sensors. Apple uses them for features like Spatial Audio with dynamic head tracking and for Siri gestures such as nodding or shaking your head. Step outside Apple's ecosystem and those features disappear.
Developer Matteo Gaudioso, who goes by starman-tech on GitHub, has now filled that gap. Reports spell his name differently: AppleInsider and iLounge call him "Guaduisi" and "Guadisi" respectively. His project MousePods is an open-source Python program that reads AirPods motion data on Linux and turns it into mouse movements. You don't need an iPhone or Mac, and the AirPods firmware isn't modified. The code is on GitHub under the starman-tech account. AppleInsider, GadgetReview and iLounge are among the outlets that have covered it.
An afternoon with Claude Code
According to AppleInsider, Gaudioso wrote on Reddit that he wanted to control his mouse cursor on Linux with his AirPods 3. Every open-source project in the space, though, said AirPods 3 weren't supported. So he spent an afternoon with Claude Code, Anthropic's command-line AI coding tool, working out how the earbuds' motion detection works.
AppleInsider reports that he had AI agents running in the background, combing through similar projects for a solution. Agents are AI instances that take on subtasks on their own. It paid off: one of them found the answer in iOS framework code, the libraries Apple's operating system uses to talk to AirPods. That code showed AirPods 3 use a different protocol than the Pro models. That's why existing projects built for AirPods Pro had failed with them.
GadgetReview points out that the project documentation is very precise about what the AI contributed. It lists Claude as an "AI pair engineer", a coding partner that helped with hardware testing, analyzing public research, firmware analysis, code and tests. Gaudioso supplied the hardware, checked the results and steered the work. As GadgetReview puts it:
This is iterative human-AI development, not an AI autonomously reverse engineering Apple hardware.
The one setting that blocked everything
The core problem turned out to be surprisingly small. AirPods expose their motion sensors as virtual HID devices, meaning input devices that follow the same standard as keyboards, mice and game controllers. This runs over Apple's RemoteHID protocol, which is carried inside Apple's own accessory protocol.
For those devices to show up at all, the Bluetooth packets have to be big enough. That's where the MTU, or Maximum Transmission Unit, comes in. It sets the maximum size of a single data packet, a bit like the maximum parcel size at the post office. On Linux, the receive MTU for L2CAP, one of Bluetooth's basic transport layers, defaults to 672 bytes. According to the project documentation, that's too small for the sensor devices to appear. AppleInsider explains that the MTU couldn't handle audio and sensor data at the same time, so the sensor data got dropped.
Gaudioso raised the value to 2,582 bytes, which the documentation says is what iOS uses too. Once the right sequence of HID commands is sent, the AirPods stream their processed motion data to the Linux machine.
| Detail | Value |
|---|---|
| Linux default L2CAP MTU | 672 bytes |
| Required MTU (same as iOS) | 2,582 bytes |
| Sample rate per documentation | up to approx. 210 Hz (AppleInsider: 200 Hz) |
| Data transmitted | Orientation, gyroscope, acceleration, gravity vector |
| Requirements | Linux with BlueZ, Python, access to /dev/uinput |
The data includes head orientation, gyroscope readings (rotation), acceleration and the gravity vector. The sample rate goes up to about 210 readings per second, more than enough for smooth control.
What MousePods can and can't do today
According to GadgetReview, the head mouse feature is confirmed: with paired AirPods 3 or AirPods Pro 2, you move the cursor by moving your head. The reports disagree on supported models. GadgetReview names AirPods 3 and AirPods Pro 2, AppleInsider talks about AirPods 3 and AirPods Pro in general, and iLounge mentions AirPods Pro 3. Check the repository to see exactly which models work.
The community has been discussing hooking MousePods up to OpenTrack, popular software that feeds head movements to flight and racing sims so you can look around a virtual cockpit. GadgetReview says that hasn't been built yet, though. So MousePods doesn't replace dedicated head-tracking hardware yet.
On the technical side, you need a Linux system with the BlueZ Bluetooth stack, Python, paired AirPods and access to /dev/uinput, the Linux interface that lets programs create virtual input devices like a mouse. The repository calls the whole thing experimental, and whether it works depends on your hardware and software.
No risk to your AirPods
AppleInsider stresses that all changes happen on the Linux side. Nothing touches the earbuds' firmware, so experimenting won't brick your AirPods or void your warranty. The outlet places the project in a broader trend: AI is increasingly used to modify existing hardware and software, all the way up to entirely new firmware for devices like cameras. For that kind of thing, AppleInsider advises checking the warranty terms first. MousePods, by contrast, is a "very non-destructive" solution.
The bigger picture
The story shows what AI coding tools can do with hardware: one person works out in a single afternoon why earlier open-source projects had failed. The breakthrough came less from a stroke of genius than from diligent research, with parallel agents digging through other people's code and documentation. That kind of legwork is exactly where language models shine.
GadgetReview also makes a broader point: missing Linux support doesn't mean a capability is missing. The sensors were always there. They were just out of reach because of an undocumented protocol quirk and a default setting.
There are still limitations. The project is experimental, reports contradict each other on supported models, and practical uses like the sim integration exist only as ideas for now. But if you're a Linux user with AirPods, a tinkerer, or someone looking for hands-free mouse control, say for accessibility reasons, MousePods is an interesting starting point. And because the code is open, other developers can build on it.
Sources
- Bing News (de-DE) msn.com
- gadgetreview.com gadgetreview.com
- ilounge.com ilounge.com
- appleinsider.com appleinsider.com
Ask the AI assistant
Questions about this article, installation or background? Our assistant knows this page and runs on our own machine, not in someone else's cloud.
The Assistant is an AI (Gemma 4) and can make mistakes – please check important details against the source. Questions are used only to generate an answer and are deleted after one hour. Please don't enter any personal data.
Comments
What do you think? Already tried it? Write it here, no sign-up needed.
Comments are public. Links aren't allowed, and we delete abusive posts. You can delete your own comment at any time in this browser. Learn more in the Privacy Policy.