How can I stop my TV from turning off when my Linux box is idle?
I have a box running kodi in standalone mode with X11. My TV displays "no signal" if I leave it for too long, does anyone know how to stop this from happening?
I can still ssh into the box and use the remote app Kore so the system hasn't suspended or anything like that.
Pressing up/down etc on the kore remote, which should change what is displayed on screen, doesn't wake kodi up. However, I can wake it up if I tell Kodi to play a video.
Thanks, I will try this and let you know if it works. The file didn't exist so I created it with the following contents because I saw online the option is supposed to go in the monitor section:
I don't know what the identifier should be so I haven't set it.
---- edit
That didn't work for me, I got this error and kodi won't start
[ 4.485] Parse error on line 6 of section Monitor in file /etc/X11/xorg.conf.d/10-monitor.conf This section must have an Identifier line.
[ 4.485] (EE) Problem parsing the config file [ 4.485] (EE) Error parsing the config file
[ 4.485] (EE)
Fatal server error: [ 4.485] (EE) no screens found(EE)
[ 4.485] (EE)
Please consult the The X.Org Foundation support at http://wiki.x.org
for help. [ 4.485] (EE) Please also check the log file at "/var/log/Xorg.0.log" for additional information. [ 4.485] (EE)
[ 4.485] (EE) Server terminated with error (1). Closing log file.
I can't work out what that display should be called though
kodi@kodi:~$ sudo xrandr
Can't open display
kodi@kodi:~$ sudo xdpyinfo | grep -A4 '^screen' >xdpyinfo: unable to open display "".
kodi@kodi:~$ DISPLAY=:0 xset -q
Keyboard Control:
auto repeat: on key click percent: 0 LED mask: 00000000
XKB indicators:
00: Caps Lock: off 01: Num Lock: off 02: Scroll Lock: off
03: Compose: off 04: Kana: off 05: Sleep: off
06: Suspend: off 07: Mute: off 08: Misc: off
09: Mail: off 10: Charging: off 11: Shift Lock: off
12: Group 2: off 13: Mouse Keys: off
auto repeat delay: 660 repeat rate: 25
auto repeating keys: 00ffffffdffffbbf
fadfffefffedffff
9fffffffffffffff
fff7ffffffffffff
bell percent: 50 bell pitch: 400 bell duration: 100
Pointer Control:
acceleration: 2/1 threshold: 4
Screen Saver:
prefer blanking: no allow exposures: no
timeout: 0 cycle: 0
Colors:
default colormap: 0x20 BlackPixel: 0x0 WhitePixel: 0xffffff
Font Path:
/usr/share/fonts/X11/misc,/usr/share/fonts/X11/100dpi/:unscaled,/usr/share/fonts/X11/75dpi/:unscaled,/usr/share/fonts/X11/Type1,/usr/share/fonts/X11/100dpi,/usr/share/fonts/X11/75dpi,built-ins
DPMS (Energy Star):
Standby: 600 Suspend: 600 Off: 600
DPMS is Disabled
I also added the commands above to ~/.xinitrc so hopefully they will be run automatically every time
-- edit:
So, although those xset commands work I have to run them every time, the commands in .xinitrc clearly aren't being run.
I have a feeling this is because kodi is being started using xinit run from a systemd unit file so it isn't reading /kodi/home/.xinitrc.
So the plan is to set the home environment variable in the unit file (like below) and see if that works. Will test when the box is free.
I spent a few years looking for this solution. I will be able to check the exact config on that system tomorrow. If I forget to reply just send me a message.
The system has an intel onboard gpu, some low powered cpu with hdmi out. It's running Arch with Mesa drivers, hooked directly to TV.
Thanks, in this case that wasn't suitable for me because it wasn't a full desktop environment, just Kodi in standalone mode. So there was no easy way to run the command like there would be on a desktop or laptop, I had to add it to my systemd unit file.