How do I programmatically change the monitor brightness on Linux?
I\'m using SLES 11.
If you have multiple displays and php installed, put this in
/usr/bin/brightness
#!/usr/bin/php
$br=(double)$argv[1];
if(!$br||$br>1) die("enter brightness lvl 0.1 - 1");
preg_match_all('!^(\S+)!m',`xrandr --current | grep ' connected'`,$m);
foreach($m[1] as $display){
echo `xrandr --output $display --brightness $br`."\n";
}
than call brightness .7