Cool bluetooth device detection in kbluetoothd
Well, while I was playing with bluetooth proximity detection.(see previous post) I discovered some really cool things about kbluetoothd!
If you go to configuration from the menu you can go to Configure Services.
This brings up a dialog with three tabs. The one that most interested me is the one named "Device Discovery" On this tab you can create jobs from templates they have already created to do things like lock the screen and perform custom activation actions.
That is what I used it for. Now when I activate my bluetooth headset it automatically runs my little script to turn on bt_sco. This is great. I think it could also be used to do the screensaver thing but when I tried it, it was not updating fast enough to make it worth while. So, I am still using the proximity script from the privious post but I used dcop to start and stop the screensaver.
The commands I used are:
FAR_CMD='dcop kdesktop KScreensaverIface lock'
NEAR_CMD='dcop kdesktop KScreensaverIface quit'
I also used the suggestion made by one of the commenters in the cool solution and started the script like
./proximity > /dev/null ?
Tomorrow I find that directory that I have to put it in to get it to happen when I login.
If you go to configuration from the menu you can go to Configure Services.
This brings up a dialog with three tabs. The one that most interested me is the one named "Device Discovery" On this tab you can create jobs from templates they have already created to do things like lock the screen and perform custom activation actions.
That is what I used it for. Now when I activate my bluetooth headset it automatically runs my little script to turn on bt_sco. This is great. I think it could also be used to do the screensaver thing but when I tried it, it was not updating fast enough to make it worth while. So, I am still using the proximity script from the privious post but I used dcop to start and stop the screensaver.
The commands I used are:
FAR_CMD='dcop kdesktop KScreensaverIface lock'
NEAR_CMD='dcop kdesktop KScreensaverIface quit'
I also used the suggestion made by one of the commenters in the cool solution and started the script like
./proximity > /dev/null ?
Tomorrow I find that directory that I have to put it in to get it to happen when I login.
0 Comments:
Post a Comment
<< Home