Linux [RELEASE]Plugin for Timer- and Powermanagement in XBMCbuntu/XBMC-live and TVHeadend

  Thread Rating:
  • 2 Votes - 5 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
_BJ1 Offline
Senior Member
Posts: 122
Joined: Apr 2010
Reputation: 0
Location: Germany
Post: #31
(2012-06-11 13:43)Claudio.Meldini Wrote:  
Code:
File "/home/adone/.xbmc/addons/script.program.pvrmanager/default.py", line 196, in getSysState
epgTime = curTime + datetime.timedelta(days=int(curTime.strftime('%j')) % int(__epg_interval__))
ZeroDivisionError: integer division or modulo by zero

Now i set 6 days on interval, but i'd like to set 0 days, can you tell me how resolve this error?
Have you also this error if you set 0 days?
thanks in advance.

I've not tested yet if interval ist set to 0. There's division by zero indeed if interval is set to "off".
I'll fix this and upload a new version this evening.

Thank you for your response.

_BJ1
(This post was last modified: 2012-06-11 17:06 by _BJ1.)
find quote
Claudio.Meldini Offline
Junior Member
Posts: 4
Joined: Apr 2012
Reputation: 0
Post: #32
Sorry, i wrote "0 days" but there is no option for "0 days" (my memory doesn't work...).
The option is "off".

Thanks for now, i'll wait new version!
find quote
_BJ1 Offline
Senior Member
Posts: 122
Joined: Apr 2010
Reputation: 0
Location: Germany
Post: #33
(2012-06-11 17:58)Claudio.Meldini Wrote:  Sorry, i wrote "0 days" but there is no option for "0 days" (my memory doesn't work...).
The option is "off".

Yes, the option "off" returns "0" as value and this reacts as a division by zero, so you are correct Wink
I have fixed this. Download it from post #1, it's uptodate now.

_BJ1
(This post was last modified: 2012-06-11 23:50 by _BJ1.)
find quote
Claudio.Meldini Offline
Junior Member
Posts: 4
Joined: Apr 2012
Reputation: 0
Post: #34
Now it works!!!!
thank you!
and the popup with next recording (on power off) is nice, you could rename this version to 0.1.6 Big Grin
find quote
_BJ1 Offline
Senior Member
Posts: 122
Joined: Apr 2010
Reputation: 0
Location: Germany
Post: #35
(2012-06-10 23:34)mastix Wrote:  It keeps displaying the 401 message... for some reason that I don't understand.

What version of tvheadend do you use? My is "2.99.16.g0e3bb" (from Webinterface -> about) on two machines here - self compiled.
(This post was last modified: 2012-06-14 19:54 by _BJ1.)
find quote
mastix Offline
Junior Member
Posts: 24
Joined: May 2012
Reputation: 0
Post: #36
Hi,

I'm using a self-compiled version as well... I'm always on the latest greatest...

Currently: HTS Tvheadend 2.99.44.g4ef72

Greetz,

Sascha
find quote
bilbonvidia Offline
Fan
Posts: 433
Joined: Jun 2011
Reputation: 1
Location: Britain
Post: #37
Thanks for this plugin I am currently testing it.

Can I get the machine to suspend instead of shutdown, does that involve changing the script?

I am having a slight issue for which I have posted another thread here:
http://forum.xbmc.org/showthread.php?tid=137207

xbmc hanging when coming back on
16:10:51 T:3006838592 ERROR: Create - Error( Connection timed out )
16:10:51 T:3006838592 ERROR: Create - Error creating /home/billy/.xbmc/userdata/Thumbnails/generated/4
find quote
_BJ1 Offline
Senior Member
Posts: 122
Joined: Apr 2010
Reputation: 0
Location: Germany
Post: #38
(2012-07-30 17:43)bilbonvidia Wrote:  Can I get the machine to suspend instead of shutdown, does that involve changing the script?

A quick'n dirty solution could change the shellscript for shutdown of the addon (~/.xbmc/addons/script.program.pvrmanager/resources/lib/shutdown.sh).
Just replace the last line

Code:
/sbin/shutdown -h now "PVRManager shutdown the system"

with:

Code:
/usr/sbin/pm-suspend && echo "PVRManager suspends the system"

Be aware that I have not this tested yet!
find quote
bilbonvidia Offline
Fan
Posts: 433
Joined: Jun 2011
Reputation: 1
Location: Britain
Post: #39
Thanks, but tvheadend itself seems to stop the system from suspending I seems to have to stop tvheadend for it to suspend properly. This is what happens when not using the addon aswell.

I would somehow have to tvheadend stop before issuing the pm-suspend then start it again after the resume I think.

Its not a big issue, the shutdown and resume from shutdown works great!
find quote
bilbonvidia Offline
Fan
Posts: 433
Joined: Jun 2011
Reputation: 1
Location: Britain
Post: #40
I need to do more testing but when the computer wakes itself during the night to record it does record but xbmc crashes and he computer is still on.

I think this is to do with the fact I have a shared mysql library for films and music on a separate pc which is switched off at night time. Under normal circumstances I think xbmc eventually falls back to local databases.and contunues to function.

Could the adddon be causing the crash, if so is there a way around it by setting a delay or something?
find quote
Post Reply