Re: dimm background light
Klaus Weidner <[email protected]>
| Newsgroups | gmane.linux.debian.devel.3com-pilot |
|---|---|
| Message-ID | <[email protected]> |
On Tue, Oct 21, 2003 at 04:10:50PM +0000, Joerg Sommer wrote: > how can I dimm or turn off the background light on the console? If you're running zapmd, you can echo a value from 0 to 100 to /dev/zapmd (or use the "light" shell script included w/ my distribution). This doesn't give you maximum brightness though on the SL-C7x0, there you can instead use "echo 0xFFFF > /proc/driver/fl/corgi-bl" (or any hex value from 0..0xffff. I've appended the "bl" shell script I'm currently using on my C750 which keeps state information saved in /tmp/llevel.dat, so that the Fn-OK shortcut key in the fbvnc client will cycle through a series of brightness levels. -Klaus
bl
(text/plain, 426 B)
#!/bin/sh [ -e /dev/zapmd ] || exit 1 if [ ! -f /proc/driver/fl/corgi-bl ] then echo light > /dev/zapmd & exit 0 fi LEVFILE=/tmp/llevel.dat LEVEL=0x0105 [ -f $LEVFILE ] && LEVEL=`cat $LEVFILE` case $LEVEL in 0x0000) LEVEL=0xFFFF ;; 0xFFFF) LEVEL=0x0105 ;; 0x0105) LEVEL=0x000B ;; 0x000B) LEVEL=0x0005 ;; 0x0005) LEVEL=0x0001 ;; 0x0001) LEVEL=0x0000 ;; esac echo $LEVEL > /proc/driver/fl/corgi-bl echo $LEVEL > $LEVFILE