- Status Closed
- Percent Complete
- Task Type Bug Report
- Category Core
- Operating System All
- Severity Low
- Reported Version SuperZaxxon Beta 4
Attached to Project: OpenPandora Main OS
Opened by Michael Mrozek - 11.01.2010
Last edited by Michael Mrozek - 27.01.2010
Opened by Michael Mrozek - 11.01.2010
Last edited by Michael Mrozek - 27.01.2010
FS#21 - op_bright.sh doesn't work correctly
The file has to be changed to make it work.
The working script is:
#!/bin/bash
#get value range
minbright=3
maxbright=$(cat /sys/devices/platform/twl4030-pwm0-bl/backlight/twl4030-pwm0-bl/max_brightness)
curbright=$(cat /sys/devices/platform/twl4030-pwm0-bl/backlight/twl4030-pwm0-bl/brightness)
device=/sys/devices/platform/twl4030-pwm0-bl/backlight/twl4030-pwm0-bl/brightness
if [ ! $1 ]; then
newbright=$(DISPLAY=0:0 zenity --scale --text "set brightness" --min-value=$minbright --max-value=$maxbright --value=$curbright --step 1)
else
newbright=$1
fi
if [ $newbright -le $minbright ]; then newbright=$newbright; fi
echo $newbright > $device