Control intel backlight on FreeBSD (and OpenBSD)
openbsd
at master 51 lines 1.4 kB view raw
1This allows to control the backlight level on certain Intel(R) GPUs, 2including i915. 3 4This has been taken from intel-gpu-tools which can be found 5here: http://cgit.freedesktop.org/xorg/app/intel-gpu-tools/ 6 7Originally ported to FreeBSD by "emmex" of the FreeBSD forums. 8 9FreeBSD Build: 10 pkg install libpciaccess libdrm 11 make 12 make install 13 14OpenBSD Build: 15 make 16 make install 17 18(this installs intel_backlight setuid root, so any user can execute it). 19 20Usage: 21 $ intel_backlight 22 current backlight value: 30% (281/937) 23 $ intel_backlight 50 24 current backlight value: 15% (141/937) 25 set backlight to 50% (469/937) 26 $ intel_backlight incr 27 current backlight value: 50% (469/937) 28 set backlight to 51% (478/937) 29 $ intel_backlight incr 30 current backlight value: 51% (478/937) 31 set backlight to 60% (562/937) 32 $ intel_backlight incr 33 current backlight value: 60% (562/937) 34 set backlight to 70% (656/937) 35 $ intel_backlight decr 36 current backlight value: 70% (656/937) 37 set backlight to 60% (562/937) 38 $ intel_backlight decr 39 current backlight value: 60% (562/937) 40 set backlight to 51% (478/937) 41 42The included example allows adjusting brightness automatically based on the 43input of the isl driver (currently not part of standard FreeBSD). 44 45Usage: 46 ./isl_backlight.sh & 47 48 49OpenBSD Notes: 50Requires a kernel capable of concurrent opening of /dev/xf86, via 51machdep.allowaperture=3.