Device: Fix ear detection and call settings on several models#571
Merged
Conversation
Sync flags with what the BLE classes actually report and what iOS exposes: - AirPods Gen 1/2/3: enable hasEarDetection (already parsed via DualApplePods) and hasEarDetectionToggle - AirPods Gen 3, Pro 1: enable hasEndCallMuteMic (force-sensor stems) - Powerbeats Pro, Beats Fit Pro: enable hasEarDetectionToggle (iOS exposes it) - Beats Solo Pro, Studio 3: drop hasEarDetection (over-ear, BLE class is bare SingleApplePods) - FAKE_AIRPODS_GEN1/2/3: enable hasEarDetection to match HasEarDetectionDual - Generalize microphone mode description from 'AirPod' to 'earbud' Tests rewritten as exhaustive set assertions plus implication invariants.
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.
What changed
Several AirPods and Beats models had incorrect or missing device feature settings:
Technical Context
DualApplePods/HasEarDetectionDual; the advertisement bits were always parsed and the feature flag was simply lagging.SingleApplePodswith noHasEarDetectioninterface — thehasEarDetection = trueadded infe4ac306was a false positive and is removed.c5d9bed5(Apple iOS exposes the setting; an unsupported AAP write is a silent no-op on the chip).ModelFeaturesTestrewritten as exhaustive per-feature set assertions plus directional invariants (earDetectionToggle => earDetection,sleepDetection => earDetection,allowOff => listeningModeCycle, etc.) to catch future drift.