Comment 107 for bug 95444

Revision history for this message
Shawe Ewahs (shawe-ewahs) wrote : Re: No Screen Backlight Control; Sony Vaio with nvidia 8 series graphics

More information:

/etc/acpi/events/sony-brightness-down

With this:

# /etc/acpi/events/sony-brightness-down
event=sony/hotkey SNC 00000001 00000010
action=/etc/acpi/sonybright.sh down

/etc/acpi/events/sony-brightness-up

With this:

# /etc/acpi/events/sony-brightness-up
event=sony/hotkey SNC 00000001 00000011
action=/etc/acpi/sonybright.sh up

/etc/acpi/sonybright.sh

With this:

#!/bin/bash
if [ "x$1" = "xdown" ]; then
# xbacklight -time 100 -steps 10 -dec 10 2>/tmp/sonybright.log
        nvclock -S -10
elif [ "x$1" = "xup" ]; then
# xbacklight -time 100 -steps 10 -inc 10 2>/tmp/sonybright.log
        nvclock -S +10
else
   echo >&2 Unknown argument $1
fi

sudo /etc/init.d/acpid restart
sudo /etc/init.d/hal restart

And Fn+F5 and Fn+F6 works, only fail that don't show the correct % in graph.
I think that graphical % fails because:
/usr/lib/hal/scripts/linux/hal-system-lcd-set-brightness-linux
and
/usr/lib/hal/scripts/linux/hal-system-lcd-get-brightness-linux
aren't working correctly. Only this fault.