Deal with DPMS in xf86-input driver
Kautschitz Horst
H.Kautschitz at ssi-schaefer-peem.com
Tue Oct 22 11:09:24 PDT 2013
Hello!
We are using an embedded Platform with X11R7.7 without Window Manager.
The input is done over a Touchscreen with the xf86-input-tslib driver.
The behaviour until now is that a touch (click) on the touchscreen generates an input event when dpms is active.
This behaviour should be changed in such way that no touch(click) event should occur and screen should go on when dpms is active
This has to be done because an operation could start.
So i want to implement following behaviour in the xf86-input-tslib driver.
- Check if dpms is active
- If dpms active - switch monitor to on
o -> force dpms mode to or simply create a moving event - no "click" should be announced
I tried to implement this by using the DPMS Functions.
if (DPMSQueryExtension(dpy, &dummy, &dummy))
if (DPMSCapable(dpy)) {
DPMSInfo(dpy, &state, &onoff);
if (onoff) {
ErrorF("DPMS is Enabled");
switch (state) {
case DPMSModeOn:
ErrorF(" Monitor is On");
....
My problem is that getting dpy in the driver breaks the xserver itself and i have no intention why. I also get no information why this happens until now.
dpy = XOpenDisplay(dpyName);
Does anyone know a better way how to deal with such a behaviour?
Is creating a socket to the XServer allowed in a driver?
I also checked other input drivers but didn't find a starting point.
TIA
h.kautschitz
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.x.org/archives/xorg/attachments/20131022/cfeb70a8/attachment.html>
More information about the xorg
mailing list