Skip to content

Instantly share code, notes, and snippets.

@sandorkazi sandorkazi/
Last active Jul 8, 2018

What would you like to do?
bluetooth headset autoconfig
if [ "" != "${ADDRESS}" ]; then
echo ">>> RESTART bluetooth"
sudo systemctl restart bluetooth
sleep 2
echo -e "connect ${ADDRESS}\nexit\n" | bluetoothctl
sleep 4
DEVICE_ID=`pactl list cards short | grep "bluez_card.${ADDRESS//:/_}" | cut -f1`
pacmd set-card-profile ${DEVICE_ID} a2dp_sink
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.