Skip to content

fix(macos): auto-connect Sony ULT WEAR (empty device picker) - #26

Open
catcam wants to merge 1 commit into
AmitRajput-Dev:mainfrom
catcam:fix/macos-ult-wear-autoconnect
Open

catcam wants to merge 1 commit into
AmitRajput-Dev:mainfrom
catcam:fix/macos-ult-wear-autoconnect

Conversation

@catcam

@catcam catcam commented Oct 7, 2026

Copy link
Copy Markdown

Problem

v0.3.3 from the Homebrew cask, with a Sony ULT WEAR (WH-ULT900N, fw 2.0.7) paired and playing audio: clicking Connect opens the native "Select Bluetooth Device" picker, and the list is empty.

The v0.3.3 fix (8c81a27) touched MacOSBluetoothConnector::getConnectedDevices, but the SwiftUI app goes through HeadphonesBridge -scanAndConnectWithCompletion:. That only auto-selects a paired device that is isConnected and has WH-/WF-/WI-/MDR-/XB/LinkBuds in its name. "ULT WEAR" fails both checks, so it drops to IOBluetoothDeviceSelectorController, which only shows discoverable devices.

Fix

  • add ULT to the prefixes in SHCLooksLikeSonyHeadset
  • if nothing connected matches, fall back to any paired device that looks like a Sony headset. BLE/audio-only links report isConnected == NO (same thing 8c81a27 ran into), and connect() opens RFCOMM on demand anyway

Tested

MacBook Pro (Apple Silicon), macOS 27.0.1, Xcode 27.0, ULT WEAR fw 2.0.7.
Before: empty picker. After: Connect picks up the ULT WEAR straight away and the controls work.

Unrelated, didn't touch it here: Xcode 27 refuses MACOSX_DEPLOYMENT_TARGET = 11.0 (supported range is 12.0–27.0), so I built with MACOSX_DEPLOYMENT_TARGET=12.0 on the command line.

🤖 Generated with Claude Code

@catcam

catcam commented Oct 7, 2026

Copy link
Copy Markdown
Author

Screenshot with the patched build, ULT WEAR connected (battery, codec and ambient control all come through):

ULT WEAR connected in SonyBridge

@catcam
catcam force-pushed the fix/macos-ult-wear-autoconnect branch from 766787d to f82f4a5 Compare October 7, 2026 00:55
The v0.3.3 ULT WEAR fix changed MacOSBluetoothConnector::getConnectedDevices,
but the macOS app connects through HeadphonesBridge.scanAndConnect, which
only auto-selects a paired device that is isConnected AND whose name matches
WH-/WF-/WI-/MDR-/XB/LinkBuds. "ULT WEAR" matches neither, so the app fell
back to IOBluetoothDeviceSelectorController, which lists only discoverable
devices and showed an empty list.

- add "ULT" to the Sony name prefixes
- if no connected match, fall back to any paired device that looks like a
  Sony headset (BLE/audio-only links report isConnected == NO)

Assisted-by: Nikša Barlović <catcam@gmail.com>
Tested-by: Nikša Barlović <catcam@gmail.com>
@catcam
catcam force-pushed the fix/macos-ult-wear-autoconnect branch from f82f4a5 to 22c3676 Compare October 7, 2026 00:55

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants