4

I'm on the similar project and issue as OP with screen-blanking (HDMI output), running a Raspbian Server 2.4:

The standard user pi logs the session that auto-starts after a boot.

I have tried different approaches with no luck:

.xinitrc

exec unclutter -root -noevents &
while sleep 5
do
        $HOME/websnurra-ng/websnurra-ng http://test.se
done

xset s off
xset s noexpose
xset -dpms
xset s noblank
setterm -blank 0 -powersave off -powerdown 0

/etc/X11/xinit/xinitrc

#!/bin/sh

# /etc/X11/xinit/xinitrc
#
# global xinitrc file, used by all X sessions started by xinit (startx)

# invoke global X session script
. /etc/X11/Xsession
xset s off
xset -dpms
xset s noblank
setterm -blank 0 -powersave off -powerdown 0

/etc/rc.local

setterm -blank 0 -cursor off

I have run the xset commands manually in the terminal and they execute correct viewing xset q just as they do when I boot the configuration files, although the screen still blanks out after some minutes.

I wanted to execute them as root, to see if that would make a difference, but end up with an error message:

X11 connection rejected because of wrong authentication.
xset:  unable to open display "localhost:10.0"

Permissions:

pi@raspberrypi ~ $ ls -la

totalt 112
drwxr-xr-x 8 pi   pi    4096 okt 18 11:39 .
drwxr-xr-x 3 root root  4096 maj 25 18:35 ..
-rw------- 1 pi   pi    4184 okt 18 11:31 .bash_history
-rw-r--r-- 1 pi   pi     220 maj 25 18:35 .bash_logout
-rw-r--r-- 1 pi   pi    3243 maj 25 18:35 .bashrc
drwxr-xr-x 3 pi   pi    4096 okt 15 14:53 .config
drwxr-xr-x 2 pi   pi    4096 jun 12 14:01 Desktop
drwxr-xr-x 2 pi   pi    4096 okt  8 15:03 .gstreamer-0.10
-rw-r--r-- 1 pi   pi    5781 feb  3  2013 ocr_pi.png
-rwxr-xr-x 1 pi   pi     175 jun 12 16:00 pkgs.sh
-rw-r--r-- 1 root root 36740 jun 12 15:23 pkgs.txt
-rw-r--r-- 1 pi   pi     675 maj 25 18:35 .profile
drwxrwxr-x 2 pi   pi    4096 mar 10  2013 python_games
drwx------ 2 pi   pi    4096 okt 15 14:32 .ssh
drwxr-xr-x 3 pi   pi    4096 okt 18 08:25 websnurra-ng
-rw------- 1 pi   pi      57 okt 18 11:39 .Xauthority
-rw-r--r-- 1 pi   pi     210 okt 18 11:25 .xinitrc
-rw-r--r-- 1 pi   pi     181 okt 17 09:40 .xinitrc.save

pi@raspberrypi /etc/X11/xinit $ ls -la

totalt 16
drwxr-xr-x 2 root root 4096 okt  8 14:03 .
drwxr-xr-x 9 root root 4096 okt  8 14:04 ..
-rw-r--r-- 1 root root  246 okt 18 11:25 xinitrc
-rwxr-xr-x 1 root root   56 okt 17 10:33 xserverrc

pi@raspberrypi /etc $ ls -la rc.local

-rwxr-xr-x 1 pi pi 553 okt 18 13:40 rc.local

3 Answers 3

3

I created a xorg.conf file with the following input and now it stays up:

Section "Monitor"
    Identifier "Monitor"
    Option "DPMS" "false"
EndSection

Section "ServerLayout"
    Identifier "ServerLayout0"
    Option "BlankTime"  "0"
    Option "StandbyTime" "0"
    Option "SuspendTime" "0"
    Option "OffTime" "0"
EndSection
1

What I did to disable screen blanking on my Raspberry Pi 2 with Raspbian.

Created a file on /etc/X11/Xsession.d/:

# /etc/X11/Xsession.d/98x11-screen_blank
xset s off
xset -dpms
xset s noblank

Be sure you have xset installed. The latest Raspbian already have it.

0

Just wanted to put this out there so others searching for this very issue (screen blanking) could find this answer useful.

In /etc/xdg/lxsession there are two directories (LXDE and LXDE-pi)

NOTE: This is if you are using the GUI (ex: in my case booting to terminal then using startx)

Many forums are saying to edit the autostart file in LXDE but that did not resolve my issue. What did is to edit the autostart in LXDE-pi with the below.

@lxpanel --profile LXDE-pi
@pcmanfm --desktop --profile LXDE-pi
#@xscreensaver -no-splash

@xset s noblank
@xset s off
@xset -dpms

Then perform a reboot if needed.
The version currently using is:
Version: Raspbian GNU/Linux 7 \n \l

Hope someone finds this useful..

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.