ACPI Script for bluetooth
I wrote a little bluetooth script for acpi. It's run when a fn+f5 hotkey is pressed on the thinkpad:
Code:
#!/bin/bash There is one problem with it. When the script is trying to do 'modprobe -r hci_usb', it says that the module is busy, but when I try to run the command manually right after the script was run, it works perfectly. Any ideas what's going on? |
That's not the entire script is it ? There is a 'fi' after that right ? and perhaps an 'exit 0' too ?
Does it work to make a script that just runs 'modprobe -r hci_usb' ? Does it give you the same error, or just the sequence there ? Code:
modprobe -r rfcomm As for echoing things into '/proc' ... I don't think it's a good idea :), but whatever you wanna do. |
Yeah, I created a test.sh with that one line and it works, but it won't work from within this script..
Yeah, I think I solved it. rfcomm and l2cap libs just don't have enough time to be removed first. I tried inserting a sleep statement before hci_usb and it worked. |
Try this:
Code:
while : |
All times are GMT -5. The time now is 04:18 PM. |