[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: APM console blanking



On Thu, Jun 21, 2001 at 09:13:40PM -0400, Rick Pasotto wrote:
> On Thu, Jun 21, 2001 at 05:53:17PM -0700, Brian McGroarty wrote:
> > Thanks, setterm sure looks like where it should be, but no good
> > so far. And unfortunately, this is a DVI display with no
> > workable off switch, so this really needs to work.
> > 
> > No dice on the above or setterm with -powersave powerdown. The
> > screen goes blank, but does not shut off - the backlight is
> > still burning.
> > 
> > I know from past experience that if I enable APM and console
> > display blanking in a custom kernel it works on this machine -
> > sure should be possible without that though.

Any laptop may do it differently at the hardware (port) level.  
No way for the generic console driver to know each and every one.
APM lets you ask the bios to do it for you IIRC.  Cross fingers
that your bios is not buggy.

> I found the original email and it had the following comments:
> 
>   setterm -blank 5 -powersave on  # dpms on
>   echo -en "\033[9;8]"            # suspend after 10 min
>   echo -en "\033[14;10]"          # off after 30 min
> 
> I can't find any documentation to explain the values but I remember
> playing with them and it's the echo statements that tell the monitor
> to go to sleep.

Never believe the comments blindly though.  Someone might tweak some
bits and not update the comment part, like above happened  :-P

You made me look it up in console_codes(4) again.  Enjoy:

   Linux Console Private CSI Sequences
       The following sequences are  neither  ECMA-48  nor  native
       VT102.  They are native to the Linux console driver.  Col­
       ors are in SGR parameters: 0 = black, 1 = red, 2 =  green,
       3 = brown, 4 = blue, 5 = magenta, 6 = cyan, 7 = white.

       ESC [ 1 ; n ]       Set color n as the underline color
       ESC [ 2 ; n ]       Set color n as the dim color
       ESC [ 8 ]           Make the current color pair the default attributes.
       ESC [ 9 ; n ]       Set screen blank timeout to n minutes.
       ESC [ 10 ; n ]      Set bell frequency in Hz.
       ESC [ 11 ; n ]      Set bell duration in msec.
       ESC [ 12 ; n ]      Bring specified console to the front.
       ESC [ 13 ]          Unblank the screen.
       ESC [ 14 ; n ]      Set the VESA powerdown interval in minutes.

Cheers,


Joost



Reply to: