NextPVR Forums

Full Version: NEW PLUGIN: Sleep Timer
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I resurrected the Sleep Timer project. Well, actually I killed the old one dead and created a new one from scratch.

For some reason I don't have sufficient permission to edit the wiki entry; nevertheless, you can download the new Sleep Timer here. It's even simpler than the old one. (I don't think the old one even works anymore.)

There's just the one DLL. Let the setup program copy it to your plugins directory, or copy it manually; no skin files or other support stuff to worry about.

This new sleep timer is configured via the GB-PVR Config program. You set the number of minutes you want GB-PVR to run. To activate or de-activate it, just select the Sleep Timer button from within GB-PVR.

Note that the Sleep Timer shuts down GB-PVR itself, but does NOT shut down the GB-PVR recording service.

Enjoy. Post any bugs or questions on this thread (assuming that's OK with the moderator).

Oh, one final note: Even though you configure the Sleep Timer via the GB-PVR Config program, once you close the Sleep Timer configuration dialog, your changes are set. That is, you don't have to subsequently click OK on the GB-PVR config screen (thereby forcing a restart of the recording service).
Added to the wiki... http://gbpvr.com/pmwiki/pmwiki.php/Plugin/SleepTimer

Send a PM to blader_se to get access to edit the wiki.

I haven't installed this but I would be really happy if it could be set inside GB-PVR (not through the config) and instead of killing the program only stopped watching tv/recording/dvd (send the stop command?) and then goes to the main menu.
I would also be interested in this plugin if it simply dropped back to main menu after X hours with no user interaction.

I often find someone simply turns off the tv and leaves gbpvr playing live tv all night, if i could set a timeout that would drop back to main menu my gbpvr box would then drop into stanby.

Bob
23skidoo, I have a need to shut GBPVR down prior to my system goes into hibernation (http://forums.nextpvr.com/showthread.php?t=27059). Is there any way I could use the sleep timer to do this after a set amout of time when there has been no activity with GBPVR.

\\Agerdin
-Oz- Wrote:Added to the wiki... http://gbpvr.com/pmwiki/pmwiki.php/Plugin/SleepTimer

Send a PM to blader_se to get access to edit the wiki.

I haven't installed this but I would be really happy if it could be set inside GB-PVR (not through the config)
This isn't likely to change anytime soon. The code's a lot simpler (read: less time-consuming to write and maintain) without having to interact with the GB-PVR user interface.

Quote:and instead of killing the program only stopped watching tv/recording/dvd (send the stop command?) and then goes to the main menu.
I'll look into this. Maybe I'll make it a checkbox option.
BobBuilder Wrote:I would also be interested in this plugin if it simply dropped back to main menu after X hours with no user interaction.

I often find someone simply turns off the tv and leaves gbpvr playing live tv all night, if i could set a timeout that would drop back to main menu my gbpvr box would then drop into stanby.

Bob
I can't utilize lack of user interaction as a criterion for the timer because there's no way to tell if someone is still actually watching TV. GB-PVR doesn't have an eyeball sensor. Not a built-in one, anyway. :-)
agerdin Wrote:23skidoo, I have a need to shut GBPVR down prior to my system goes into hibernation (http://forums.nextpvr.com/showthread.php?t=27059). Is there any way I could use the sleep timer to do this after a set amout of time when there has been no activity with GBPVR.
Please see above. No eyeball sensor.

But what are the ramifications of your system going into hybernation with GB-PVR running? Would this necessarily be a bad thing?
23skidoo Wrote:Please see above. No eyeball sensor.

But what are the ramifications of your system going into hybernation with GB-PVR running? Would this necessarily be a bad thing?

No, that should be ok, but for me the Hauppauge PVR stops responding when my system is awaking from hibernation and I need to unplug the power on the PVR in order for it to restart. If GBPVR is not running this problem is not occurring. Hence, I am looking for a way to shut GBPVR down prior to hibernation.

\\Agerdin
23skidoo Wrote:I can't utilize lack of user interaction as a criterion for the timer because there's no way to tell if someone is still actually watching TV. GB-PVR doesn't have an eyeball sensor. Not a built-in one, anyway. :-)

Personally I think if this were configurable by the user I dont see anything wrong with using lack of interaction as a timeout indicator.
If the timer were reasonably high, say 3 hours it would be fine for me.
I dont think I would ever watch the same chanel for 3 hours continually without ever pressing a button, ie change volume change chanel etc.

I realise this is an arguable point which is why it should be an option thats off by default.

I think it would be more acceptable if you had the gui within GBPVR, and perhaps a warning / icon on the main page to indicate that the option is active.

I know youve said you dont want to maintain the gui etc so thats fair enough so Ill understand if you dont think its an option you want to support.

I'm half consdering implementing the interface myself as I'm looking for a small pet project to improve my c# knowledge.
Maybe you would consider making your plugin open source so I could use that as a starting point?
At least that way I only have to worry about writing the gui and not the rest of the back end.

Thanks for plugin anyway.

Bob