Sign up here and you can log into the forum!

Plugin: SleepTimer + sleep on idle (update 3)

The WDTVExt plugin depot. Plugins/libraries/code only

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby CrashX » Wed Jun 23, 2010 12:20 pm

b-rad.cc wrote:power consumption of average tv is ~40x of wdtv, most tv's go off after a bit with lack of signal...so this effectively shuts off your tv too.


What about the sleep button on your tv remote ? :mrgreen: :mrgreen:
CrashX
Global Moderator
 
Posts: 143
Joined: Thu Apr 15, 2010 9:04 am

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby b-rad.cc » Wed Jun 23, 2010 1:56 pm

What about falling asleep on the couch without setting any timers anywhere :lol:
PM's are for private matters only, please post public matters on the forum to help others who might have the same issue.
:mrgreen:
User avatar
b-rad.cc
WDLXTV Team
 
Posts: 3002
Joined: Sat Apr 03, 2010 9:35 am
Location: New York

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby recliq » Wed Jun 23, 2010 3:57 pm

THAT is my favourite :mrgreen:

Main features:
- No OSD interference with other plugins!
- No key interference with other plugins!
- No use!

Here's the plugin:
Code: Select all
traceln("Nop.Plugin: Start loading NOP plugin")
function NopPlugin(path) {
   this.rootPath = path;
   traceln("Nop.Plugin:   base path:" + this.rootPath);
}
NopPlugin.prototype = new Plugin()
NopPlugin.prototype.constructor = NopPlugin
NopPlugin.instance = new NopPlugin(scriptPath)
Plugin.registerPlugin(NopPlugin.instance)
traceln("Nop.Plugin: End loading NOP plugin")

:ugeek:
­WDLXTV Project Maintainer
-:] If you like my contributions feel free to donate for a beer or a new flash drive. ...and always remember: RTFM! (README, FAQ, WIKI) [:-
User avatar
recliq
WDLXTV Team
 
Posts: 5036
Joined: Thu Apr 15, 2010 8:09 am
Location: Kiel, Germany

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby b-rad.cc » Wed Jun 23, 2010 4:21 pm

I like the conciseness of the plugin, I will await it to do its magic when I fall asleep tonight :lol:

recliq wrote:THAT is my favourite :mrgreen:

Main features:
- No OSD interference with other plugins!
- No key interference with other plugins!
- No use!

Here's the plugin:
Code: Select all
traceln("Nop.Plugin: Start loading NOP plugin")
function NopPlugin(path) {
   this.rootPath = path;
   traceln("Nop.Plugin:   base path:" + this.rootPath);
}
NopPlugin.prototype = new Plugin()
NopPlugin.prototype.constructor = RSSPlugin
NopPlugin.instance = new NopPlugin(scriptPath)
Plugin.registerPlugin(NopPlugin.instance)
traceln("Nop.Plugin: End loading NOP plugin")

:ugeek:
PM's are for private matters only, please post public matters on the forum to help others who might have the same issue.
:mrgreen:
User avatar
b-rad.cc
WDLXTV Team
 
Posts: 3002
Joined: Sat Apr 03, 2010 9:35 am
Location: New York

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby nofak » Sun Jul 18, 2010 9:29 am

Code: Select all
traceln("SleepTimerPlugin: Start loading VolumeControl plugin");
:D
nofak
n00b
 
Posts: 4
Joined: Mon Jul 05, 2010 7:24 am

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby recliq » Mon Jul 19, 2010 7:44 am

Yea things like this happen if you don't re-invent the wheel again and again.. 8-)
­WDLXTV Project Maintainer
-:] If you like my contributions feel free to donate for a beer or a new flash drive. ...and always remember: RTFM! (README, FAQ, WIKI) [:-
User avatar
recliq
WDLXTV Team
 
Posts: 5036
Joined: Thu Apr 15, 2010 8:09 am
Location: Kiel, Germany

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby degifted » Tue Jul 27, 2010 12:36 pm

Hi guys,

It would be nice to have also an ability to put all HDDs connected to WDTV to idle state after the some time of inactivity. I wrote a quick and dirty script doing that, but I think it would be appreciated by many users if someone develop a plug-in for this.

For those who is interested in my solution the following are the content of relevant files:

wdtv[conf]$ cat /conf/hdd_down
for drive in `ls /sys/block/ | egrep -o ^sd.`;do

cmp -s /var/tmp/$drive /sys/block/$drive/stat && \
(test -f /var/tmp/${drive}_idle || (touch /var/tmp/${drive}_idle;sync;sync;sync;logger $drive goes idle;sdparm -C stop /dev/${drive}0)) || \
(test -f /var/tmp/${drive}_idle && (rm /var/tmp/${drive}_idle; logger $drive is back from idle))

cat /sys/block/$drive/stat 2>&1 > /var/tmp/$drive

done

wdtv[conf]$ cat /conf/config |grep CRON
CROND='ON'

wdtv[conf]$ cat /tmp/cron/crontabs/root
0 * * * * /bin/sh /conf/hdd_down
degifted
n00b
 
Posts: 1
Joined: Tue Jul 27, 2010 12:25 pm

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby recliq » Wed Jul 28, 2010 4:58 am

try building an app.bin from your script ;)
http://forum.wdlxtv.com/viewtopic.php?f=40&t=468&start=0
­WDLXTV Project Maintainer
-:] If you like my contributions feel free to donate for a beer or a new flash drive. ...and always remember: RTFM! (README, FAQ, WIKI) [:-
User avatar
recliq
WDLXTV Team
 
Posts: 5036
Joined: Thu Apr 15, 2010 8:09 am
Location: Kiel, Germany

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby spielverderber » Fri Aug 13, 2010 10:26 pm

I've installed the SleepTimer in 1.02.21_WDLXTV.COM_WDLXTV_LIVE-0.4.2.2 via the Plugin Manager. I can choose the desired time until shutdown with the search-key but when the limit is reached - nothing happens. Do I need to configure somthing else?
spielverderber
WDTVer
 
Posts: 22
Joined: Fri Aug 13, 2010 10:04 pm

Re: Plugin: SleepTimer + sleep on idle (update 3)   

Postby dan » Sat Aug 14, 2010 8:27 pm

Did you enable EIRI in your conf?

in /boot/S00custom-options insert:
config_tool -c EIRI=ON
dan
Developer
 
Posts: 40
Joined: Fri May 28, 2010 11:35 pm

PreviousNext

Return to WDTVExt plugins

Who is online

Users browsing this forum: No registered users and 0 guests