From ca610bca9cbc662b62c12a36382981b612d27071 Mon Sep 17 00:00:00 2001 From: Michael Mrozek Date: Wed, 8 Sep 2010 02:20:11 +0200 Subject: [PATCH] op_bright_down.sh & op_bright_up.sh: Changed brightness so that values of 1 and 2 are not possible. --- testdata/scripts/op_bright_down.sh | 2 +- testdata/scripts/op_bright_up.sh | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) 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 -- 2.39.2