summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbrightness-control13
1 files changed, 13 insertions, 0 deletions
diff --git a/brightness-control b/brightness-control
new file mode 100755
index 0000000..ebc0f1b
--- /dev/null
+++ b/brightness-control
@@ -0,0 +1,13 @@
+#!/bin/sh
+
+if [ $(id -u) -ne 0 ]; then
+ echo "Please use this with root privileges"
+ exit 2
+fi
+
+if [ $# -ne 1 ]; then
+ echo "Usage $0: brightness"
+ exit 2
+fi
+
+su -c "echo $1 > /sys/devices/pci0000:00/0000:00:02.0/drm/card0/card0-LVDS-1/intel_backlight/brightness"