BMX Bicycle freestyle
BMX Bicycle freestyle

Friday, April 16, 2010

Distribute Mice and other controlers usage on time for better ergonomics


Software for ergonomic computer usage

Most computers today are controlled with mouse, keyboard. There is slight chance that you use pen, fingers (touch screen), gamepad and other controllers. Time distribution on each controller usage can be controled by software.

Basicaly if you used your mouse mostly for last half hour, you should switch to keyboard

Case: waiting time during sites&blogs load.
In this case a bash script is used to load differet url adresses.
Because line is slow it take about 40 s to load all websites. While waiting, game is played. Based on previous mouse usage (high or low) user get different game that use only keboard or only mouse (if previous mouse usage was low)

mousemovementssize=$(stat -c%s /home/user/mousemovementsfile)
if [ $mousemovementssize -gt 66000 ]
then
xgalaga&
else
mahjongg&
fi
fi

note that both games should be configured to run in fullscreen to prevent firefox from stealing focus.
(mousemouvementsfile is file that contain data from mouse.)
cat -n /dev/input/mice > mousemovementsfile&
(need to give persmission)
* * * * * sudo chmod 755 /dev/input/mice


if you have problems on this comment.

0 comments:

Post a Comment