I’m using workrave to remind me to take breaks from the computer. It is a program that assists in the recovery and prevention of Repetitive Strain Injury (RSI). The program frequently alerts you to take micro-pauses, rest breaks etc., which in my case is a bit too frequent. I do not deal with RSI — I just want to avoid prolonged sitting sessions, which might be detrimental to one’s health.
There’s no way to configure idle detection parameters in the workrave UI, but they can be tuned by directly manipulating gsettings (or gconf for older versions). There are 3 parameters of interest (in milliseconds):
- activity — how much time between key presses, to register activity (see bellow).
- idle — how long before activity time expires and workrave goes back into idle mode.
- noise — how long before activity timer is reset.
By default, single key press isn’t enough to take workrave out of idle mode — you must press at least two keys (or key + mouse) during the activity window to count. With default settings if you press single key every 10 seconds, you are still detected as idle. For example reading a web page, and pressing PgDn every 20 seconds, won’t register as activity at all. There’s “Reading” mode for this in workrave, but you must remember to turn it on/off when you suddenly go away (long phone call?) from the computer.I’ve set my workrave to activity = 0, idle = 30. This is: every key press is activity and then I’m in active mode for the following 30 seconds. Here’s how to do it:
$ gsettings set org.workrave.monitor activity 0 $ gsettings set org.workrave.monitor idle 30000 $ gsettings list-recursively org.workrave.monitor org.workrave.monitor activity 0 org.workrave.monitor idle 30000 org.workrave.monitor noise 9000
You must restart workrave for settings to take effect. Use gconf-editor for workrave versions < 1.10. If you are using Ubuntu, there’s 1.10 ppa: https://launchpad.net/~rob-caelers/+archive/workrave