View Full Version : Let screen lit while slide open
dhcmega
03-09-2010, 12:11 PM
Hi
Is it possible to let the screen always on while the slide is open and return to normal configured screen time out while slide screen is close?
Thanks
dhcmega
No, not that I know of. You could try writing your own script.
An alternative is to use Simple Brightness Applet, and toggle "Keep display on."
dhcmega
03-16-2010, 11:24 AM
Yes, but I just want it to lit when it is opened, so I have to keep changing that config option all the time.
pelago
03-17-2010, 06:18 AM
This sounds like a good idea. It would be nice to be able to separately control timeouts whether the keyboard is open or closed.
nicolai
03-17-2010, 10:06 AM
You may try dbus-scripts.
Write a script to turn screen on every few seconds while
keybord open. And call this script from dbus-scripts when keyboard opened.
For example:
dbus-scripts setting:
/home/user/stay_lit.sh * * org.freedesktop.Hal.Device Condition ButtonPressed cover
Your script (/home/user/stay_lit.sh)
#!/bin/sh
# path to the keyboard slide state
SLIDE_PATH=/sys/devices/platform/gpio-switch/slide/state
TIMEOUT=25
read SLIDE_STATE < $SLIDE_PATH
while [ "$SLIDE_STATE" == "open" ]; do
# dbus-call to stop display blanking, I thought this one should turn light on
# for at least 60 seconds, but it depends on your display settings.
run-standalone.sh dbus-send --system --type=method_call --dest=com.nokia.mce /com/nokia/mce/request com.nokia.mce.request.req_display_blanking_pause
sleep $TIMEOUT
read SLIDE_STATE < $SLIDE_PATH
done
The TIMEOUT value has to be less than your display blank time.
regards nicolai
vBulletin® v3.8.2, Copyright ©2000-2012, Jelsoft Enterprises Ltd.