maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Applications (https://talk.maemo.org/forumdisplay.php?f=41)
-   -   [Announce] fcron wiki entry - schedule anything at anytime (https://talk.maemo.org/showthread.php?t=47369)

rooted 2010-03-14 20:32

[Announce] fcron wiki entry - schedule anything at anytime
 
http://wiki.maemo.org/Fcron

You can use this simple yet powerful tool to schedule just about anything at anytime. You can schedule:

- profiles
- backup scripts
- resetting the GPRS counter every month
- disconnection and connection of mobile network or internet
- 3G/2G/Dual radio modes
- NTP update
- email notify/refresh
- brightness level
- locking
- rebooting
- your own scripts
- ...

The wiki entry covers why is using fcron the best way for scheduling events, installation and configuration guide and some scripts.

rooted 2010-03-15 17:43

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
The sample configuration file in the wiki has been updated with a very important function and whoever did already set fcron up should re-configure it (the difference is that in the new sample config GPRS counter reset is also performed on the next boot if the phone was off at 00:00 or whenever did you set it up).

bugelrex 2010-03-15 17:53

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
Can you provide a sample if I wanted to:
- turn off internet (but keep phone) at 01:00 and turn back on at 07:00 (thus allowing any IM's to be received)

I couldnt figure out how to reconnect, I tried:
dbus-send --system --dest=com.nokia.icd /com/nokia/icd_ui com.nokia.icd_ui.disconnect boolean:false

dbus-send --system --dest=com.nokia.icd /com/nokia/icd_ui com.nokia.icd_ui.connect boolean:true


Thanks!

rooted 2010-03-15 18:18

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
0 1 * * * /disconnect/script
0 7 * * * /connect/script

disconnect script is in the fcron wiki (but I think you got it right)
connect script is wrong, because you have to specify what should phone connect to, you can't just type a command connect and expect that phone will know to which connection :D

the info you need is to be found: http://wiki.maemo.org/Phone_control#...ved_connection

also check out Phone control wiki page extensively, because it also contains dbus calls to control IM...

pete.fu 2010-03-15 19:31

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
On the wiki page it says that fcron sleeps between events, does that imply that it doesn't affect the battery life at all?

rooted 2010-03-15 20:24

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
That's right, there is no difference in battery times. I definitely trust fcron more than alarm daemon and a few other Nokia daemons...

bugelrex 2010-03-16 20:03

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
Quote:

Originally Posted by rooted (Post 568152)
0 1 * * * /disconnect/script
0 7 * * * /connect/script

disconnect script is in the fcron wiki (but I think you got it right)
connect script is wrong, because you have to specify what should phone connect to, you can't just type a command connect and expect that phone will know to which connection :D

the info you need is to be found: http://wiki.maemo.org/Phone_control#...ved_connection

also check out Phone control wiki page extensively, because it also contains dbus calls to control IM...

Unfortunately (no fault of fcron), the disconnect at 1am would eventually be re-connected by the OS if you have "automatically switch to wifi". Any other way to disable IM's during bedtime but still allow phone calls (possible emergencies)?

rooted 2010-03-17 16:01

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
disable wlan during the night. scripts are in the wiki.

oneFinn 2010-03-19 05:00

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
Hi,

I set up fcron according to instructions. Everything looks ok, but nothing happens..:) No errors either..

according to ps, fcron seems to be running and fcrontab -e works

I tried to run dbus-send (phone to silent/general mode) scripts manually with run-standalone.sh. Also...nothing happens.

What might be wrong?

lemmyslender 2010-03-19 12:40

Re: [Announce] fcron wiki entry - schedule anything at anytime
 
Quote:

Originally Posted by bugelrex (Post 569646)
Unfortunately (no fault of fcron), the disconnect at 1am would eventually be re-connected by the OS if you have "automatically switch to wifi". Any other way to disable IM's during bedtime but still allow phone calls (possible emergencies)?

Use a Tweakr profile for night: turn volume down for email, im, sms, etc and leave ringer volume up.

Then you just need to run a script to switch your profile at night and in the morning.


All times are GMT. The time now is 12:05.

vBulletin® Version 3.8.8