WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: Disable console screen blanking  (Read 6083 times)

Offline tohox

  • Newbie
  • *
  • Posts: 25
Disable console screen blanking
« on: September 30, 2016, 12:00:23 PM »
Hi,

I noticed that the console screen goes blank after a few minutes and would like to disable this. Under Raspbian in /etc/kbd/config one could set BLANK_TIME=0 and POWERDOWN_TIME=0 to achieve this. What would the equivalent be under PiCore 8.0?

Thanks,

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: Disable console screen blanking
« Reply #1 on: September 30, 2016, 12:04:12 PM »
Not sure for the RPi but one of these usually work for me
Code: [Select]
setterm -blank 0
Code: [Select]
echo -e '\033[9;0]'
Download a copy and keep it handy: Core book ;)

Offline tohox

  • Newbie
  • *
  • Posts: 25
Re: Disable console screen blanking
« Reply #2 on: September 30, 2016, 12:11:57 PM »
Setterm doesn't seem to be available (I assume it is part of util-linux.tcz?) so I'll try echo -e '\033[9;0]'

Must this be entered on the console itself or would entering it from any SSH terminal window or a startup script work as well?

Thanks,

Offline Misalf

  • Hero Member
  • *****
  • Posts: 1702
Re: Disable console screen blanking
« Reply #3 on: September 30, 2016, 12:14:56 PM »
I don't know. I'd add it to  /opt/bootlocal.sh .
Download a copy and keep it handy: Core book ;)

Offline andyj

  • Hero Member
  • *****
  • Posts: 1036
Re: Disable console screen blanking
« Reply #4 on: September 30, 2016, 01:17:24 PM »
Try: xset s noblank

Offline tohox

  • Newbie
  • *
  • Posts: 25
Re: Disable console screen blanking
« Reply #5 on: September 30, 2016, 01:41:46 PM »
So far echo -e '\033[9;0]' works if entered from the physical console or a startup script but not if entered from an SSH terminal window which is fine for me.

Xset also appears to require the installation of a separate TCE extension as it isn't available to me currently.

Thanks!

Offline beerstein

  • Hero Member
  • *****
  • Posts: 530
Re: Disable console screen blanking
« Reply #6 on: October 02, 2016, 05:11:41 AM »
hi: please try:
$ xset s off -dpms &
and let me know whether it worked or not
t(w)o be(ers) or not t(w)o be(ers) that is the question

Offline tohox

  • Newbie
  • *
  • Posts: 25
Re: Disable console screen blanking
« Reply #7 on: October 03, 2016, 02:46:50 PM »
@Beerstein, thanks for the suggestion but I assume xset is used with X? My system is currently running headless.

echo -e '\033[9;0]' did the trick though.

thanks,

Offline xpector

  • Newbie
  • *
  • Posts: 16
Re: Disable console screen blanking
« Reply #8 on: March 16, 2018, 09:38:08 AM »
For the sake of completeness, here is where ESC[9;#] and other codes come from:

https://www.winds.org/pub/grdl/ANSI.txt -- ANSI Escape Codes List