From: Michael Mrozek Date: Wed, 8 Sep 2010 00:20:11 +0000 (+0200) Subject: op_bright_down.sh & op_bright_up.sh: Changed brightness so that values X-Git-Tag: sz_beta3~119 X-Git-Url: https://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ca610bca9cbc662b62c12a36382981b612d27071;p=pandora-libraries.git op_bright_down.sh & op_bright_up.sh: Changed brightness so that values of 1 and 2 are not possible. --- diff --git a/testdata/scripts/op_bright_down.sh b/testdata/scripts/op_bright_down.sh index 1de2be9..2e79385 100755 --- a/testdata/scripts/op_bright_down.sh +++ b/testdata/scripts/op_bright_down.sh @@ -12,7 +12,7 @@ elif [ "$cur" -gt "0" ]; then new=$(($cur-1)) fi -if [ "$new" -lt "0" ]; then +if [ "$new" -lt "3" ]; then new=0 fi diff --git a/testdata/scripts/op_bright_up.sh b/testdata/scripts/op_bright_up.sh index f8df260..2619004 100755 --- a/testdata/scripts/op_bright_up.sh +++ b/testdata/scripts/op_bright_up.sh @@ -11,11 +11,13 @@ elif [ "$cur" -gt "5" ]; then elif [ "$cur" -gt "0" ]; then new=$(($cur+1)) elif [ "$cur" -eq "0" ]; then - new=$(($cur+1)) + new=3 fi if [ "$new" -gt "54" ]; then new=54 fi + + echo $new > /sys/devices/platform/twl4030-pwm0-bl/backlight/twl4030-pwm0-bl/brightness