TiVo Community
TiVo Community
TiVo Community
Go Back   TiVo Community > Main TiVo Forums > TiVo Series 1 - UK
TiVo Community
Closed Thread
Forum Jump
 
Thread Tools
Old 10-11-2003, 04:44 PM   #91
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Thanks Chris, by co-incidence I just fixed that bug!

I hope to post the new version tomorrow.
sanderton is offline  
Old 10-11-2003, 05:00 PM   #92
mas
274GB, Oct 2000-2011
 
Join Date: Jan 2002
Location: West Yorkshire, England
Posts: 30
There is definitely a problem when there is a gap between programs, it just happened to me....

Prog 1 records at 1pm next sceduled prog is for 11pm

after prog 1 is recorded next pad check is sceduled for within the program at 11pm and sleeps (checking kill file) until the 11pm program.

If you then request a recording at 8pm this program does not have any padding added.

When in sleep mode (checking for kill) it needs to recheck to see if there is an earlier program sceduled. every 5 mins ? dont know...

Great Utility... Hope this helps.

Mas
mas is offline  
Old 10-11-2003, 05:05 PM   #93
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by ccwf
If you keep in memory the ID of the last show that's been padded, then you should be able to check very quickly whether or not the that recording is still current, in which case it can skip the rest of the logic and just go back to sleep.
It's not quite that simple, as it is possible for endpad to wake up up to three times during a single recording, and it will have logic to process each time.

But every 30 mins doesn't seem a huge overhead, I'll set it to that.
sanderton is offline  
Old 10-11-2003, 05:29 PM   #94
ccwf
国際化 Member
 
ccwf's Avatar
 
Join Date: Dec 2001
Location: Malibu
Posts: 8,634
Quote:
Originally posted by sanderton
It's not quite that simple, as it is possible for endpad to wake up up to three times during a single recording, and it will have logic to process each time.
Are you saying that the recording database ID check wouldn't work (does the ID change?), or is the overhead for just waking up and checking the current recording's ID still significant?
__________________
ccwf

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

TiVo
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

