Last active
December 26, 2015 03:39
-
-
Save vo/7087584 to your computer and use it in GitHub Desktop.
Lenovo Y500 Backlight Control
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
sudo ./NVIDIA-Linux-x86_64-319.23.run -e -Z --opengl-headers |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
event=video LCD 00000087 00000000 | |
action=/etc/acpi/lenovo_backlight.sh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
event=video LCD 00000086 00000000 | |
action=/etc/acpi/lenovo_backlight.sh |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/bash | |
test -f /sys/class/backlight/nvidia_backlight/brightness || exit 0 | |
NEW_VALUE=`cat /sys/class/backlight/acpi_video0/brightness` | |
let BRIGHTNESS=$NEW_VALUE*127/100 | |
echo -n $BRIGHTNESS > /sys/class/backlight/nvidia_backlight/brightness |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment