disable screensaver for script run time
#1
How can I disable the screensaver (dim in my case) to activate when my python script is active?
If there is no way to do this, how can I send the keypress to the script when the screensaver is active? I want to avoid pressing the remote key twice, first to wake up from screensaver, then second time to send it to the script.
Reply
#2
pru1 Wrote:How can I disable the screensaver (dim in my case) to activate when my python script is active?
If there is no way to do this, how can I send the keypress to the script when the screensaver is active? I want to avoid pressing the remote key twice, first to wake up from screensaver, then second time to send it to the script.

you can use executehttpapi to do this..

first you might want to get what it your current screen saver:
Code:
screensaver = xbmc.executehttpapi( "GetGUISetting(3;screensaver.mode)" ).replace( "<li>", "" )

then to turn off:
Code:
xbmc.executehttpapi( "SetGUISetting(3,screensaver.mode,None)" )

to turn back on:
Code:
xbmc.executehttpapi( "SetGUISetting(3,screensaver.mode,%s)" % screensaver )
Reply
#3
Thanks, it does the job with the screensaver.
However after the idle time (when normally screensaver would start) I still have to press any remote key to take the xbmc out from an inactive state.
Can I avoid it entering this state at all?
Reply
#4
I have tried the above code and while it appears to work, it causes my Addon (XSqueeze) to hang on exit (when I re-enable the screensaver).

Any ideas or alternate methods??
http://forum.xbmc.org/showthread.php?p=1012231
Addons I wrote &/or maintain:
OzWeather (Australian BOM weather) | Check Previous Episode | Playback Resumer | Unpause Jumpback | XSqueezeDisplay | (Legacy - XSqueeze & XZen)
Sorry, no help w/out a *full debug log*.
Reply

Logout Mark Read Team Forum Stats Members Help
disable screensaver for script run time0