Idle shutdown timer
#1
Hi, I'm trying to access the idle shutdown timer set under the power saving tab in settings from a addon using
Code:
xbmc.getCondVisibility('System.HasAlarm(shutdowntimer)')
and
Code:
xbmc.getCondVisibility('System.AlarmLessOrEqual(shutdowntimer,300)')
This however does not seem to work. Never triggers the "AlarmLessOrEqual" and always shows there is no alarm no matter how long it's been idle. I'm wondering if the alarm name is something different or if this setting is using alarms or something else?

Thanks
Reply
#2
it's not using an alarm, but a built-in timer.
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#3
(2017-02-18, 19:55)ronie Wrote: it's not using an alarm, but a built-in timer.

Do you know if there is anyway to access that timer from an add-on?
Reply
#4
nope.

depending on what you're exactly trying to accomplish, a combination of these might work:
- use json-prc to check if the setting is enabled / what value it's been set to.
- use xbmc.getCondVisibility('System.IdleTime(300)') to check if the system has been idle for the specified amount of time
Do not PM or e-mail Team-Kodi members directly asking for support.
Always read the Forum rules, Kodi online-manual, FAQ, Help and Search the forum before posting.
Reply
#5
I think I can make that work for this. One more question. Does inhibitidleshutdown reset that timer or just not allow the shutdown while it's enabled? To clarify. If you set the sleep timer for say 5 minutes and inhibit sleep is enabled and it's been say 10 minutes if the inhibit is taken off does it sleep instantly or wait another 5 minutes? Thanks for all your help!
Reply
#6
Finally made it home and had time to play with this. It seems inhibit idle shutdown does not effect the system.idletime. How does the inhibitidle shutdown effect the shutdown timer? does it reset it or as I asked above just wait till its no longer inhibited and immediately shutdown? Sure would be easier if I could just access the shutdown timer to check how much time was left on it.
Reply

Logout Mark Read Team Forum Stats Members Help
Idle shutdown timer0