2011-04-20, 20:26
Jason102 Wrote:I've been thinking about a good way to update in the background (or something similar) and haven't been able to come up with a good solution. The problem with updating and quiting at a certain time is that you can now never watch PseudoTV at that time, on the weekends for example. Plus you would have to start the script at just the right time (presumable within some small range) to get this to work.
I guess I could make an option to update and quit on the next startup, but I'm not sure that's a good solution either. Ideally, they would update while you're actually using the script. Again, this presents several issues:
- JSON calls take some time so if you quit the script at the wrong time then you wouldn't have control over the system until it completed.
- If the update completes and then you add to your video library, the next start of the script won't reflect those new shows / movies.
- If your computer takes the majority of processor usage in order to just decode and display the movie, the addition of a background task might cause skipping in the video.
- Multithreading in Python inside of XBMC is very touchy and doesn't really like to be used...I'm afraid of stability problems if I start doing entire tasks in the background.
I'm not really sure what the best solution would be. Perhaps if there was some way to invoke the script at a certain time automatically then it would generate and quit, but I don't know of a way to do that.
jtucker1972 says that he has a solution for TV time, so I'm going to see what he has and decide if it will work for PseudoTV.
Didn't know if it was feasable or even doable, thought I would ask. I'll probably set up a cron job using windows scheduler and/or Event Ghost to wake up the pc, open XBMC just before a scheduled refresh of the playlist. After the refresh, I'll close XBMC the pc will go back to sleep. I plan on having all of this happen during the day when everyone is at work. The good thing about Windows Scheduler, I think, is that you can just schedule on weekdays.
It would have been so much easier if there was a setting in PseudoTV that would close XBMC automatically after a refresh. One less thing to worry about.
Don't know what the impact would be with a refresh running in the background. Three of my pc's are Emachines 1402s and they only have a single core 1.7MHz processor. A lot of other use single core atoms. I would expect some sort of disruption in play which is why I thought of doing it while away for the day.
At any rate, I love what you guys are doing and the WAF is pretty good now.
Thanks,
Mark