summary |
shortlog |
log |
commit | commitdiff |
tree
raw |
patch |
inline | side by side (from parent 1:
b61ed90)
this used to come through op_lid.sh but that caused problems, as lid can
be configured to do things like suspend.
DEPENDS = "zenity dbus"
RDEPENDS = "zenity dbus"
DEPENDS = "zenity dbus"
RDEPENDS = "zenity dbus"
SRC_URI = " \
file://op_paths.sh \
SRC_URI = " \
file://op_paths.sh \
suspend_net
cat /proc/pandora/cpu_mhz_max > /tmp/oldspeed
suspend_net
cat /proc/pandora/cpu_mhz_max > /tmp/oldspeed
- /usr/pandora/scripts/op_cpuspeed.sh 125
+ /usr/pandora/scripts/op_cpuspeed.sh -n 125
}
lowPowerOff(){ # switch from lowpower to normal mode
oldspeed=$(cat /tmp/oldspeed)
}
lowPowerOff(){ # switch from lowpower to normal mode
oldspeed=$(cat /tmp/oldspeed)
- /usr/pandora/scripts/op_cpuspeed.sh $oldspeed
+ /usr/pandora/scripts/op_cpuspeed.sh -n $oldspeed
+elif [[ "$2" == "screensaver" ]]; then
+ # warning: don't try to interact with X or do real suspend here -
+ # will cause various deadlocks
+ unset DISPLAY
+
+ if [[ "$1" == 0 ]]; then # deactivate screensaver
+ display_on
+ elif [[ "$1" == 1 ]]; then # activate screensaver
+ display_off
+ fi
+fi
+
debug && echo "powerstate=$powerstate"
echo "$powerstate" > /tmp/powerstate
debug && echo "powerstate=$powerstate"
echo "$powerstate" > /tmp/powerstate