中日韓
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
ccwf is offline  
Old 10-11-2003, 05:39 PM   #95
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by ccwf
Are you saying that the recording database ID check wouldn't work (does the ID change?), or is the overhead for just waking up and checking the current recording's ID still significant?
There are circumstances (esp. now I'm adding start padding) when endpad can wake up more than once during a recording and do different things each time, so a simple "x is still recording so go straight back to sleep" won't work. Nor can I assume that all the retrieved data stays the same (eg, someone is recording the grand prix, discovers there's been a restart so comes in and adds 30 mins end padding. If endpad just assumed everything was the same as the first time it checked the db, that padding would get wiped 5 mins from the end!)

However the overhead for a 30 minute check is so low that it will be fine. My first draft has the script not look ahead and just check every minute, but I was nervous about that, especially as I already run one (LJ's red dot) which does pretty much the same thing..
sanderton is offline  
Old 10-11-2003, 07:03 PM   #96
bobnick
Registered User
 
Join Date: Jun 2002
Location: London
Posts: 862
Quote:
Originally posted by sanderton
Has anyone got any stability issues with their TiVos running EndPad?
The Binary transfer worked a treat, and I've finally found out to track down and kill the FTP process on Tivo, so I don't need to restart the unit when FTP hangs! However.... Endpad crashed on me this evening. It's also a bugger to restart, as you have to delete the PID file (which said 1793).

The error code was
PHP Code:
error writing "file1"I/O error
    
while executing
"puts "retrying after $errorCode ...""
    
(procedure "RetryTransaction" line 12)
    
invoked from within
"RetryTransaction {
        set currec [mfs scan "
/Recording/Active" -start "3:" -count 1]
      }"
    
(file "./end.tcl" line 128
Was this down to the fact I'd renamed the tcl file? (I'd had to use http_get to get the binary to my Tivo as FTP crashed after the ascii transfer)

The error log:
Sat Oct 11 16:36:00 localtime 2003 : Next Channel: ITV1LON
Sat Oct 11 16:36:00 localtime 2003 : Next Programme: {Pop Idol}
Sat Oct 11 16:36:00 localtime 2003 : Next Scheduled Start Time: Sat Oct 11 18:05:00 localtime 2003
Sat Oct 11 16:36:00 localtime 2003 : Added 3 minutes padding
Sat Oct 11 16:36:00 localtime 2003 : Sleep until Sat Oct 11 19:00:00 localtime 2003
-NB Isn't this GMT rather than localtime?
Then...
Sat Oct 11 16:36:00 localtime 2003 : Waiting a minute before checking for kill
repeated every minute until
Sat Oct 11 18:59:01 localtime 2003 : Waiting a minute before checking for kill

I'd cancelled the pending Pop Idol recording @ 6.03pm to record WWI on Channel 4, by pressing record on live TV and going to options and chosing record new portion (high quality)

And as for waking endpad up every 30 minutes, might it be an idea to wake it every 29 minutes, so the overhead is spread throughout the hour, just in case it regularly clashes with other things?
bobnick is offline  
Old 10-11-2003, 08:06 PM   #97
Fozzie
Registered User
 
Fozzie's Avatar
 
Join Date: Sep 2001
Location: Alton, Hants, UK
Posts: 837
Ok, there's something really strange going on here.

If I start endpad from rc.sysinit.author then TiVo tries to dial up to get its' guide data instead of using Turbonet. Take the endpad entry out, reboot and it's back to using the ethernet port. Put endpad back in, reboot and it tries to dial again!

My rc.sysinit.author:

#!/bin/bash
/var/hack/tivoweb-tcl/tivoweb
/var/hack/endpad.tcl 5 -auto

TivoWeb runs fine with or without the endpad entry. Confused

(As an aside, what does -auto switch do?)

Last edited by Fozzie : 10-11-2003 at 08:13 PM.
Fozzie is offline  
Old 10-11-2003, 09:06 PM   #98
ccwf
国際化 Member
 
ccwf's Avatar
 
Join Date: Dec 2001
Location: Malibu
Posts: 8,634
Auto tries to kill an existing endpad.tcl process (if it exists) and then waits two minutes for boot-up to complete.
__________________
ccwf

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

TiVo
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

中日韓
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
ccwf is offline  
Old 10-12-2003, 06:39 AM   #99
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by bobnick

Endpad crashed on me this evening. It's also a bugger to restart, as you have to delete the PID file (which said 1793).

The error code was
[php]error writing "file1": I/O error
while executing
"puts "retrying after $errorCode ...""
That is an error generated by a TiVo internal routine not my code, so I have to say I'm not quite sure what's happening there. Normally that routine's messages (it was just trying to say the database was locked and would retry in a moment) just get sent to the console so disappear into the ether for a bacgrounded app with no console. However it seems to be trying to write them to "file1". I have no idea at all what that means. Anyone?
sanderton is offline  
Old 10-12-2003, 11:22 AM   #100
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by Fozzie
Ok, there's something really strange going on here.

If I start endpad from rc.sysinit.author then TiVo tries to dial up to get its' guide data instead of using Turbonet. Take the endpad entry out, reboot and it's back to using the ethernet port. Put endpad back in, reboot and it tries to dial again!

My rc.sysinit.author:

#!/bin/bash
/var/hack/tivoweb-tcl/tivoweb
/var/hack/endpad.tcl 5 -auto

TivoWeb runs fine with or without the endpad entry. Confused

(As an aside, what does -auto switch do?)
Sorry, had to think about that for a minute!

My mistake. The line should be:

/var/hack/endpad.tcl 5 -auto >> /dev/null &

I had thought rc.sysinit.author ran last of all on startup, but rc.net runs after it. endpad had a two minute pause in it, which it seems is long enough to bggr up the code in rc.net which configures TiVo to use the internet for guide data.

Apologies.
sanderton is offline  
Old 10-12-2003, 12:00 PM   #101
Fozzie
Registered User
 
Fozzie's Avatar
 
Join Date: Sep 2001
Location: Alton, Hants, UK
Posts: 837
Cheers Stuart. That's fixed it. I thought I was going mad
__________________

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
Fozzie is offline  
Old 10-12-2003, 01:01 PM   #102
Lysander
Registered User
 
Join Date: Sep 2003
Location: Bedfordshire
Posts: 74
Stuart,

Great little app, well done.

James
Lysander is offline  
Old 10-12-2003, 01:07 PM   #103
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by bobnick
It's also a bugger to restart, as you have to delete the PID file (which said 1793).
Dibblah has kindly given me a bit of code which will deal with that in the next version.
sanderton is offline  
Old 10-12-2003, 02:03 PM   #104
ccwf
国際化 Member
 
ccwf's Avatar
 
Join Date: Dec 2001
Location: Malibu
Posts: 8,634
In case you overlooked it, I also posted a one-line bash script up above which should immediately relaunch endpad.tcl if it ever exits abnormally (based on script exit value), ignoring the presence or absence of the PID file. With that script, the PID file is used only to cause a normal exit.

The one-liner could be put into a separate launcher script to make it more convenient to run from the command-line or integrated into endpad.tcl itself.
__________________
ccwf

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

TiVo
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

中日韓
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
ccwf is offline  
Old 10-12-2003, 03:26 PM   #105
dd400005
Banned Member
 
Join Date: Jun 2003
Location: Forum Outcast
Posts: 119
Fascinated by this thread. I can't wait to see how it ends up.

Will I be able to run it, when it's finished, on my unhacked UK TiVo running 2.5.5? I have a serial cable but haven't done anything with it yet. I assume the only issue is whether you can get one of those bash prompts (whatever they are )
__________________
(User was ex-communicated and banished from the forums for all eternity)
dd400005 is offline  
Old 10-12-2003, 03:30 PM   #106
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by ccwf
In case you overlooked it, I also posted a one-line bash script up above which should immediately relaunch endpad.tcl if it ever exits abnormally (based on script exit value), ignoring the presence or absence of the PID file. With that script, the PID file is used only to cause a normal exit.

The one-liner could be put into a separate launcher script to make it more convenient to run from the command-line or integrated into endpad.tcl itself.
Yes I saw it. Many thanks for your suggestions. I hope to get it stable enough not to need it, but we'll see!
sanderton is offline  
Old 10-12-2003, 03:36 PM   #107
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by dd400005
Fascinated by this thread. I can't wait to see how it ends up.

Will I be able to run it, when it's finished, on my unhacked UK TiVo running 2.5.5? I have a serial cable but haven't done anything with it yet. I assume the only issue is whether you can get one of those bash prompts (whatever they are )
It will run fine via the serial cable, but you will need to get your hard disk out and into a PC to set up the ability to access the legendary bash prompt.
sanderton is offline  
Old 10-12-2003, 06:28 PM   #108
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by bobnick
The error code was
[php]error writing "file1": I/O error
while executing
"puts "retrying after $errorCode ...""
OK, I think I've figured this one out, and the fix will be in the next version.

Which is coming along, but putting start padding into the equations adds a lot of complications - once it's negotiated a day full of CBeebies tomorrow I'll be much happier that it works OK.
sanderton is offline  
Old 10-13-2003, 02:05 AM   #109
dd400005
Banned Member
 
Join Date: Jun 2003
Location: Forum Outcast
Posts: 119
quote:
--------------------------------------------------------------------------------
Originally posted by sanderton

It will run fine via the serial cable, but you will need to get your hard disk out and into a PC to set up the ability to access the legendary bash prompt.
--------------------------------------------------------------------------------

Great. I expect that's a one-time only occurrence to install/enable the bash prompt and copy your script over. Then I'll be able to get a bash prompt and start your script via a terminal emulator window over the serial cable.
__________________
(User was ex-communicated and banished from the forums for all eternity)
dd400005 is offline  
Old 10-13-2003, 02:50 AM   #110
Fozzie
Registered User
 
Fozzie's Avatar
 
Join Date: Sep 2001
Location: Alton, Hants, UK
Posts: 837
Stuart,

As mentioned in a previous post, any chance you could put endpad's log in/var/log as it would be really useful to be able to view it from TivoWeb. That way, I can remotely see what it's doing and, if necessary, reschedule any recordings.

Ta.
Fozzie is offline  
Old 10-13-2003, 03:42 AM   #111
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
That's in the new version.
sanderton is offline  
Old 10-13-2003, 03:43 AM   #112
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by dd400005
quote:
--------------------------------------------------------------------------------
Originally posted by sanderton

It will run fine via the serial cable, but you will need to get your hard disk out and into a PC to set up the ability to access the legendary bash prompt.
--------------------------------------------------------------------------------

Great. I expect that's a one-time only occurrence to install/enable the bash prompt and copy your script over. Then I'll be able to get a bash prompt and start your script via a terminal emulator window over the serial cable.
Well it'll be by a telnet session over a serial PPP link, but yes.
sanderton is offline  
Old 10-13-2003, 12:04 PM   #113
tivo_boj
Tivo is getting old
 
Join Date: Feb 2001
Location: Pitsea, Basildon, Essex, UK
Posts: 215
Stuart,

just to let you know I have been running Endpad for over 24hours with no issues. Seems to be padding when it should, and not when it shouldn't. Saved me missing an ending already.

One question - is there a limit on the size of the log files as it is getting bigger by the minute. Do we need to manually delete this if it gets too big?

Other than this - this is the biggest step forward (especially when you put start padding in) since the last officail upgrade to 2.5.5 ( you know the one that did not give us soft padding!)

Keep up the very good work
__________________
TiVo Boj (Tivo -Nov 2000)
GSOD caused 160G upgrade Oct 2006. TivoWebPlus (beta 1.4.0) Using PPP over serial (Aug 2002). & Turbocard ( 2005)
tivo_boj is offline  
Old 10-13-2003, 12:22 PM   #114
Lysander
Registered User
 
Join Date: Sep 2003
Location: Bedfordshire
Posts: 74
No problems here either, saved missing the end of Silent Witness which in turn saved my life. My wife thinks you are lovely...
Lysander is offline  
Old 10-13-2003, 01:22 PM   #115
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
EndPad 1.2 now up

I have updated the first post with version 1.2.

Main changes:

- All posted bugs fixed (I hope)
- Start padding added
- Logs now viewable with the TiVoWeb logs module
- Handles restarts better (thanks Dibblah)
- Will add the max possible padding if it can't add the full amount
- Checks every 30 mins for new recordings being added to the TDL
- Code revamped and tidied

Cheers to all above, esp. Dibblah and ccwf for assistance and suggestions.

Post your new bugs below....
sanderton is offline  
Old 10-13-2003, 01:28 PM   #116
sanderton
TiVoer since 11/2000
 
Join Date: Jan 2002
Posts: 6,341
Quote:
Originally posted by tivo_boj
One question - is there a limit on the size of the log files as it is getting bigger by the minute. Do we need to manually delete this if it gets too big?
I've made them less verbose, and while I'm not sure how big the /var partition is, if you fill it then your TiVo is just far too stable!
sanderton is offline  
Old 10-13-2003, 01:39 PM   #117
Fozzie
Registered User
 
Fozzie's Avatar
 
Join Date: Sep 2001
Location: Alton, Hants, UK
Posts: 837
Re: EndPad 1.2 now up

Quote:
Originally posted by sanderton
I have updated the first post with version 1.2.
Very nice work Stuart.

Downloaded, installed and never worry about missed beginnings and ends again............hopefully

Small request - any chance of having the times in the log as local time?

Last edited by Fozzie : 10-13-2003 at 01:46 PM.
Fozzie is offline  
Old 10-13-2003, 01:49 PM   #118
ccwf
国際化 Member
 
ccwf's Avatar
 
Join Date: Dec 2001
Location: Malibu
Posts: 8,634
Stuart, since I haven't looked through the code, yet, and for the benefit of the non-programmers, perhaps you could explain what you chose to do when soft start-padding conflicts with soft end-padding? Do you just split the difference, or what?
__________________
ccwf

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

TiVo
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

中日韓
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
ccwf is offline  
Old 10-13-2003, 01:54 PM   #119
ccwf
国際化 Member
 
ccwf's Avatar
 
Join Date: Dec 2001
Location: Malibu
Posts: 8,634
Re: Re: EndPad 1.2 now up

Quote:
Originally posted by Fozzie
Small request - any chance of having the times in the log as local time?
This is actually harder to do right than you might thinkTiVo Web doesn't handle it 100% correctly, for example. It would also make the timestamps for this hack different from all the other timestamps TiVo logs.

It would be nice, though, to add the ability to TiVo Web to view log files with times converted into local time.
__________________
ccwf

To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

TiVo
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.


To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.

中日韓
To view links or images in signatures your post count must be 10 or greater. You currently have 0 posts.
ccwf is offline  
Old 10-13-2003, 02:03 PM   #120
Fozzie
Registered User
 
Fozzie's Avatar
 
Join Date: Sep 2001
Location: Alton, Hants, UK
Posts: 837
Re: Re: Re: EndPad 1.2 now up

Quote:
Originally posted by ccwf
This is actually harder to do right than you might think........
I thought it might be, otherwise he'd have done it right?

Looking at the new blurb in the first post, Stuart says that end padding has priority over start padding so I'm guessing that potential start padding will not prevent the full end padding from being added.

Stuart - another quickie. The log now has the padding added in seconds. Just wondering why it has changed from being in minutes before? Is it because end padding can now be automatically scaled down from the max, in seconds?
Fozzie is offline  
Closed Thread
Forum Jump




Thread Tools


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Advertisements

TiVo Community
Powered by vBulletin® Version 3.6.8
Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
vBulletin Skins by: Relivo Media

(C) 2013 Magenium Solutions - All Rights Reserved. No information may be posted elsewhere without written permission.
TiVo is a registered trademark of TiVo Inc. This site is not owned or operated by TiVo Inc.
All times are GMT -5. The time now is 06:43 PM.
OUR NETWORK: MyOpenRouter | TechLore | SansaCommunity | RoboCommunity | MediaSmart Home | Explore3DTV | Dijit Community | DVR Playground |