WelcomeWelcome | FAQFAQ | DownloadsDownloads | WikiWiki

Author Topic: "xset -dpms" not working from ~/.X.d/ but fine if manually in text terminal  (Read 2004 times)

Offline xpector

  • Newbie
  • *
  • Posts: 16
My Xorg screen turns black after some minutes. I added a script to ~/.X.d/
Code: [Select]
#!/bin/sh
export DISPLAY=:0
xset s noblank
xset s off
xset [b]-dpms[/b]
After filetool.sh -b and reboot. I press Ctrl-Alt-F1 to switch back to the text terminal and check:
Code: [Select]
export DISPLAY=:0
xset q
It reports that DPMS is on. I type manually
Code: [Select]
export DISPLAY=:0
xset -dpms
xset q
DPMS is off now. Other scripts in ~/.X.d/ run fine. Should I resort to adding the stuff to Xorg's command options directly in .xsession or am I missing something?

Offline fault-tolerant

  • Newbie
  • *
  • Posts: 19
As an experiment, I'd place an xset q >> some-file.txt right after every xset command you have there in your script, to see if something resets the xset settings on a later stage or if it simply can't do the setting. I remember trying something like this about two years ago, don't remember the results though.
Having the same problem, I've been using the x0vnc4server, it could possibly fiddle with xset settings now when I think of it.
« Last Edit: March 19, 2018, 10:32:59 PM by fault-tolerant »

Offline xpector

  • Newbie
  • *
  • Posts: 16
@fault-tolerant, thanks for your ideas
Following modification of my ~/.X.d/noblank.sh helped
Code: [Select]
#!/bin/sh
while true; sleep 60s && export DISPLAY=:0 && xset s noblank && xset s off && xset -dpms; done &

I had yet no time to check what could re-enable dmps, despite a rather short list of candidates: ImageMagick's convert; hsetroot; RealVNC vncviewer.