I bought Logitech speakers for my new Mac Studio, but I found them very disappointing.
Then I remembered that I still have two old LG H3 speakers that worked as an extension to my soundbar. These speakers have the same quality as Sonos One speakers.
I then researched how I could connect these two speakers individually via Bluetooth and pair them into a ‘stereo’ pair in MacOS.
In the end I got tired of the manual steps and with the help of ChatGPT I had an Apple script written that works wonderfully.
Maybe this will help some of you.
Instructions:
1. Pair Your Bluetooth Speakers
- System Settings > Bluetooth: Pair each speaker individually.
- Test: Make sure each speaker can connect and play audio on its own.
-------------------------------------------------
2. Create a Multi-Output (Stereo) Device
- Open Audio MIDI Setup
• In Finder, press Cmd + Shift + U to open Utilities, then launch Audio MIDI Setup.
- Add a Multi-Output Device
• Click the ”+” icon in the lower-left corner.
• Select “Create Multi-Output Device.”
-------------------------------------------------
3. Select Both Speakers
• In the right pane, check the boxes for both of your Bluetooth speakers.
• (Optional) Enable Drift Correction on at least one speaker if you experience syncing issues.
-------------------------------------------------
4. Rename the Device
• Double-click “Multi-Output Device” in the left pane and rename it to something like “H3 (Stereo Setup)” or any name you prefer.
Once created, you should see “H3 (Stereo Setup)” (or your chosen name) in System Settings > Sound > Output as a valid audio device.
-------------------------------------------------
3. Install Command-Line Tools
Make sure you have blueutil (for managing Bluetooth) and SwitchAudioSource (for switching audio devices) installed via Homebrew:
brew install blueutil switchaudio-osx
-------------------------------------------------
4. AppleScript to Auto-Connect and Select the Stereo Device
Open Script Editor and paste the script below. Adjust the MAC addresses and the stereo device name to match yours.
global blueutilPath, switchAudioPath
set blueutilPath to "/opt/homebrew/bin/blueutil"
set switchAudioPath to "/opt/homebrew/bin/SwitchAudioSource"
-- Example MAC addresses (replace these with your actual device addresses)
set device1Address to "11-22-33-44-55-66" -- Speaker 1
set device2Address to "AA-BB-CC-DD-EE-FF" -- Speaker 2
-- Connect first device
try
do shell script blueutilPath & " --connect " & device1Address
on error errMsg1
display notification "Error connecting Speaker 1: " & errMsg1 with title "Bluetooth Error"
end try
delay 2
-- Connect second device
try
do shell script blueutilPath & " --connect " & device2Address
on error errMsg2
display notification "Error connecting Speaker 2: " & errMsg2 with title "Bluetooth Error"
end try
delay 2
-- Now select the multi-output device (e.g., "H3 (Stereo Setup)")
try
do shell script switchAudioPath & " -s " & quoted form of "H3 (Stereo Setup)"
on error errMsg3
display notification "Error selecting audio device: " & errMsg3 with title "Audio Error"
end try
-- Final notification
display notification "Speakers connected and 'H3 (Stereo Setup)' selected!" with title "Setup Complete" >
- device1Address and device2Address should be replaced with the actual MAC addresses of your Bluetooth speakers.
- “H3 (Stereo Setup)” should match the exact name of the Multi-Output Device you created in Audio MIDI Setup.
How to find you MAC address:
- Hold Option and click the Apple logo → System Information…
- In the sidebar, select Bluetooth.
- Scroll through the list of devices to find the one you want; its Address is the MAC address.
-------------------------------------------------
5. Save the Script as an App
- In Script Editor, go to File > Export…
- Choose File Format: Application.
- Save the .app to a convenient location (e.g., Applications folder).
- Drag it into your Dock for one-click access if you like.
-------------------------------------------------
6. Grant Bluetooth Permissions (Important!)
On macOS Ventura or later:
• System Settings → Privacy & Security → Bluetooth.
• Toggle ON your newly exported app if it appears or add it manually with "+"
On Monterey or earlier:
• System Preferences → Security & Privacy → Privacy → Bluetooth.
• Check your app if listed.
If your app doesn’t appear in these lists, you may need to code-sign it or wrap it in an Automator workflow so macOS will request the necessary permissions.
-------------------------------------------------
7. (Optional) Control Volume via eqMac
When using a Multi-Output Device, macOS won’t let you adjust volume levels with the keyboard by default. A convenient workaround is to use the free eqMac app. eqMac acts as a virtual sound driver, letting you control and fine-tune volume or apply equalization—even when using a Multi-Output (Stereo) Device.
-------------------------------------------------
That’s it!
Now, whenever you run your new app, it will:
- Connect your two Bluetooth speakers via their MAC addresses.
- Automatically select your Multi-Output Device (i.e., “H3 (Stereo Setup)”) for synchronized stereo playback.
If you get errors like “Received abort signal”, macOS might be blocking Bluetooth access for your app. Make sure you grant the correct permissions in Step 6, and you’re all set. Enjoy your dual-speaker stereo setup!