diff options
Diffstat (limited to 'sys-power/speedfreq/files/battery.sh')
-rwxr-xr-x | sys-power/speedfreq/files/battery.sh | 27 |
1 files changed, 0 insertions, 27 deletions
diff --git a/sys-power/speedfreq/files/battery.sh b/sys-power/speedfreq/files/battery.sh deleted file mode 100755 index b9da7d15da5e..000000000000 --- a/sys-power/speedfreq/files/battery.sh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -# Battery acpi script that set different speedfreq modes depending on AC adapter -# Can only handle one battery at the time, will add support for more when I get time -# -# To use this script add the following lines to /etc/acpi/events/default -# event=battery.* -# action=/etc/acpi/battery.sh %e - -set $* -source /etc/conf.d/speedfreq -[ "${SPEEDFREQ_SPEED}" != "auto" ] && exit 0 - -case "$2" in - BAT1) - if [ $4 -eq 00000001 ] && [ -f /proc/acpi/battery/BAT1/state ] ; then - action="`cat /proc/acpi/battery/BAT1/state | grep charging | cut -c 26-`" - case $action in - charging) /usr/bin/speedfreq -p performance - logger "A/C adapter plugged in" - ;; - discharging) /usr/bin/speedfreq -p powersave - logger "A/C adapter plugged out" - ;; - esac - fi - ;; -esac |