View Full Version : Sleep Timer Function (non-idle)
Chambers
2003-10-01, 17:20
hi guys,
would it be possible to add a sleep function to this project? basically i usually set my tv to turn off after 30 mins at night while i go to sleep. it would be nice if there was a way to have my xbox turn off after say, 30,45,60 mins. maybe assign a button to this action and each time it's pressed it cycles through the increments? does this sound like anything people would be interested in? that way you could fall asleep to music or a movie.
xbmp has this already. i hope that xbmc will too, and that it just isn't coded yet.
xbmp will shut down after x minutes of inactivity, you pick the x, so watch a movie, tv shuts off, xbox finished playing a movies and x minutes later it shuts itself off.
Chambers
2003-10-02, 22:26
xbmp has this already. *i hope that xbmc will too, and that it just isn't coded yet. *
xbmp will shut down after x minutes of inactivity, you pick the x, so watch a movie, tv shuts off, xbox finished playing a movies and x minutes later it shuts itself off.
right, isn't that more in the xml code though? it'd be nice to have it in the program itself. so it wouldn't be dependant on if xbmc was idle or not. just make it in combination of a few button. light left thumbstick button plus x would increment it? it just seems more user friendly that way and an excellent bonus. not sure if that's really what the devs are striving for.
Gamester17
2003-10-03, 12:29
something like this then? http://sourceforge.net/tracker....=508680 (http://sourceforge.net/tracker/index.php?func=detail&aid=696288&group_id=64793&atid=508680)
Chambers
2003-10-03, 17:22
that's it!! thanks gamester! tio the devs, would it be difficult to include this in media center?
Zoidberg
2003-11-03, 11:55
every modern audio system (expect very expensive ones :-) )
had a timer.
to start playing music and then turn into relaxing and maybe sleeping and then the system turns off after couple of half hours.
why dont u implement this?
is there a way to get a shutdown timer like in xbmp?
i think it is an very useful feature...
but a shutdown timer would be possible?
sorry, to ask again.
i always use xbmp/xbmc when i go to bed. so i can hear some goodnight music. http://www.xboxmediaplayer.de/forums/non-cgi/emoticons/wink.gif
but without a timer the xbox remains turned on the whole night...
how about an autoplay functionality? this could be used for backgroundmusic or startup sound (kinda)...
just more ideas * :)
yooo!!!
yesterday i watched a movie but sadly i falled in sleep so my xbox was on for the whole night kinda bad *:( ... so maybe you guys can fix a sleep timer function in the next xbmc that would be great!!! let me here what you other guys think of this..
greetz *http://www.xboxmediaplayer.de/forums/non-cgi/emoticons/cool.gif
joseph_hac
2004-05-10, 19:59
atrax,
there is a python script that functions as a sleep timer. i use it all the time. you can find a link to it in the python development forum.
it would be really nice to see sleep timer integrated right into xbmc though.
correct me if i'm wrong, but can't you use the shutdown timer? i thought once the movie has finished playing xbmc returns to it's menu, in which case the idle timeout kicks in and the screensaver and shutdown timer can do their work.
edit: check in settings for screensaver options, you'll see the shutdown timer setting there.
going to try it right now but a other thing can i make a shortcut of the script too the 1st menu of xbmc where video,mp3 ans so on...?
Gamester17
2004-05-11, 12:31
correct me if i'm wrong, but can't you use the shutdown timer? i thought once the movie has finished playing xbmc returns to it's menu, in which case the idle timeout kicks in and the screensaver and shutdown timer can do their work.yes you can use xbmc existing idle sleep timer always enabled but this request is for a non-idle sleep timer (http://sourceforge.net/tracker/index.php?func=detail&aid=696288&group_id=64793&atid=508680) (like new tv's has),
they are only enabled on demand and even then it's one time useage as reset after use, (u only press it when feeling sleepy)
an auto shutdown timer would be great for xbmc. it could permit to play music or any file until a certain amount of time and then auto shutdown the xbox...
althekiller
2004-12-30, 09:31
like shutdown idle timeout? which is already in settings. i could see the addition of a one time use button so that after it turns off the setting gets cleared. also i think there is a python script that could hold you over until something get implemented.
i was more thinking about something like a shutdown button that will shut the xbox after a specified time (30 min, 1h, etc). it can be useful if u wanna listen to music at bed time for instance ;)
there's already a python script for that. if you don't have in your scripts folder, than go here: http://www.xboxmediaplayer.de/cgi-bin....hutdown (http://www.xboxmediaplayer.de/cgi-bin/forums/ikonboard.pl?act=st;f=21;t=2754;hl=shutdown)
-munde
nice, exactly what i was thinking. i underestimated the power of scripts :blush:
not even sure if this is possible. i would think it wouldnt been too hard to create. i always watch a movie or fall asleep to music in xbmc but i would prefer to not leave my xb on overnight. i think that a sleep timer would be an awesome addition. that was after an hour, it shuts the xb down automatically.
its in there... theres an idle shutdown timer. and theres the option to shutdown in a fixed time period regardless if its playing or not.
there's also a python shutdown timer script.
i've tried the idle shutdown timer, and it doesn't seem to work right, it would be great if it was like a tv's sleep timer that you only turn on when you are ready fot it, and could adjust the time period.
hi
i already found a function near to what i wanted,
but the timer only turns the xbox off after an idle time...
would be n1ce if you could write a timer where the user can set the time himeself , dont matter if the xbox is idle or not.
thx.
keep up the great work!
there is a python script which acts as a shutdown timer.
i there not a shutdown while playing media option in the system settings? would that not just shutdown the xbox idle or not?
yes there is a shutdown while playing option but i dont believe its a hard shutdown timer. a hard shutdown timer will shutdown the box regardless of what the user is doing, even navigating the gui.
i believe xbmc doesnt start the idle timeout until playback ends. with this option enabled, playback counts as idle time. so, if you hit pause, you now reset the idle timeout.
Bobbin007
2005-03-17, 19:13
every keypress resets the idle timer, if you just leave it alone while playing, it will shutdown after the amount of time.
greets
bobbin007
magical_muggle
2005-04-16, 15:36
it would be cool to have a sleep timer that will shut off the box after a prescibed time. my tv shuts itself off, but my box runs all night beacuse i go to sleep to a playlist running. it is just a suggestion.
thanks fir the great program! :bowdown:
isn't it a good idea to put a sleep timer in the next release of the xbmc
i'm listening to radio/mp3 beofre sleep and d'like the xbox to be shut within a certain time ... so do my tv
regards
los93sol
2005-09-14, 02:45
hate bringing up an old subject like this as it appears there was mass confusion over it and how it does/should work. *i personally do not use this feature due to how it works currently, but sometimes would find this very useful. *i believe something like this is most useful on demand rather than a permanent setting. *i would like to see a few things that i think would make this feature perfect and get a lot more people using it as well.
-add it to the shutdown menu so it can be quickly/easily accessed and configured from anywhere in xbmc.
-default to "off" after each reset so it has to be set by the user when they want to use it.
-change "shutdown while playing" to "shutdown after playing" (i'm thinking this could be done as a conditional button in the skin to see if a video is even playing so if it's not playing anything the user won't have the option.)
seperate feature request that ties in with this is an alarm clock. *i hate waking up to my alarm clock and that annoying "brap! brap! brap! brap!" sound so this would be awesome to have quick access to as well. *i see something like this allowing you to set your alarm time and choose what media to play at that time to wake you up. *it would be really cool to be able to choose anything from a movie to a shoutcast stream.
anyways, that's my feature request and my reasons for bringing this thread back from the dead.
regards,
los93sol
edit: i wasn't very clear on this...but i think these should both be available from the shutdown menu via a button "shutdown timer/alarm" as these two features would compliment eachother very nicely and in my opinion should be quick and easy to access at all times to be used effectively.
BritneysPAIRS
2005-09-14, 13:29
ummm im using the xbmc alarm clock popup warning kind of hidden away in code (<execute>xbmc.alarmclock</execute>), it would be great if i set alarm for x time and it asked me would you like notification or shutdown. then timer would be really usefull and not just to tell me my eggs are cooked.
cheers
Gamester17
2005-09-14, 14:26
alarm-clock is a separate request from the (non-idle) sleep-timer function that this thread if open for.
(please use => http://www.xboxmediaplayer.de/cgi-bin....=4;t=92 (http://www.xboxmediaplayer.de/cgi-bin/forums/ikonboard.pl?act=st;f=4;t=92) for alarm-clock suggestions, tia)
BritneysPAIRS
2005-09-14, 14:48
alarm clock code is already in there and i use it alot. all it would need to ask you is do you want notification or shut down at moment if you select 5 mins it will popup a notification every 5 minutes saying alarm clock!
:) the coding would be instead of running notifation run shutdown if selected and then choke may want to add it to the shutdown menu (notify / shutdown timer)
cheers
alarm clock code is already in there and i use it alot. all it would need to ask you is do you want notification or shut down at moment if you select 5 mins it will popup a notification every 5 minutes saying alarm clock!
:) the coding would be instead of running notifation run shutdown if selected and then choke may want to add it to the shutdown menu (notify / shutdown timer)
cheers
hi,
i'm willing to the (limited amout of) coding required to add this.
however, i have a few notes.
a) the notify message should not be repeated every 5 mins. this makes the feature a real pain in the arse to use for what i implemented it for (saving my pizza's/eggs).
b) we need a new dialog in xbmc to do this (there is really no dialog suitable for choosing amongst a set of items). since the code for extending the alarmclock to execute any builtin instead of just shutdown is just as easy to do, this will probably be the way i do it, thus using the 'scan'-trick (using the yes/no dialog) won't work.
c) accidentially this gives you a way to have the 'painful' notifications you'd like; just let the alarmclock start another alarmclock.
d) until the new dialog is done, i can add it in a hackish way.
e.g.
xbmc.alarmclock() - will assume normal alarm with choosable timerlength - this is what's hackish about it.
xbmc.alarmclock(xbmc.notification(alarm)) - ditto.
xbmc.alarmclock(xbmc.notification(alarm),i) - time i until alarm.
xbmc.alarmclock(xbmc.shutdown()) - shutdown with choosable timer length.
xbmc.alarmclock(xbmc.shutdown(),i) - time i until shutdown.
xbmc.alarmclock(xbmc.runscript(...)) - the script is run - this won't be possible to choose from the gui until the dialog is added.
what do you think?
edit: i have it working like this now.
BritneysPAIRS
2005-09-14, 22:18
id love this, id put a timer and shutdown on shutdown menu, just saw this thread and thought it was logical quick hack to have this feature and its not used in cvs at moment.
cheers
BritneysPAIRS
2005-09-16, 23:27
cheers spiff, i think it will be a great feature ill talk to choke and see if it cant go into the shutdown menu
yes, and wake up with music !!!
BritneysPAIRS
2005-10-17, 11:18
dear spiff
hi there sleep timer is good.......
i use it alot, little mod to pm3 i use for sleep timer is at
www.thraxen.com/britneyspairs/sleep timer.rar
one little bug though if you activate sleep timer 2 times it shuts down straight away. please try with example given, it also includes the language file to make it look pretty and also when you select shutdown in 15mins press right again it will go shutdown in 30min then 1hour 2 hours 4 hours 8hours.
any comments would be great, and cheers
will check it out when i get home.
edit: got home. damn that mod of yours is pretty freaking awesome!
as for the bug, chokeman made me aware a little while back.
i'll try to push it up on my todo..
edit: fixed. stupid leftover from the alarm-only days.
this was so cool, i'll bump it all the way up on my todo-list. what would you like to see? we definitely need xbmc.cancelalarm(..). thus we need named alarms. that should be doable..
other suggestions are welcome
BritneysPAIRS
2005-10-17, 21:16
a cancel would be nice of course (im sorry i didnt use numerical pad but found it easier the way it was, not so controllable but its really quick for me to choose aprox time).
the way id like to see a popup notification
xbox will go to sleep in 60secs
xbox will go to sleep in 30secs
good night (5 secs before shut down)
and ill add a cancel button and if i see warning and i dont want it to shut off ill cancel it :)
other feature would be shutdown 5 minutes after muisc/movie has finished once again with notification its going to to do it eg 1min 30sec good night to give you time to cancel it
cheers just my thoughts
that about it from me
hi,
- changed: new alarmclock syntax! xbmc.alarmclock(alarmname,command,time).
naming a timer
- added: new builtin command xbmc.cancelalarm(alarmname)
to cancel an already running command
- added: new visbility condition, system.hasalarm(alarmname). for use in skins.
hopefully you get the idea :)
spiff
BritneysPAIRS
2005-10-18, 01:31
thats perfect, any chance to add a notifcation even 30 secs before shutdown, or another vis tag for ... timer has less than x time, that way i can put a little alarm like the lock and at 30 sec make it bigger and at 15sec put an animated gif thats quite large :)
just dreaming really all whats is done is great
BritneysPAIRS
2005-10-18, 01:35
system.alarmshuttingin(x,alarmname)
is example :)
basically any way to warn you that it is going to shut down so you could cancel it (last warning basically).
also no matter what ill do a proper shutdown menu this weekend with new features and post it....ill try and talk to choke first and see if something cant go to cvs cause we dont want your work to waste.
cheers again
i often turn on my music when i go to bed, just to have some background noise. well anyways now that i have xbmc i want to do that over my xbox but i don't want it running all night. i think a sleep timer, woould be perfect here, so that you could choose that the xbox is going to turn of itself after x minutes (15, 30, 45, 60, 120 ...) i think this function would be really usefull,
thx a lot , jochen
AnonyOne
2006-05-06, 20:00
hey lyzrd,
although what you are specifically asking for doesn't exist, you can still achieve something similiar by setting the "auto shutdown" feature in the settings section to something like 15 minutes. this would turn off your xbox 15 minutes (or whichever you select) after the playback of your audio/video terminates.
actually, you can even choose to have it turn off "t" minutes after your latest key press regardless of whether it is still playing something or not (very similiar to a sleep function).
as a sidenote - i have been using this feature for quite a while since i like dozing-off to music/video as well, and quite honestly it does the trick.
oh i didn't know that, thanks a lot, well im new here so i dont know every feature. but thanks im gonna use it from now on.
love the software. best in the world all it needs is a sleep mode so i could have it turn off at night
jmarshall
2007-12-04, 23:45
Press in the right thumbstick button.
sweet,,, what about the remote thanks
the thumb did not work just brought up the shut down menu
jmarshall
2007-12-05, 01:09
Of which one of the items is Sleep - it's probably push up on the shutdown button.
found it thanks feel like a ID10T .....should have tried it... once again Best in the world i have tried the Dlink media thing and a few others nothing holds a match to XBMC thanks once again
klikkamongo
2009-07-08, 01:05
Is it possible to make this program work with XBMC Babylon - 9.04? Where can I download the files? I have looked around all of this forum, but cant find a non-idle-shutdown-script for Babylon on XP...
maybe because its builtin? read the thread
klikkamongo
2009-07-08, 14:36
Is it built in Babylon 9,04? I can only find the idle sleep function! Are you sure about this?
YES i am. and if you actually read what jmarshall wrote further up you'll even be able to find it! assuming you're using pm3/pm3.hd of course - it's up to the skin.
klikkamongo
2009-07-08, 22:22
Hmm.. Strange, I can only figure out how to fix the idle-sleep-timer in the config.
Could you please tell me how to get the non-idle-timer to work?
Is it any key on the keyboard that are mapped as right thumbstick?
's' brings up the button menu. select the shutdown button. push up / down.
klikkamongo
2009-07-08, 22:48
oh! nice, thanks.. This works perfect:)