keeblebrox

a2dp-disconnect.sh

Jul 27th, 2011
165
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.48 KB | None | 0 0
  1. #!/bin/bash
  2. # Copyright 2011 Brian Crockford
  3. # a2dp-disconnect.sh
  4.  
  5. # For reversing the connection instructions
  6. # http://ubuntuforums.org/showpost.php?p=9511043&postcount=10
  7.  
  8. # disconnect the device
  9. dbus-send --system --dest=org.bluez --type=method_call /org/bluez/4546/hci0/dev_00_23_76_79_08_D8 org.bluez.AudioSource.Disconnect
  10. # unlink the audio stream
  11. MODULE_NUMBER=$(pactl list | grep -B 1 "Name: module-loopback" | sed -n '1 s/[^0-9]*//gp')
  12. pactl unload-module $MODULE_NUMBER
Advertisement
Add Comment
Please, Sign In to add comment