View Single Post
Posts: 4 | Thanked: 4 times | Joined on Feb 2010
#229
at last: Radio Alarm Clock

Daily command execution at 6:45 of /home/user/start_radio.sh

and here is start_radio.sh:

Code:
#!/bin/sh

#unlock phone
dbus-send --system --type=method_call --dest=com.nokia.mce /com/nokia/mce/request com.nokia.mce.request.req_tklock_mode_change string:"unlocked" | echo ""

sleep 5

# connect to known internet connection
dbus-send --system --type=method_call --dest=com.nokia.icd /com/nokia/icd com.nokia.icd.connect string:"[ANY]" uint32:0 | echo ""

sleep 20

# open browser
/usr/bin/browser_dbuscmd.sh open_new_window | echo ""

sleep 5

# load BBC Radio 4 live stream in browser
/usr/bin/browser_dbuscmd.sh load_url http://www.bbc.co.uk/iplayer/console/bbc_radio_fourfm | echo ""
many thanks to shapeshifter for at last making one of my favourite use cases possible

Last edited by lrose; 2010-06-19 at 13:32. Reason: works now
 

The Following 3 Users Say Thank You to lrose For This Useful Post: