stop screen from blanking

Have some feedback, questions, suggestions, or just fancy a chat? Pop it in here.
Post Reply
nitrogen_widget

stop screen from blanking

Post by nitrogen_widget »

Can we stop the screen from blanking due to inactivity?
I tried installing xscreensaver but the deamon wouldn't run from root.

Want to use this for an arcade cabinet and want to keep the screen from turning off.
rhkean@gmail.com

Re: stop screen from blanking

Post by rhkean@gmail.com »

I agree. This can be frustrating... especially when attempting to monitor a fully automated install with no keyboard attached. (I have a bluetooth keyboard that doesn't activate until the end of my install 45-55 minutes later....)

I believe that this issue is further upstream in the kernel (framebuffer module is my guess), though.

There may be a config.txt or module parameter setting that can be changed, though. I'll take a peak into the settings and see.

BTW, which board are you using?
rhkean@gmail.com

Re: stop screen from blanking

Post by rhkean@gmail.com »

I think I found what you're looking for. Check out this post: https://www.raspberrypi.org/forums/view ... 66&t=18200

basically, edit /etc/kbd/config
and set
BLANK_TIME=0
POWERDOWN_TIME=0

then reboot or /etc/init.d/kbd restart

I'm at work right now, so I haven't tested this yet. I'll do some preliminary testing tonight. I don't think that it's a good idea to make this a default change, but, perhaps set it during dietpi-software installs then reset it before the reboots....
User avatar
Fourdee
Site Admin
Posts: 2788
Joined: Tue Feb 06, 2007 1:36 pm

Re: stop screen from blanking

Post by Fourdee »

Just to add to Rhkean's post. You can disable the powersaving option on the current screen with:

Code: Select all

setterm -blank 0 -powersave off
But if you want a system-wide and reboot proof method, check Rhkean's post above.
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal or become a DietPi patron.
rhkean@gmail.com

Re: stop screen from blanking

Post by rhkean@gmail.com »

Fourdee wrote:Just to add to Rhkean's post. You can disable the powersaving option on the current screen with:

Code: Select all

setterm -blank 0 -powersave off
But if you want a system-wide and reboot proof method, check Rhkean's post above.
Dan,
Do you think there would be an issue with adding this to the dietpi-software automated install logic?
like, around line dietpi-software:4630, if we are entering automation, disable screen blanking until next reboot....

-rob
nitrogen_widget

Re: stop screen from blanking

Post by nitrogen_widget »

Thanks guys!
I'll be using rpi2/3 boards.

I'll give it a try tonight!
User avatar
k-plan
Posts: 416
Joined: Sun Feb 28, 2016 5:28 pm

Re: stop screen from blanking

Post by k-plan »

Hi,
rhkean@gmail.com wrote:Do you think there would be an issue with adding this to the dietpi-software automated install logic?
like, around line dietpi-software:4630, if we are entering automation, disable screen blanking until next reboot..
hmm, if you will do, please only for RPi. It may work (not tested), but not on all other devices.

Code: Select all

root@Odroid-C2:~# setterm -blank 0 -powersave off
setterm: terminal xterm does not support --blank
setterm: cannot (un)set powersave mode: Unpassender IOCTL (I/O-Control) für das Gerät
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal and Bitcoin.
User avatar
Fourdee
Site Admin
Posts: 2788
Joined: Tue Feb 06, 2007 1:36 pm

Re: stop screen from blanking

Post by Fourdee »

rhkean@gmail.com wrote:
Fourdee wrote:Just to add to Rhkean's post. You can disable the powersaving option on the current screen with:

Code: Select all

setterm -blank 0 -powersave off
But if you want a system-wide and reboot proof method, check Rhkean's post above.
Dan,
Do you think there would be an issue with adding this to the dietpi-software automated install logic?
like, around line dietpi-software:4630, if we are entering automation, disable screen blanking until next reboot....

-rob
Good idea Rob, never thought of it. I think it would be best placed at the start and inside of Run_Installations function. I've created a Git ticket for this, your more than welcome to add this in if you like :)
https://github.com/Fourdee/DietPi/issues/277
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal or become a DietPi patron.
User avatar
Fourdee
Site Admin
Posts: 2788
Joined: Tue Feb 06, 2007 1:36 pm

Re: stop screen from blanking

Post by Fourdee »

k-plan wrote:Hi,
rhkean@gmail.com wrote:Do you think there would be an issue with adding this to the dietpi-software automated install logic?
like, around line dietpi-software:4630, if we are entering automation, disable screen blanking until next reboot..
hmm, if you will do, please only for RPi. It may work (not tested), but not on all other devices.

Code: Select all

root@Odroid-C2:~# setterm -blank 0 -powersave off
setterm: terminal xterm does not support --blank
setterm: cannot (un)set powersave mode: Unpassender IOCTL (I/O-Control) für das Gerät
This will only affect the main screen. Does not get applied to SSH sessions. We could probably redirect stdout to prevent the warning from appearing.
If you find our project or support useful, then we’d really appreciate it if you’d consider contributing to the project however you can.
Donating is the easiest – you can use PayPal or become a DietPi patron.
Post Reply