Skip to content

Instantly share code, notes, and snippets.

@dvf
Last active April 12, 2024 06:15
Show Gist options
  • Save dvf/3771e58085568559c429d05ccc339219 to your computer and use it in GitHub Desktop.
Save dvf/3771e58085568559c429d05ccc339219 to your computer and use it in GitHub Desktop.
Enable High Quality mode on your headphones (Updated for macOS Catalina)

If you're using a high-end bluetooth headset on your Macbook Pro it's likely your mac is using an audio codec which favors battery efficiency over high quality. This results in a drastic degradation of sound, the SBC codec is the likely culprit, read more about it here.

Find out what codec you're using

  1. Play a song on your headphones
  2. Option (⌥) click the Bluetooth button at the top of your screen Inspect the Bluetooth Coded
  3. If you're using AAC or aptX, you can stop here—those are the highest quality codecs.

Change your codec to AAC or aptX

UPDATE: It looks like Apple has silently dropped support for aptX, leaving only AAC

You'll need to download Apple's Bluetooth Explorer in order to change codecs.

  1. Head over to Apple's Developer Downloads

  2. Search for additional tools and download Additional Tools for XCode 11.dmg Search for "additional tools"

  3. Open the dmg, and open Bluetooth Explorer Open Bluetooth Explorer

  4. Click on Tools > Audio Options and change your audio codec to the following settings:

    • Enable AAC
    • Force use of aptX
    Change your audio codec
  5. Disconnect your Bluetooth headset, reconnect it, and while some music is playing, inspect your codec. It should now show either AAC or aptX.

    Your codec should now show AAC/aptX

Squeezing the most out of AAC

You can increase the AAC bitrate in Audio Options but be sure to keep an eye on the graphs. The retransmission percentage is roughly equivalent to packet loss, and if you increase the bitrate too high your audio will start cutting out:

The retransmission rate is a function of distance and interference, and you'll need to disconnect/reconnect on each attempt before you find the sweet spot.

@gr3ddy
Copy link

gr3ddy commented Jan 20, 2024

But the bitrate value in console hasn't changed🤔

Try by restarting the computer. If that doesn't work it probably means your headphones are not capable of higher bitrates.

Also you could try the increasing the bitpool even more. It probably won't work if the headphones have a limit, but it's worth trying:

defaults write com.apple.BluetoothAudioAgent "Apple Bitpool Max (editable)" 320;
defaults write com.apple.BluetoothAudioAgent "Apple Bitpool Min (editable)" 2;
defaults write com.apple.BluetoothAudioAgent "Apple Initial Bitpool (editable)" 320;
defaults write com.apple.BluetoothAudioAgent "Negotiated Bitpool" 320;
defaults write com.apple.BluetoothAudioAgent "Negotiated Bitpool Max" 320;
defaults write com.apple.BluetoothAudioAgent "Negotiated Bitpool Min" 2;
defaults write com.apple.BluetoothAudioAgent "Stream - Flush Ring on Packet Drop (editable)" 0;
defaults write com.apple.BluetoothAudioAgent "Stream - Max Outstanding Packets (editable)" 1;
defaults write com.apple.BluetoothAudioAgent "Stream Resume Delay" "0.75"

defaults write bluetoothaudiod "Enable AAC codec" -bool true
defaults write bluetoothaudiod "AAC Bitrate" -int 320
defaults write bluetoothaudiod "AAC max packet size" -int 644

I'm using an "Alternative A2DP Driver" on Windows PC and it works properly with higher bitpool values. Anyway, now I'm trying to enable 320kbit/s bitrate for AAC codec.

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