[prev in list] [next in list] [prev in thread] [next in thread] 

List:       freedesktop-xorg
Subject:    Resetting DPMS idle timeout
From:       Greg Kennedy <kennedy.greg () gmail ! com>
Date:       2016-02-09 23:13:02
Message-ID: CAN1+P_3kcH=eUe3MqLAuUiHRm_Jd-_-t2smKqpvJ5TXrGUGNWw () mail ! gmail ! com
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


Is there a "proper" Xlib API call to reset the DPMS timeout?

I am working on a game in C which takes joystick input.  After ~10 minutes
of gameplay, the screen shuts off - this is because I haven't hit any keys
or moved the mouse, so X doesn't see any of the events that I'm actually
reading from /dev/input/js0.

I'm looking for a function that I can call myself on every joystick event,
which will signal to the server "yes, user is still active" and reset the
timeout to 10mins again or whatever is configured in xorg.conf.

I don't want to globally disable DPMS, because my kids have a tendency to
just walk away from the game without shutting it off first, and it'll burn
the screen : )

-Greg Kennedy

[Attachment #5 (text/html)]

<div dir="ltr"><div><div><div><div>Is there a &quot;proper&quot; Xlib API call to \
reset the DPMS timeout?<br><br></div>I am working on a game in C which takes joystick \
input.   After ~10 minutes of gameplay, the screen shuts off - this is because I \
haven&#39;t hit any keys or moved the mouse, so X doesn&#39;t see any of the events \
that I&#39;m actually reading from /dev/input/js0.<br><br></div>I&#39;m looking for a \
function that I can call myself on every joystick event, which will signal to the \
server &quot;yes, user is still active&quot; and reset the timeout to 10mins again or \
whatever is configured in xorg.conf.<br><br></div>I don&#39;t want to globally \
disable DPMS, because my kids have a tendency to just walk away from the game without \
shutting it off first, and it&#39;ll burn the screen : )<br><br></div>-Greg \
Kennedy<br></div>


[Attachment #6 (text/plain)]

_______________________________________________
xorg@lists.x.org: X.Org support
Archives: http://lists.freedesktop.org/archives/xorg
Info: https://lists.x.org/mailman/listinfo/xorg
Your subscription address: %(user_address)s

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic