# Automatic soft padding running on the TiVo



## sanderton

*This thread and the software posted in it are now deprecated. The current version of EndPad and support for it are now handled by maxwells_daemon in this thread.*

EndPad is a program which runs in the background on the TiVo and extends the recording time of shows (start and end) by the amount you specify if, and only if, that would not cause a clash with another recording. This means that you need no longer juggle SPs with extra recording time which cause other SPs to be missed.

A particular bugbear in the UK is BBC 2, which frequently runs 2 mins late, but also has a lot of shows you might wish to record running back to back. Keeping track of which of these shows was the last one, which needed padding, and which was an earlier one, which didn't, was a nightmare, especially as the shows on BBC 2 usually have different season durations, so it keeps changing! EndPad sorts BBC 2 (and ITV 1) out for you.

I took LJ's noreddot as my inspiration - rather than try to get everything done in advance, this program only actually adds the end padding to the programme being recorded 5 minutes before the end of the recording, and adds start padding just 1 minute before it is due.

This "just in time" automated approach has many advantages:

The recordings remain part of their SP with all other settings completely intact. 
New recordings and new SPS do not trigger clashes with padding, because the padding is not there until almost the end of the recording
Suggestions get padded too (something many have asked for)
It can run from rc.sysinit.author, so is completely automated with no user input needed
In fact, it's as close to TiVo implemented soft padding as I think you are going to get until we get v5 in the UK !

If the full amount of padding cannot be added, EndPad will add as much as it can. End padding on a show has priority over start padding on the next one. Padding you set manually or in a SP has priority over both (although EndPad will try and increase the user set padding to the soft level if it can).

If you want to see what it is up to, you can view the logs (which are I hope reasonably intelligible) through the Logs module of TiVoWeb.

Note 1: By default, when EndPad looks at the next recording it takes suggestions as being disposable and deletes them to accommodate end padding if needed. If two back to back suggestions are scheduled, EndPad pads the first one and deletes the second. You can use the -sugeq switch to turn off the deletion of suggestions

Note 2: if you try and add a recording as it is actually starting and get the clash warning because of EndPad's padding of the previous show, manually stop the current recording before adding the new one. TiVo's built in conflict resolution can result in the whole prior programme being deleted in some circumstances.

Note 3: EndPad has the ability to alter the recording quality of any suggestions, allowing you to, say record suggestions at Medium while leaving the default at Best, making setting up SPs faster. Use the optional -sugqual switch with values of 0 (Basic), 40 (Medium), 75 (High) or 100 (Best)

To get the best out of it, your SPs should not set any hard padding themselves. That way TiVo will be able to operate with the lowest number of clashes. The PC based utility I wrote (http://www.tivocommunity.com/tivo-vb/showthread.php?s=&threadid=135029) has an option to remove all padding from SPs if you have a lot to go through.

It will work on all TiVos on both sides of the pond, but will not be fully optimal on DirecTivos as it does not attempt to use the second tuner for extending shows. falconx has produced a version which works with dual tuners - unfortunately forum rules mean I can link to it as it's on the database of deals. The thread id is /forum/showthread.php?t=31854

Copy to the TiVo using binary mode FTP then:

chmod 755 endpad.tcl

Run with:

./endpad.tcl -s x -e y -sugqual z -sugeq

where:

x is the number of minutes of start padding to add
y is the number of end padding to add
z is the recording quality to change suggestions to (0/40/75/100) (Optional)
the optional sugeq parameter prevents EndPad cancelling a suggestion by padding another one

Stop with:

./endpad.tcl -stop

Run from rc.sysinit.author with the -auto flag:

/var/hack/endpad.tcl -s x -e y -sugqual z -sugeq -auto >> /dev/null &

This post will always contain the most up to date version and instructions.

*EndPad is entirely free to use, but next time its saves you a verbal beating thanks to a caught ending that would otherwise be missed, please consider an appropriate donation to Cancer Research through this link:

http://www.justgiving.com/brigid

Please put "EndPad" in the comment.*

Please not that there are restrictions on distribution - read the readme.


----------



## cwaring

Just wanted to say, nice one, Stuart. Pity I can't use it  Then again, I haven't really needed it so far. Of course, you know what'll happen now, don't you


----------



## sanderton

You don't need TurboNet to run it Carl, a serial cable will work fine.


----------



## groovyclam

Can you go even further and add soft padding to the start of a recording ?

Ideally I would set all my SP's to start/end at scheduled times to avoid overlaps from hard padding *but* have your super utility add 1 minute of soft padding to the start of my SPs and 5 minutes soft padding at the end.

Well done for doing what you have done so far.


----------



## tivo_boj

This is superb if it works. Just the thing we have been looking for. All we need now is a simalar programme which checks x minutes before a programme starts to see if any thing else is recording, if not start the sceduled recording early. Combined we would have as close as possible soft padding.

Have just loaded it up and await tonight to see the outcome. I will post my findings.


----------



## Dibblah

Wow. Very nice!

Cheers,

Allan.


----------



## pahunt

Thanks very much for all your hard work, it's much appreciated


----------



## sanderton

> _Originally posted by tivo_boj _
> * All we need now is a simalar programme which checks x minutes before a programme starts to see if any thing else is recording, if not start the sceduled recording early. Combined we would have as close as possible soft padding.
> *


Easy to do, and will be in a future version, but I want to be sure this one is running and stable first.

My main concern with it as it stands is long term stability - I know from other stuff I run that sometimes these things just stop and need restarting.


----------



## gregh

>> I know from other stuff I run that sometimes these things just stop and need restarting.

I've seen this done on other unix boxes where you check for a process running and if it's not there start it!


----------



## mas

That should keep the other half and my son happy !

Can't wait to try it

Can I go home from work now - oh - its only just gone 9am damm!

Thanks

MAS


----------



## groovyclam

I'm trying to get a bash via serial on my TiVo

I have the right lead for a serial connection and manage to get the prompt to put in the "factory" password.

I then get to the menu where I enter "B" to boot but then I get no bash - just nothing. Hitting return causes nothing to happen ( the TiVo *has* booted all the way )

Is there no bash run in the default UK version init scripts - or do I have to rip the harddrive out and put it in my PC to put a bash in the init script first ?

If I have to rip the disk out I will cry! ( Although I suppose my TiVo is due for a backup )


----------



## sanderton

> _Originally posted by gregh _
> *>> I know from other stuff I run that sometimes these things just stop and need restarting.
> 
> I've seen this done on other unix boxes where you check for a process running and if it's not there start it! *


Yes, that was the conclusion I was coming to as a safety net - a cron job every couple of hours looking for the process ID and running it if it's not there.


----------



## sanderton

> _Originally posted by groovyclam _
> *I'm trying to get a bash via serial on my TiVo
> 
> I have the right lead for a serial connection and manage to get the prompt to put in the "factory" password.
> 
> I then get to the menu where I enter "B" to boot but then I get no bash - just nothing. Hitting return causes nothing to happen ( the TiVo *has* booted all the way )
> 
> Is there no bash run in the default UK version init scripts - or do I have to rip the harddrive out and put it in my PC to put a bash in the init script first ?
> 
> If I have to rip the disk out I will cry! ( Although I suppose my TiVo is due for a backup ) *


I think you have to pull the disk - they took out the ability to get a bash prompt on an unmodded TiVo with 2.5.5. Mr Tickle is the bash over serial in the the UK guru. Have you checked the link in his sig?


----------



## groovyclam

> I think you have to pull the disk - they took out the ability to get a bash prompt on an unmodded TiVo with 2.5.5.


Oh that was really useful of them wasn't it! Well done TiVo.

In that case I will wait until you have perfected your super script and rip my disk out then.

You realise you have made something that is worth all the hassle of opening my TiVo again!


----------



## leejordan

> _Originally posted by groovyclam _
> *Can you go even further and add soft padding to the start of a recording ?
> 
> *


This sounds absolutely fantastic! I can't wait to get home and try it out.

I agree with the above quote about adding some front end padding as well. This might help those of us with NTL/Telewest cable boxes that have trouble changing channels sometimes exactly on the hour.

Lee.


----------



## Adder

Well done Stuart!

I've had this running overnight and it added 2 minutes of much needed padding to thr World Rally Championship Omnibus on Channel 4!

I run some consecutive recordings each morning and they all seem to be fine as well!

I'd like to support also the request for front padding as well.

It's top stuff!


----------



## burriko

nice work sanderton!

one quick question though before i try it. what does this do to recordings that already have hard padding set? say i have this program running with soft padding set to 2 minutes, and then i schedule a recording and set tivo to pad the end by 5 mins. would this prog remove the 5 mins that i added and set it 2 mins, or would it add 2 mins to the 5 mins that is already set.

cheers.


----------



## sanderton

As it stands it will remove the 5 mins and insert 2 mins. Which is a good point!


----------



## groovyclam

Another question:

If I am recording something which finishes at ( for example ) 2pm and your super util soft pads it for 5 mins -> 2:05

BUT...

TiVo has a suggestion to record starting at 2pm what will happen:

1) Your softpad takes priority and my scheduled recording runs until 2:05 and the suggestion is discarded or...

2) TiVo stops recording my scheduled recording at 2pm exactly and changes channel to record the suggestion ( which itself will then be padded )

I would prefer it if TiVo did option [1]


----------



## Dapper Dan

Sounds much better than softpad. I look forward to trying this out, and startpad when it's ready. 

:up:


----------



## burriko

> _Originally posted by groovyclam _
> *Another question:
> 
> If I am recording something which finishes at ( for example ) 2pm and your super util soft pads it for 5 mins -> 2:05
> 
> BUT...
> 
> TiVo has a suggestion to record starting at 2pm what will happen:
> 
> 1) Your softpad takes priority and my scheduled recording runs until 2:05 and the suggestion is discarded or...
> 
> 2) TiVo stops recording my scheduled recording at 2pm exactly and changes channel to record the suggestion ( which itself will then be padded )
> 
> I would prefer it if TiVo did option [1] *


from reading through the script it appears to discard suggestions if they get in the way. so option [1].
i could be wrong though.


----------



## sanderton

You are correct, it will cancel any suggestion which would block padding. At least it is supposed to, but looking at that code again there's a typo in it which means it actually won't. Say what you like about VB but at least it doesn't let you key in a variable name wrong!  I'll post an update when I've had a chance to check it.

I'll make it not reduce any pre-existing padding while I'm at it.


----------



## tivo_boj

> I'll make it not reduce any pre-existing padding while I'm at it.


 .

I would rather have it set hard padding to zero and then put in the softpad. This way I know where I am. I know you cant please all the people all the time, so I will just happy which ever way you go.

It might be worth in a later version to have this selectable (or two versions).

Keep up the very good work


----------



## doogie

I started it running this morning, but have had a check and it's not running anymore.... how often should I expect it to require re-run and does it write to any logs when it dies?

Fabulous idea by the way! 

Cheers


----------



## tivo_boj

Sorry for being thick, I did know once but have never used it - where should i place 

rc.sysinit.author.

Also has anyone got a copy I could use as a template.

I think it worth using now we have "softpad"


----------



## sanderton

I suggest you read through this:

http://tivo.stevejenkins.com/network.html#_Toc43127463


----------



## sanderton

> _Originally posted by doogie _
> *I started it running this morning, but have had a check and it's not running anymore.... how often should I expect it to require re-run and does it write to any logs when it dies?
> *


The next iteration writes a log file!

The two copies on my TiVos were up for 18hrs each until I replaced them with an updated copy a few mins ago, so they CAN stay up for a while.


----------



## leejordan

Sorry to be dim  

I've installed endpad.tcl in /var/hack and done a chmod 755 endpad.tcl, but when I try to run it I get the message

": no such file or directory (including the leading quote and colon)

Any ideas please?

Thanks.

Lee


----------



## tivo_boj

Move to the hack directory 

/var/hack

then run endpad

endpad.tcl 5

THAT SEEMED TO WORK FOR ME

BUT THERE AGAIN I'AM ALSO A BIT DIM....SO MAYBE I WAS LUCKY.


----------



## leejordan

> _Originally posted by tivo_boj _
> *Move to the hack directory
> 
> /var/hack
> 
> then run endpad
> 
> endpad.tcl 5
> 
> THAT SEEMED TO WORK FOR ME
> 
> BUT THERE AGAIN I'AM ALSO A BIT DIM....SO MAYBE I WAS LUCKY. *


Thanks but I still get the same message.

Lee.


----------



## mike0151

depends if /var/hack is in the PATH
If not, from /var/hack run ./endpad.tcl
or run /var/hack/endpad.tcl

HTH


----------



## leejordan

> _Originally posted by mike0151 _
> *depends if /var/hack is in the PATH
> If not, from /var/hack run ./endpad.tcl
> or run /var/hack/endpad.tcl
> 
> HTH *


/var/hack is in my PATH and I get the same result which ever way I run it.

Told you I was dim


----------



## sanderton

Did you transer the file in ASCII mode, or open it and save it in a Windows text editor before transferring it?

Try FTPing it again making sure you are in binary mode.


----------



## leejordan

> _Originally posted by sanderton _
> *Did you transer the file in ASCII mode, or open it and save it in a Windows text editor before transferring it?
> 
> Try FTPing it again making sure you are in binary mode. *


Thanks Sanderton, that did the trick 

I had opened it in Wordpad before I ftp'd it.

Thanks again!

Lee.


----------



## sanderton

New version in top post:

Couple of bug fixes (suggestions now work as they were supposed to, pre-existing end padding is respected). Plus now saves a log file which could give some clues if it falls over!


----------



## Fozzie

Truly great work  

Installed and working fine so far. (Just had a look in the log. Am i correct in saying that although it says local time, it is in fact GMT?)

Thanks again for this great app.


----------



## ccwf

> _Originally posted by sanderton _
> *My main concern with it as it stands is long term stability - I know from other stuff I run that sometimes these things just stop and need restarting. *


 At the cost of an extra bash process, you should be able to do this by changing the rc.sysinit.author to something like the following:


Code:


(sleep 120 && while ! /var/hack/endpad.tcl n -run 2>>/var/hack/endpad.err) &

 Basically, bash then runs endpad.tcl over and over until it exits normally (or, looking at it the other way, it re-runs endpad.tcl if it exits abnormally).

Note: The line above appends to the log file instead of replacing it.

Also, is there a reason to put the log file is in /var/hack instead of /var/log?


----------



## ccwf

> _Originally posted by tivo_boj _
> *I would rather have it set hard padding to zero and then put in the softpad. This way I know where I am.*


 What would be the usefulness of unconditionally wiping out the hard padding? Soft padding does not remove the need to hard pad sometimes (e.g., sports events that habitually run longwith only soft padding, no padding might occur, missing the ends of games in order to record another programme).


----------



## Dibblah

Files in transit - Passworded to stop forking 

Cheers,

Allan.


----------



## ccwf

It looks like the current script is an all-or-nothing padding and also simply replaces existing hard padding if the soft pad amount is greater.

The code below changes behavior so that 
soft padding adds to the existing (hard) padding and
less soft padding will be used if necessary.
 First, change endtime to be at the end of the hard-padding.



Code:


# Time this recording ends, including hard-padding.
set endtime [expr "$recstartdate  * 86400  + $recstarttime" + $duration + existingpadding]

 Then, change the block where padding is set to 


Code:


# Check if padding can be added
if {$endtime < $nextstart || $nselectiontype == 6} {

    RetryTransaction {

	# Alter the database record to add the padding
	set rec [db $db openid $recfsid]
        if {$newstoptime <= $nextstart} {
	    # Extend with maximum soft padding.
	    dbobj $rec set EndPadding [expr "$existingpadding + $padding * 60"]
	    puts $logchan "[clock format [clock seconds]] : Added $padding minutes padding"
	} else {
	    # Soft pad until start of next recording.
	    set shortpad [expr "$nextstart - $endtime + $existingpadding"]
	    dbobj $rec set EndPadding $shortpad
	    puts $logchan "[clock format [clock seconds]] : Added $shortpad seconds padding"
	}
    }

} else {

 Warnings: 
The above was coded blind and hasn't been tested!
All existing padding is treated as hard padding. If the script dies repeatedly, then the current recording can get padded repeatedly (i.e., soft padding is treated as hard padding once the script exits, so it can then get padded further). If stability proves to be a problem, state files can be written to preserve padding information between runs of the script so that recordings do not get re-padded.


----------



## ccwf

The code for setting $nextrec needs to be changed to a loop that searches for the next non-suggestion. Currently, it's always the next recording, even if the next recording is a suggestion.

With my changes suggested above, this bug results in suggestions being able to prevent or limit soft padding.

With the code as is, this bug can result in soft padding preventing the next non-suggestion from recording if a sufficiently large soft padding setting was specified.


----------



## sanderton

Thanks Dibblah and ccwf, I will look at incorporating your improvements in the code tonight.

ccwf, I'm happy with its existing behaviour with hard padding, ie if it's been set it stays as set (unless it's less than the softpadding amount). The logic being that if someone is using this utility then they will have removed all hard padding from their programmes, except in instances where they have a particular reason for setting an amount. In such circumstances I think the code should respect their judgment about how much padding they want.


----------



## Fozzie

> _Originally posted by ccwf _
> *What would be the usefulness of unconditionally wiping out the hard padding? Soft padding does not remove the need to hard pad sometimes (e.g., sports events that habitually run longwith only soft padding, no padding might occur, missing the ends of games in order to record another programme). *


I'm with you on this one. Hard padding should not be removed before applying any soft padding,



> _Originally posted by ccwf _
> *It looks like the current script is an all-or-nothing padding and also simply replaces existing hard padding if the soft pad amount is greater.
> 
> The code below changes behavior so that
> soft padding adds to the existing (hard) padding
> *


I think I prefer the first method - e.g. If hard padding of 3 mins has been set up in the SP and soft padding is configured to add 5 mins, I would expect a grand total of 5 min of padding to be added to the recording (which you could think of as the original 3 mins of hard padding and 2 mins of soft padding)



> _Originally posted by ccwf _
> *The code below changes behavior so that
> soft padding adds to the existing (hard) padding and
> less soft padding will be used if necessary.
> *


I'm not sure what you mean by this. Please could you (or Sanderton) clarify. In the original softpad PC based app, I thought that the amount of soft padding applied to a recording could be reduced automatically, if the full amount would have caused a clash with the next scheduled recording. Isn't that what endpad.tcl does currently? Is that what you are proposing?

Many thanks.

Edit: I agree entirely with Sanderton's approach/methodology for dealing with hard vs. soft padding.


----------



## sanderton

> _Originally posted by Fozzie _
> *
> I'm not sure what you mean by this. Please could you clarify. In the original softpad PC based app, I thought that the amount of soft padding applied to a recording could be reduced automatically, if the full amount would have caused a clash with the next scheduled recording. Isn't that what endpad.tcl does currently? Is that what you are proposing?
> 
> Many thanks. *


I was going to implement it that way in the first instance, but I need to do some more checking about the way TiVo actually does some of the start/stop calculations.

It appears if you look at the top-level data that the stop and start times of adjacent recordings are "on the minute", but then you look more closely at some of the other timing parameters, and TiVo does give itself a few seconds to make the change. I didn't want to code for all available padding to be set if that then messed up the time TiVo needs to make the change, and I haven't yet has the chance to test the various options for how to handle that.


----------



## Fozzie

Ok, thanks Sanderton. I understand.

Actually, thinking about it a bit more, the chances of needing to reduce the amount of soft padding occuring are extremely low. I use 5 minutes of soft padding so it's pretty unlikely that the next scheduled recording is at an odd number of minutes i.e. 1,2,3, or 4 minutes later! Have you done any testing with end to start gaps equal to the amount of soft padding and confimed that both the padding is applied and the next recording does start ok? I can give it a thrash later.

So, having said all that, I probably don't really need endpad to automatically reduce the amount of soft padding  

(I guess things do get interesting if/when start padding comes into play. Again, I can't really see myself using that one and so would hope that it's implementation is not detrimental to the way that end padding currently works. As at a lot of people have said before, I would much rather miss the start of a programme than the end.)


----------



## ccwf

> _Originally posted by sanderton _
> *It appears if you look at the top-level data that the stop and start times of adjacent recordings are "on the minute", but then you look more closely at some of the other timing parameters, and TiVo does give itself a few seconds to make the change. I didn't want to code for all available padding to be set if that then messed up the time TiVo needs to make the change, and I haven't yet has the chance to test the various options for how to handle that. *


 Definitely needs investigation. Worst case, it might be necessary to cut the soft-padding short a few seconds in the case where soft-padding all the way to the next recording.


----------



## sanderton

> _Originally posted by Fozzie _
> *
> (I guess things do get interesting if/when start padding comes into play. Again, I can't really see myself using that one and so would hope that it's implementation has not detrimental to the way that end padding works. As at a lot of people have said before, I would much rather miss the start of a programme than the end.) *


Yes, I'm wrrestling with the logic of that one at the moment! The easiest thing to do is to add the start padding to the next programme at teh same time as you add the end padding to the current one. However that goes against the "just in time " philosphy which minimises the possibilities of soft padding causing a clash.

I'm thinking at the moment that if the next programme starts within say 15 mins of the end of the current recording then it will get on and do it, othewise it will wait until just before the next one. I need to test how late I can leave it and TiVo will still respond!

Soft end padding will take priority of over soft start padding, but hard start padding will override both.


----------



## ccwf

> _Originally posted by Fozzie _
> *I use 5 minutes of soft padding so it's pretty unlikely that the next scheduled recording is at an odd number of minutes i.e. 1,2,3, or 4 minutes later!*


 Here in the U.S., a small number of widely watched programmes have guide data starting or ending on odd-minute boundaries (late night talk shows, NBC's most popular primetime shows), so odd minute recordings can definitely occur. I don't know how common such situations are in the UK.


> *(I guess things do get interesting if/when start padding comes into play. Again, I can't really see myself using that one and so would hope that it's implementation is not detrimental to the way that end padding currently works. As at a lot of people have said before, I would much rather miss the start of a programme than the end.) *


 Agreed that missing the starts of programmes is less important than missing the ends, but enough programmes start a bit early that soft-padding the starts would be useful for many.


----------



## Fozzie

Crikey, you guys have it tough - consistently late starting programmes, odd minute boundaries, early starting programmes..... etc etc. Poor TiVo. Do you ever get to watch a complete programme from start to finish?


----------



## sanderton

In the UK we have odd numbered starts and finishes - they just give Tribune the round-numbered version!

Of course when Tribune in the US started using the odd-numbered figures for some shows, it caused chaos as the extra couple of minutes caused a load of unexpected SP clashes. You can't win (unless brodacsters agrre to stick to nice round numbers).


----------



## iankb

> _Originally posted by sanderton _
> *You can't win (unless brodacsters agrre to stick to nice round numbers). *


And that would never work on non-commercial channels, since nobody would want to watch 2 or 3 minutes of BBC promotions or interludes (remember those?) after each episode of the Simpsons.

Ian.


----------



## Fozzie

I've been having a think about how to handle start padding so how's this for a starter for 10:

e.g. Scheduled recording for 1030, start padding of 5 mins set up.

1. Startpad checks at 1025 to see if TiVo is recording anything.
2. If it isn't, start recording programme (5 mins early).
3. If it is, don't do anything (and so scheduled recording starts at 1030).

Sounds too simple and so therefore can't be!

Keeping with the just-in-time philosphy is definitely worth sticking with.


----------



## sanderton

> _Originally posted by Fozzie _
> *
> Sounds too simple and so therefore can't be!
> B]*


*

Nothing is quite that simple 

Code-wise the main complication with that approach would be if you have start padding set to be over 5 mins - that would mean the code would have to wake up before it had run in the first place!*


----------



## Fozzie

> _Originally posted by sanderton _
> *Nothing is quite that simple
> 
> Code-wise the main complication with that approach would be if you have start padding set to be over 5 mins - that would mean the code would have to wake up before it had run in the first place! *


Sorry, I didn't quite mean that. I meant to say that the app does the check at whatever the start padding time is set to. e.g if start padding is set for 7 minutes, then it checks 7 minutes before the start of each recording, if it's set to 3 minutes, then it checks 3 minutes before each recording etc.


----------



## sanderton

Yes, but as it only looks up the start time of the next recording 5 mins before the end of the current recording, that time could already be in the past!

Not exactly insuperable I'll grant you, but trying to think through all the possibilities is what slows the coding down!


----------



## Fozzie

I guess I was thinking of startpad (hey, it's got a name already) as a completely seperate process, without any dependencies on endpad. Therefore 'all' it needs to do is makes a 'simple' decision at the user defined time (the start padding interval) before each recording, whether to start recording or not. This decision being based on whether it is currently recording or not - if it is currently recording, don't do anything; if it isn't currently recording, start the next scheduled recording.

Anyway, it was just a thought. I bow to your greater experience with these things


----------



## sanderton

> _Originally posted by Fozzie _
> *I guess I was thinking of startpad (hey, it's got a name already) as a completely seperate process, without any dependencies on endpad. *


I started down that road, but the run times of startpad and endpad would have to be co-ordinated, as once soft padding is added it cannot be told apart from padding added manually, so if the start pad got added first then it would take priority ove an overlapping start pad.


----------



## Fozzie

hmmm, I can't see how start padding could be added before any end padding using my decison process. If a programme is currently being recorded when it checks to see if it can start the next one early, it won't do anything. It doesn't matter if the current programme is being recorded because of a 'real' end time, a hard padded end time or a soft padded end time. What matters is that it is being recorded and so shouldn't be stopped.

If however, nothing it is being recorded when it checks, then it should be ok to start the next recording (early)?


----------



## sanderton

Yes, but you're logic has the starpad programme checking 5 mins before if 5 mins can be added - and I think you have to give the TiVo a chance to react to the changed padding settings - i'm not sure if it's event driven or ssome kind of timed check.

It's all fun and games!

Anyway, I'm sure it can be made to work.


----------



## bobnick

If there's two suggestions scheduled back to back, or a regular programme followed immediately by a suggestion, will the first show be soft padded?


----------



## sanderton

Yes


----------



## tivo_boj

When using endpad thewvideo has frozen twice, and have needed change channels to unfreeze. This seems to have happened once while recording , once when not. As this did not happen before I can only put it down to endpad.

I also had startrd.tcl running at the same time, could this be causing a clash and thus the video freeze?


----------



## tivo_boj

> _Originally posted by bobnick _
> *If there's two suggestions scheduled back to back, or a regular programme followed immediately by a suggestion, will the first show be soft padded? *


I think this is how we want it to work I would rather have a padded regular programme and miss the suggestion.

If its two suggestions back to back, again is it best to to get one full suggested programme than two suggestion with missed endings? Can't make up my mind on this, no doubt as author sanderton will make the decsion on which is easiest(and most stable).


----------



## sanderton

I think it's very unlikely that endpad could interfere with the video in that way; especially not when there is no recording going on. 

When there is no recording it is simply polling to see if a text file exists every minute - hard to see how that could freeze the video. 

It won't clash with the red dot remover even if they were timed to go off at the same time; they only make one call to the same bit of data, and both use TiVo's built-in locking mechanism to avoid a clash.

The red dot remover is more likley to cause a problem as it simulates sending IR signals to the TiVo, and also capures the keypress events from a received IR signal, both things that could, I guess, cause issues if there was a problem.

I've been running endpad and noredot on one of my two TiVos with no issues (yet!).


----------



## Fozzie

> _Originally posted by tivo_boj _
> *If its two suggestions back to back, again is it best to to get one full suggested programme than two suggestion with missed endings? Can't make up my mind on this, no doubt as author sanderton will make the decsion on which is easiest(and most stable). *


I'm not sure that the assumption that endings are 'normally' missed is right. I would prefer to have both suggestions recorded and run the risk of an ending being missed. After all, if I was that interested in the programme I would have set up an explicit recording. If only the first suggestion was recorded (because of padding), the second (now cancelled) suggestion may have actually been a programme that better matched my viewing habits (or was more interested in). After all, we know how random TiVo's suggestions can be 

All good healthy debate


----------



## Fozzie

> _Originally posted by sanderton _
> *Yes, but you're logic has the starpad programme checking 5 mins before if 5 mins can be added - and I think you have to give the TiVo a chance to react to the changed padding settings - i'm not sure if it's event driven or ssome kind of timed check.*


If time was needed then perhaps you could check at 'padding duration' + 'n' seconds or check at 'padding time' and then start recording at 'padding time' - 'n' seconds?


----------



## tivo_boj

> _Originally posted by sanderton _
> *I think it's very unlikely that endpad could interfere with the video in that way; especially not when there is no recording going on.......
> (cut)
> ...I've been running endpad and noredot on one of my two TiVos with no issues (yet!). *


Thanks,

I will have a play to see if i can re-create, or maybe it was just a "blip" on my system


----------



## ccwf

> _Originally posted by sanderton _
> *I started down that road, but the run times of startpad and endpad would have to be co-ordinated, as once soft padding is added it cannot be told apart from padding added manually*


 It really needs to be one script to handle the end padding, start padding, and possibly negative padding. Trying to coordinate multiple scripts in a safe fashion seems much harder than using a single script.

As for distinguishing between soft padding and the original hard padding, just save (in a variable outside the main loop and, eventually, also to a state file on disk) the ID and original end padding of the current recording (if any) and the ID and original start padding of the next non-suggestion recording. This information can be used between runs of the padding script to know what is soft padding and what is not. It can also be used within the script when this knowledge is necessary.


----------



## sanderton

> _Originally posted by ccwf _
> *It really needs to be one script to handle the end padding, start padding, and possibly negative padding. Trying to coordinate multiple scripts in a safe fashion seems much harder than using a single script.
> 
> As for distinguishing between soft padding and the original hard padding, just save (in a variable outside the main loop and, eventually, also to a state file on disk) the ID and original end padding of the current recording (if any) and the ID and original start padding of the next non-suggestion recording. This information can be used between runs of the padding script to know what is soft padding and what is not. It can also be used within the script when this knowledge is necessary. *


I agree, it will be a single app.

I'm aiming to make it so that it simply doesn't need to know about what is soft and what is hard. (Insert own Carry On joke here..)


----------



## ccwf

As long as you don't care about reducing the soft padding of a recording in progress in the case where someone kills and then restarts endpad with a smaller amount of padding (and I wouldn't), that should be possible.


----------



## bobnick

OK, I'm having trouble getting the script to run. The tcl script is ideal for me, as I'm an airnet user and have dodgy reception!

I've downloaded the zip, and unzipped it using winzip. I've then transferred it using cuteftp to my tivo (ascii transfer) without opening the file. I've then telneted into tivo, gone into the hack directory and set the file permissions. 
No matter whether or not I use ./endpad.tcl 3 or /var/hack/endpad.tcl 3 I get the error message ": no such file or directory
I've pulled the script back on to my PC, and it looks fine in notepad. I've also downloaded it again, and uploaded it using the dos ftp program - but always have the same problem.

Can anyone see what I'm doing wrong? I've run plenty of scripts ok in the past...


----------



## sanderton

Try as a binary transfer; it's a text file but its a Unix text file; maybe your FTP client garbles the CR/LF. This doesn't seem to matter for TCL files that are not executable, eg TiVoWeb modules, but breaks executable ones.


----------



## sanderton

> _Originally posted by ccwf _
> *As long as you don't care about reducing the soft padding of a recording in progress in the case where someone kills and then restarts endpad with a smaller amount of padding (and I wouldn't), that should be possible. *


As it only runs 5 mins from the end of the recording, they'd have to be trying quite hard to do that.


----------



## ccwf

Yes, it's an unlikely case and not really worth the bother.


----------



## Fozzie

Have just checked my log and there seems to be a few instances for the first few hours or so of starting endpad, where padding wasn't added but I can't see why:

e.g.

Thu Oct 09 23:55:00 localtime 2003 : Recording in progress
Thu Oct 09 23:55:00 localtime 2003 : Channel: UKST1
Thu Oct 09 23:55:00 localtime 2003 : Programme: {Garden Rivals}
Thu Oct 09 23:55:00 localtime 2003 : Scheduled End Time: Thu Oct 09 23:59:58 localtime 2003
Thu Oct 09 23:55:00 localtime 2003 : Next Channel: DISC1
Thu Oct 09 23:55:00 localtime 2003 : Next Programme: {Trauma: Life in the ER}
Thu Oct 09 23:55:00 localtime 2003 : Next Scheduled Start Time: Fri Oct 10 00:30:00 localtime 2003
Thu Oct 09 23:55:00 localtime 2003 : Can't add padding
Thu Oct 09 23:55:00 localtime 2003 : Sleep until Fri Oct 10 00:55:00 localtime 2003

Any idea why? It's several hours before it starts adding padding and behaving as expected.

I've attached the logfile.


----------



## pahunt

I've just installed 1.01 but when I run 

/var/hack/endpad.tcl 5 

I get the following error

wrong # args: should be "while test command"
while compiling
"while {$wait} { ..."
("while" body line 118)
while compiling
"while {$test} { ..."
(file "/var/hack/endpad.tcl" line 99)


----------



## sanderton

Looks like the file got corrupted there Paul, try uploading it to the TiVo again.


----------



## sanderton

> _Originally posted by Fozzie _
> *Have just checked my log and there seems to be a few instances for the first few hours or so of starting endpad, where padding wasn't added but I can't see why:
> 
> e.g.
> 
> Thu Oct 09 23:55:00 localtime 2003 : Recording in progress
> Thu Oct 09 23:55:00 localtime 2003 : Channel: UKST1
> Thu Oct 09 23:55:00 localtime 2003 : Programme: {Garden Rivals}
> Thu Oct 09 23:55:00 localtime 2003 : Scheduled End Time: Thu Oct 09 23:59:58 localtime 2003
> Thu Oct 09 23:55:00 localtime 2003 : Next Channel: DISC1
> Thu Oct 09 23:55:00 localtime 2003 : Next Programme: {Trauma: Life in the ER}
> Thu Oct 09 23:55:00 localtime 2003 : Next Scheduled Start Time: Fri Oct 10 00:30:00 localtime 2003
> Thu Oct 09 23:55:00 localtime 2003 : Can't add padding
> Thu Oct 09 23:55:00 localtime 2003 : Sleep until Fri Oct 10 00:55:00 localtime 2003
> 
> Any idea why? It's several hours before it starts adding padding and behaving as expected.
> 
> I've attached the logfile. *


Could that programme already have hard padding on it?. It's the only thing I can think of as the releavny if statement is:

if {($newstoptime < $nextstart || $nselectiontype == 6) && $padding > $existingpadding}

and the log has printed the values of newstoptime and nextstart so the first bit is definitely TRUE; the only possibility is that the other part ($padding > $existingpadding) was FALSE.


----------



## pahunt

> _Originally posted by sanderton _
> *Looks like the file got corrupted there Paul, try uploading it to the TiVo again. *


That did the trick. Thanks very much


----------



## sanderton

Has anyone got any stability issues with their TiVos running EndPad?


----------



## pahunt

> _Originally posted by sanderton _
> *Has anyone got any stability issues with their TiVos running EndPad? *


Not on mine. I had version 1 running for about 24 hours without a hitch and there must have been about a dozen recordings done during that time as well. I've only had 1.01 installed for a couple of hours now but no problems so far.


----------



## 10203

_Originally posted by sanderton _
*I'm aiming to make it so that it simply doesn't need to know about what is soft and what is hard. (Insert own Carry On joke here..) *

Nice module Stuart!  

Maybe you could code the original padding into the recalculated figure. Looks like there are 8 possible values for padding: 1, 2, 5, 15, 30, 60, 90 and 180 minutes (unless you're MrTickle and have hacked the database  ). They're stored in the database in seconds, so you've got all the values inbetween that will never be used by the UI. You could add the index into that array to the padding value so you could decode which one was originally used. e.g. to encode:


Code:


set ui_padding_values { 0, 60, 120, 300, 900, 1800, 3600, 5400, 10800 }

set padding_in_db [defaultval 0 [dbobj $rec get EndPadding]]
set new_padding [lsearch -exact $ui_padding_values $padding_in_db]
if { $new_padding > -1 } {
   incr new_padding $default_soft_padding_value
} else {
   puts "Hello MrTickle!"
}

To decode:


Code:


set flag [expr $current_padding_from_db % 10]
set original_padding [lindex $ui_padding_values $flag]


----------



## pahunt

Just spotted one thing that might be a problem but it might just be how it's supposed to work. 

I had a suggestion that was scheduled from 10:20am to 10:50am this morning and then Friends started recording at 10.55am. I have got it set to use 5 minutes of soft padding but none was used on the suggestion. As it actually had exactly 5 minutes inbetween recordings I would have expected it to pad it.


----------



## Fozzie

> _Originally posted by sanderton _
> *Could that programme already have hard padding on it?*


I thought that and checked but it doesn't!?! In fact, none of my SPs do because I removed it all when I used softpad. I'll keep a check on the logs and see if it happens again.

I did have another question about something that happened last night though. A suggestion (I think) was scheduled to start straight after an explicit recording. From your answer earlier in this thread, a suggestion will get cancelled in order to soft pad a regular recording. That appears to have happened below:

Sat Oct 11 04:54:01 localtime 2003 : Waiting a minute before checking for kill
Sat Oct 11 04:55:00 localtime 2003 : Recording in progressSat Oct 11 04:55:00 localtime 2003 : Channel: ITV2
Sat Oct 11 04:55:00 localtime 2003 : Programme: Rugby
Sat Oct 11 04:55:00 localtime 2003 : Scheduled End Time: Sat Oct 11 04:59:58 localtime 2003
Sat Oct 11 04:55:00 localtime 2003 : Next Channel: DISCOV
Sat Oct 11 04:55:00 localtime 2003 : Next Programme: {Cleopatra's Palace: In Search of a Legend}
Sat Oct 11 04:55:00 localtime 2003 : Next Scheduled Start Time: Sat Oct 11 05:00:00 localtime 2003
Sat Oct 11 04:55:00 localtime 2003 : Added 5 minutes padding
Sat Oct 11 04:55:00 localtime 2003 : Sleep until Sat Oct 11 05:55:00 localtime 2003
Sat Oct 11 04:55:00 localtime 2003 : Waiting a minute before checking for kill

Sat Oct 11 05:54:00 localtime 2003 : Waiting a minute before checking for kill
Sat Oct 11 05:55:00 localtime 2003 : No recording in progress
Sat Oct 11 05:55:00 localtime 2003 : Next recording starts: Sat Oct 11 06:00:00 localtime 2003
Sat Oct 11 05:55:00 localtime 2003 : Next Channel: UKBRID
Sat Oct 11 05:55:00 localtime 2003 : Next Programme: {Garden ER}
Sat Oct 11 05:55:00 localtime 2003 : Next Scheduled Start Time: Sat Oct 11 06:00:00 localtime 2003
Sat Oct 11 05:55:00 localtime 2003 : Sleep until Sat Oct 11 06:25:00 localtime 2003
Sat Oct 11 05:55:00 localtime 2003 : Waiting a minute before checking for kill

Once the padding was added it then says 'Sleep until Sat Oct 11 05:55:00' which is presumeably when the now cancelled suggestion {Cleopatra's Palace: In Search of a Legend} was due to finish. What happens if as a result of the suggestion being cancelled, a recording is scheduled for the now empty slot 05:05:00 to 06:00:00? Will Endpad pick it up or does it do nothing until the end of the sleep period? If not, what about when there is say 6 hours between recordings - will Endpad sleep until the end of the recording that starts in 6 hours time and/or will it still pick up recordings subsequently scheduled?

Many thanks. Oh yeah, it has been stable so far - a day and half


----------



## ccwf

Well, cancelling a suggestion should only enable TiVo to record replacement suggestions.

For your other question, from the source it looks like it sleeps until the next time it thinks it's needed. You are right, there should be a cap on the amount of time endpad sleeps between checks so that it can detect changes to the To Do list, in particular from cancelling the current recording and choosing to record something else.


----------



## sanderton

> _Originally posted by Fozzie _
> *
> Once the padding was added it then says 'Sleep until Sat Oct 11 05:55:00' which is presumeably when the now cancelled suggestion {Cleopatra's Palace: In Search of a Legend} was due to finish. What happens if as a result of the suggestion being cancelled, a recording is scheduled for the now empty slot 05:05:00 to 06:00:00? Will Endpad pick it up or does it do nothing until the end of the sleep period? If not, what about when there is say 6 hours between recordings - will Endpad sleep until the end of the recording that starts in 6 hours time and/or will it still pick up recordings subsequently scheduled?
> 
> Many thanks. Oh yeah, it has been stable so far - a day and half  *


What will happen in this case it that it will wake up 5 mins before the now cancelled suggestion was due to finish. If another suggestion has taken its place, it will pad that. If not, back to sleep it goes until the next recording.

It does not poll for a recording when running, it relies on the TDL. I'm trying to keep the overhead for running the script to the minimum.

BTW, the reason I haven't posted a version wth Dibblah and ccwf's amendments in yet is that I've decided the next version will have start padding, and my blasted social life is interfering with my TiVo hacking!

A start padding enabled version is running now on my TiVos, and I will post when I think it probably works.


----------



## sanderton

> _Originally posted by ccwf _
> *You are right, there should be a cap on the amount of time endpad sleeps between checks so that it can detect changes to the To Do list, in particular from cancelling the current recording and choosing to record something else. *


3 hours?


----------



## ccwf

> _Originally posted by sanderton _
> *I'm trying to keep the overhead for running the script to the minimum.*


 Which is certainly a good thing.

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.

As for the cap on the sleep interval, I would suggest a half hour to an hour. Or just make it another command line option or argument.


----------



## Fozzie

> _Originally posted by sanderton _
> *It does not poll for a recording when running, it relies on the TDL. I'm trying to keep the overhead for running the script to the minimum.*


Thanks sanderton, I think I have it - endpad bases it's time to wake up on the TDL as it stands at the point 5 mins before the end of the current recording. If the TDL changes between that point and when it has decided to wake up, those new programmes will not get padded. I guess the TDL could change for a couple reasons:

a. The next recording (a suggestion) gets cancelled because endpad has just padded the current recording. This could cause a different suggestion to be recorded. This would only get padded if it happened to end at or after the cancelled recording. If it ended before that, it would get missed by endpad. I don't see this as a drama because it's 'only' a suggestion. (Initially, I thought it might be but having typed through the logic I don't think it is!).

b. If there was a large time gap between the current recording and the next scheduled one, there is more potential for either a user initiated recording to be scheduled or perhaps as a result of new guide data being loaded. This seems to be where there is most potential for endpad to accidentally miss something.

I've no idea what the performance overhead would be and whether it's feasible, but would have thought 1/2 hour for checking the TDL would capture most changes, if not all.

Keep up the excellent work. endpad has already saved me an ending


----------



## Chris T

Just found that Endpad fell over at 7.55pm, 55 minuets into recording an hour-long suggestion, and exactly 2 hours after it had been last started.

The error was:

syntax error in expression "1065898798 + * 60"
while executing
"expr "$endtime + $padding * 60""
(file "/var/hack/endpad.tcl" line 158)

Line 158: set newstoptime [expr "$endtime + $padding * 60"]


----------



## sanderton

Thanks Chris, by co-incidence I just fixed that bug!

I hope to post the new version tomorrow.


----------



## mas

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


----------



## sanderton

> _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.


----------



## ccwf

> _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?


----------



## sanderton

> _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..


----------



## bobnick

> _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:


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?


----------



## 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?)


----------



## ccwf

Auto tries to kill an existing endpad.tcl process (if it exists) and then waits two minutes for boot-up to complete.


----------



## sanderton

> _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 ...""
> [/B][/QUOTE]
> 
> 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

> _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.


----------



## Fozzie

Cheers Stuart. That's fixed it. I thought I was going mad


----------



## Lysander

Stuart,

Great little app, well done.  

James


----------



## sanderton

> _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.


----------



## 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.


----------



## 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 )


----------



## sanderton

> _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

> _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

> _Originally posted by bobnick _
> *The error code was
> 
> 
> PHP:
> 
> 
> error writing "file1": I/O error
> while executing
> "puts "retrying after $errorCode ...""
> [/B][/QUOTE]
> 
> OK, I [i]think[/i] 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.
> 
> *


----------



## 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.


----------



## Fozzie

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.


----------



## sanderton

That's in the new version.


----------



## sanderton

> _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.


----------



## tivo_boj

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


----------



## Lysander

No problems here either, saved missing the end of Silent Witness which in turn saved my life. My wife thinks you are lovely...


----------



## sanderton

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

> _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!


----------



## Fozzie

> _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?


----------



## ccwf

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

> _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 thinkTiVo 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.


----------



## Fozzie

> _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?


----------



## sanderton

Local time is hard work, and anyway local time will be GMT in a few days, at least over here. 

TiVo does _everything_ in seconds, even dates (v. big numbers!). Sometimes I convert back to minutes, sometimes life is just too short...

End padding takes priority, which just reflects the way I prefer to work. In practice, unless you set very large amounts of padding, it's rare to have an overlap. In fact I had to run endpad with 15 mins start and 15 mins end to force some to test the code!


----------



## tivo_boj

> _Originally posted by sanderton _
> *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! *


yes , much better, but if I do delete the log file (now in Var/Logs)will endpad start a new one ( just in case I ever need to).

I also take it that end padding takes preference to start padding in that it checks for a to see if a start of a programme clashes with required end padding and if not adds the pad. It then checks the start of the next programme 1 minute plus the start pad setting time before the start of that programme. If that now clashes with the programme plus end pad ( ie the total record time), it does not pad the start.

is this correct, if so might be worth adding such an explaination to the first post.

Thanks ....1.2 now loaded and awaiting my first start and end pads!!!!


----------



## sanderton

I'd stop endpad first, then delete the log. Don't know how happy it will be to have a file it open deleted while it is using it! It starts a new one each time you run it.

If there is a 5 minute gap between programmes and you have start padding for 5 mins and end padding of 5 mins, you will get 5 mins of end padding and 0 mins of start padding.

If there is a 5 min gap and you set 4 mins of end padding and 4 mins of start padding you will get 4 mins of end paddinga nd 1 min of start padding. 

I hope....


----------



## Fozzie

> _Originally posted by sanderton _
> *Local time is hard work, and anyway local time will be GMT in a few days, at least over here. *


Good point 



> *TiVo does everything in seconds, even dates (v. big numbers!). Sometimes I convert back to minutes, sometimes life is just too short...*


Understood.



> *End padding takes priority, which just reflects the way I prefer to work.*


That approach suits me too.

Oh yeah, first successful end pad and a start pad. Great stuff.


----------



## ccwf

> _Originally posted by sanderton _
> *I'd stop endpad first, then delete the log. Don't know how happy it will be to have a file it open deleted while it is using it!*


 In Linux/Unix systems, deleting an in-use file deletes it from the directory it is in but not from the disk. Files are not really deleted until all references to them are removed; so as long as endpad keeps a reference to it (even via redirection, but not always with network mounts if you install a network filesystem on your TiVo), it will remain even though invisible when trying to list files using ls.

This behavior is _very_ different from the DOS/Windows way of doing things.


----------



## tivo_boj

> _Originally posted by sanderton _
> *If there is a 5 minute gap between programmes and you have start padding for 5 mins and end padding of 5 mins, you will get 5 mins of end padding and 0 mins of start padding.
> 
> If there is a 5 min gap and you set 4 mins of end padding and 4 mins of start padding you will get 4 mins of end paddinga nd 1 min of start padding.
> 
> I hope.... *


Thats better than I expected, I think I will now increase the start pad, I did have 1 minute start, 4 minute end , think will move both to 4 minutes.


----------



## sanderton

> _Originally posted by ccwf _
> *In Linux/Unix systems, deleting an in-use file deletes it from the directory it is in but not from the disk. Files are not really deleted until all references to them are removed; so as long as endpad keeps a reference to it (even via redirection, but not always with network mounts if you install a network filesystem on your TiVo), it will remain even though invisible when trying to list files using ls.
> 
> This behavior is very different from the DOS/Windows way of doing things. *


You learn something every day.


----------



## ccwf

> _Originally posted by sanderton _
> *End padding takes priority, which just reflects the way I prefer to work. In practice, unless you set very large amounts of padding, it's rare to have an overlap. In fact I had to run endpad with 15 mins start and 15 mins end to force some to test the code! *


 I'm happy with that for now, too. (Even though mentioned splitting the difference above as an example, I actually don't think that would be a good idea.)

However, as a future enhancement, it might be nice to give priority to a half minute or less of start padding in case of a conflict because, at least in the U.S., there are a number of programmes that do start a few seconds early (needing just a tiny amount of start padding and not even a full minute).

As you wrote, the start/end-padding conflict situation shouldn't come up that often for most people, so this is just something to think about for the future.


----------



## Dapper Dan

> _Originally posted by sanderton _
> *...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. *


Is there any reason why you shouldn't change your rc.sysinit file so that the rc.sysinit.author line is at the very end ?


----------



## ccwf

> _Originally posted by ccwf _
> *[low-level stuff about how deletion works]*


 The effect of in this situation is that it doesn't matter if you delete the file first and then stop endpad.tcl or vice versa.

Actually, since endpad.tcl is logging in append mode, I would just truncate the log file and leave endpad.tcl running instead of deleting the log file and stopping endpad.tcl. (You truncate by overwriting with a zero-length file. /dev/null is typically used for this purpose.)


----------



## sanderton

Why whenever you decide something is ready, does a really obvious bug crop up 2 mins later?

Version 1.2.1 is now on the front page.


----------



## Fozzie

> _Originally posted by sanderton _
> *Why whenever you decide something is ready, does a really obvious bug crop up 2 mins later?*


Doh! Which was?


----------



## ccwf

The setting of nextrec still needs to loop until a non-suggestion is found. I know this scenario is unlikely (e.g., unwisely large end padding setting with a film short or Making Of  show as a suggestion), but I think it's important to fix because it can actually result in endpad.tcl cancelling a real recording.


----------



## sanderton

> _Originally posted by Fozzie _
> *Doh! Which was? *


TiVo doesn't store the end time of a recording, so you have to calculate it from various other settings, and there was one particular circumstance where I got the sum wrong, which meant that the start padding could back into the programme being recorded, making it the second recording fail.

I just watched it happen, and the mistake was so obvious I don't know how it sat there all this time.

Such is life.


----------



## sanderton

> _Originally posted by ccwf _
> *The setting of nextrec still needs to loop until a non-suggestion is found. I know this scenario is unlikely (e.g., unwisely large end padding setting with a film short or Making Of  show as a suggestion), but I think it's important to fix because it can actually result in endpad.tcl cancelling a real recording. *


It's still on my things to do list (as is a whole bunch of other stuff) but it's so unlikely to happen in practice (you would have to have so much end padding set that it would be longer than the entire suggestion) and the code is made quite a lot more complex by it, that I decided to leave it until this version is completely stable and bug free before changing it.

I don't envisage people typically having more than 5 mins soft end padding set ( my settings are 1 min start and 2 mins end) - if I'm misjudging that perhaps people could set me straight?


----------



## Fozzie

I use 1 min start and 4 mins end.

Sticking with your opening post about 'in for a penny, in for a pound' how about a Tivo Web module to remotely stop it and remotely start it; with configurable paramaters of course 

(I'm just flapping about my one month trip away to SA at Xmas, checking endpad's log and finding it had stopped and then having no way of re-starting it!)


----------



## sanderton

ccwf posted a command that will automatically restart endpad should it crash earlier in the thread.


----------



## alunj

1 min start 5 end here . So far so good!
It also got the end of silent witness so my SO is happy too!
dosnt like being killed tho, whish I had readthe file and discovered the
-stop option !! :-0


----------



## ccwf

> _Originally posted by sanderton _
> *It's still on my things to do list (as is a whole bunch of other stuff) but it's so unlikely to happen in practice (you would have to have so much end padding set that it would be longer than the entire suggestion)*


 This is true, but it's worth at least a warning in the first post to tell people not to use very large values for the padding.

I'll post some sample code for the logic in a few minutes, but it could be way off since I'm not as familiar with the idiosyncrasies of the database.


----------



## Adder

> _Originally posted by sanderton _
> *It's still on my things to do list (as is a whole bunch of other stuff) but it's so unlikely to happen in practice (you would have to have so much end padding set that it would be longer than the entire suggestion) and the code is made quite a lot more complex by it, that I decided to leave it until this version is completely stable and bug free before changing it.
> 
> I don't envisage people typically having more than 5 mins soft end padding set ( my settings are 1 min start and 2 mins end) - if I'm misjudging that perhaps people could set me straight? *


How about having 15 minutes of end padding say on a program that finishes at 7pm

A suggestion that is 5 mins long at 7.05pm and a real program at 7.10pm for an hour?

You would lose the 7.10pm program would you not?

Also would end padding on a suggestion override start padding on a real recording?

Questions, questions...


----------



## ccwf

Here's some untested modified code that also tries to find the next non-suggestion: 


Code:


RetryTransaction {
    set currec [mfs scan "/Recording/Active" -start "3:" -count 1]
    set nextrec [mfs scan "/Recording/Active" -start "4:" -count 1]

    set realrec 4
    while { 1 } {
	set nextrealrec [mfs scan "/Recording/Active" -start "${realrec}:" -count 1]
	scan [lindex [lindex $nextrealrec 0] 1] "%d:%d:%d:%d"\
	    nextrealrectype nextrealrecstartdate\
	    nextrealrecstarttime nextrealrecfsid

	if {[dbobj [db $db openid $nextrealrecfsid] get SelectionType] != 6} {
	    break
	}
	incr realrec
    }
}

The padding calculations would be switched to using the nextrealrec-based variables. The wake-up calculation would continue to use the nextrec-based variables.

Easier said than done, of course, and certainly less important than stability as stated above.


----------



## sanderton

And you'd lose the padding of suggestions, which is an often requested feature.

I'll have more of a think about it.


----------



## sanderton

> _Originally posted by alunj _
> *1 min start 5 end here . So far so good!
> It also got the end of silent witness so my SO is happy too!
> dosnt like being killed tho, whish I had readthe file and discovered the
> -stop option !! :-0 *


No, its a tivosh process and they get very upset when you kill them. Nice animation though isn't it?


----------



## ccwf

> _Originally posted by sanderton _
> *And you'd lose the padding of suggestions, which is an often requested feature.
> 
> I'll have more of a think about it. *


 It shouldn't lose padding for suggestions, but you should indeed think about it before implementing.


----------



## cinnamon_oil

Just tried 1.2 out - wowsa! It works! Found one little bug though; although it should (if I read the blurb right) allow values of 30 seconds and 90 seconds (i.e. endpad 0.5 1.5) it doesn't work; it appears to silently die if I try those values. According to the log it goes through one cycle and then dies before it starts the "polling every minute" bit.

Still haven't quite worked out what happens under certain circumstances though! Am I right in thinking that, with start and end padding, it would be

scheduled:suggestion -> suggestion gets dropped
scheduled:scheduled -> no padding, change on time
suggestion:scheduled -> suggestion gets dropped

If so, would it be possible to have a couple of options to set the behaviour in those circumstances? An option for suggestions, do that instead of dropping the suggestions the start time is pushed forward or the end time is pushed back (--preserve-suggestions?), and an option for scheduled so that the channel change time is pushed forward (--always-pad?). Personally I think the latter isn't a good choice, but I know some people have asked for it. 

Actually, a third option just came to mind; if a scheduled recording follows a scheduled one then the padding is applied to the one that has priority in the SP list? With those options I reckon everyone can have the options that suit them.

Anyway - it works pretty darn good already in my opinion! Kudos all round!


----------



## 10203

Another option with the logfile could be to rotate it to 'Oendpad.log' once a day like the other logs. Something along these lines would rotate on the first run after midnight each day. It keeps the current log file if endpad is restarted:




Code:


### Add this definition

set Ologfile "/var/log/Oendpad.log"


### Change the "Open logfile" section to:

set logdate [clock format [file mtime "$logfile"] -format "%j"]

set logchan [open $logfile "a"]

puts $logchan "[clock format [clock seconds] -format $datestamp] : endpad.tcl log file, starting up"


### Add this to the main loop

if {$logdate != [clock format [clock seconds] -format "%j"] } {
   flush $logchan
   close $logchan

   catch {file copy -force $logfile $Ologfile}

   set logchan [open $logfile "a"]
   puts $logchan "[clock format [clock seconds] -format $datestamp] : endpad.tcl log file, log rotated"

   set logdate [clock format [clock seconds] -format "%j"]
}


----------



## sanderton

> _Originally posted by cinnamon_oil _
> *Am I right in thinking that, with start and end padding, it would be
> 
> scheduled:suggestion -> suggestion gets dropped
> scheduled:scheduled -> no padding, change on time
> suggestion:scheduled -> suggestion gets dropped
> 
> *


Yes that's what it's supposed to do, but I need to tidy up the code which handles dealing with adjacent suggestions - you can't schedule suggestions so the testing has been quite limited so far, and I want to add more code to make absolutely certain it is doing what I want.



> _Originally posted by cinnamon_oil _
> * If so, would it be possible to have a couple of options to set the behaviour in those circumstances? An option for suggestions, do that instead of dropping the suggestions the start time is pushed forward or the end time is pushed back (--preserve-suggestions?), and an option for scheduled so that the channel change time is pushed forward (--always-pad?). Personally I think the latter isn't a good choice, but I know some people have asked for it.
> 
> Actually, a third option just came to mind; if a scheduled recording follows a scheduled one then the padding is applied to the one that has priority in the SP list? With those options I reckon everyone can have the options that suit them.
> *


Options to force negative start padding to guarantee end padding (which is what I think you mean) are on the drawing board.


----------



## sanderton

> _Originally posted by LJ _
> *Another option with the logfile could be to rotate it to 'Oendpad.log' once a day like the other logs. Something along these lines would rotate on the first run after midnight each day. *


Ta, I'll add that in.


----------



## Edwards_sj

Jut trying out version 1.2.1 and I saw this in the log...

Tuesday 09:57:00 : Woken up
Tuesday 09:57:00 : Recording {Come Outside} on CBEEB now
Tuesday 09:57:00 : Recording Scheduled End Time: 09:59
Tuesday 09:57:00 : Next recording is Angel on SKYONE at 10:00
Tuesday 09:57:00 : Next end padding setting due 10:55
Tuesday 09:57:00 : Added 120 seconds start padding to Angel
Tuesday 09:57:00 : Next start padding setting due 10:55
Tuesday 09:57:00 : Next wake up will be 10:27

Both were suggestions.

It seems to have added 2 minutes to the beginning of Angel even though there wasn't room... the result was that angel didn't record...

Endpad was running with 2 minutes start and end padding.

Is this right?

Cheers

Steve


----------



## sanderton

No, it's not. I realised this morning that the code for adjacent suggestions needs changing as TiVo's default behaviour when there's a clash is the opposite way round to what I thought it was.

I will tidy it up and post a fix tonight.


----------



## Edwards_sj

> _Originally posted by sanderton _
> *No, it's not. I realised this morning that the code for adjacent suggestions...*


If it's just a problem with suggestions then I'll leave it running for now...


> *I will tidy it up and post a fix tonight. *


Thanks for that...

Cheers

Steve


----------



## sanderton

It _might_ cancel a real recording if there is an suggestion immediately prior to it. Enc. is the fixed code, but I'm not near a TiVo at the moment so I can't test it. I'll post a tested version in the first post later.

Edit: first post now updated


----------



## pwarnes

Hi,

This sounds really cool. I haven't been allowed to open the box yet, or make the serial connection, but I suspect that this will get me permission from SWMBO 

I have read and reread the whole thread ( I think).
Could someone summarise for me exactly what this does, as it seems that people have been suggesting changes and they have been put in along the way.
Isn't documentation a drag


----------



## Edwards_sj

> _Originally posted by sanderton _
> *It might cancel a real recording if there is an suggestion immediately prior to it. Enc. is the fixed code, but I'm not near a TiVo at the moment so I can't test it. I'll post a tested version in the first post later. *


Well I would install it but I've managed to crash my Tivo telnet session, I'll need to reboot the Tivo when I get home 

Cheers

Steve


----------



## sanderton

> _Originally posted by pwarnes _
> *Hi,
> 
> This sounds really cool. I haven't been allowed to open the box yet, or make the serial connection, but I suspect that this will get me permission from SWMBO
> 
> I have read and reread the whole thread ( I think).
> Could someone summarise for me exactly what this does, as it seems that people have been suggesting changes and they have been put in along the way.
> Isn't documentation a drag  *


The first post is kept up to date with the latest version (and instructions).


----------



## sanderton

> _Originally posted by Edwards_sj _
> *Well I would install it but I've managed to crash my Tivo telnet session, I'll need to reboot the Tivo when I get home
> 
> Cheers
> 
> Steve *


Perhaps I should explain, I don't think there's a problem (except with two back to back suggestions), but it did occur to me that I'm assuming that when my code generates a clash between a suggestion and a scheduled recording that the scheduled recording will win, just like it would if you did it by hand. However I hadn't actually tried it to see as my machine has very few Suggestions scheduled as it's full. The amended code just forces the deletion to make double sure.


----------



## sanderton

1.2.2 is now in the first post. Fixed a couple of potential bugs, and made the timing elements more robust.

I've taken a saftety first approach and if a suggestion is followed immediately by a scheduled recording I've not added start padding. This is until I can confirm that it is the suggestion that gets deleted, not the scheduled recording in those circumstances. Suggestions that follow a scheduled recording and clash with the padding are now expressly deleted instead of relying on the clash to do it.


----------



## Fozzie

Thanks Stuart.

One thing I'm not sure on. I remember you saying that end padding has priority over start padding. Is this regardless of whether the current recording is a suggestion or not? In other words if there is a suggestion followed by a scheduled (with say a 5 minute gap in between) and padding was set for 5 & 5. Would the suggestion get the end padding?

(I was thinking in the car on the way home, about how most of the the questions are about suggestions. I think I watch about 1 per week - I wouldn't mind betting this is the same for a lot of other people. If the programme was that important, then I'd set up an explicit recording! So to put things into perspective (for me anyway) this really is ultra-fine tuning.)


----------



## tivo_boj

I agree that a sceduled recording should take preference over any suggestion so I am glad stuart has put "safety first". I too would specifically record a programme if I really wanted it not rely on suggestion to record it.


----------



## cinnamon_oil

> _Originally posted by sanderton _
> *Suggestions that follow a scheduled recording and clash with the padding are now expressly deleted instead of relying on the clash to do it. *


Cool... installing 1.2.2 now. Any thoughts as to if the alternative I suggested might be possible as an option? (That is, instead of deleting the suggestion instead the start time of the suggestion is changed to avoid the clash?)

And yes, I know that if the program is important I should record it, but I only regard a few programs as important and quite like flicking through the suggestions of an evening. ;-)


----------



## ccwf

> _Originally posted by cinnamon_oil _
> *Any thoughts as to if the alternative I suggested might be possible as an option? (That is, instead of deleting the suggestion instead the start time of the suggestion is changed to avoid the clash?)*


 As mentioned above, once Stuart implements negative padding, that should do most of what you want, especially if there were indepedent padding settings for suggestions and normal recordings (which actually isn't that hard to add for positive padding, but I don't know how negative padding will complicate things).


----------



## cinnamon_oil

endpad.tcl 0.5 1.5 still isn't working for me in 1.2.2 - I am right in thinking that should work, amn't I?

(I'm easily confused!)


----------



## cinnamon_oil

> _Originally posted by ccwf _
> *As mentioned above, once Stuart implements negative padding, that should do most of what you want, especially if there were indepedent padding settings for suggestions and normal recordings (which actually isn't that hard to add for positive padding, but I don't know how negative padding will complicate things). *


I have to admit... I never actually quote got my noggin around what "negative padding" meant in this context, so I sort of glossed over that part in my head and thought about fluffy bunnies instead...

Someone want to take a shot at explaining? ;-)


----------



## ccwf

Normal padding makes programmes start recording earlier and stop recording later. Negative padding does the reverse.


----------



## cinnamon_oil

> _Originally posted by ccwf _
> *Normal padding makes programmes start recording earlier and stop recording later. Negative padding does the reverse. *


That much I'd figured... but I wasn't quite sure how that would be used to implement what I'd suggested (moving suggestion start times if the padding on the scheduled program in front would otherwise result in the suggestion being deleted). Although having seperate start and end padding for scheduled and suggestions would sort of do that (2 mins end padding for scheduled, -2 start padding for suggestions) it would result in suggestions always having 2 minutes less, even if there's no reason for the start time to alter. I think what I'm suggesting is different, and perhaps more useful?

Or am I missing a fundamental point... as per normal!


----------



## Fozzie

> _Originally posted by cinnamon_oil _
> *And yes, I know that if the program is important I should record it, but I only regard a few programs as important and quite like flicking through the suggestions of an evening. ;-) *


But if endpad cancelled the recording of a suggestion because of a (potential) clash with the end padding of a scheduled recording, you'd be none the wiser because you probably didn't know that it was going to be recorded in the first place 

It's not like a whole bucket load of suggestions is going to get cancelled because of end padding of a scheduled recording - I would expect the odd one or two perhaps, per day. I was surprised when I looked in my recording history earlier, to see dozens of things not recorded today for various reasons - endpad cancelled suggestions would be a drop in the ocean comparatively speaking 

My preference is for any padding for scheduled recordings to have priority over any padding for suggestions (in fact, priority over suggestions full stop) and, end padding to have priority over start padding. This may be where we are, or not - Stuart? All I know is that I've got the ends of some progs that I would have missed without endpad (and a smattering of start padding thrown in for good measure) 

I don't know if I would have a use for different settings for suggestions & scheduled?


----------



## ccwf

> _Originally posted by cinnamon_oil _
> *[Negative padding] would result in suggestions always having 2 minutes less, even if there's no reason for the start time to alter.*


 Well, if the negative padding were hard (meaning, it's always applied, like TiVo's normal padding), this would indeed be the case. Soft negative padding, on the other hand, would be applied only if necessary.


----------



## Fozzie

> _Originally posted by ccwf _
> *Soft negative padding, on the other hand, would be applied only if necessary. *


hehe, which is the opposite of soft positive padding which is always applied in full, if it can be!


----------



## cinnamon_oil

> _Originally posted by ccwf _
> *Well, if the negative padding were hard (meaning, it's always applied, like TiVo's normal padding), this would indeed be the case. Soft negative padding, on the other hand, would be applied only if necessary. *


Oh, now I get it... it's not so much padding, it's more a case of (if it was start padding of "-2") "allow this programme to start up to two minutes late if needed to prevent a clash"

Having said that - basically, that's what I was suggesting, isn't it? ;-)


----------



## sanderton

As things stand in 1.2.2, a suggestion could get end padded stopping a real recording getting start padded. That will change once I am sure I know how to kill an in-progress suggestion. (TiVoWeb doesn't do that so there's no code I can pinch. )

I just got to the page in my Idiots Guide to TCL on data types in TCL, so I now understand the problem with 0.5 and I can fix it.


----------



## bobnick

Might it be possible to set postive and negative padding when running the program, so shows can be shortend or lengthened as appropriate?


----------



## Fozzie

> _Originally posted by bobnick _
> *Might it be possible to set postive and negative padding when running the program, so shows can be shortend or lengthened as appropriate? *


Hard positive end padding can be adjusted during recording from the main TiVo interface so perhaps it could be done from endpad?


----------



## tivo_boj

Think I may have found a problem

Recorded Crouches (see below)

Tuesday 21:32:01 : Next start padding setting due 22:00
Tuesday 21:32:01 : Next wake up will be 22:00
Sleeping, checking every minute for kill signal............................. 
Tuesday 22:00:00 : Woken up
Tuesday 22:00:00 : Recording Crouches on BBC1SE now
Tuesday 22:00:00 : Recording Scheduled End Time: 22:05
Tuesday 22:00:00 : Next recording is {The Farewell} on BBC4 at 23:10
Tuesday 22:00:00 : Added 240 seconds end padding to Crouches
Tuesday 22:00:00 : Next end padding setting due 00:35
Tuesday 22:00:00 : Not time to add start padding yet
Tuesday 22:00:00 : Next start padding setting due 23:07
Tuesday 22:00:00 : Next wake up will be 22:30
Sleeping, checking every minute for kill signal.......................

Then after "men behaving badly"(which followed direcly) had been on for 10 mins pressed the record bustton and chose "record at best".

Now find no sign of Crouches on Now playing, in recording history or in deleted programmes. What happened to it it seems to ahve vanished, but as the log shows above it was recording. 

However this looks as if the crouches it was a suggestion....so is the reason?


----------



## sanderton

Suggestions are delicate things. You will find the To Do list stuffed with them, but most fall over at the slightest provocation and never even start recording. Cancel one mid recording and it vanishes. This is probably - and I'm guessing mind you - to do with the way the 240 seconds padding on the the suggestion meant it overlapped with MBB. As Suggestions never have padding, the TiVo code probably just sees that as a clash with a user scheduled recording and kills the suggestion, even though its finished.

You might find a trace of it by using TiVowWeb too look in MFS in the Recording/Active directory. Have a look through the last few entries which start with "1".


----------



## sanderton

> _Originally posted by bobnick _
> *Might it be possible to set postive and negative padding when running the program, so shows can be shortend or lengthened as appropriate? *


Can't see why you would choose to have blanket negative pad? What I do intent to implement is a switch to force the inclusion of the end padding in all circumstances, starting any subsequent programme late if need be.

Blanket negative start padding probably works right now, but I haven't tried it.


----------



## bobnick

I was concentrating on the *soft* element of negative padding; if only one show was going to be recorded, it'd be nice to have it start a minute early. If two programmes were on, overlapping by 5 minutes, it'd be nice to have the first one recorded in its entirety, and have the second programme recorded too (apart from the first overlapped 5 minutes)


----------



## Fozzie

> _Originally posted by bobnick _
> *If two programmes were on, overlapping by 5 minutes, it'd be nice to have the first one recorded in its entirety, and have the second programme recorded too (apart from the first overlapped 5 minutes) *


Would this even be possible? One of the two shows (the lowest priority) will not even be in the TDL (because of the overlap) so endpad would not know of it's existence?

Won't negative soft padding add an unecessary level of complexity? How do you decide whether to pad the end of the current recording & start late the next recording or pad the end of the current recording and don't record the next recording or even partially pad the end of the current recording and start the next recording on time? Beyond me. (Aren't positive and negative soft padding mutually exclusive and so you would have to decide on a global basis whether you want programmes to be possibly started early or, possibly started late? I know which one I'd go for).

Sanity check - isn't the purpose of endpad to, where possible, start recordings early and delay the ends of recordings to ensure that beginnings and endings are not missed. If you then start using negative padding you could end up with a whole load of recordings that either miss the beginning or miss the end and so we're back to where we started?!?!

Ok, so I'm unconvinced about the benefits of globally set, automatic, negative, soft padding


----------



## Fozzie

> _Originally posted by sanderton _
> *This is probably - and I'm guessing mind you - to do with the way the 240 seconds padding on the the suggestion meant it overlapped with MBB. As Suggestions never have padding, the TiVo code probably just sees that as a clash with a user scheduled recording and kills the suggestion, even though its finished.*


Or it possibly got trashed at the time of pressing the record button. There would have been 4 minutes of MBB as part of the previous suggestion but also still in the Live Buffer. Perhaps pressing record claimed back that 4 minutes since it was part of MBB, causing the suggestion to be trashed?

tivo_boj - did the MBB recording that you manually instigate start at the beginning of the programme or 4 minutes into it?


----------



## dd400005

Aren't we getting a little over-complicated now?

In my opinion, the amount of end or start padding defined should be a maximum, rather than a fixed amount. If you specify 5 mins of soft end-padding, then the script should try and add as much as possible without interrupting the next scheduled program (SP or Suggestion). Maybe it's only 1 minute, maybe 4 minutes. If there's no clashes then the full 5 minutes.

I maybe oversimplifying things, and having never written a TCL script or even hacked my TiVo that's certainly possible, but don't we just want something as simple as this below?

1. Wakeup 5 mins before end of program. I don't know how you do that, but clearly you already are.

2. Add as much soft padding as possible (up to selected amount) so long as it doesn't affect the next scheduled SP or Suggestion.

3. Determine next scheduled recording and set a wakeup time of a few minutes before that, or every half hour.

4. At wakeup time, if not currently recording, and a recording is due to start shortly, add as much soft start-padding as possible (up to selected amount). If no recording scheduled, set wake up in half an hour again.


I think the regular half hourly wake-ups would catch things being added to the to do list that you might normally miss because 5 mins before the end of the previous program you specified the wakeup time 5 mins before the start of the next program. By specifying the wakeup time for start padding checking as either 5 mins before the next prog, or every half hour (whichever is nearer) then you would manage to soft-start-pad new items added to the list.

Waking up x mins before a scheduled start gives you time to add the soft start padding if not currently recording. If that prevents the user from being able to record a current show, or recording that show would cause a clash because the next one is scheduled to start y mins early, tough! TiVo will let you know about it. Likewise, if adding the soft end padding prevents the user from adding another show at the end interactively, or hitting record to the current show while in the end padding, tough!

I think the smallish problems you'd encounter by keeping the script simpler would be trivial. The simpler it is, the easier it is to understand the logic of how it's thinking. If you can summarize it in just a few lines of pseudo code, then the TiVo user will know exactly what it will do in the current circumstances just by looking at their todo list. There'll be no mystery, and that's worth a lot. Wondering what it might do because it's a complex beast isn't good IMHO.

I personally would specify 2 mins of soft start padding and 5 mins of soft end padding. I'd be happily looking in my To Do list and know "I'll get both there, I'll get only end there, I'll get only start there" etc etc.


----------



## Fozzie

> _Originally posted by dd400005 _
> *In my opinion, the amount of end or start padding defined should be a maximum, rather than a fixed amount. If you specify 5 mins of soft end-padding, then the script should try and add as much as possible without interrupting the next scheduled program (SP or Suggestion). Maybe it's only 1 minute, maybe 4 minutes. If there's no clashes then the full 5 minutes.
> 
> I maybe oversimplifying things, and having never written a TCL script or even hacked my TiVo that's certainly possible, but don't we just want something as simple as this below?
> 
> 1. Wakeup 5 mins before end of program. I don't know how you do that, but clearly you already are.
> 
> 2. Add as much soft padding as possible (up to selected amount) so long as it doesn't affect the next scheduled SP or Suggestion.
> 
> 3. Determine next scheduled recording and set a wakeup time of a few minutes before that, or every half hour.
> 
> 4. At wakeup time, if not currently recording, and a recording is due to start shortly, add as much soft start-padding as possible (up to selected amount). If no recording scheduled, set wake up in half an hour again.
> 
> *


That is basically what we current have. TiVo wakes up just before the max endpadding time of the current recording and will add (up to) the max end padding it can, without causing a clash with the next scheduled recording. It then look sat the next recording and is set to wake up just before the max start padding interval. It will then add (up to) the max start padding without causing a clash with the current recording. It then goes to sleep until either a - just before the max start padding time of the next recording or b - 30 minutes, whichever is the earlier.

I'm with you on not overcomplicating things. For me, things seem to be pretty much working perfectly. There's some very minor tweaking to be done with the handling off suggestions but the app's philosophy is spot on. 1 - add as much end padding as possible. 2 - add as much start padding as possible.

Things will get unweildy as soon as you start going down the line of " if...then....but not if.....however.....then...... but only if.......unless......." etc.
I want to guarantee the ends of recordings and if possible start a bit early - that's all. (You've heard of the KISS philosphy? Keep It Simple, Stupid!)

All IMHO of course.


----------



## pahunt

I installed 1.2.2 last night and I think I may have a problem. 

I recorded Life of Grime and it quite correctly put 5 minutes of extra padding on the end. However when it got to the end of the 2nd Father Ted on E4 it put 10 minutes on the end. I haven't recorded anything else since so I don't know if this was a one off and I won't be able to check anymore until I get home this evening but I thought I'd raise the question anyway.


----------



## Roj

> _Originally posted by sanderton _
> *1.2.2 is now in the first post. Fixed a couple of potential bugs, and made the timing elements more robust.
> 
> I've taken a saftety first approach and if a suggestion is followed immediately by a scheduled recording I've not added start padding. This is until I can confirm that it is the suggestion that gets deleted, not the scheduled recording in those circumstances.*


If it helps, I can confirm that with 1.2.1, the scheduled recording can get deleted, since it happened to me last night.
Tivo suggestion "The Others" on Ch5 immediately followed by "Ever wondered about food" on BBC2.
Endpad set to start=2, end=4.
"The others" was correctly recorded with 2 mintes start pad, no end pad.
"Ever wondered about food" not recorded - endpad log shows that it tried to add 2 minutes start padding to this as well.

I can send/post logs if that will be helpful?

Many thanks for your work on this - it's already nearly a great utility, and I'm sure it soon will be!

Roj


----------



## Fozzie

> _Originally posted by sanderton _
> *I've taken a saftety first approach and if a suggestion is followed immediately by a scheduled recording I've not added start padding.*


Not that you need the confirmation (because you wrote the code!), this is what happens. This occured last night and I have both the suggestion & scheduled recording in my TDL, with no padding applied.


----------



## sanderton

> _Originally posted by bobnick _
> *I was concentrating on the *soft* element of negative padding; if only one show was going to be recorded, it'd be nice to have it start a minute early. If two programmes were on, overlapping by 5 minutes, it'd be nice to have the first one recorded in its entirety, and have the second programme recorded too (apart from the first overlapped 5 minutes) *


Yes, that's exactly what I'm planning as an option.


----------



## Fozzie

> _Originally posted by cinnamon_oil _
> *Actually, a third option just came to mind; if a scheduled recording follows a scheduled one then the padding is applied to the one that has priority in the SP list? With those options I reckon everyone can have the options that suit them.*


I wouldn't use that option. If there was a choice between adding end padding to the current recording or adding start padding to the next (higher) priority recording, I'd still prefer to get the end padding - as I believe currently happens i.e end padding has priority of start padding.


----------



## sanderton

> _Originally posted by pahunt _
> *I installed 1.2.2 last night and I think I may have a problem.
> 
> I recorded Life of Grime and it quite correctly put 5 minutes of extra padding on the end. However when it got to the end of the 2nd Father Ted on E4 it put 10 minutes on the end. I haven't recorded anything else since so I don't know if this was a one off and I won't be able to check anymore until I get home this evening but I thought I'd raise the question anyway. *


Thanks; could you post the relevant clip of log file? I can't immediately see how that could happen.


----------



## sanderton

> _Originally posted by Fozzie _
> *I wouldn't use that option. If there was a choice between adding end padding to the current recording or adding start padding to the next (higher) priority recording, I'd still prefer to get the end padding - as I believe currently happens i.e end padding has priority of start padding. *


I'd rather no got down that route as it's adding loads of database accesses to look up the SPs. Less is more when it comes to stability.


----------



## sanderton

> _Originally posted by dd400005 _
> *Aren't we getting a little over-complicated now?
> 
> In my opinion, the amount of end or start padding defined should be a maximum, rather than a fixed amount. If you specify 5 mins of soft end-padding, then the script should try and add as much as possible without interrupting the next scheduled program (SP or Suggestion). Maybe it's only 1 minute, maybe 4 minutes. If there's no clashes then the full 5 minutes.
> 
> I maybe oversimplifying things, and having never written a TCL script or even hacked my TiVo that's certainly possible, but don't we just want something as simple as this below?
> 
> 1. Wakeup 5 mins before end of program. I don't know how you do that, but clearly you already are.
> 
> 2. Add as much soft padding as possible (up to selected amount) so long as it doesn't affect the next scheduled SP or Suggestion.
> 
> 3. Determine next scheduled recording and set a wakeup time of a few minutes before that, or every half hour.
> 
> 4. At wakeup time, if not currently recording, and a recording is due to start shortly, add as much soft start-padding as possible (up to selected amount). If no recording scheduled, set wake up in half an hour again.
> 
> I think the regular half hourly wake-ups would catch things being added to the to do list that you might normally miss because 5 mins before the end of the previous program you specified the wakeup time 5 mins before the start of the next program. By specifying the wakeup time for start padding checking as either 5 mins before the next prog, or every half hour (whichever is nearer) then you would manage to soft-start-pad new items added to the list.
> 
> Waking up x mins before a scheduled start gives you time to add the soft start padding if not currently recording. If that prevents the user from being able to record a current show, or recording that show would cause a clash because the next one is scheduled to start y mins early, tough! TiVo will let you know about it. Likewise, if adding the soft end padding prevents the user from adding another show at the end interactively, or hitting record to the current show while in the end padding, tough!
> 
> I think the smallish problems you'd encounter by keeping the script simpler would be trivial. The simpler it is, the easier it is to understand the logic of how it's thinking. If you can summarize it in just a few lines of pseudo code, then the TiVo user will know exactly what it will do in the current circumstances just by looking at their todo list. There'll be no mystery, and that's worth a lot. Wondering what it might do because it's a complex beast isn't good IMHO.
> 
> I personally would specify 2 mins of soft start padding and 5 mins of soft end padding. I'd be happily looking in my To Do list and know "I'll get both there, I'll get only end there, I'll get only start there" etc etc. *


You just described precisely what EndPad does and how it works (except I prefer for padding to take priority over suggestions). I may steal this post for the ReadMe.


----------



## sanderton

> _Originally posted by Roj _
> *If it helps, I can confirm that with 1.2.1, the scheduled recording can get deleted, since it happened to me last night. *


Bggr. Sorry about that. 1.2.2 fixes the problem.


----------



## sanderton

Version 1.2.3 now in the first post:

- fractions now really do work (ie, use 0.5 to give 30 seconds padding)
- log file handling improved, thanks to LJ
- the potential bug with very long end padding cancelling the next-but-one show if the next show was a suggestion fixed


----------



## Dibblah

> _Originally posted by pahunt _
> *I installed 1.2.2 last night and I think I may have a problem.
> 
> I recorded Life of Grime and it quite correctly put 5 minutes of extra padding on the end. However when it got to the end of the 2nd Father Ted on E4 it put 10 minutes on the end. I haven't recorded anything else since so I don't know if this was a one off and I won't be able to check anymore until I get home this evening but I thought I'd raise the question anyway. *


Is it possible that the season pass has padding? Soft padding will add to this, up to the amount you specified.

Cheers,

Allan.


----------



## Crispin

I have just installed 1.2.3, and it seems like it won't run unless you first create the /var/log/endpad.log file:



Code:


A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
         couldn't stat "/var/log/endpad.log": no such file or directory
             while executing
         "file mtime "$logfile""
             (file "/var/hack/bin/endpad.tcl" line 229)

Once I create the file, it starts up fine


----------



## sanderton

Thanks!

Fixed in 1.2.4, now in first post.


----------



## pahunt

> _Originally posted by Dibblah _
> *Is it possible that the season pass has padding? Soft padding will add to this, up to the amount you specified.
> 
> Cheers,
> 
> Allan. *


No I definitely haven't got any padding on the Father Ted season pass because there were 2 episodes shown back to back and I got both of them. If there had been any hard padding I wouldn't have got the 2nd one at all.


----------



## pahunt

> _Originally posted by pahunt _
> *No I definitely haven't got any padding on the Father Ted season pass because there were 2 episodes shown back to back and I got both of them. If there had been any hard padding I wouldn't have got the 2nd one at all. *


Well all my recordings today have worked perfectly so I've put last night's "problem" down as a one-off. I just installed 1.2.4 so I'll see what happens


----------



## sanderton

Can you post the relevant bit of the log file (cut and paste from the Logs section of TiVoWeb)? I can't figure out how it could add more padding than you set.


----------



## pahunt

> _Originally posted by sanderton _
> *Can you post the relevant bit of the log file (cut and paste from the Logs section of TiVoWeb)? I can't figure out how it could add more padding than you set. *


Sorry but I've rebooted since then (telnet died ) so I can't see the relevant part of the log in Tivoweb.


----------



## tivo_boj

Found that endpad had teminated as log was stop mid way. on re-loading endpad got this

bash-2.02# cd /var/hack
bash-2.02# endpad.tcl 1.5 4.5
A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
expected integer but got "$nextrecfsid"
while executing
"db $db openid $recfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
set rec [db $db openid $recfsid]
set state [dbobj $rec get State]
if { $state != 6 } {
dbclose $db
return 0
} else {
dbob..."
(procedure "DeleteSuggestion" line 7)
invoked from within
"DeleteSuggestion {$nextrecfsid}"
(file "/var/hack/endpad.tcl" line 372)
bash-2.02# endpad.tcl 1.5 4.5
EndPad is already running
bash-2.02#

Any reason for this?


----------



## Dibblah

It looks like the suggestion died because someone looked at it funny, before endpad could do it.

Cheers,

Allan.


----------



## Dibblah

NSecondsWatched is an entry on each recording, which gets set when you pause it. How about setting it to either a variable amount, or the unpadded start of the recording?

Just an idea,

Allan.


----------



## leejordan

Hi,

I'm running endpad 1.2.4 and it failed with this message last night..

A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
syntax error in expression "-auto * 60"
while executing
"expr $endpadding * 60"
(file "/var/hack/endpad.tcl" line 362)
syntax error in expression "-auto * 60"
while executing
"expr $endpadding * 60"
(file "/var/hack/endpad.tcl" line 362)

Hope this is of some help.

Lee.


----------



## Chris T

The latest version also failed on me last night, with the error:

expected integer but got "$nextrecfsid"
while executing
"db $db openid $recfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
set rec [db $db openid $recfsid]
set state [dbobj $rec get State]
if { $state != 6 } {
dbclose $db
return 0
} else {
dbob..."
(procedure "DeleteSuggestion" line 7)
invoked from within
"DeleteSuggestion {$nextrecfsid}"
(file "/var/hack/endpad.tcl" line 372)

Tivo was recording back to back suggestions at the time.


----------



## sunscreem

Just a quick one...

I installed the latest version 1.2.4 (?) (for the first time last night). 

It works a treat - but it did appear to stop running about 3 hours after it was installed (my friends did the same too).

I just started it again and it appears to be fine now.

Rob


----------



## Fozzie

Stuart, could you explain how the log switching works.

I've got endpad.log which runs from when I started endpad going up to now and Oendpad.log which starts from when I started endpad going up to 00:28 last night.

I was expecting that when Oendpad.log was created, endpad.log would be cleared and then start from that time?

Thanks.

Edit: endpad's been running solid since 1900 yesterday


----------



## sanderton

Errors, lovely errors. 

There are so many nested "if"s in the code to catch all the possibilities that I can never be sure each line has been run until its been out in the field for a bit.

The two "expected integer but got "$nextrecfsid"" are because of a typo in the the code; I used the wrong kind of brackets in a command. Look for 1.2.5 in a couple of minutes.

The "syntax error in expression "-auto * 60"" error is because the order the arguments appear is imprortant, it needs to be:

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

and it looks like you have entered:

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

The logfile problem is also fixed in 1.2.5.


----------



## Roj

Stuart,

Just wondered if you've already thought about whether there will be any impact on endpad from the clocks changing between GMT/BST.

The logs seem to be in GMT anyway, so perhaps there is none?

Probably worth thinking about this before the next change, since you don't get many opportunities for testing!

Roj


----------



## sanderton

EndPad uses TiVos own internal clock system, which AFAIK doesn't "do" BST etc at all. The times are converted to local time by TiVo before being displayed. Even US Tivos run on GMT! Because I only use the internal clock, there should be no issue.


----------



## iankb

> _Originally posted by sanderton _
> *Even US Tivos run on GMT!*


I'm sure they really run on UTC. 

Ian.


----------



## sanderton

That's just so they don't feel too colonial.


----------



## burriko

I just thought i'd chip in to say that i've been running endpad 1.01 for almost a week now, and haven't had a single problem. It hasn't crashed once and it's added the correct padding to every programme that it could.
From reading this thread it seems that versions since then having been causing problems. It's great that new features are still being worked on, but if people just want a stable version to use until the newer, more advanced features are fully tested, then i recommend giving 1.01 a go.

btw, thanks for all the hard work sanderton, it's a truly useful program!


----------



## sanderton

Glad its working for you. 

1.01 actually had a few bugs in it that could cause you to lose recordings, admittedly under fairly unusual circumstances. I think that 1.2.5 should be pretty stable now. If/when I add forced ngatve padding, the stable version will remain available.

But I'm mainly fiddling with a TiVoWeb module to atttempt to resolve conflicts by scheduling them on a second TiVo now!


----------



## burriko

> _Originally posted by sanderton _
> *1.01 actually had a few bugs in it that could cause you to lose recordings, admittedly under fairly unusual circumstances.*


I was wondering if i'd just been lucky so far. 



> * I think that 1.2.5 should be pretty stable now. If/when I add forced ngatve padding, the stable version will remain available.*


cool, i'll give it a try then.


----------



## RichyClarke

Sanderton - Have to say this is the second best util around (after TivoWeb of course) .

Set up 1.2.4 last night and had the same probs as others here (fell over after ~3 hours) so checked back here and installed 1.2.5 - no problems since running it this AM with a few test programs.

I felt I had to break my silence (been a lurker for a few months now) to say thanks for this excellent utility.

  :up:


----------



## mas

Record clashes on a second tivo

I'd like to see pace get sky+ to do that !


----------



## Fozzie

> _Originally posted by RichyClarke _
> *Set up 1.2.4 last night and had the same probs as others here (fell over after ~3 hours) so checked back here and installed 1.2.5 - no problems since running it this AM with a few test programs.*


I thought I'd do a quick check of my 1.2.4 from work and after running fine for ~15 hours, fell over just before lunchtime!

Stuart, Ill post the log when I get home so you can check that it was one of the bugs you've fixed in 1.2.5. It looks like it was recording back to back suggestions.


----------



## sanderton

That's where the bug was.


----------



## Fozzie

Yep. Same error as Chris T above. All back up and running now with 1.2.5.

(Just noticed a wee typo on the message after stopping endpad. It says to check the log 'withe Tivoweb')


----------



## DougF

I've only been a TiVo user for six months and haven't heard the terms "soft-padding" and "hard-padding" before. 

If I'm reading correctly, this hack will add x minutes to the end of a schedule recording, but only five minutes before that scheduled recording ends and only if there is no conflict. Example:

Recording scheduled for program guide shows starting at 8:00 PM and ending at 8:30 PM. At 8:25 PM, this hack checks for any recordings starting at 8:30 PM. If there are none, the current recording is extending past 8:30 PM by the number of minutes specified at startup. If another recording is scheduled to start at 8:30 PM, no additional time is added to the 8:00 PM recording.

Is this correct? Sorry for the question, I just want to make sure I know what I'm adding first. If I'm understanding it correctly, it seems like a very cool hack.

Thanks a bunch!


----------



## pahunt

> _Originally posted by Frozen Solid _
> *I've only been a TiVo user for six months and haven't heard the terms "soft-padding" and "hard-padding" before.
> 
> If I'm reading correctly, this hack will add x minutes to the end of a schedule recording, but only five minutes before that scheduled recording ends and only if there is no conflict. Example:
> 
> Recording scheduled for program guide shows starting at 8:00 PM and ending at 8:30 PM. At 8:25 PM, this hack checks for any recordings starting at 8:30 PM. If there are none, the current recording is extending past 8:30 PM by the number of minutes specified at startup. If another recording is scheduled to start at 8:30 PM, no additional time is added to the 8:00 PM recording.
> 
> Is this correct? Sorry for the question, I just want to make sure I know what I'm adding first. If I'm understanding it correctly, it seems like a very cool hack.
> 
> Thanks a bunch! *


Yes you've got the idea. If you read the first post in this thread it gives you a more detailed explanation of what happens


----------



## DougF

Thanks, Paul. I appreciate the response.

Is anything about this specific to UK programming or hardware? I'm in the US with a Series 1 SA with 3.0. Is there any reason I can't use it?


----------



## pahunt

I don't know to be honest. AFAIK it's only be tried on UK Tivo's which means 2.5.5 software but somebody else may be able to give you the answer.


----------



## sanderton

> _Originally posted by Frozen Solid _
> *Thanks, Paul. I appreciate the response.
> 
> Is anything about this specific to UK programming or hardware? I'm in the US with a Series 1 SA with 3.0. Is there any reason I can't use it? *


It should work fine with a US TiVo, I looked through TiVoWeb for the bits of code which vary depending on 2.x or 3.x, and EndPad doesn't touch any of them. I've also left all times and dates in raw TiVo format so nothing uses UK dates or BST. But I'd appreciate it if you could report back if you do have any problems (or indeed if you don't!).


----------



## ccwf

There is possible non-optimal behavior with DirecTiVos because of the dual tuners, but standalone U.S. TiVos that aren't running ancient releases should be fine.


----------



## Bakdraft

Hi Stuart,

Could you clarify the Command line arguments s and e. You say:

*Run it with:

/var/hack/endpad.tcl s e

where s is the number of minutes padding to be added and e is the number of end minutes*

And I understand s, but I am not clear on what e means, which may mean I do not understand s as I thought.

I hope that hasn't confused you 

Thanks

Dave


----------



## pahunt

s is the number of minutes that will be added to the beginning of the recording and e is the number that will be added to the end.


----------



## Bakdraft

Ta very much Paul.

Thanks Stuart for modifying the narrative

I look forward to tomorrows hacking

Dave


----------



## srs5694

I'm running it on a Sony SAT-T60 DirecTiVo running 2.5.2 software in the US, and it works, but not optimally -- the script doesn't know about the dual tuners, and it determines whether or not to pad something based on a search for a potentially-conflicting upcoming show (I've not yet checked the logic for the start padding, but I assume it's similar). The bottom line is that it won't pad some shows that could be padded because the script doesn't realize there's an unused tuner. None of these issues would affect SA TiVos in the US.

FWIW, I hope to look over the code and modify it to work with both single-tuner and dual-tuner TiVos, but I'm busy with other matters right now. With any luck I'll have the free time in a week or so.


----------



## RichyClarke

Sanderton - still going on 2.2.5, hasn't missed a beat yet!
Happy bunnies here  
Thanks again


----------



## smokie

Wow, this looks just what I need...all too often we are missing the last few minutes of things.

Now I just need to bone up on hacking...


----------



## pahunt

> _Originally posted by RichyClarke _
> *Sanderton - still going on 2.2.5, hasn't missed a beat yet!
> Happy bunnies here
> Thanks again *


Version 2.25 wow! I'm running 1.2.5 and I thought that was good. Imagine the features that you must have


----------



## racingclub

nice one - this works great for me


----------



## tivo_boj

couple of days now with no issues and no missed endings

*GREAT PIECE OF WORK*

what about being able to stop/start and change settings directly via tivoweb? -_ Some people are never satisfied_


----------



## leejordan

I'm not sure if this is just my imagination but it does seem to have happened a couple of times..

Tivo was recording Speed Machines and was scheduled to record Pompeii immediately afterwards.

The Endpad 1.2.5 log said..

Monday 19:53:58 : Woken up
Monday 19:53:58 : Recording {Speed Machines} on C4 now
Monday 19:53:58 : Recording Scheduled End Time: 19:58
Monday 19:53:58 : Next recording is {Pompeii: The Last Day} on BBC1SE at 20:00
Monday 19:53:58 : Added 60 seconds end padding to {Speed Machines}
Monday 19:53:58 : Next end padding setting due 20:55
Monday 19:53:58 : Not time to add start padding yet
Monday 19:53:58 : Next start padding setting due 19:58
Monday 19:53:58 : Next wake up will be 19:58
Sleeping, checking every minute for kill signal......
Monday 19:58:01 : Woken up
Monday 19:58:01 : Recording {Speed Machines} on C4 now
Monday 19:58:01 : Recording Scheduled End Time: 19:59
Monday 19:58:01 : Next recording is {Pompeii: The Last Day} on BBC1SE at 20:00
Monday 19:58:01 : Next end padding setting due 20:55
Monday 19:58:01 : Can't add start padding to {Pompeii: The Last Day}
Monday 19:58:01 : Gap is only 2 seconds
Monday 19:58:01 : Next start padding setting due 20:55
Monday 19:58:01 : Next wake up will be 20:28
Sleeping, checking every minute for kill signal.....................

but it didn't actually start recording Pompeii, I had to start it manually.

Could there be a problem here?


----------



## ccwf

> _Originally posted by tivo_boj _
> *what about being able to stop/start and change settings directly via tivoweb?*


 For changing the settings, it should be a simple matter for endpad.tcl to read the padding settings each time from a file instead of just getting them from the command line. TiVo Web would then only have to overwrite the file with new settings, which would take effect for the next recording to be padded (they would not affect currently recording, already padded programmes near their ends).

Taking this a step further, a major enhancement I would like to see later is the ability to specify custom soft padding for season passes (and maybe wishlists). This would involve creating a mini season pass->soft padding lookup/database, correlating items in the to do list with their season passes, and TiVo Web code for the front end.


----------



## sanderton

> _Originally posted by leejordan _
> *I'm not sure if this is just my imagination but it does seem to have happened a couple of times..
> 
> Tivo was recording Speed Machines and was scheduled to record Pompeii immediately afterwards.
> 
> The Endpad 1.2.5 log said..
> 
> Monday 19:53:58 : Woken up
> Monday 19:53:58 : Recording {Speed Machines} on C4 now
> Monday 19:53:58 : Recording Scheduled End Time: 19:58
> 
> but it didn't actually start recording Pompeii, I had to start it manually.
> 
> Could there be a problem here? *


The odd part of the log is that it has the finish time for Speed Machines at 19.58 (the 19.59 after the padding). C4 programmes in the logs on my TiVo always start and end with the round numbers. I just checked the MFS data for Speed Machines and it was due to end at 20:00 TiVo time, not 19:58.

It looks like it's calced the end time wrong and added 60 seconds padding which there wasn't room for.

Are you *absolutely sure* you're running 1.2.5, as I this used happen on earlier versions but I rewrote the end time calculation to prevent it, and I haven't seen a non-round number end time in my logs since? (The log should announce itself as 1.2.5).


----------



## sanderton

> _Originally posted by ccwf _
> *For changing the settings, it should be a simple matter for endpad.tcl to read the padding settings each time from a file instead of just getting them from the command line. TiVo Web would then only have to overwrite the file with new settings, which would take effect for the next recording to be padded (they would not affect currently recording, already padded programmes near their ends).
> 
> Taking this a step further, a major enhancement I would like to see later is the ability to specify custom soft padding for season passes (and maybe wishlists). This would involve creating a mini season pass->soft padding lookup/database, correlating items in the to do list with their season passes, and TiVo Web code for the front end. *


I got half way through a TiVoWeb control module, but stopped when my wife threatened me with violence.

A per-SP version would be quite nice, and I can see how to do it. But with the World Cup on at the moment my programming time is strictly limited!


----------



## leejordan

> _Originally posted by sanderton _
> *Are you absolutely sure you're running 1.2.5, as I this used happen on earlier versions but I rewrote the end time calculation to prevent it, and I haven't seen a non-round number end time in my logs since? (The log should announce itself as 1.2.5). *


I'll reinstall it tonight just to make sure.

I've noticed non-round end times a few times in the log.

Lee.


----------



## RichyClarke

> Version 2.2.5 wow! I'm running 1.2.5 and I thought that was good. Imagine the features that you must have.


Haven't you heard - Auto Soft padding on a per season pass basis, padding that takes account of preferences, in-built conflict resolution (dials your mobile and asks you what you want), MP3 playback, records 2 channels at the same time, makes the Tea!!!

Tell you what - don't know how I managed without it!


----------



## leejordan

Sanderton, you were right as usual, I was using an old version. I'm definately on 1.2.5 now!

Thanks,

Lee.


----------



## sanderton

Phew.

My TiVos have been stable running 1.2.5 for four days continuously so far, so I think I can tentatively say that it is working now...


----------



## pahunt

> _Originally posted by sanderton _
> *Phew.
> 
> My TiVos have been stable running 1.2.5 for four days continuously so far, so I think I can tentatively say that it is working now... *


Since there hasn't been a significant number postings in this thread for 4 or 5 days I think most people would agree. No news is good news 

Thanks for your efforts


----------



## sanderton

Can I gauge how much interest there is in three possible additional features, so I can decide whether it's worth adding them:

1) A TiVoWeb control panel to turn padding off and on and set the amounts.
2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL
3) Forced end padding, with a following show starting to record a couple of minutes late if need be

Please post your thoughts. Ta.


----------



## pahunt

Out of the things you list the only one that I would be interested in is (3) as I can see use for that on my top 5 season passes (but then you would have to be able to do it on a season pass specific basis, I suppose).

I can see some people might want (2) but to be honest I've enough trouble prioritising season passes without having to worry about padding each one as well! Item (1) would be nice but I can certainly live without it


----------



## iankb

I'm not using it yet because, until now, I haven't found a real need to install TiVoWeb. However, if I were to install it, I would find (3) the most useful.

Ian.


----------



## fireshipjohn

Hi,

I just want to say thanks, its been doing fine service here for a week , and I dont think it needs any more...

It just does what it says on the tin 

John


----------



## Fozzie

> _Originally posted by iankb _
> *I'm not using it yet because, until now, I haven't found a real need to install TiVoWeb.*


Hmmm - but you don't need TiVoWeb installed to use Endpad. Or am I misunderstanding you?


----------



## iankb

It would help if I had network access 'though. And if I installed a network interface, I would automatically install TivoWeb. To me, they're the same thing.

Ian.


----------



## ccwf

(2) would be the most useful for me because 
it would be nice to be able to set a large amount of soft end padding only for sports programmes and
some channels are much worse about starting and ending programmes on time than others.
 (3) is often requested but less pressing for me because semisoft padding can often be used already for this purpose (but not always, and it's cumbersome).


----------



## ccwf

> _Originally posted by ccwf _
> *it would be nice to be able to set a large amount of soft end padding only for sports programmes*


 This was, in fact, the reason I wanted to be able to have soft padding add onto any hard paddingmany live sports events need to be hard padded because they often run long, but soft padding beyond that would be nice to catch some of the cases where an event runs really, really long.


----------



## Fozzie

> _Originally posted by sanderton _
> *1) A TiVoWeb control panel to turn padding off and on and set the amounts.*


This would be nice - just to give it a more user friendly front-end and the ability to adjust things remotely.



> *2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL*


Agree with pahunt - a global setting is good enough for me. Deciding priorities for SPs tears me up, let alone stressing about individual padding  I wouldn't use individual settings.



> *3) Forced end padding, with a following show starting to record a couple of minutes late if need be*


I wouldn't use this either. I use padding to ensure I get the start and ends of recordings. I don't want to start losing the beginnings again because of some random combination of prioritised, negative, positive, soft, hard, season pass, suggestion, user screwed up padding setting 

I think that you've got the functionality just right as it is.
Finally, just to add my thanks for this superb piece of code.


----------



## Fozzie

> _Originally posted by ccwf _
> *........many live sports events need to be hard padded because they often run long, but soft padding beyond that would be nice to catch some of the cases where an event runs really, really long. *


Why not just set up more hard padding for that recording in the first place (or even just a manual recording)? You obviously want to watch the end of the sports event so why take the chance with soft padding which could easily get curtailed by another scheduled recording?

(Not picking holes, just trying to understand your reasoning )


----------



## pahunt

> _Originally posted by Fozzie _
> *
> I wouldn't use this either. I use padding to ensure I get the start and ends of recordings. I don't want to start losing the beginnings again because of some random combination of prioritised, negative, positive, soft, hard, season pass, suggestion, user screwed up padding setting *


But if it was able to be done on a season pass specific basis then you could set it on only the things that are really important. For instance I would hate to find I missed the end of an episode of the next series of 24 because it wanted to record a suggestion straight afterwards.


----------



## Fozzie

> _Originally posted by pahunt _
> *For instance I would hate to find I missed the end of an episode of the next series of 24 because it wanted to record a suggestion straight afterwards. *


How would that happen? Endpad will add the max amount of end padding you've specified, cancelling any following suggestions, if needs be.


----------



## pahunt

> _Originally posted by Fozzie _
> *How would that happen? Endpad already adds the max amount of end padding you've specified, cancelling any following suggestions, if needs be. *


I didn't realise it did that! Note to self: must learn to read instructions 

I still stand by my original point though (albeit with a slightly modified argument . I would hate to miss the end of something important to record an episode of something with bad guide data that I've already watched.


----------



## ccwf

> _Originally posted by Fozzie _
> *Why not just set up more hard padding for that recording in the first place (or even just a manual recording)? You obviously want to watch the end of the sports event so why take the chance with soft padding which could easily get curtailed by another scheduled recording?
> 
> (Not picking holes, just trying to understand your reasoning ) *


 It's a good question. For really important events, I obviously do use very large amounts of padding.

However, sometimes a regular season basketball game will go into triple (or even quadruple) overtime, a non-final tennis match will go 2119 in the fifth set, and so forth. Often, these extraordinarily long events are the best and most exciting events to watch, so it would be nice if TiVo could use soft padding to catch some of these rare cases. However, because they _are_ rare, I don't want to hard pad the numerous normal sports event recordings by 2.5 hours, preempting other recordings, just for the _chance_ that one might turn out to be a game/match for the ages.


----------



## Fozzie

Looking at 3) from a slightly different angle, isn't it the same as saying I want to hard pad endings but allow follow on recordings to start late?

So, an advantage over TiVo hard padding is that the follow on recording still gets recorded. Downsides are a) the follow on recording is guaranteed to be missing the beginning (whereas the end padded recording may not have actually needed the end padding, if it was running on time) and b) TiVo will not even think about scheduling a possible alternative recording of the follow on programme because it has just recorded it (and doesn't know that it's missed the beginning) and so you are stuck with an incomplete recording.


----------



## pahunt

> _Originally posted by Fozzie _
> *Looking at 3) from a slightly different angle, isn't it the same as saying I want to hard pad endings but allow follow on recordings to start late?
> 
> So, an advantage over TiVo hard padding is that the follow on recording still gets recorded. Downsides are a) the follow on recording is guaranteed to be missing the beginning (whereas the end padded recording may not have actually needed the end padding, if it was running on time) and b) TiVo will not even think about scheduling a possible alternative recording of the follow on programme because it has just recorded it (and doesn't know that it's missed the beginning) and so you are stuck with an incomplete recording. *


I can see what you're saying but I would still prefer to miss the beginning of a "normal" program than the end of something I really wanted.


----------



## Fozzie

> _Originally posted by ccwf _
> *Often, these extraordinarily long events are the best and most exciting events to watch, so it would be nice if TiVo could use soft padding to catch some of these rare cases. However, because they are rare, I don't want to hard pad the numerous normal sports event recordings by 2.5 hours, preempting other recordings, just for the chance that one might turn out to be a game/match for the ages. *


Understood. Your TDL can't be as busy as mine because the chances of my TiVo being able fit in large amounts of padding between scheduled recordings is pretty slim  There's even less of a chance that if it did happen, it would a) be on a particular sports event and b) it was that sports event that over ran.

My only concern is for the amount of code that may be needed for these potentially rare occasions and thus introducing more possible things to go wrong. However, Stuart's not daft so I'm sure he won't turn endpad into bloatware if he can avoid it.


----------



## shaunH

> 1) A TiVoWeb control panel to turn padding off and on and set the amounts.
> 2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL
> 3) Forced end padding, with a following show starting to record a couple of minutes late if need be
> [/B]


Hi,

I've been using your excellent script for a couple of days. Cheers 

I think that all of the above improvements would be useful, but particularly 2)a the ability to vary padding according to the channel. I find that some channels are bad at keeping programmes to schedule (mainly BBC).

Cheers,

ShaunH


----------



## leejordan

I would say option 3 would be the most useful.

Lee.


----------



## ccwf

> _Originally posted by pahunt _
> *I still stand by my original point though (albeit with a slightly modified argument . I would hate to miss the end of something important to record an episode of something with bad guide data that I've already watched. *


 The situation with option (3) is actually the reverse: you might miss the beginning of an important programme so that a show you didn't care about could get end-padded. Furthermore, as Fozzie noted, TiVo would then not try to re-record future showings of that programme so that you could catch the first few minutes.


----------



## Fozzie

> _Originally posted by pahunt _
> *I can see what you're saying but I would still prefer to miss the beginning of a "normal" program than the end of something I really wanted. *


Ok, but what about if the first recording was No.1 on your SP list and the follow on recording was No.2. You've just lost the beginning of your second favourite programme (which for that particular episode, you may have actually preferred to catch all of it over SP No.1). (This is all also assuming that padding can be applied according to priorities in the SP Manager. If it was a global setting things would be even worse).

Also, you're saying that you'd prefer TiVo to record the incomplete follow on programme rather than not record it and attempt to schedule an alternative showing?

Ok, you can see where I'm coming from. I can't see myself using negative start padding because to me, allowing the beginnings of recordings to be missed is a step backwards. I could possibly see a use if negative start padding could be set on a per SP basis. e.g. take your bottom 10 SPs and set them to start early by up to 'n' minutes if possible but also allow them to start late by 'n' minutes if needs be. (This is slightly different to allowing your top 10 to force end padding - if you did that then you could end up with the situation I mentioned at top of this post). I still wouldn't use it though.


----------



## pahunt

> _Originally posted by ccwf _
> *The situation with option (3) is actually the reverse: you might miss the beginning of an important programme so that a show you didn't care about could get end-padded. Furthermore, as Fozzie noted, TiVo would then not try to re-record future showings of that programme so that you could catch the first few minutes. *


I did state earlier that I would only use this if it could be done a season pass specific basis and then you could decide if for yourself whether to take the chance of missing the beginning of a subsequent program. The only things I can seriously see me using this for would be 24 and Angel.

The reason I'm so for this is because I had a bad experience with a BBC2 episode of 24. It finished recording during the closing credits and I missed the last 30 seconds that happens after them which had a vital part of the plot in it which I was none the wiser about until people at work told me about it the next day


----------



## Fozzie

> _Originally posted by pahunt _
> *The only things I can seriously see me using this for would be 24 and Angel.
> 
> The reason I'm so for this is because I had a bad experience with a BBC2 episode of 24. It finished recording during the closing credits and I missed the last 30 seconds that happens after them which had a vital part of the plot in it which I was none the wiser about until people at work told me about it the next day  *


Oooops. So why not just set up 5 or more minutes of TiVos hard padding for those 2 SPs then you're guaranteed to get the endings? Endpad doesn't need to do a thing


----------



## Fozzie

> _Originally posted by shaunH _
> *.........but particularly 2)a the ability to vary padding according to the channel. I find that some channels are bad at keeping programmes to schedule (mainly BBC).*


That's true enough. I'd been concentrating more on a per SP basis but per channel could be more useful. That would probably also suit ccwf for his sports channels and the quadruple overtime thingy


----------



## pahunt

> _Originally posted by Fozzie _
> *Ok, but what about if the first recording was No.1 on your SP list and the follow on recording was No.2. You've just lost the beginning of your second favourite programme (which for that particular episode, you may have actually preferred to catch all of it over SP No.1). (This is all also assuming that padding can be applied according to priorities in the SP Manager. If it was a global setting things would be even worse).
> 
> Also, you're saying that you'd prefer TiVo to record the incomplete follow on programme rather than not record it and attempt to schedule an alternative showing?
> 
> Ok, you can see where I'm coming from. I can't see myself using negative start padding because to me, allowing the beginnings of recordings to be missed is a step backwards. I could possibly see a use if negative start padding could be set on a per SP basis. e.g. take your bottom 10 SPs and set them to start early by up to 'n' minutes if possible but also allow them to start late by 'n' minutes if needs be. (This is slightly different to allowing your top 10 to force end padding - if you did that then you could end up with the situation I mentioned at top of this post). I still wouldn't use it though. *


I get the feeling we're never going to agree on this 

I think that the kind of things that you have setup as season passes and wishlists affect how you might look at negative padding. Most of things I watch tend to be on channels such as Discovery, BBC3, UK Gold, Paramount (i.e. channels where guide data is sparse and the 28 day rule doesn't come into play that much). This means that I'm usually not that bothered if I miss the beginning of something as it is often repeated within a fairly short timescale.

If you have lots of new series with good guide data as season passes, negative padding becomes less appealing.


----------



## pahunt

> _Originally posted by Fozzie _
> *Oooops. So why not just set up 5 or more minutes of TiVos hard padding for those 2 SPs then you're guaranteed to get the endings? Endpad doesn't need to do a thing  *


Yes but with negative padding I would get most of the subsequent program. Hard padding would give me none of it.


----------



## Fozzie

> _Originally posted by pahunt _
> *Yes but with negative padding I would get most of the subsequent program. Hard padding would give me none of it. *


But didn't you also say in the post before:


> _Originally posted by pahunt _
> *This means that I'm usually not that bothered if I miss the beginning of something as it is often repeated within a fairly short timescale. *


Seems like an ideal scenario for hard padding, where TiVo will automatically reschedule one of those repeats instead of using negative start padding where that won't happen and you'll end up with a partial recording in Now Playing. I know which one I'd go for


----------



## ccwf

> _Originally posted by Fozzie _
> *My only concern is for the amount of code that may be needed for these potentially rare occasions and thus introducing more possible things to go wrong. However, Stuart's not daft so I'm sure he won't turn endpad into bloatware if he can avoid it. *


 The code for making this change was posted a long time ago near the beginning of this thread. However, it's not clear how many people want this behavior. Also, adding new features is less important than making sure the code is stable; but since the code does seem to be stable now, I guess the discussion can be reopened.

My opinion is that this should wait until after a web interface is introduced for managing soft padding for individual season passes and channels. Then, this option could be added at the same time to allow soft padding to add to hard padding for particular season passes instead of the default behavior.


----------



## srs5694

> _Originally posted by sanderton _
> *Can I gauge how much interest there is in three possible additional features, so I can decide whether it's worth adding them:
> 
> 1) A TiVoWeb control panel to turn padding off and on and set the amounts.
> 2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL
> 3) Forced end padding, with a following show starting to record a couple of minutes late if need be*


#2 would be of most interest to me. (Or even something to do the job without TiVoWeb -- say, via a configuration file.) The reason is that some channels are far worse than others at starting/ending on time. In fact, most of the shows I record don't really need the padding, so why use it? It just takes up disk space. As it is, it's better to soft-pad everything just for those that need it than to soft-pad nothing.


----------



## occitan

> _Originally posted by sanderton _
> *Can I gauge how much interest there is in three possible additional features, so I can decide whether it's worth adding them:
> *


Many many many thanks, I installed 1.2.5 yesterday evening and it's already saved a couple of late programs !



> *
> 1) A TiVoWeb control panel to turn padding off and on and set the amounts.
> *


It would be useful to look at the config and possibly modify the settings from TiVoWeb, but I hope you don't make TiVoWeb a requirement for it to run.

This utility is still very interesting for those able to set up a bash prompt over serial, but will rarely use it to connect to the TiVo.



> *
> 2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL
> *


Not amazingly interesting, but could be a nice extra for some.



> *
> 3) Forced end padding, with a following show starting to record a couple of minutes late if need be
> 
> Please post your thoughts. Ta. *


Negative padding on some programs would be a big boon to me, but I guess it must be optional, as there are some who arn't interested.

However, I'd like to suggest a solution that doesn't require TiVoWeb, but relies on existing recording options that can be set through the standard TiVo UI.

How about using the 'Deletion/Expiry date' information for a recording to determine what to do ? Normally, programs that have the default settings, and record one after the other on the same day will have the same expiry date. In this case no -ve padding should be applied.

For programs that one cares more about seeing, one often sets the expiry date later in the week, or for the unmissable programs, to manually delete.

Therefore, if a program B follows program A, and B has an earlier deletion date, then following this scheme B could be negative padded to allow a little more of A to be recorded.

It may be necessary to add another parameter to endpad to set the maximum negative padding to apply, which may be less that the standard end padding.

I guess an adjustment would need to be made to the calculation for a program that spans midnight.

I think using deletion dates would be better than the main alternative which would be using season pass order to determine -ve padding. As every SP recording will always be higher or lower than any other SP recording, -ve padding would happen more often than one might want it to. It also poses a problem on what to do for non SP recordings...

Thanks again for a great addition to the TiVo. I think we should petition TiVo to add it in to a special UK 2.6 s/w release !

Cheers
Guy


----------



## Adlopa

I cast a vote for 3) Forced end padding. I'm firmly in the camp that I want *all* of a high priority Season Pass rather than a complete episode of a less important follow-on programme that I can manually reschedule from a repeat, if need be. 

Forced end padding would be particularly useful for when Sky dumps a half-finished series in a late night slot at random times each week -- something, thanks to usually-outdated EPG data, that a few minutes of soft padding wouldn't catch...

(Soft-padding rocks, btw -- nice one Stuart)


----------



## pwarnes

Sanderton,

3) gets my vote, even if it applies regardless of priorities etc. I hate losing ends, and would rather lose the beginning than the whole program.


----------



## tivo_boj

> _Originally posted by ccwf _
> *
> 
> My opinion is that this should wait until after a web interface is introduced for managing soft padding for individual season passes and channels. Then, this option could be added at the same time to allow soft padding to add to hard padding for particular season passes instead of the default behavior. *


I agree with CCWF. Now the software seems stable, make it user friendly by allowing it to be started,stopped and alterered via tivoweb. Then add the changes to allow to chose either which channels to add padding (BBC of course), then for individual season passes.

I would rather have the current version which is stable rather than a more complex one which may cause crashes or missed programmes

It might be worth to have the simple version as it stand today (named endpad) and a more complex one (endpad plus) so people can choose.


----------



## tdenson

Sorry, I'm late into this thread, but this is brilliant news. The discarding of overlapping programs is my one and only gripe with Tivo. Can anyone who has actually used this mod tell me if there is any downside to it ?

Tony


----------



## sanderton

> _Originally posted by tivo_boj _
> *
> It might be worth to have the simple version as it stand today (named endpad) and a more complex one (endpad plus) so people can choose. *


Yes, that's my thinking at the moment.


----------



## jamieo

Great program sanderton, installed just now and has added 5 mins to the beginning of the first program that is recording since. :up:

_1) A TiVoWeb control panel to turn padding off and on and set the amounts._

Would be nice but is not that important as the code is right now.

_2) A TiVoWeb control panel to allow padding settings to be varied either_ a) per channel or b) per SP/WL

This would be great! I can already see that 10 mins padding on every 30 min program will eat up quite a lot of disc space so this is essential imho. Both a) and b) should be implemented. 

_3) Forced end padding, with a following show starting to record a couple of minutes late if need be_

This would also be a great and much needed feature. Of course, it should work along side 2) to be of any real use. 

Thanks,

Jamie


----------



## Fozzie

> _Originally posted by Adlopa _
> *I cast a vote for 3) Forced end padding. I'm firmly in the camp that I want *all* of a high priority Season Pass rather than a complete episode of a less important follow-on programme that I can manually reschedule from a repeat, if need be.*


And this is exactly what TiVo hard padding currently does. It will guarantee that the end padding is applied and will attempt to reschedule the follow on programme automatically for you.

I must be missing something here. What extra does forcing endpad to apply padding give you? All I can see is that it will force TiVo to record a follow on programme with a missing beginning and not automatically try and reschedule a repeat recording for you. Help me out here 



> _Originally posted by Adlopa _
> *Forced end padding would be particularly useful for when Sky dumps a half-finished series in a late night slot at random times each week -- something, thanks to usually-outdated EPG data, that a few minutes of soft padding wouldn't catch...*


How would forced end padding make a difference compared to soft end padding? Sorry, I don't see how the type of padding would change anything. The duration of padding might but how would the type?


----------



## ccwf

> _Originally posted by srs5694 _
> *#2 would be of most interest to me. (Or even something to do the job without TiVoWeb -- say, via a configuration file.)*


 Well, ultimately, that's how it will probably be implementedwith TiVo Web reading/writing a configuration file that endpad.tcl then reads.


----------



## Adlopa

> _Originally posted by Fozzie _
> *And this is exactly what TiVo hard padding currently does. It will guarantee that the end padding is applied and will attempt to reschedule the follow on programme automatically for you.
> 
> I must be missing something here. What extra does forcing endpad to apply padding give you? All I can see is that it will force TiVo to record a follow on programme with a missing beginning and not automatically try and reschedule a repeat recording for you. Help me out here
> *


Oh, hang on, I think I misread Stuart's info. I thought that soft padding negated any hard padding when in fact that seems not to be the case. If hard padding still works, then this isn't a problem. 


> _Originally posted by Fozzie _
> *How would forced end padding make a difference compared to soft end padding? Sorry, I don't see how the type of padding would change anything. The duration of padding might but how would the type? *


Again, my point is void if end padding still works with SoftPad, which it seems to when I thought it didn't, thus it isn't and never was. Or something.


----------



## Fozzie

> _Originally posted by Adlopa _
> *Oh, hang on, I think I misread Stuart's info. I thought that soft padding negated any hard padding when in fact that seems not to be the case. If hard padding still works, then this isn't a problem.*


Yeah, hard padding still works. If Endpad is set to a larger value than the explicit hard padding, it will attempt to increase the overall amount of amount of padding up to the Endpad setting. (And if you get that, you'll get anything!).

e.g. An SP has 3 minutes of TiVo hard padding configured and Endpad is set to add 5 minutes of soft padding. When it get nears to the end of the recording, Endpad will attempt to add an extra 2 minutes to the recording, making the total amount of padding 5 minutes (3 mins hard & 2 mins soft).


----------



## manolan

> _Originally posted by ccwf _
> *For changing the settings, it should be a simple matter for endpad.tcl to read the padding settings each time from a file instead of just getting them from the command line. TiVo Web would then only have to overwrite the file with new settings, which would take effect for the next recording to be padded (they would not affect currently recording, already padded programmes near their ends).
> *


I've never played with the internals of the TiVo, but in a normal UNIX daemon, you would generally try to avoid reading the config settings each time round because of the file management overhead. More usual would be to send a signal to the daemon that wakes it up and causes it to refresh the settings before resuming the normal cycle.


----------



## ccwf

> _Originally posted by manolan _
> *I've never played with the internals of the TiVo, but in a normal UNIX daemon, you would generally try to avoid reading the config settings each time round because of the file management overhead. More usual would be to send a signal to the daemon that wakes it up and causes it to refresh the settings before resuming the normal cycle. *


 This is true; but 
I don't know if tivosh has TCL extensions for POSIX signal handling, and
we're only talking about reading a file a few times an hour anyways.


----------



## tdenson

Just started running endpad. All looks OK, can see the process running and the log file seems to show that it's going to do something on the next recording. However, I notice that my Tivo linux shell seems to think that the time is an hour less than it is. I am very reluctant to change it to the real time in case that screws up my Tivo recordings which are all working at the right time. What's going on here - it's 09:17 at the moment and if I type date I get 08:17.

Tony


----------



## ccwf

TiVo works internally in UTC, not BST.


----------



## tdenson

> _Originally posted by ccwf _
> *TiVo works internally in UTC, not BST. *


OK, thanks, just never noticed before.


----------



## Bakdraft

Thanks Stuart,

As everyone has said so far Brilliant. I have a number of friends who have unhacked Tivo's who are now considering Airnet, and Turbonet cards (does anyone have spares??) just on the strength of your patch.

I, like most love it. :up: :up: :up: 

I was wondering if you know exactly how many people are running endpad now? Do you keep a count?

Also is your endpad the only version or have some US forum members come up with similar ideas?

Dave


----------



## srs5694

The endpad program works fine as-is on US TiVos. At least, it works on my Sony SAT-T60 DirecTiVo. (As I've said before in this thread, it doesn't know about the dual tuners, so it doesn't pad everything it could, but it does run and it does pad shows where no others are scheduled around the padded one.) I don't see why it wouldn't run on US SA TiVos.

I expect you'd see an uptick in comments from US users if this thread were moved to the Underground forum (where, IMHO, it belongs). The program was announced on various forums other than this one, but discussion in those threads died out very quickly, presumably because the original announcements all said to come here for further discussions.


----------



## sanderton

137 people have downloaded the latest version, so something around that I guess! there is no separate US version, although someone with dual tuners said he might try to adapt the code for that machine.

Should this be in the Underground? Well, maybe, but I tend to think of the UK forum as being a thing in its own right, and rarely venture to those places. They keep talking about Series 2 and OS 4 and it gets depressing. 

Call me a Little Englander, but I think of myself as be ing a member of the UK forum, and the Underground etc as being quite separate.

However if Gary or Ozsat think it should be moved, then that's their call.


----------



## tdenson

I've got endpad working successfully but I'm a bit confused as to why I can't see the process running when I do ps. It's definitely running because if I try and run it again it says it's already running. I can also see other user processes I have started (e.g. yac).


----------



## Popeye

Why does the TIVO not use PDC (Picture Delivery Control) that my video recorder has (ooh, wash my mouth out)?


----------



## Fozzie

> _Originally posted by Popeye _
> *Why does the TIVO not use PDC (Picture Delivery Control) that my video recorder has (ooh, wash my mouth out)? *


Hmmm, not heard of that one. I've heard of PDC (Programme Delivery Control) but not many channels support it.


----------



## bobnick

> _Originally posted by srs5694 _
> *I expect you'd see an uptick in comments from US users if this thread were moved to the Underground forum *


This is a UK forum and we like our area of the board very much... we don't want have to trek all the way over to some shabby area full of Americans to discuss our software thank you very much! You're welcome to visit any time you like, but moving it to an American area would mean that lots of Brits would then miss it. Endpad adds essential features to Tivo's in the UK - it's not really needed in America due to the fact that most shows start on time!

Mind you, the american areas are graced with Tivo employees - they don't come round here any more.

Popeye: PDC doesn't work well, it's not sent on DTT or DSAT, and Tivo is completely pants at anything VBI related (which is where teletext and subtitles are broadcast)


----------



## srs5694

> _Originally posted by bobnick _
> *This is a UK forum and we like our area of the board very much...*


Fine, and I'm certainly not trying to take it away from you; my point is just that the software under discussion is in no way UK-specific, except for the fact that the original author is from the UK and uses it on a UK machine. The Underground forum, although perhaps dominated by Americans, is not country-specific, and is dedicated to discussions of hacks like this one.



> *Endpad adds essential features to Tivo's in the UK - it's not really needed in America due to the fact that most shows start on time!*


Many Americans would disagree with this statement -- quite strongly. That said, having no direct experience with British TV, I can't make a direct comparison of UK vs. US scheduling practices. It's quite possible that the situation is worse in the UK than in the US, but that doesn't mean that it's good in the US or that the endpad features are "not really needed" here. Many US networks _do not_ start or end their shows at the scheduled times, and gripes about the lack of soft padding do pop up in the general forums all the time from users on both sides of the pond.

This will be my last comment on this issue; I certainly don't want to start a trans-Atlantic debate over it. I've stated my opinion, I stand by it, but I'm not going to press the issue in any way. I'll continue popping into the UK forum to check the progress of this hack, even though it's the only thread I read here.


----------



## sanderton

> _Originally posted by tdenson _
> *I've got endpad working successfully but I'm a bit confused as to why I can't see the process running when I do ps. It's definitely running because if I try and run it again it says it's already running. I can also see other user processes I have started (e.g. yac). *


It showes as "tivosh" under ps, I think. Look in endpad.pid to see the process id.


----------



## kitschcamp

'ps ax' shows it quite clearly complete with run conditions.


----------



## Fozzie

Simple solution to where this thread should sit:

UK Underground

Why not - there's a few issues that are UK specific - TiVo Web Genres, TCS Weather Module as well as some others. This stuff gets lost in the noise in the main Underground Forum, for most people here.


----------



## JeFurry

> _Originally posted by sanderton _
> *1) A TiVoWeb control panel to turn padding off and on and set the amounts.*


Would be nice, certainly, but far from vital. However...


> *2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL*


This would be _marvellous_. BBC tend to run off times, whereas Sky One almost never run late, and the movie channels are spot-on. Per-channel padding would be a big bonus.


> *3) Forced end padding, with a following show starting to record a couple of minutes late if need be*


As always, more options are welcome. This I'd rate as a low-ish priority for my personal needs, but I imagine there are plenty of people who'd welcome it.
EDIT: On reflection, and examining my recording history, I realise there are a lot more programmes that _could_ have been recorded, so I'll up this slightly in my personal priorities to "Very nice, would like it, but option 2 still wins my highest vote". 

And I neglected to add... thank you, Stuart and others, for the _sterling_ work you've done on this, one of the longest sought-after additions to TiVo. Well done!


----------



## iankb

I think that my main reason for (3) being a higher priority is that everything else can be handled manually, and I am already working that way by adjusting my schedules every morning.

What the UK version of the software can't do (and I believe that the US software can) is _negative padding_. Without resorting to setting-up manual recordings, I cannot start a program late. And I find it more important to know whether the butler did it than to see the original murder which I will soon find out more than enough about.

Ian.


----------



## sanderton

> _Originally posted by iankb _
> *I think that my main reason for (3) being a higher priority is that everything else can be handled manually, and I am already working that way by adjusting my schedules every morning.
> 
> What the UK version of the software can't do (and I believe that the US software can) is negative padding. Without resorting to setting-up manual recordings, I cannot start a program late. And I find it more important to know whether the butler did it than to see the original murder which I will soon find out more than enough about.
> 
> Ian. *


It would be easy to knock up a TiVoWeb module to add negative padding to individual To Do List items.


----------



## iankb

That's a nice idea, but since I don't really want to regularly program my Tivo via Tivoweb (because I prefer the more convenient method of using my TV), it wouldn't be the best solution for me.

Ian.


----------



## sanderton

> _Originally posted by iankb _
> *That's a nice idea, but since I don't really want to regularly program my Tivo via Tivoweb (because I prefer the more convenient method of using my TV), it wouldn't be the best solution for me.
> 
> Ian. *


As you know, the 2.5.5 UI won't take negative numbers, so it's hacking or nothing on that score!


----------



## iankb

I suppose I was thinking that, as an option, endpad could automatically add negative start padding for me to the next program as an alternative to removing the end padding of the previous program.

Not quite sure how it works at the moment, since I got bored re-reading this ever-growing thread. 

Ian.


----------



## sanderton

That's one of the options under consideration.


----------



## iankb

I'm sure that's how my VCR works, but I use it so rarely, I would have to get the manual out. In practice, it would only work well if you could set a different option for each channel.

Ian.


----------



## Fozzie

Stuart - could you just outline your thoughts on how forced end padding would work because it could work in a number of quite different ways? e.g.

1. A global setting where any follow on recordings are started late.

2. An SP or channel based setting where only those recordings are 'allowed' to force their end padding.

3. An SP or channel based setting that allows those recordings to have their start times delayed.

4. If the priority of the SP was to be taken into account, this could be done in a couple of different ways:

a. A higher priority programme always causes a lower priority programme to start late.

b. Any programme that is allowed to force it's end padding cannot have its' own start time delayed.

I expect some of the above are either impossible or too complex to achieve anyway. I'm interested in your thoughts.


----------



## sanderton

I was going to do 1), as it's relatively easy.  Then 2) if/when SP specific settings are possible.

However don't expect either very soon, as children's birthday parties are eating in to coding time at the moment.


----------



## srs5694

> _Originally posted by iankb _
> *I think that my main reason for (3) being a higher priority is that everything else can be handled manually, and I am already working that way by adjusting my schedules every morning.*


How would you suggest handling option 2 (adjusting pad values on a per-channel or per-show basis) manually? The only way I can think of would be to constantly monitor the TiVo, stopping and re-starting endpad for individual shows. If that's the solution, it'd be simpler to just abandon endpad and do the job manually from the TiVo user interface.



> *What the UK version of the software can't do (and I believe that the US software can) is negative padding.*


I don't believe the US software can do this. Certainly I've not seen it on any version I've used (through 3.something on my SA TiVo before I sold it). It's conceivable it's a new feature in the 4.0 software, but I've not seen that version, and I don't recall hearing about this feature in it.


----------



## sanderton

> _Originally posted by srs5694 _
> *How would you suggest handling option 2 (adjusting pad values on a per-channel or per-show basis) manually? The only way I can think of would be to constantly monitor the TiVo, stopping and re-starting endpad for individual shows. If that's the solution, it'd be simpler to just abandon endpad and do the job manually from the TiVo user interface.
> *


There would be a default as at present and a config file containing a list of season passes or channels with each one's individual settings. If no setting is in the file then use the default. Settings file created either manually or via a TiVioWeb module.



> _Originally posted by srs5694 _
> *
> I don't believe the US software can do this. Certainly I've not seen it on any version I've used (through 3.something on my SA TiVo before I sold it). It's conceivable it's a new feature in the 4.0 software, but I've not seen that version, and I don't recall hearing about this feature in it. *


There is a simple hack to add "start late" amounts to the padding menu by altering a string value in the database, have a search in the Underground. Unfortunately it doesn't work on UK TiVos.


----------



## ccwf

> _Originally posted by sanderton _
> *If no setting is in the file then use the default. Settings file created either manually or via a TiVioWeb module.*


 Of course, the options are not mutually incompatible. Would make sense to create the file manually at first but in a simple format so that it can later be managed by a TiVo Web module.


----------



## sanderton

A SP based one would be harder to do manually as the obvious way to do the file would be to create it based on fsids of the season passes - not frantically human readable/createable though!


----------



## ccwf

It has to be fsid-based, but people could add in a human-readable name as a comment. It is true people would need to get the series IDs in the first place.


----------



## Fozzie

> _Originally posted by sanderton _
> *I was going to do 1), as it's relatively easy.  Then 2) if/when SP specific settings are possible.*


Presumeably with 2), those SPs that are allowed to force end padding, would cause a start delay to any follow on recordings (including SPs that themselves are allowed to force end padding).

So with option 1) (global setting), all follow on recordings would be started late and with option 2) all recordings following an 'allow programme to force end padding' would be started late.

Nope, I don't see the benefit of 1) at all  I can see a possible benefit of 2) (on a per SP basis not channel basis), if the number of SPs that were allowed to force end padding was very small.


----------



## sanderton

Just depends on how much getting the bong just before the denouement bothers you! 

Forced end padding would also cure something I've done more than once - recorded back to back shows on BBC 2 where the end of one is on the start of the next thanks to late running, but watched them in the "wrong" order and deleted the show with ethe end of the previous one before watching it! With forced end padding the end would be in the correct show.


----------



## iankb

> _Originally posted by srs5694 _
> *How would you suggest handling option 2 (adjusting pad values on a per-channel or per-show basis) manually?*


That's easy. Every morning I make sure that the correct programs are going to be recorded in my TDL and manually adjust any padding on each recording if I would otherwise have an overlap. It's incredibly easy, apart from the inability to enter negative padding which stops me entering padding on consecutive programs.

Maybe you are getting confused because, once you start running endpad, you are losing some of that manual control.

Ian.


----------



## sanderton

I think its more the idea of manually looking at the TDL every morning that is confusing him. It certainly confuses me.  

For me, it's the fire-and-forget nature of TiVo which makes it so compelling over Sky+ etc.

(You don't lose any manual control with Endpad - if you set padding manually it will not remove it)


----------



## iankb

> _Originally posted by sanderton _
> *For me, it's the fire-and-forget nature of TiVo which makes it so compelling over Sky+ etc.*


It's a nice idea, but I would miss new series, one-off programs, and anything that clashed. By checking each morning, I also get the chance to reconcile clashes more neatly by rescheduling recordings selectively, based upon future showings. The TiVo will never managed to get the priorities right in all cases, however careful you are to set it up.

Maybe it's because I don't fill up my TiVo with disposable programs such as Friends and other sitcoms, where it doesn't really matter whether you watch it or not, or in which order you watch them. There would be nothing worse than missing one episode out of a series such as '24', because of incorrectly-handled clashes.

Ian.


----------



## sanderton

Every Sunday morning I sit down with the TV guide from the paper and TiVoWeb to schedule new series and one offs. I run the Conflict Resolver module which highlights any unresolved clashes in the week ahead and use the second TiVo to sort them out (or do it manually if needed). I then run my CBEEBIES deduper to stop us getting 25 episodes of Clifford the Big Red Dog, and manually deselect the four weekly duplicates of The Rugby Club which I've given up reporting on the errors thread after two years of being wrong every week.

Takes 15 mins tops once a week and I can then let TiVo get on with it until the following Sunday.


----------



## iankb

So you do it once a week, and I do it daily. Not that different. 

It takes me longer because, with only one TiVo, I find it much harder to manage clashes. A lot of attempts at rescheduling based upon other broadcasts and much breast-beating as I have to discard recordings.  

I definitely need that extra Sky+ box with dual-recording to handle clashes.

Ian.


----------



## b166er

Be nice to me. New forum user but not new tivo-er.

Sanderton, is it possible to submit your modification (script?) to Tivo UK and they distribute it as a software patch? I don't know if this is a ridiculous suggestion or not.


----------



## iankb

Excuse my ignorance, but do TiVo use TCL for routine processing, or do they use compiled languages?

Ian.


----------



## b166er

It would be cool if they did. Perhaps the popular scripts could be submitted to Tivo UK, and if approved, downloaded as patches that could be started via a backdoor code perhaps.


----------



## iankb

Now you are showing your ignorance.   

TiVo UK was closed down quite a while ago. It is all run from the US nowadays. Customer Services in the UK are run by Sky on TiVo's behalf.

Ian.


----------



## b166er

*Oops*


----------



## sanderton

> _Originally posted by iankb _
> *Excuse my ignorance, but do TiVo use TCL for routine processing, or do they use compiled languages?
> 
> Ian. *


Bit of both I think. The heavy duty stuff is compiled into the TCL interpreter as built-in commands, and TCL scripts handle some of the things you need to tweak more easily and quickly than recompiling allows. "myworld", the main TiVo command process, is in fact a TCL interpreter,


----------



## Fozzie

> _Originally posted by sanderton _
> *Forced end padding would also cure something I've done more than once - recorded back to back shows on BBC 2 where the end of one is on the start of the next thanks to late running, but watched them in the "wrong" order and deleted the show with ethe end of the previous one before watching it! With forced end padding the end would be in the correct show. *


Understood & it would be very useful in that situation to overcome poor watching discipline  (of course I've never done that!) But would you really want to force all back to back recordings to have the second recording start late for the pretty rare (I would have thought) situation that a)there is a back to back recording in the first place & b) the recordings are on the same channel & c)the first programme really is running late and actually needs the padding in the first place?

It just seems to me that the negatives far outweigh the positives. All hail 1.2.5 - hurrah


----------



## pmk

Can this hack be installed with just a serial cable and the BASH prompt with no need to open the TiVo? No other hacks or extras have been installed. TIA.


----------



## b166er

As I understand it. You need to put your hard disk in a PC to run some software that allows you to be able to get a bash prompt via serial cable. Then you put the hard disk back in, connect your serial cable, and then you can get a bash prompt and can transfer the script and run it. I've not done it myself yet. I don't have a PC running anything older than win2k and I'm scared of this qunlock thing that can render a disk almost useless.

edit: Additional question:

Can you run TiVoweb over the serial cable or does it need a LAN card?


----------



## pahunt

I've got both tivoweb and end pad running over a serial cable to a Win XP machine and it works fine. In theory there isn't anything you can do over a proper network connection that you can't do by using a serial cable, it's just that bit slower 

The best places to start looking are the Black Widow guide and this thread

edit: now link points to the correct thread


----------



## ccwf

> _Originally posted by pahunt _
> *In theory there isn't anything you can do over a proper network connection that you can't do by using a serial cable, it's just that bit slower *


 Broadcasting and multicasting? I have, in fact, given some thought on how to integrate endpad.tcl into a collaborative scheduling algorithm whereby each TiVo would try to farm out conflicts to other TiVos using multicasting or broadcasting in part for communication. (But since multicasting and broadcasting are unreliable and most people don't have giant numbers of TiVos, I think both are not the right choice for this purpose other than an auto-discovery component, which HMO already does.)


----------



## Dibblah

> _Originally posted by pmk _
> *Can this hack be installed with just a serial cable and the BASH prompt with no need to open the TiVo? No other hacks or extras have been installed. TIA. *


If you have a non-upgraded machine, you can switch to the alternate boot partition through the serial port using the PROM configuration menus. The alternate partition still contains the 1.3 software, which recognises the shondss, handcraft and runmyworld boot params. It should be similar to the following:

"root=/dev/hda7 shondss=true handcraft=true runmyworld=false"

You then need to mount the current partition, futz with it to install endpad, unmount it, set the bootparms back to normal and reboot.

Overall, it's easier just taking the case off and mounting the drive on a PC 

Also, I'm not sure if the PROM presents any config interface on 2.04 (Current version)...

Cheers,

Allan.


----------



## sanderton

I was going down the "background intercommunication for scheduling conflicts over multiple TiVos" route (easy enough to have scripts listening on a port for conflict info), until I found that it actually required more human interaction than I expected. You could go so far fully automatically, but not far enough to just let them get on with it, so the TiVoWeb module I built was the best compromise for me between manual decisons and machine automation.

I know that are were folks with unsubscribed TiVos who would like to use the second TiVo as a conflict recording slave machine, but my second Tivo is fully working in its own right. 

The idea of having several slave TiVos recording conflicts before copying their programmes into the Now Playing of the master was quite intriguing though. One for cyril


----------



## sanderton

> _Originally posted by b166er _
> *As I understand it. You need to put your hard disk in a PC to run some software that allows you to be able to get a bash prompt via serial cable. Then you put the hard disk back in, connect your serial cable, and then you can get a bash prompt and can transfer the script and run it. I've not done it myself yet. I don't have a PC running anything older than win2k and I'm scared of this qunlock thing that can render a disk almost useless.
> 
> edit: Additional question:
> 
> Can you run TiVoweb over the serial cable or does it need a LAN card? *


Don't worry about the QUULOCK thing - it's only a problem for UPGRADED disks (an even then only one model), there is no issue whatsoever for the factory fit ones.


----------



## b166er

> _Originally posted by pahunt _
> *I've got both tivoweb and end pad running over a serial cable to a Win XP machine and it works fine. In theory there isn't anything you can do over a proper network connection that you can't do by using a serial cable, it's just that bit slower
> 
> The best places to start looking are the Black Widow guide and this thread
> 
> *


Oh my. I read that black widow guide and the thread. It seems to have a tremendous amount of things can go wrong:

- If you have XP or 2K you'll have problems to deal with to get that working.

- If you want to keep your daily call via telephone you'll have to deal with complications to keep that working.

- You might damage your Tivo hard disk if qunlock is run, but if it isn't you can't access your disk, but if it is, it can't be run again etc etc. I'm terrified to put my tivo disk anywhere near my computer now.

- the timezone may be 7 hours out for some odd reason.

Add to that the immense number of steps involved and it's made the choice clear for me. My tivo will remain unhacked. It's a shame. Tivoweb sounds intriguing.

How about this for an idea. Someone setup a machine that will respond to incoming calls. Those of us who want to hack our machines, change our daily call number to the number of that machine. We select "make daily call now" and it dials into that computer but instead of getting a daily call, it gets the changes made that are necessary, but they're made automatically. Not only will the machine be modified so that it accepts incoming PPP calls, it can also receive the popular scripts direct to their correct home. Then we change our daily call number back to normal. Then the only issue we need to deal with is setting up the PC. Does that make sense? Is it possible?


----------



## b166er

> _Originally posted by sanderton _
> *Don't worry about the QUULOCK thing - it's only a problem for UPGRADED disks (an even then only one model), there is no issue whatsoever for the factory fit ones. *


How about pre-installed upgrade drives? I'm thinking of buying one of those 120GB pre-installed drives.


----------



## ccwf

> _Originally posted by sanderton _
> *I was going down the "background intercommunication for scheduling conflicts over multiple TiVos" route (easy enough to have scripts listening on a port for conflict info), until I found that it actually required more human interaction than I expected. You could go so far fully automatically, but not far enough to just let them get on with it, so the TiVoWeb module I built was the best compromise for me between manual decisons and machine automation.*


 It's never going to be possible to make the process fully automatic. That's one of the reasons we have the Recording History after all. But what are some of the problems you forsee with writing an automatic collaborative scheduler?


----------



## sanderton

The hit rate for being able to just say "doing nothing, record that" was WAY lower than I thought, plus many of the conflicts were generated by high-frequency low-importnace shows that i didn't really care about.

It's not that it didn't work technically, it just didn't solve my problem.


----------



## iankb

> _Originally posted by ccwf _
> *... since multicasting and broadcasting are unreliable*


Not on a local area network with a reasonable processor. Just read them in an above-normal priority thread and place them into FIFO buffers for processing in another thread. I can happily build up buffers of more than a hundred thousand multicast and unicast messages in a Windows service and never lose one.

Is the problem the poor TiVo processor, the Linux version, the network software, or the fact that it would need to be written in compiled code?

Ian.


----------



## ccwf

Ah, but what I had in mind would also be able to preempt low priority season passes and wishlists on other TiVos. Farming out conflicts wouldn't be limited to when other TiVos were doing nothing.


----------



## sanderton

> _Originally posted by b166er _
> *Oh my. I read that black widow guide and the thread. It seems to have a tremendous amount of things can go wrong
> ..
> I'm terrified to put my tivo disk anywhere near my computer now.
> ...
> My tivo will remain unhacked. It's a shame. Tivoweb sounds intriguing.
> *


Oh dear. 

Reading the more technical threads can make you feel like that if you haven't actually done it before. But don't worry. First off, the chances of something going wrong is very low. Secondly the chances of you doing anything that can't be fixed with the help of the people on this forum are pretty much nil.

If you really can't face it, perhaps there is someone who lives near you who could help. But whatever, it really isn't that bad or dangerous!


----------



## iankb

One answer to collaborative scheduling is to unicast the TiVo scheduling events to a PC, process them with PC software, and use TiVoweb to implement the changes. You then get a more powerful processor to receive the unicasts and process the conflicts, and it would not be necessary for the TiVo's to catch unicasts or multicasts with the possibility of them being missed.

Ian.


----------



## Dibblah

> _Originally posted by iankb _
> *One answer to collaborative scheduling is to unicast the TiVo scheduling events to a PC, process them with PC software, and use TiVoweb to implement the changes. You then get a more powerful processor to receive the unicasts and process the conflicts, and it would not be necessary for the TiVo's to catch unicasts or multicasts with the possibility of them being missed.
> 
> Ian. *


Since multicast is not included in the default kernel, you'd also need to roll your own module.

Cheers,

Allan.


----------



## b166er

Re-posting the overlooked question I asked.

How about this for an idea. Someone setup a PC somewhere that will respond to incoming calls. Those of us who want to hack our Tivos without taking the hard drive out and throwing it in a PC, change our daily call number to the number of the aforementioned PC.

We select "make daily call now" and it dials into that remote computer but instead of getting a daily call, the PC will have been setup to emulate the Tivo centre but not give listings, instead it gives some updates. 

Not only will the Tivo then be modified so that it accepts incoming PPP calls, it can also have received the popular scripts direct to their correct place.

Then we change our daily call number back to normal. Then the only issue we need to deal with is setting up the PC. Does that make sense? Is it possible?


----------



## iankb

I doubt that it would be possible to emulate the TiVo center since that is not a documented interface and involves strong security in the validation of the account.

AFAIK, software updates are normally implemented by downloading a completely new version into an alternate boot partition, and the rebooting into that partition. We would not have legal access to all of the software that would need to be downloaded.

Even if it could be done, the whole process would almost certainly be frowned upon by TiVo who would see it as a way of implementing service theft.

Ian.


----------



## sanderton

Sledgehammer to crack a nut, that one, I'm afraid.


----------



## iankb

> _Originally posted by Dibblah _
> *Since multicast is not included in the default kernel, you'd also need to roll your own module.*


Ah!, there you have me. What it is to be totally-ignorant of the ins and outs of Linux, and have to be restricted to professional operating systems. 

Having said that, you would only need to send unicasts on the TiVo, and I presume that Linux could handle those. Or not?

Ian.


----------



## sanderton

> _Originally posted by iankb _
> *One answer to collaborative scheduling is to unicast the TiVo scheduling events to a PC, process them with PC software, and use TiVoweb to implement the changes. You then get a more powerful processor to receive the unicasts and process the conflicts, and it would not be necessary for the TiVo's to catch unicasts or multicasts with the possibility of them being missed.
> 
> Ian. *


Unless you're cyril, the number of Tivos you have is known to you, as are their IP addresses, and doesn't change, so you can do all the communication peer-to-peer.

The only benefit of coming out to a PC would be if you wanted to throw some processing power at the optimal scheduling, instead of the rather crude (and definitely non-optimal) way that TIvo handles it now. that would apply to a single Tivo as much as network of them.


----------



## b166er

> _Originally posted by iankb _
> *I doubt that it would be possible to emulate the TiVo center since that is not a documented interface and involves strong security in the validation of the account.*


Good point. I wonder if the handshaking is mostly server driven, in which case reverse engineering the question/answer session wouldn't be too difficult if you just dial-up to it with your PC and figure it all out.

If the server is in charge and says "tell me this, tell me this, accept this, accept this, hang up" then that would be good, because our server wouldn't have to follow that protocol and the user account info wouldn't be even necessary. It could simply says "accept this and hang up".

If, however, the client leads the conversation then it would be more of a pain, with our server needing to be able to respond to any unsolicited query the tivo might make and at some point say "accept this also".



> _
> Even if it could be done, the whole process would almost certainly be frowned upon by TiVo who would see it as a way of implementing service theft.[/B]_


_

Not sure why they'd think it's service theft. It's just another creative way of achieving the hacking  But if y'all think it's a sledgehammer to crack a nut, because hacking is not all that troublesome anyway, then I guess I'm overengineering the solution _


----------



## sanderton

> _Originally posted by b166er _
> *How about pre-installed upgrade drives? I'm thinking of buying one of those 120GB pre-installed drives. *


Disks only get locked in a TiVo; if you configured the drive BEFORE you put it in the Tivo the issue simply doesn't arise.

But as I said, it ONLY effects one particular model of Maxtor. Any other model of Maxtor, and any other brand of disk, there is no issue.


----------



## iankb

> _Originally posted by b166er _
> *Not sure why they'd think it's service theft.*


Because if you can emulate the center to the extent that you can perform software upgrades, then you can emulate it to the extent that you could download EPG data from an alternate unsubscribed source.

Also, I wouldn't be surprised if the TiVo didn't use some sort of random session keys (such as Diffie-Hellman) to encrypt part of the communications, so they may be much harder to monitor than you think.

I suspect that you would have trouble hitting the nut with your sledgehammer. 

Ian.


----------



## sanderton

I think they have got this going to some extent in Aus; I beleive they can recofigure their TiVos to pick up guide adat slice files from an IP addres they specify. Let's hope we don't have to go down that route a while.


----------



## iankb

> _Originally posted by sanderton _
> *... the number of Tivos you have is known to you, as are their IP addresses, and doesn't change, so you can do all the communication peer-to-peer.*


Which was why I was suggesting peer-to-peer unicasts, and not multicasts. The reason why I prefer UDP rather than TCP is that, being connectionless, you do not need to worry about machines going up and down, and you will never hang on a broken connection. However, because there is no handshaking protocol, you need to capture and buffer UDP datagrams on a higher-priority thread.

On a LAN, they can work very well for the processing of event data. I even use them on the Internet, 'though the Internet has a habit of losing data without handshaking.

Ian.


----------



## b166er

Good about the Maxtors 

Well it was interesting to talk about the server idea. Sorry it's somewhat off-topic for this thread (as are the upgrade talks)


----------



## ccwf

Actually, many people assign addresses to their TiVos via DHCP and, judging from some of the posts to the Help Center forum, are not necessarily aware of the IP addresses of their TiVos. In fact, there's been more than one case of TiVo owners configuring their TiVos to use a neighbour's wireless access point.


----------



## sanderton

I don't think our series ones "do" DHCP, do they? I've not seen the option. It would be useful if they did as my router ahs a bug which means it can only port forward to a DHCP assigned address.


----------



## alunj

Stuart,
is there a problem with endpad bailing out after a while ?
It seems to run well for me for a couple of days then end with nowt in the logs

Alun


----------



## occitan

Sorry for posting my tuppence worth so long after the orriginal post !



> _Originally posted by Fozzie _
> *Stuart - could you just outline your thoughts on how forced end padding would work because it could work in a number of quite different ways? e.g.
> 
> 1. A global setting where any follow on recordings are started late.
> 
> 2. An SP or channel based setting where only those recordings are 'allowed' to force their end padding.
> ...
> *


As many have said, (1) isn't going to be much use. (2) and some of the other options could be very useful.

Like Ian, I would hope for a solution that wouldn't need TivoWeb.

What about 2b. using the deletion date rather than SP/channel settings.

E.g if the first recording was "Never Delete" and the second recording was 'Delete when space needed" then the end pad on the first recording is forced.

I'd posted this thought some pages earlier, but noone commented on it. Apologies for raising it again if the reason for the lack of comments was you were all just being polite and didn;t want to say this was an insane idea....


----------



## sanderton

> _Originally posted by alunj _
> *Stuart,
> is there a problem with endpad bailing out after a while ?
> It seems to run well for me for a couple of days then end with nowt in the logs
> 
> Alun *


Not that I'm aware of. If it crashed with an error you'll see that error listed on screen when you re-run it. It would be useful to see that error code if there was any?


----------



## sanderton

> _Originally posted by occitan _
> *Sorry for posting my tuppence worth so long after the orriginal post !
> 
> As many have said, (1) isn't going to be much use. (2) and some of the other options could be very useful.
> 
> Like Ian, I would hope for a solution that wouldn't need TivoWeb.
> 
> What about 2b. using the deletion date rather than SP/channel settings.
> 
> E.g if the first recording was "Never Delete" and the second recording was 'Delete when space needed" then the end pad on the first recording is forced.
> 
> I'd posted this thought some pages earlier, but noone commented on it. Apologies for raising it again if the reason for the lack of comments was you were all just being polite and didn;t want to say this was an insane idea.... *


There are many ways you could do it - we could probably all come up with one each. 

Personally I would prefer a system where it was very clear what will happen in all circumstances, which points to either global or individually specified options, rather than implicit ones such your suggestion or the one for using SP priority to decide.


----------



## iankb

> _Originally posted by sanderton _
> *Personally I would prefer a system where it was very clear what will happen in all circumstances ...*


As would I, and all control freaks everywhere. 

Ian


----------



## sanderton

EndPad 1.2.6 now up.

This fixes a bug I found yesterday which could cause EndPad not to load after a TiVo reboot if it was in rc.sysinit.author, because the PID it had pre-reboot was active again with another process.


----------



## pahunt

I just installed 1.2.6 and gave the Tivo a quick reboot. Approx 1 minute later while watching a recorded program the screen when black and then "Welcome, powering up"  

A coincidence ?


----------



## pahunt

Well after a second "unplanned" reboot I managed to stop endpad and this seems to have cured the problem. Is there anything I could have done wrong (permissions etc.) that would cause this?


----------



## sanderton

Well the only difference between 1.2.5 and 1.2.6 is that 1.2.6 deletes the endpad.pid file come what may, while 1.2.5 checked to see if there was an active process with the same number as was contained in the PID first. So it's hard to see how that could restart the TiVo, especially as that has happened before you'll even see the Now Playing screen.

Check 1) the kernel log to see what happened immediately before the restart, 2) endpad.err if it exists and 3) the Ednpad log, comparing the time of its logged actions to the time of the reboot in the kernel log.


----------



## sanderton

Also, if you could post your rc.sysinit.author file that might give a clue.

Is it possible that you haven't updated rc.sysinit.author to have the start and end parameters, and it's trying to set the end padding to "-auto"? That's all I can think of at the moment!


----------



## pahunt

Can I check that you have updated the log message as it still tells me it's starting up 1.2.5.


----------



## sanderton

Yes, the message has been updated to read 1.2.6.

You often have to refresh your web browser to see the latest zip file, it's a bug in IE.

The finger of suspicion moves away from 1.2.6 then.


----------



## pahunt

I think the finger of suspicion is now pointing at my telnet client.

I can't use FTP at the moment (another story) so I have been transferring files using rz from telnet. However something must have happened when I transferred it the first time because I've just done it again and it seems OK now. The log is now reporting 1.2.6 and no reboots yet. 

Thanks for your help

P.S. I think the bug in IE is unlikely to have affected me, especially as I'm using Firebird


----------



## Fozzie

> _Originally posted by iankb _
> *As would I, and all control freaks everywhere.
> 
> Ian *


You're not a Virgo too Ian? - everything nice and orderly 

I agree with keeping things straightforward & predictable. It would be a real nause to lose a recording because of some combination of padding settings (that I hadn't thought about) kicking in.


----------



## iankb

No I'm a Gemini. And I like it as complicated and flexible as possible, but predictable. 

Ian.


----------



## sanderton

> _Originally posted by iankb _
> *No I'm a Gemini. *


Now ther's off topic and off topic, but that is off topic!


----------



## iankb

You didn't like the bit about '_And I like it as complicated and flexible as possible, but predictable_' ? 

Ian.


----------



## srs5694

> _Originally posted by sanderton _
> *I don't think our series ones "do" DHCP, do they? I've not seen the option. It would be useful if they did as my router ahs a bug which means it can only port forward to a DHCP assigned address.*


TiVo added unofficial DHCP support to 3.x software. With 3.x, you enter an undocumented but well-known dialing prefix (401, IIRC) into the phone prefix and the system uses DHCP over a TurboNET or TiVoNET (for Series 1 units; over USB-to-Ethernet for Series 2). With later software, DHCP is officially supported, but I don't know offhand how it's activated -- if there's an explicitly labeled option somewhere or if you've got to use the dialing prefix trick.

I don't see why a Series 1 running older software couldn't be hacked to support DHCP, but I don't know of any instructions for doing so, and I've not tried it myself. You'd need to cross-compile a DHCP client, or extract one from a 3.x or later Series 1 TiVo software image (chances are the binary from a US image would even work on a UK TiVo), then plug it into the TiVo startup scripts. Personally, I think it's simpler to just use a static IP address, but if your router has a bug, as you describe, it might be worth the effort to try it.


----------



## alunj

Stuart
It did produce an error in enndpad.err
here you go

----------

Sleeping, checking every minute for kill signal............................ 
Wednesday 00:55:00 : Woken up
Wednesday 00:55:00 : Recording {Swiss Toni} on BBC3 now
Wednesday 00:55:00 : Recording Scheduled End Time: 01:00
Wednesday 00:55:00 : Next recording is {Cosmetic Surgery: Pursuit of Perfection} on DISCOV at 01:00

expected integer but got "$nextrecfsid"
while executing
"db $db openid $recfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
set rec [db $db openid $recfsid]
set state [dbobj $rec get State]
if { $state != 6 } {
dbclose $db
return 0
} else {
dbob..."
(procedure "DeleteSuggestion" line 7)
invoked from within
"DeleteSuggestion {$nextrecfsid}"
(file "/var/hack/endpad.tcl" line 362)
expected integer but got "$nextrecfsid"
while executing
"db $db openid $recfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
set rec [db $db openid $recfsid]
set state [dbobj $rec get State]
if { $state != 6 } {
dbclose $db
return 0
} else {
dbob..."
(procedure "DeleteSuggestion" line 7)
invoked from within
"DeleteSuggestion {$nextrecfsid}"
(file "/var/hack/endpad.tcl" line 362)


----------



## sanderton

That bug got fixed already; install 1.2.6 and you should be OK.


----------



## gyro

> _Originally posted by sanderton _
> *1.2.2 is now in the first post. Fixed a couple of potential bugs, and made the timing elements more robust.
> 
> I've taken a saftety first approach and if a suggestion is followed immediately by a scheduled recording I've not added start padding. This is until I can confirm that it is the suggestion that gets deleted, not the scheduled recording in those circumstances. Suggestions that follow a scheduled recording and clash with the padding are now expressly deleted instead of relying on the clash to do it. *


I am running 1.2.6 and was wondering about what now happens with a suggestion immediately followed by a scheduled recording. Does start padding delete the suggestion?


----------



## sanderton

No, a suggestion before a scheduled recording will record as normal and the soft start padding will not be added to the scheduled recording. this because, as I feared, if you just try to add the start padding the scheduled recording gets cancelled, not the suggestion.

I'm personally inclined to leave it that way, rather than delete a perfectly good suggestion which has almost finished recording for the sake of the start padding. 

But if others feel differently I can revisit that bit of code (once I figure out how to kill an in-progress recordng gracefully).

Let me know.


----------



## TivoTown

I really would like Endpad on my Tivo but have to say that I'm a bit daunted by the serial cable PPP method and I don't fancy spending the £50+ for TurboNet.

I've already upgraded my HDD to 120GB using the Hinsdale method and was happy with the instructions. Is there any way of me getting a supplementary image of a UK Tivo with TivoWeb and Endpad already installed or is that just plain stupid?


----------



## sanderton

You could in theory pull your hard disk out, attach it to your PC, boot with one of the TiVo boot CDs and manually copy over the endpad.tcl file and edit rc.sysinit.author to start it up automatically.

But without a connection of some kind you would not be able to stop or restart Endpad (without rebooting), or change the settings.

Personally I'd feel a bit uneasy at not being able to control it!


----------



## SolidTechie

Stuart,

I've been running v1.2.5 for a dew days now -I haven't had a chance yet to install 1.2.6, and I'm not having any problems, but I will get around to it hopefully at the weekend.

One observation though, I'm using LJ's Now playing with Sort module for TiVoWeb which also lists the duration(s) of shows - but it still lists the time as the original length of a programme - not the padded length. This may be appropriate and correct, but thought it was worth mentioning....


----------



## sanderton

The TiVo database stores a value for duration (which is what LJ uses) based entirely on the scheduled duration. The padding values are held separately in the database; you have to add them on to get the real recorded duration.


----------



## 10203

_Originally posted by iancdbutcher _
*I'm using LJ's Now playing with Sort module for TiVoWeb which also lists the duration(s) of shows - but it still lists the time as the original length of a programme - not the padded length. This may be appropriate and correct, but thought it was worth mentioning.... *

Pah! Someone spotted my sloppy programming   I'll post an updated version "soon"....


----------



## srs5694

> _Originally posted by TivoTown _
> *I really would like Endpad on my Tivo but have to say that I'm a bit daunted by the serial cable PPP method and I don't fancy spending the £50+ for TurboNet.*


I've not tried this, but you _should_ be able to control it via a serial cable running a bash prompt. Do as sanderton suggests and install it by copying it onto the hard disk on a PC, then run a serial cable, configure bash to run on it, and run a terminal program on your PC. That's much simpler than PPP and much cheaper than TurboNET. You'll need to dig up more detailed instructions on getting a bash prompt over serial, though. I don't have any pointers offhand, but I expect there's a FAQ or a pointer to a FAQ on this on the Underground forum.


----------



## pahunt

> _Originally posted by srs5694 _
> *I've not tried this, but you should be able to control it via a serial cable running a bash prompt. Do as sanderton suggests and install it by copying it onto the hard disk on a PC, then run a serial cable, configure bash to run on it, and run a terminal program on your PC. That's much simpler than PPP and much cheaper than TurboNET. You'll need to dig up more detailed instructions on getting a bash prompt over serial, though. I don't have any pointers offhand, but I expect there's a FAQ or a pointer to a FAQ on this on the Underground forum. *


As I understand it that should work, although to be honest getting to bash is the trickiest part. Once you are there then it's just a matter of editing a few files on the Tivo and setting up a modem and connection in Windows. The best place to find out about all this the Black Widow guide. Just follow the instructions up to the "Getting to Bash" section and ignore the PPP stuff if you want.


----------



## TivoTown

Thanks guys, I think I'm going to have to bite the bullet and do it the correct way.


----------



## mas

Moderators - Can this thread be made sticky ?


----------



## djrowley

Just wanted to add my thanks for endpad - installed and working in 30 seconds. It's been running for a day now without drama. If it continues OK for the next few days I will add to rc.sysinit.author

David


----------



## tivo_boj

working withouut hitch all week, already I rely on it......best thing that happend on this forum in the past year-18months


----------



## bobnick

agreed!


----------



## producer

Will this work on a US TiVo running v3.0?

It sounds cool.


----------



## sanderton

Yes.


----------



## mark.stringer

Just a quick thanks to Stuart for creating Endpad. As someone else said it is the best thing to happen program wise in ages. I wish I had had it when 24 and 24 day 2 were on as it often did not run on schedule.

Thanks,
Mark.


----------



## Tony Hoyle

Best bit of Tivo software in ages!

I've also gone to max. resolution on my Tivo at the same time, and installed the email thingy... Great stuff!


----------



## djrowley

> _Originally posted by Tony Hoyle _
> *Best bit of Tivo software in ages!
> 
> I've also gone to max. resolution on my Tivo at the same time, and installed the email thingy... Great stuff! *


Ooh, what's the email thingy, and what does it do?

David


----------



## bobnick

Have a look at DailyMail in this forum!


----------



## Fatbloke

Quick question:
I'm currently awaiting my first recording under endpad!.. and have been checking the TiVoweb logs to see how endpad is thinking. How big will/could the endpad log get? And is there any housekeeping to keep it to a managable level (whatever that happends to be)?


----------



## sanderton

It resets at midnight, with the previous day's log retained.


----------



## Fatbloke

Nice one.


----------



## Fatbloke

:up: :up: :up: 
Nice bit of coding there!

1 question: how can I change the rc.sysinit.author file? Its marked as read only on my system and even chmod 777 doesn't make it writable  

Also, it might aid others to add to your first post just where rc.sysinit.author sits in tivo (i.e. in etc/rc.d)

Once again, well done.


----------



## SolidTechie

> _Originally posted by Fatbloke _
> [B1 question: how can I change the rc.sysinit.author file? Its marked as read only on my system and even chmod 777 doesn't make it writable  [/B]


You need to make the partition writable first, and *don't forget* to make it read only again when you've made the changes....

HTH..


----------



## sanderton

I assumed that people had made chnages to rc.sysyint.author before and therefore didn't need instructions on that bit!

But for reference:



Code:


cd /etc/rc.d

mount -o remount,rw /

[edit rc.sysinit.author with whatever editor you have]

mount -o remount,ro /

sync


----------



## AMc

Hi, this sounds _so good_ 
I've read through this whole thread and I've followed the links to Mr Tickle's setting up serial thread and the blackwidow guide. I've successfully upgraded my Tivo, but I'm frankly pretty scared by the walkthroughs and guides for getting to a BASH prompt over serial to get endpad on my Tivo.

I'd _really_ like to be able to install and occassionally reconfigure endpad but I'm very scared of hurting my Tivo.

I know this is a lot to ask but I also know there are some fantastic, clever and generous people on here (grovel grovel)...

* Is anyone prepared to assemble an idiots guide to turning an unhacked UK Tivo into a UK Tivo with serial control and endpad installed and running?*.

Basically if someone was prepared to put together a step by step guide dedicated to this task I'd be happy to send a few quid to the charity of their choice/their beer fund.


----------



## Fatbloke

> _Originally posted by sanderton _
> *I assumed that people had made chnages to rc.sysyint.author before and therefore didn't need instructions on that bit!
> 
> But for reference:
> 
> 
> 
> Code:
> 
> 
> cd /etc/rc.d
> 
> mount -o remount,rw /
> 
> [edit rc.sysinit.author with whatever editor you have]
> 
> mount -o remount,ro /
> 
> sync
> 
> *


OK, what have I done wrong here then...?
I did the above, FTP'd the rc.sysinit.author off onto my desktop and added the endpad line. My rc.sysinit.author now looks like the following:

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

I FTP'd the file back to Tivo, did the mount -o remount,ro / and the sync.
Finally I restarted the whole machine (power off) since I needed to update Tivoweb after the clock change.

Anyway... after restart, neither Tivoweb nor Endpad restarted. 

I needed to manually restart both from Telnet.

Any suggestions?


----------



## pahunt

Did you chmod 755 rc.sysinit.author after you FTPed it back?


----------



## iankb

... and did you use a Linux-compatible editor to edit the file?

Ian.


----------



## Fatbloke

I'm ok on the editor - used Ultra edit and said NO to the 'convert to dos' prompt.

Checking the file, it's sitting there with rw-r--r-- at the moment - no Execute I notice... I'll give it a chmod to see if it helps.

I posted the original question just in case I needed a ; or , after the first line. I didn't think about the properties of the file...


----------



## pahunt

> _Originally posted by Fatbloke _
> *I'm ok on the editor - used Ultra edit and said NO to the 'convert to dos' prompt.
> 
> Checking the file, it's sitting there with rw-r--r-- at the moment - no Execute I notice... I'll give it a chmod to see if it helps.
> 
> I posted the original question just in case I needed a ; or , after the first line. I didn't think about the properties of the file... *


You'll only get this kind of permission problem if you transfer the file back and forwards. If you edit it directly on Tivo then the permissions are preserved but if you FTP off and back on again then the permissions get reset.


----------



## ccwf

You might be able to do site chmod 755 rc.sysinit.author from your FTP client, which may or may not be more convenient than running chmod from a shell on the TiVo.


----------



## Fatbloke

Sorted - it was the chmod after all.


----------



## doubledrat

> _Originally posted by AMc _
> *
> Is anyone prepared to assemble an idiots guide to turning an unhacked UK Tivo into a UK Tivo with serial control and endpad installed and running?.
> 
> Basically if someone was prepared to put together a step by step guide dedicated to this task I'd be happy to send a few quid to the charity of their choice/their beer fund. *


I can imagine this is very scary for the uninitiated. I've done my own, and came up against some obstacles. I'm now going to do it for 2 friends, so I'll make an effort to document it while I do it and post the results.

in the meantime, here's some pointers -

always do a backup BEFORE you mess with your tivo!

if you boot from the mfstools cd, you won't be able to mount the tivo partitions unless you "byteswap" the tivo drive(s) before you boot linux. search the forums for "byteswap"

I found that when I booted from floppy I couldn't access my DOS hd (where I'd put all the source files and my tivo backup) - presumable because all the drives are byteswapped when booting from the floppy.

The tivo binaries come bundled in a sub directory called tivo-bin, but the instructions for adding them to your path states /hack/bin - they should say /hack/tivo-bin

Most importantly it IS worth the effort. Thanks again Stuart for a fantastic hack 

Bob


----------



## pahunt

> _Originally posted by doubledrat _
> *if you boot from the mfstools cd, you won't be able to mount the tivo partitions unless you "byteswap" the tivo drive(s) before you boot linux. search the forums for "byteswap"*


This isn't an issue if you use the Kazymyr boot CD that is recommended in the Black Widow guide.


----------



## doubledrat

does that one byteswap the hdb and hdc? only I'm unable to have my machine boot a cd in that config, so my tivo disks have to be hdc and hdd


----------



## pahunt

> _Originally posted by doubledrat _
> *does that one byteswap the hdb and hdc? only I'm unable to have my machine boot a cd in that config, so my tivo disks have to be hdc and hdd *


AFAIK it byteswaps everything apart from hda.


----------



## AMc

doubledrat - if you managed to do a step by step I'd very grateful. I've got a 3 week old baby so I'm not getting a lot of spare time to play with Tivo and the PC right now.
If you don't manage it then I guess I'll have to take the plunge myself and try and write the guide too at some point.

That said a TurboNet is quite tempting as Tivo sits next to a wireless AP/repeater for the PS2online...so many toys so little time


----------



## alphabeta

Like a lot of people the idea of endpad was compelling enough for me to finally get my Tivo in bits to do some hacking.

As several people have alread said, I found all the overlapping instructions rather confusing. I have tried to write down my own "simple" guide using all the steps I did this afternoon at: 
http://www.pinedragon.com/tivo/endpad_instructions.html.

To make life simple just to install endpad I've tried a novel approach. Rather than getting a Bash prompt and then install endpad via Bash or PPP I've copied endpad directly on to the Tivo. The code in there should also enable Bash in case you need in in the future, but *I haven't tested this. At this stage the process should be regarded as only being at the "testing" level, so don't assume it will work and please provide feedback to this thread.*

Anway, feel free to try this (at your own risk). Hopefully this will help some of the people wanting simple instructions! Also comments from experts who can review the code would be useful.

Congratulations and thanks to all the authors of the excellent "how tos" and tools to make this possible.


----------



## sanderton

The only comment I'd make, alphabeta, as that it would be wise to insert a note that users of Windows XP should be very careful not let their PCs boot into Windows if following these instructions, as that could prevent their TiVos from booting.


----------



## alphabeta

Good point! I thought about putting an "XP warning" in then forgot it again. Its in there now.

Great tool Stuart. Why couldn't Tivo have written that themselves ;-)


----------



## iankb

Is there any reason why an MFSTools 2 boot CD can't be used instead of a Kazymyr boot CD plus MFSTools 1.1 files? Seems a little easier, and more up-to-date.

Ian.


----------



## sanderton

I use a CD burned from the image of the TurboNet install disk, as it seems to have most stuff on it.


----------



## pahunt

> _Originally posted by iankb _
> *Is there any reason why an MFSTools 2 boot CD can't be used instead of a Kazymyr boot CD plus MFSTools 1.1 files? Seems a little easier, and more up-to-date.
> 
> Ian. *


The advantage that the Kazymyr CD has over MFS Tools is that it enables byteswapping by default which can make the process a little easier.


----------



## alphabeta

Paul, Ian,

Yes the byteswapping was the reason why I chose Kazymyr. I also don't know if MFS tools 2 CD does an auto Qunlock.

I agree having MSFtools2 on the CD would be nice though!


Iain


----------



## doubledrat

Hi. great start. a few suggestions -

The possible need for qunlock needs a mention (if the tivo drive does not report the correct size - use shift pageup to check). Or is that only necessary for mfstools?

Can you get away with just the A drive of a 2 drive tivo for this operation? I presume you can.

You should mention that there might not be both a 4 and a 7 partition e.g. if it's an upgraded tivo

at the end, the umount can be made simpler with -

umount -a

the cp might be less prone to error like this -

cp /mnt/7/etc/rc.d/rc.sysinit.author /mnt/4/etc/rc.d 

I can imagine non unix people omitting the "." same goes for the other cp(s) - either that or elaborate that the "." neans current directory and it's not just there as punctuation!

the bit where endpad is added to .author, say that "2 5" means 2 mins start pad and 5 mins end pad - not everyone knows what a "parameter" is. Or perhaps if you don't know what a parameter is you shouldn't be attempting this!

How about getting them to put the tivo binaries in /var/hack while they're at it? It's only a couple more steps...

Bob


----------



## pahunt

> _Originally posted by alphabeta _
> *Paul, Ian,
> 
> Yes the byteswapping was the reason why I chose Kazymyr. I also don't know if MFS tools 2 CD does an auto Qunlock.
> 
> I agree having MSFtools2 on the CD would be nice though!
> 
> Iain *


MFSTools definitely doesn't qunlock automatically, it has to be done manually.


----------



## sanderton

Are you sure? Last time I upgraded a machine I used 2 and I'm sure I saw "unlocking hdb" flying past in that initial flurry of text.


----------



## racingclub

> Are you sure? Last time I upgraded a machine I used 2 and I'm sure I saw "unlocking hdb" flying past in that initial flurry of text.


I remember noticing that as well...........


----------



## pahunt

> _Originally posted by sanderton _
> *Are you sure? Last time I upgraded a machine I used 2 and I'm sure I saw "unlocking hdb" flying past in that initial flurry of text. *


Well when I upgraded from my original 40GB Maxtor I ran qunlock because the BIOS was reporting it it 10MB but I suppose it's possible that I didn't actually need to do it and MFS Tools would have done it anyway. But that wasn't the impression I got from reading Hinsdale.

EDIT: I've had a quick look at the latest Hinsdale instructions and it definitely still talks about putting qunlock on a floppy and booting from that first.


----------



## alphabeta

I definately sure a "qunlocking" message from Kazymyr Boot CD. Actually Hinsdale (MFS 1 version) seems to explain the answer:


> The Boot Cd will generally automatically unlock any TiVo locked Quantum drives. However, if your TiVo comes with a Maxtor drive or are using a new Quantum or Maxtor (some newer Maxtors have Quantum firmware and components) hard drive in your planned upgrade, then you may require another utility to unlock this drive if it is ever placed into the TiVo for testing/use and then removed later for further upgrading steps.


So it seems that for the basic activity in this script you may need to do a manual QUNLOCK if your Tivo comes with a Maxtor drive. Does this apply in the UK?

Doubledrat Bob has made some good comments about improving the Unix command line. I'll try and include some of these ideas.

On the question of supporting dual-drives and upgraded Tivo's I avoided these partly to keep things simple and partly because I couldn't test them. If would be helpful if someone can send me a modified page to cover these cases it would be useful.

Bob is also right that I deliberately wrote the document to assume a certain amount of knowledge to try and filter users to people who have a certain basic level of skills/knowledge.

What are the "Tivo binaries"?


----------



## pahunt

> _Originally posted by alphabeta _
> *I definately sure a "qunlocking" message from Kazymyr Boot CD. Actually Hinsdale (MFS 1 version) seems to explain the answer:
> 
> So it seems that for the basic activity in this script you may need to do a manual QUNLOCK if your Tivo comes with a Maxtor drive. Does this apply in the UK? *


All becomes clear!



> _Originally posted by alphabeta _
> *
> What are the "Tivo binaries"? *


They are some standard unix commands that tivo doesn't have, such as ls, ps etc. Take a look at section 4.2 in the Steve Jenkins Guide


----------



## Dibblah

> _Originally posted by alphabeta _
> Actually Hinsdale (MFS 1 version) seems to explain the answer:


Be careful here. Only use Qunlock on ORIGINAL quantum disks, that have been locked by the Tivo. There is a specific issue with certain Maxtor disks that causes them to fail (After qunlock, they are permanently limited in size). I'm guessing that other issues may also occur with other manufacturers, since (AFAIK) the size lock is not part of the ATA standard.

Cheers,

Allan.


----------



## blindlemon

> _Originally posted by Dibblah _
> *There is a specific issue with certain Maxtor disks that causes them to fail (After qunlock, they are permanently limited in size). *


 AFAIK the latest evidence (and my own experience) suggest that this is only a problem if you run qunlock on a maxtor drive that is _not_ locked.

See towards the end of this thread for more info.


----------



## 10203

_Originally posted by iancdbutcher _
*One observation though, I'm using LJ's Now playing with Sort module for TiVoWeb which also lists the duration(s) of shows - but it still lists the time as the original length of a programme - not the padded length.*

Version 2.8 just posted - it now has an extra field showing the total padding (if there is any) - e.g.: "45 +5" shows the programme is 45 minutes long with a total of 5 minutes padding.


----------



## doubledrat

> _Originally posted by LJ _
> *Originally posted by iancdbutcher
> One observation though, I'm using LJ's Now playing with Sort module for TiVoWeb which also lists the duration(s) of shows - but it still lists the time as the original length of a programme - not the padded length.
> 
> Version 2.8 just posted - it now has an extra field showing the total padding (if there is any) - e.g.: "45 +5" shows the programme is 45 minutes long with a total of 5 minutes padding. *


endpad only adds the padding 5 mins before it's needed, so you won't see it in any list of shows to be recorded...

If you want some assurance that it's working, you need to check 0endpad.log and endpad.log in /var/log

I use

grep -i added /var/log/*endpad.log


----------



## sanderton

Now Playing contains stuff which has been recorded.


----------



## doubledrat

duh! yeah, read "now playing" and thought "todo"


----------



## alphabeta

Thanks to you all for your comments. I have updated my "how to" with the latest thinking on "qunlock" and some other improvements.

The "how to" is (still) at:
http://www.pinedragon.com/tivo/endpad_instructions.html


----------



## groovyclam

Do MFSTools 1.1 backup version 2.5.5 fully ?

I say this as the first person to fall victim to the problem when trying to upgrade my disk just after the 2.5.5 upgrade was released in the UK. Rob had to send me a disk image on CD to get out of a right pickle after we all found out 2.5.5 needed special backup parameters and/or an updated MFSTools.

Can someone with more knowledge than me confirm what version of MFSTools and what parameters are required for a *complete* divorced UK 2.5.5 backup...


----------



## Rob Nespor Bellis

Yes and no.

MFStools can backup fully a UK 2.5.5 machine as long as you use the -l 32 parameter in the backup command.

However, when you use the -s parameter ( to "shrink" the backup, or divorce it ) it may go back to a 30GB or 40GB image, but *only* if all the streams you are backing up are contained in the first 30 or 40GB.

This should not be an issue if you performed the disk upgrade *after* V2.5.5 was installed, as all the relevant streams are contained in the first 30 or 40GB in that case.

Rgds,

R.


----------



## Adlopa

Just to herd this monster thread back on topic, I have a 1.2.6 crash to report...

bash-2.02# /var/hack/endpad.tcl 2 5
A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
no such object: {CONFLICT err=errTmActiveLockConflict}
while executing
"dbobj $nstation fsid"
("uplevel" body line 8)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 5)
invoked from within
"RetryTransaction {
set nrec [db $db openid $nextrecfsid]
set nselectiontype [dbobj $nrec get SelectionType]
set nshowing [dbobj $nrec ge..."
(file "/var/hack/endpad.tcl" line 312)
bash-2.02#

rc.sysinit.author is:

#!/bin/bash
/var/hack/tivoweb-wml-beta2/tivoweb
/var/hack/endpad.tcl 2 5 -auto >> /dev/null &

Ideas, anyone..?


----------



## doubledrat

Stuart:

Do you know what the significance of programme names in {} in your endpad log file? Most are bracketed, but some aren't. Just curious


----------



## pahunt

> _Originally posted by doubledrat _
> *Stuart:
> 
> Do you know what the significance of programme names in {} in your endpad log file? Most are bracketed, but some aren't. Just curious  *


An educated guess  Titles of one word appear not to be bracketed whereas multiple word titles are.

E.g. 
Friends
{The Simpsons}

You get the same kind of thing in SQL Server except with [] instead


----------



## doubledrat

you could be right there. I was trying to find a link based on program type or wishlist or manual recording or something like that!

cheers


----------



## sanderton

> _Originally posted by Adlopa _
> *Just to herd this monster thread back on topic, I have a 1.2.6 crash to report...
> 
> bash-2.02# /var/hack/endpad.tcl 2 5
> A stale PID file was found and has been deleted.
> This means that this script terminated unexpectedly last time. Loading now.
> The errors logged (if any) before the last termination were:
> no such object: {CONFLICT err=errTmActiveLockConflict}
> while executing
> "dbobj $nstation fsid"
> 
> Ideas, anyone..? *


The database was busy when endpad attempted to access it and contiunued to be so until it exceeded its retry count.

Happens (rarely) with all TCL scripts. No real way around it. Just restart endpad.


----------



## sanderton

> _Originally posted by doubledrat _
> *Stuart:
> 
> Do you know what the significance of programme names in {} in your endpad log file? Most are bracketed, but some aren't. Just curious  *


TCL uses lists, which are string arrays delimited by spaces. If a member of a list itself contains spaces you use the brackets to define them. Normally you parse them out for user consumption, but i didn't bother with the log files!


----------



## Fatbloke

Just a little warning to people using Endpad...

Last night, around 8.57pm, I decided to record the Horizon program on BBC2 that started at 9.00pm.
I went through the search, and asked Tivo to record it. The clash menu popped up, since it was curently recording Superstars on BBC1 and endpad had extended the run by 5 minutes as requested.

It simply asked "Get this recording (Horizon) or cancel the Horizon recording"

I chose get this recording thinking that, in the same way that you manually end a recording, you'd get the partial recording on the disk (Superstars had finished by now).
But I was wrong... Tivo stopped the superstars recording and the _whole_ recording vanished. What makes it worse - I popped over to Live TV and the buffer showed just 1 minute of stuff, basically only the tv after I'd cancelled the recording.

So just a warning for people putting in last minute recordings... cancel any Endpad'd programs from Now Playing. This should give you your normal partial recording. Then enter your new program.

Interestingly, Tivo had automatically added my BBC3 superstars season pass into ToDo thinking that the BBC1 version has been cancelled. So I should get the program later in the week.

_Stuart_ - do you think it's possible to make the value that Endpad wakes up before the end of a show into a variable? Or is there a reason why you've chosen 5 minutes. I was thinking of *endpad s e w* where w is the wake-up-before-end-of-program variable. If this is made smaller (0.5 perhaps) it could avoid most of these last minute clashes.

Just a thought


----------



## ccwf

TiVo does a lot of scheduling and allocation roughly a minute before a recording is about to start, so waiting until a half minute before won't work.


----------



## doubledrat

was superstars a suggestion? normally it's only suggestions that vaporise if you cancel them...


----------



## sanderton

You have to allow sufficient time for the TiVo to realise that you've added the padding into the db entry and act on it, and as ccwf says, TiVo starts doing lots of stuff immediately before a recording ends which can block endpad for getting accesss to teh db at all. 5 mins seemed safe, although I didn't do a lot of testing to see how close you could get. Feel free to edit the code and experiment! However even if it was 0 seconds, that wouldn't solve the problem if you tried to do what you suggest during the padded period itself.

Can you undelete Superstrs with TiVoWeb?


----------



## ccwf

> _Originally posted by Fatbloke _
> *Just a little warning to people using Endpad...*





> _Originally posted by doubledrat _
> *was superstars a suggestion? normally it's only suggestions that vaporise if you cancel them... *


 No, it wasn't. Actually, none of this was specific to endpad, although it's still good to warn people about this situation since it may not be obvious that scheduling a conflicting recording during the soft padding period can delete the original recording.

Basically, if you have a recording in progress (again, even if not using endpad) and then schedule a conflicting recording, the current recording is cancelled and *deleted*. No partial recording is left, and an entry is left in the recording history that a conflict prevented the recording. Therefore, TiVo will try to reschedule that recording.


----------



## Fatbloke

Indeed, this is not an endpad problem. Although by using endpad you may come across the problem more often. Just a head's up really 

No sign of the deleted show in tivoweb's undelete function 

Edit endpad !!!  I'm not worthy


----------



## sanderton

This is the bit that controls it:



Code:


if {[clock seconds] < [expr $cendtime - 300]} {
		
		set nextepwake [expr $cendtime - 300]
		
	} else {
	
		if {$nduration < 400} {

			set nextepwake [expr $nextstart + 60]

		} else {

			set nextepwake [expr $nextstart + $nduration - 300]
		}
	}

The 300 is the time (in seconds) before the end of the programme thet EndPad wakes up to set the end padding.

Just change the number!


----------



## groovyclam

Hi all,

I'm going to install EndPad today but I haven't got TiVoWeb so I'm going to have to pull my TiVo apart - yes, endpad is that useful!!!

I have a 120G drive in a UK TiVo - I upgraded the disk ages ago and was hoping I would never have to pull my TiVo apart again because of the trauma I went through last time ( first UK user to discover then current usage of MFSTools didn't back up UK 2.5.5 ) and because my drive has behaved beautifully for such a long time I am loathe to "fix what aint bust". Anyway...

What I am asking is I have read the thread and am going to trial alphbeta's instructions but have seen comments that some partitions may be different on an already upgraded disk.

I can check that I am in the correct 4 and 7 partitions by looking for etc/rc.d directories but my question is - will partition 9 still be the same ? What files or dirs should I check for before I know I am in the correct partiton and make /hack and install endpad in it ?

Also to alphabeta - are you sure about the syntax for the bash prompt in rc.sysinit.author:

/bin/bash < /dev/ttyS3 >& /dev/ttyS3 &

where will stderr go to ?


----------



## sanderton

I think /var is always on partion 9, whichever OS partition is active.

IIRC, some of the boot disks have joe on them so you can edit rc.sysinit.author that way.


----------



## doubledrat

groovy: endpad IS worth pulling apart your beloved tivo for 

as it's an upgraded one, you'll probably only have 4 OR 7 not both. So if the mount of 4 fails, just mount 7. Mine only had 7. 9 I believe as Stuart says is the same no matter what.

as you have the machine in pieces, I would recommend you also install the tivo binaries in /var/hack/bin while you're at it. it will allow you to easily further change things via the serial connection later


----------



## groovyclam

I'm going to put joe and the other useful linux binaries into var/hack at the same time but since I don't have TiVoWeb and want to use the bash via serial for any future communication I need that bash prompt syntax in rc.sysinit.author to be right first time.

I don't want to have to pull apart the TiVo again to get the correct bash syntax.

Can anyone confirm:

/bin/bash < /dev/ttyS3 >& /dev/ttyS3 &

is the right syntax ?


----------



## doubledrat

groovyclam: I can't remember specifically, but it looks about right. I used the syntax from the black widow guide? but can't remember where that guide is now!

don't forget to chmod 755 it though (I did - doh!)


----------



## pahunt

Here it is : Black Widow Guide


----------



## alphabeta

I have to admit that I don't fully understand the line you quoted groovy. I just copied it from Black Widow or one of the other referenced quides in my instructions.

I still haven't tested the BASH prompt so no idea if it works. However there was no obvious errors when the Tivo booted and Endpad works a charm so I must have done something right!

Iain.


----------



## pahunt

> _Originally posted by alphabeta _
> *I have to admit that I don't fully understand the line you quoted groovy. I just copied it from Black Widow or one of the other referenced quides in my instructions.
> 
> I still haven't tested the BASH prompt so no idea if it works. However there was no obvious errors when the Tivo booted and Endpad works a charm so I must have done something right!
> 
> Iain. *


As I understand that line tells Tivo to run the bash program but to send it to ttyS3 (which is the device name of the serial port) and to expect the responses back from the same place.


----------



## alphabeta

BTW a word on the handling of partition 9: though it becomes the /var directory if you mount it directly as shown in my guide you won't find the /var part (if that makes any sense)

If you follow my guide then the contents of /mnt/9 is the same as the contents of what will be /var when you put the disk back in the Tivo (but there is no /var to be seen!


----------



## sanderton

I've seen other giudies mount it on the PC as "/tivovar" rather than just as partition 9, to try to make that clearer.


----------



## groovyclam

OK I'm into the process and currently backing up my TiVo 120G drive.

BUT....

In the boot process the Kazymr CD reported the following partition names for my hdb TiVo drive:

hdb1 - Bootstrap1
hdb2 - Kernel1
hdb3 - Root1
hdb4 - Bootstrap2
hdb5 - Kernel2
hdb6 - Root2
hdb7 - Linux swap
hdb8 - /var
hdb9 - MFS application a10
hdb10 - MFS media a11
hdb11 - MFS application region2
hdb12 - MFS media region2
hdb13 - Hack

So which of the above will have the two /etc/rc.d in them ?

I guess hdb8 is my /var BUT can someone just answer the original question:

Please will someone name a few files in the defualt /var directory so that when I mount it and see them, I know I have mounted the correct partition as /var!!!


----------



## doubledrat

groovyclam: ignore what it tells you at boot. it's bollox 

/var is partition 9 even though it says 8

you'll see things like tmp and logs there


----------



## groovyclam

thanks doubledrat


----------



## groovyclam

OK - finished but with some weirdness.

My hdb4 and hdb7 were both /etc/ and my hdb9 was /var

I followed alphabeta's instructions and they work fine ( I even get a bash via serial now! )

I tested it with the TiVo cover off with a little manual 5 minute recording and it definitely added the 2 mins start and 5 mins end padding.

Put the cover back, on and rebooted and now it is not doing softpadding !?!?

I have rebooted again and still it is not working.

Any ideas what I should be checking ? Remember I only have bash via serial.

I am going to try another few reboots to see if it will work like when I had the cover off.

Help!

Why should it be working and then stop working after a reboot ?


----------



## pahunt

Have you put the endpad command in rc.sysinit.author and set the permissions by running chmod 755?


----------



## pahunt

And I have may have spotted the problem in alphabeta's instruction. It tells you to set the permissions on rc.sysinit.author in partition 7 but then it only gets copied to partition 4 and I don't think the permissions will be transferred as well. Therefore if 4 is your active partition it may not work.

Disclaimer: I haven't actually tested this so I may be talking rubbish


----------



## alphabeta

Ah! Could be. I thought the "cp" copied the permissions, but my Unix command line skills are pretty crap. Can someone confirm if pahunt is right please?


----------



## ccwf

> _Originally posted by alphabeta _
> *I thought the "cp" copied the permissions, but my Unix command line skills are pretty crap.*


 To copy permissions: cp -p


----------



## ccwf

> _Originally posted by groovyclam _
> *Can anyone confirm:
> 
> /bin/bash < /dev/ttyS3 >& /dev/ttyS3 &
> 
> is the right syntax ? *


 To be pedantic, ">& filename" is accepted for csh compatibility but discouraged to prevent confusion with the file descriptor duplication syntax. The traditional sh-style ">filename 2>&1" or the bash-extension &>filename are preferred.

So, a minimally better variation of alphabeta's rc.sysinit.author creation recipe would be


Code:


cat <<EOF >rc.sysinit.author
#! /bin/bash -
/bin/bash </dev/ttyS3 &>/dev/ttyS3 &
/var/hack/endpad.tcl 2 5 -auto >/dev/null &
EOF

 There's no significant difference for normal TiVo purposes, of course.


----------



## alphabeta

OK - extra chmod put in to fix permissions problem.

Iain


----------



## groovyclam

Can I fix this permission problem via the serial bash ?

Please tell me I don't have to pull the disk out again !!!


----------



## pahunt

Just type the following commands at bash

cd /etc/rc.d
chmod 755 rc.sysinit.author

That should sort it.


----------



## sanderton

Not quite. You'll need to set the partition to be writable:

cd /etc/rc.d
mount -o remount,rw /
chmod 755 rc.sysinit,author
mount -o remount,ro /
sync


----------



## sanderton

> _Originally posted by groovyclam _
> *Can I fix this permission problem via the serial bash ?
> 
> Please tell me I don't have to pull the disk out again !!! *


Now you can telnet in to a bash prompt, you can do anything which you could do with the HD attached to your PC. The only time you might need to pull the disk is if you break the bash access. Wilch I may have done occasionally.


----------



## groovyclam

OK, totally confused now.

Went in via serial bash and found my rc.sysinit.author was fine BUT...

My /var no longer contained /hack and hence the endpad.tcl ( nor the joe and tivo binaries I had put in a /var/hack/bin/ directory!!!

Where had they gone ?!?

I remade a /var/hack and ZModem'ed endpad.tcl across and all was well after a reboot.

WHAT THE HECK IS HAPPENING ?!?

How could endpad have worked once after the disk swapping and then failed after a reboot, by apparently being wiped from /var completely ?!?


----------



## burriko

> _Originally posted by groovyclam _
> *My /var no longer contained /hack and hence the endpad.tcl ( nor the joe and tivo binaries I had put in a /var/hack/bin/ directory!!!
> 
> Where had they gone ?!? *


tivo can wipe /var at any time, i think it's when it's running low on disk space. it's never happened to me, but it can happen.


----------



## groovyclam

Just want to say a big thank you to sanderton for developing this utility - I have been running it for a couple of days and it does exactly what it says on the tin so marvellously and seamlessly.


----------



## TriscuiT

In the first post, Sanderton states:



> The current version, 1.2.6 appears stable (famous last words). It will work on all TiVos on both sides of the pond, but will not be fully optimal on DirecTivos as it does not attempt to use the second tuner for extending shows.


Then, many posts later, Srs5694 states:



> I'm running it on a Sony SAT-T60 DirecTiVo running 2.5.2 software in the US, and it works, but not optimally -- the script doesn't know about the dual tuners, and it determines whether or not to pad something based on a search for a potentially-conflicting upcoming show (I've not yet checked the logic for the start padding, but I assume it's similar). The bottom line is that it won't pad some shows that could be padded because the script doesn't realize there's an unused tuner. None of these issues would affect SA TiVos in the US.
> 
> FWIW, I hope to look over the code and modify it to work with both single-tuner and dual-tuner TiVos, but I'm busy with other matters right now. With any luck I'll have the free time in a week or so.


Has there been any improvements made to allow for dual tuner use on the DirecTivo(DTivo)?


----------



## modaco

Awesome!

Nice work, I think this will make my TiVo perfect 

P


----------



## Edwards_sj

Has anyone else noticed an increase in the number of missed channel changes since installing endpad?

It's gone up from about 2 a month to about 3 a week...

Probably nothing to do with endpad, I thought I'd just check 

I'm looking at replacing the ir wand with one of the RF units...

Cheers

Steve


----------



## pahunt

> _Originally posted by Edwards_sj _
> *Has anyone else noticed an increase in the number of missed channel changes since installing endpad?
> 
> It's gone up from about 2 a month to about 3 a week...
> 
> Probably nothing to do with endpad, I thought I'd just check
> 
> I'm looking at replacing the ir wand with one of the RF units...
> 
> Cheers
> 
> Steve *


This hasn't been a problem for me. I haven't had a missed channel change since I repositioned by IR wand a few of weeks ago and I've had endpad running all that time.


----------



## doubledrat

nope.

maybe you didn't put the ir wand back where you had it before?


----------



## tivo_boj

no problem at all here on channel changes, and i have been using it from the very begining


----------



## Edwards_sj

> _Originally posted by tivo_boj _
> *no problem at all here on channel changes, and i have been using it from the very begining *


OK, seems like it's just me then 

I didn't think it was anything to do with endpad really, it's just it started happening about the same time as I installed it...

I'll have a go moving the wand...

Cheers

Steve


----------



## pahunt

It's also worth making sure that Tivo isn't picking up some stray IR from some other piece of equipment as that can cause missed channel changes as well.


----------



## Ashley

I don't know if this is a coincidence or not but since installing SoftPad my Tivo has started recording in Basic quality. 

The SPs and default recording quality still say Best quality.

If I go to ToDo in TiVoWeb and click on an episode I get the following:
Cancel date Wed 19th Nov 19:09
Cancel reason ExplicitlyDeletedFromToDo
Error string Cancelled by user

Anybody got any ideas?


----------



## sanderton

Do you mean SoftPad or EndPad? There were some bugs in an early version of SoftPad (the old PC app, no longer supported) that could do that. EndPad (the "new" on-TiVo app) does not edit any part of a recording apart from its paddings ettings.


----------



## maubp

Wow - now I really must buy a new 120GB hard disk and finally open my Tivo...



> _Originally posted by sanderton _
> *Can I gauge how much interest there is in three possible additional features, so I can decide whether it's worth adding them:
> 
> 1) A TiVoWeb control panel to turn padding off and on and set the amounts.
> 2) A TiVoWeb control panel to allow padding settings to be varied either a) per channel or b) per SP/WL
> 3) Forced end padding, with a following show starting to record a couple of minutes late if need be
> 
> Please post your thoughts. Ta. *


(1) - Sounds nice, but if you could get this into the Tivo UI even better
(2) - Per channel settings would let me deal with BBC2 properly. Per SP settings would be even better, but wouldn't this be much more complicated to code and manage?
(3) - Again sounds nice but very complicated.

So, I would vote for 1 and 2(a) because on the face of it 2(b) and 3 are asking for trouble.


----------



## pahunt

> _Originally posted by maubp _
> *but if you could get this into the Tivo UI even better
> *


Not going to happen unfortunately as the Tivo UI is effectively "closed" and cannot be modified by mere mortals


----------



## Adder

Hmm, Endpad 1.2.6 stopped on my Tivo sometime after 6am yesterday morning when it was heading into 13 hours of continuous recording (Breakfast + Dr Who Day).

The error returned was:


Code:


A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
         no such object: {CONFLICT err=errTmActiveLockConflict}
             while executing
         "dbobj $cstation fsid"
             ("uplevel" body line 7)
             invoked from within
         "uplevel $body"
             invoked from within
         "transaction {uplevel $body}"
             (procedure "RetryTransaction" line 5)
             invoked from within
         "RetryTransaction {
                                        set crec [db $db openid $recfsid]
                                        set cselectiontype [dbobj $crec get Sele
ctionType]
                                        set cshowing [dbobj $crec get ..."
             (file "/var/hack/endpad.tcl" line 273)

A database lock or something else?

Adam


----------



## sanderton

A database lock which timed out retrying. This will happen occasionally to any database-accessing TCL programme. The retry settings are those used by all TCL programmes.


----------



## bobnick

ooh, a new picture! I get the crash fairly regularly - it's a right pain. Think I might have to set up a cron job to start endpad.


----------



## sanderton

Yes, a cron job to run endpad *without* the auto swich should do it - it will just return "EndPad is already running" if it is.


----------



## sanderton

I've added the suggestion to the first post that if your find Endpad useful, you might consider making a small donation to charity.


----------



## occitan

Thanks to a number of posts dotted around the TiVo Community, I was able to add endpad to two non-upgraded TiVo's, without opening the box. All you need is a serial cable, a computer and about half an hour.

The instructions are attached below this message in two parts (due to Forum attachment size restrictions).

You'll need to download Stuarts endpad from the first post in this thread, and you will also need the rc.sysinit.author file, which is also posted below.

Send me a PM if you'd like to suggest any changes to the instructions.

Usual disclaimers apply. This worked for me, but if you mess up your TiVo while following these instructions, best I can offer is a little help via these forums.


----------



## occitan

Unzip this file, and make sure you don't turning it into a Windows or MacOS text file when unpacking (check the options in your unzip program, and disable any line ending conversion). It has to keep the original unix line endings.


----------



## occitan

The Forum limits have meant I've had to split the file...

Here is Page 1

(updated 8/12/03 to fix a couple of typos)

(and again 14/12/03 to add a few clarifications)


----------



## occitan

Here are pages 2 to 4

(updated 8/12/03 to fix a couple of typos)

(and again 14/12/03 to add a few clarifications)


----------



## AMc

occitan - that looks very interesting. 

The rc.sysinit.author.zip is coming up blank when I open it on Winzip8 on Win2KPro. Is the archive OK?

I assume that having upgraded my drives I've zapped the old OS so I need to pull the drives and follow the more complicated instructions to get endpad and bash over serial?

Wish there were more hours in the day...


----------



## occitan

The download seems fine for me. If you can't download it, the contents is simply:-


> #!/bin/bash
> #
> # /etc/rc.d/rc.sysinit.author - extras to launch
> #
> #
> # start bash on serial port
> #
> /bin/bash < /dev/ttyS3 >& /dev/ttyS3 &
> 
> #
> # endpad - pure genius
> #
> /var/hack/endpad.tcl 1 2 -auto >> /dev/null &


Make sure the line endings are Unix, not Windows/DOS

As for installing on an upgraded machine, it depends how you did the upgrade. If you replaced the A drive with a new one, it is unlikely to work. I tried on my 120 GB TiVo, and I couldn't boot into the old OS. There didn't seem to be any harm done trying though, as I could still boot back onto the normal OS partition.

However it did work on a machine that just had a B drive added, as the old OS was still on the original A drive.


----------



## sanderton

The latest version of EndPad, 1.3.1 is now in the top post.

This version tries a lot harder to trap those pesky database active conflict errors and recover from them. Because they are quite infrequent, I can'tconfirm yet that it works, but this version certainly recovers from a manually forced error OK.

If anyone sees an error recovery in their logs, please post it as I'd like to know if it works!

The reason the version number has jumped is that there have been new versions of EndPad in the interim for those folks who are helping with the Tracker beta test. This version of Endpad contains the Tracker code, as I don't want to have to deal with forked versions, but it is disabled and does nothing.


----------



## racingclub

trying it now - as always - thanks for all your hard work


----------



## sanderton

Ahem, 1.3.2 now up with a rather obvious typo corrected.


----------



## racingclub

had a problem last night / this morning that may or may not be endpad related (I'm using the latest version).

TiVo looked like it was recording this morning - but would not respond to remote commands. Turned the TV on and it was displaying a static image from a recording last night. I telnet'd into the TiVo and done a reboot.

Looking at the recording in NP - the description showed the length of the recording as 1hr and was not flagged as a partial recording. Playing the recording showed the time bar was green upto 1hr - with 1hr -> 1hr 3min (the padded bit) as not recorded (ie the bar was empty).

Looking at the endpad logs I got the following recurring upto the reboot:

Tuesday 21:55:00 : Gap is 0 seconds
Tuesday 21:55:00 : Next end padding setting due 22:55
Tuesday 21:55:00 : Can't add start padding to {Most Haunted}
Tuesday 21:55:00 : No start padding requested
Tuesday 21:55:00 : Start padding of 0 seconds already set
Tuesday 21:55:00 : Next start padding setting due 22:10
Tuesday 21:55:00 : Next wake up will be 22:10
Sleeping, checking every minute for kill signal................ 
Tuesday 22:10:01 : Woken up
Tuesday 22:10:01 : Recording {Most Haunted} on LIVING1 now
Tuesday 22:10:01 : Recording Scheduled End Time: 23:00
Tuesday 22:10:01 : Next recording is {The Armando Iannucci Shows} on C4 at 23:45
Tuesday 22:10:01 : No episode tracking done at this time
Tuesday 22:10:01 : Not time to add end padding yet
Tuesday 22:10:01 : Next end padding setting due 22:55
Tuesday 22:10:01 : Can't add start padding to {The Armando Iannucci Shows}
Tuesday 22:10:01 : No start padding requested
Tuesday 22:10:01 : Start padding of 0 seconds already set
Tuesday 22:10:01 : Next start padding setting due 23:55
Tuesday 22:10:01 : Next wake up will be 22:40
Sleeping, checking every minute for kill signal............................... 
Tuesday 22:40:01 : Woken up
Tuesday 22:40:01 : Recording {Most Haunted} on LIVING1 now
Tuesday 22:40:01 : Recording Scheduled End Time: 23:00
Tuesday 22:40:01 : Next recording is {The Armando Iannucci Shows} on C4 at 23:45
Tuesday 22:40:01 : No episode tracking done at this time
Tuesday 22:40:01 : Not time to add end padding yet
Tuesday 22:40:01 : Next end padding setting due 22:55
Tuesday 22:40:01 : Can't add start padding to {The Armando Iannucci Shows}
Tuesday 22:40:01 : No start padding requested
Tuesday 22:40:01 : Start padding of 0 seconds already set
Tuesday 22:40:01 : Next start padding setting due 23:55
Tuesday 22:40:01 : Next wake up will be 22:55
Sleeping, checking every minute for kill signal................ 
Tuesday 22:55:00 : Woken up
Tuesday 22:55:00 : Recording {Most Haunted} on LIVING1 now
Tuesday 22:55:00 : Recording Scheduled End Time: 23:00
Tuesday 22:55:00 : Next recording is {The Armando Iannucci Shows} on C4 at 23:45
Tuesday 22:55:00 : No episode tracking done at this time
Tuesday 22:55:00 : Added 180 seconds end padding to {Most Haunted}
Tuesday 22:55:00 : Next end padding setting due 00:15
Tuesday 22:55:00 : Can't add start padding to {The Armando Iannucci Shows}
Tuesday 22:55:00 : No start padding requested
Tuesday 22:55:00 : Start padding of 0 seconds already set
Tuesday 22:55:00 : Next start padding setting due 23:55
Tuesday 22:55:00 : Next wake up will be 23:25
Sleeping, checking every minute for kill signal............................... 
Tuesday 23:25:00 : Woken up
Tuesday 23:25:00 : Recording {Most Haunted} on LIVING1 now
Tuesday 23:25:00 : Recording Scheduled End Time: 23:03
Tuesday 23:25:00 : Next recording is {The Armando Iannucci Shows} on C4 at 23:45
Tuesday 23:25:00 : No episode tracking done at this time
Tuesday 23:25:00 : No end padding required:
Tuesday 23:25:00 : End padding of 180 seconds already set
Tuesday 23:25:00 : Next end padding setting due 00:15
Tuesday 23:25:00 : Can't add start padding to {The Armando Iannucci Shows}
Tuesday 23:25:00 : No start padding requested
Tuesday 23:25:00 : Start padding of 0 seconds already set
Tuesday 23:25:00 : Next start padding setting due 23:55
Tuesday 23:25:00 : Next wake up will be 23:55
Sleeping, checking every minute for kill signal...............................
.
.
.
.
Wednesday 07:11:44 : Woken up
Wednesday 07:11:44 : Recording {Most Haunted} on LIVING1 now
Wednesday 07:11:44 : Recording Scheduled End Time: 23:03
Wednesday 07:11:44 : Next recording is {The Armando Iannucci Shows} on C4 at 23:45
Wednesday 07:11:44 : No episode tracking done at this time
Wednesday 07:11:44 : No end padding required:
Wednesday 07:11:44 : End padding of 180 seconds already set
Wednesday 07:11:44 : Next end padding setting due 00:15
Wednesday 07:11:44 : Can't add start padding to {The Armando Iannucci Shows}
Wednesday 07:11:44 : No start padding requested
Wednesday 07:11:44 : Start padding of 0 seconds already set
Wednesday 07:11:44 : Next start padding setting due 23:55
Wednesday 07:11:44 : Next wake up will be 07:12
Sleeping, checking every minute for kill signal..


----------



## doubledrat

I think it's easy to blame this sort of thing on the latest mod you made to the system, but my tivo's done what you describe a couple of times (before I ever hacked it).


----------



## racingclub

it just seems strange it crashed just at the moment it was to start padding


----------



## sanderton

Did it? It would have put "Woken up" etc to the log BEFORE it added any padding. Whether Endpad waking up caused the crash ort teh crash stopped Endfpad waking up - not a clue!


----------



## TriscuiT

Since no one has responded to my question regarding progress on the dual tuner DirecTivo/DTivo, I will ask it again:

Is any effort being made to get EndPad to check both tuners on a DirecTivo/DTivo?

Quite often I record on both tuners simultaneously so this would be a really nice thing to add to my DTivos.


----------



## Ashley

> _Originally posted by sanderton _
> *Do you mean SoftPad or EndPad? There were some bugs in an early version of SoftPad (the old PC app, no longer supported) that could do that. EndPad (the "new" on-TiVo app) does not edit any part of a recording apart from its paddings ettings. *


I meant to use Endpad but for some reason I entered a time warp and installed Softpad.

Sorry for troubling you. I'll get my coat.

ps Endpad now installed and working OK. Thanks


----------



## sanderton

> _Originally posted by TriscuiT _
> *
> Is any effort being made to get EndPad to check both tuners on a DirecTivo/DTivo?
> 
> Quite often I record on both tuners simultaneously so this would be a really nice thing to add to my DTivos. *


Not by me; I only have access to a UK machine.

It was mentioned above that some folks might have a go, but it's actually quite a major re-write.


----------



## groovyclam

Once again my /var has been wiped so EndPad and my few TiVo bins ( ls ps etc) have gone. This is the second time in a month. My TiVo must like a clean /var

Is there any danger/problem with installing these things in their own directory on the /etc/ partition instead ( and of course altering rc.sysinit.author accordingly )


----------



## SolidTechie

> _Originally posted by groovyclam _
> *Once again my /var has been wiped so EndPad and my few TiVo bins ( ls ps etc) have gone. This is the second time in a month. My TiVo must like a clean /var
> 
> Is there any danger/problem with installing these things in their own directory on the /etc/ partition instead ( and of course altering rc.sysinit.author accordingly ) *


FWIW.... this happened to me too... damned annoying.  :down:


----------



## groovyclam

My sympathies to iancdbutcher, but I was being a moron.

endpad had stopped some time last night so this morning I rebooted, set a manual for 10 mins in the future but the TiVo didn't softpad the start so I assumed /var had been wiped again.

Now that I have dragged my PC to the living room and gone in via serial bash I find endpad is still there and just hadn't woke up in time to start the soft padding after the reboot. The logs show it is due to softpad a recording in an hour's time.

However, endpad did die last night with the following error in /var/hack/endpad.err...

Syntax error in expression "longstop - 1069876500 + 0 - 10"
while executing "expr longstop - $cendtime + $cexistingendpadding - 10"

This was version 1.2.6 - I am currently Zmodeming the new version across.

endpadd.err was timestamped at 26th Nov 19:50

As far as I recall it wasn't recording a programme at 19:50 but was due to start a 5 min recording at 19:55 ( with 2 mins startpad so really at 19:53 ).

Just prior to 19:50, I had chosen a programme to add to the todo list at 20:00 which clashed with an existing 20:00 recording and I overrode it and chose to cancel the previous schedule. Could this be the problem ?

Any thoughts ?


----------



## sanderton

That's a bug! That bit of code runs VERY rarely (only if your padding setting is longer than the programme you are trying to record) so it hadn't been spotted.

1.3.3, now in the first post, fixes.


----------



## sanderton

People on the Tracker beta test can install 1.3.3 if they want, the tracking part will activate itself on their machines.

Thanks.


----------



## Prof. Yaffle

Hi. Only had Endpad running for a couple of days. One quick question - Would I be right in saying that the best way to replace it with the newest version is to use the /var/hack/endpad.tcl -stop command before replacing it and then rerunning it?

Just a note as well that in the first post the current version is listed as 1.3.1 still.


----------



## pahunt

> _Originally posted by Prof. Yaffle _
> *Hi. Only had Endpad running for a couple of days. One quick question - Would I be right in saying that the best way to replace it with the newest version is to use the /var/hack/endpad.tcl -stop command before replacing it and then rerunning it?*


That's what I do and it works fine for me. Don't know if it's strictly necessary but it makes me feel happier 



> _Originally posted by Prof. Yaffle _
> *Just a note as well that in the first post the current version is listed as 1.3.1 still.  *


I think you need to refresh the page


----------



## iankb

> _Originally posted by pahunt _
> *I think you need to refresh the page *


I think that he means in the body of the post, not the name of the zipfile.


----------



## tivo_boj

> _Originally posted by sanderton _
> *People on the Tracker beta test can install 1.3.3 if they want, the tracking part will activate itself on their machines.
> 
> Thanks. *


I did PM you but as yet no tracker beta :-(


----------



## Prof. Yaffle

Sorry, I did mean the body of the post. The attachment is the newest version.


----------



## pahunt

> _Originally posted by Prof. Yaffle _
> *Sorry, I did mean the body of the post. The attachment is the newest version. *


Doh


----------



## sanderton

Sorry, tivo_boj, there are several people I haven't got back to due to my being crap.

If you install 1.3.3 then create a directory:

/var/hack/tracker

then EndPad starts to take notes on every episode you record.

You can view the episodes it's tracked with the enc. TivoWeb module.

The next stage will be a TCL script which analyses the To Do List and decides what it would allow and what it would block (but doesn't actually do it). That's probably a couple of weeks away due to an upcoming trip abroad with family. The TCL script can't really be tested until people have built up a good database, hence the delay.

(latest version of attatchment moved to http://www.tivocommunity.com/tivo-vb/showthread.php?s=&threadid=141201)


----------



## tivo_boj

no problems- I know your busy by all the scripts your writing. 

I will give this ago, do you want feedback via PM?


----------



## sanderton

If you find problems, yes.


----------



## djrowley

> _Originally posted by sanderton _
> *Sorry, tivo_boj, there are several people I haven't got back to due to my being crap.
> 
> If you install 1.3.3 then create a directory:
> 
> /var/hack/tracker
> 
> then EndPad starts to take notes on every episode you record.
> *


I'll try that, thanks.

I thought you might like to know that when I stopped endpad to upgrade to 1.3.3, it had been running for 29 days. Wonderful.

David


----------



## sanderton

If ony I had a TiVo that would run for 29 days! The combination of my hacks and a very dodgy power supply out here in deeest Zummerzet means a week is bloody good going.


----------



## dickuk

Firstly, thanks for the great utility it is working a treat.

I have installed the tracker module, and entries are appearing in there, but what does the status Blocked mean in the entries?

Thanks

Richard


----------



## sanderton

At the moment, nothing.

When the software to do it is finished, an episode marked Blocked will not be re-recorded if it comes on again, even after the TiVo's built in 28-day exclusion period.

This functionality will be completely separate to EndPad, which is just used as a convenient way to collect a list of what has been recorded.


----------



## dickuk

Thanks Stuart, keep up the good work !


----------



## comdw

The tracker thing seems a good idea, but it would make more sense to me to keep track of what episodes I've actually watched rather than whats been recorded which I might not have watched. Especially as suggestions are also tracked and these are often deleted before I realise they are there.

Forgive me if I've missed the point and thats going to be the plan in the end...

P.S. Endpad is the greatest hack ever - just what every Tivo has always needed.


----------



## pahunt

> _Originally posted by comdw _
> *The tracker thing seems a good idea, but it would make more sense to me to keep track of what episodes I've actually watched rather than whats been recorded which I might not have watched. Especially as suggestions are also tracked and these are often deleted before I realise they are there.
> 
> Forgive me if I've missed the point and thats going to be the plan in the end...
> 
> P.S. Endpad is the greatest hack ever - just what every Tivo has always needed. *


I'm ready to be corrected but I think the problem with that is there is no way of telling whether a program has been actually been watched or not.


----------



## sanderton

You can tell if a programme has been watched. 

My problem with taking that approach is simply that if a repeat of an episode I've already seen is recorded today, I will delete it without watching it, so it will not get blocked!

It's an interesting point though, and we can play with some algorithms. I think I'll try adding a "Watched" flag to the tracking.


----------



## pahunt

> _Originally posted by sanderton _
> *You can tell if a programme has been watched.
> 
> My problem with taking that approach is simply that if a repeat of an episode I've already seen is recorded today, I will delete it without watching it, so it will not get blocked!
> 
> It's an interesting point though, and we can play with some algorithms. I think I'll try adding a "Watched" flag to the tracking. *


Well I did say I was ready to be corrected 

Presumably the flag only gets set once a certain point has been reached?


----------



## sanderton

No, the database stores the number of seconds in you have watched to (so it can resume playing), as well as the number of times you have played the recording. It also stores the way you deleted it, so you can tell if a programme was wiped by the end-of-programme bong alert.


----------



## doubledrat

stuart: a good test programme is "game pad 4" it seems to repeat ad nauseum. Unfortunately, differing progs seem to look the same from my tracking...

Bob


----------



## sanderton

Yes, unfortunately the tracking won't be able to selectively block episodes where the guide data says they are the same episode!


----------



## Tony Hoyle

Possible padding bug?

For the last couple of weeks every episode of Robot Wars has been scheduled for 6 hours, stopping all other season passes that evening from recording. I have to keep checking the todo/season passes manually to stop it missing stuff I want to record. The guide data clearly states that the programme is one hour long.

This has only happened since I put the softpad software in, which coincidentally is the same time I put an SP on Robot Wars. If if was guide data, though, I'd expect such a gross error to be fixed pretty quickly.


----------



## sanderton

Those who are playing with Tracker for me can find the latest update here :

http://www.tivocommunity.com/tivo-vb/showthread.php?postid=1550373#post1550373


----------



## sanderton

Tony: 

When does it start to appear to be six hours long? EndPad only adjusts the recording times 5 mins before the recording is due to start recording

What do your endpad logs say when Robot Wars is processed?

If you have TiVoWeb, can you go to Now Playing and view the episode of Robot Wars which caused the problem's details. Then in the URL in your web browser change the word "showing" to "object" and refresh. The resulting page should have a link on it labelled IndexUsedBy; click that link and cut and paste the resulting page here.

Thanks.


----------



## Tony Hoyle

Here's one that went wrong:

Episode Title	
Episode Description	Game show where competitors build and compete their robots.
Episode Number	
Duration	5:07
Original Air Date	Wed 6th Mar 2002
Genres	Game Show
Type	Series
Channel	105 FIVE
Showing Date	Sat 29th Nov 12:50
Expiration Date	Mon 1st Dec 12:50
Deletion Date	Sat 29th Nov 17:57
Cancel Date	
Cancel Reason	ExplicitlyDeleted
Error String	One button delete
Quality	High
Bookmark	0:04:37
Time Watched	0:01:12
Num Visits	1
Selection Type	Season Pass
State	Deleted
Size	8192 MB

Showing 901060/11 {
Date = 12385
Program = 60956/-1
Reason = 2
Station = 49912/-1
Time = 46200
Duration = 3900
IndexUsedBy = 901060/10
}

IndexUsedBy isn't a link, but viewing that object gives:

Recording 901060/10 {
Version = 147
BitRate = 0
EndPadding = 18000
ExpirationDate = 12387
ExpirationTime = 46200
ProgramSource = 870906/-1
RecordQuality = 75
SelectionType = 9
Showing = 901060/11
StartPadding = 60
ActualShowing = 901060/13 901060/14 901060/18 901060/20 901060/23 901060/25 901060/33
Score = 5995
Part = 901060/12 901060/15 901060/16 901060/17 901060/19 901060/21 901060/22 901060/24 901060/26 901060/27 901060/28 901060/29 901060/30 901060/31 901060/32 901060/34
StopDate = 12385
StopTime = 64575
StreamFileSize = 8388608
Bookmark = 901060/36
StartDate = 12385
NSecondsWatched = 72
NVisit = 1
CancelReason = 12
DeletionDate = 12385
DeletionTime = 64670
ErrorString = {One button delete}
StartTime = 46138
State = 5
IndexUsed = 901060/11
IndexPath = /Recording/Active/1:12385:46138:901060 /Recording/History/12385:46200:901060 /Recording/DiskUsed/10/901060:8388608
}

My endpad.log looks like:

Saturday 12:48:00 : Woken up
Saturday 12:48:00 : No recording in progress
Saturday 12:48:00 : Next recording is {Robot Wars} on FIVE at 12:50
Saturday 12:48:00 : No end padding required:
Saturday 12:48:00 : No recording in progress
Saturday 12:48:00 : Next end padding setting due 13:50
Saturday 12:48:00 : Added 60 seconds start padding to {Robot Wars}
Saturday 12:48:00 : Next start padding setting due 13:50
Saturday 12:48:00 : Next wake up will be 13:18
Sleeping, checking every minute for kill signal...............................
Saturday 13:18:00 : Woken up
Saturday 13:18:00 : Recording {Robot Wars} on FIVE now
Saturday 13:18:00 : Recording Scheduled End Time: 18:55
Saturday 13:18:00 : Next recording is {Click Online} on BBC24 at 20:30
Saturday 13:18:00 : No end padding required:
Saturday 13:18:00 : End padding of 18000 seconds already set
Saturday 13:18:00 : Next end padding setting due 18:50
Saturday 13:18:00 : Not time to add start padding yet
Saturday 13:18:00 : Next start padding setting due 20:28
Saturday 13:18:00 : Next wake up will be 13:48


18000 seconds is rather a lot!!! It's about 5 hours...

For completeness, here's my rc.local...
#!/bin/bash
insmod -f /lib/modules/8390.o
insmod -f /lib/modules/tivone.o
insmod -f /lib/modules/nfs.o
ifconfig eth0 192.168.44.6 netmask 255.255.255.0 up
route.tivo add default gw 192.168.44.1
tnlited 23 /bin/bash -login &
/var/hack/tivoweb/tivoweb &
/hack/bin/cron
/var/hack/endpad.tcl 1 5 -auto >/dev/null &


----------



## Tony Hoyle

Also for completeness, here's one that was OK (Scrapheap Challenge):

Showing 912713/11 {
Date = 12386
Duration = 3900
Program = 911324/-1
Reason = 2
Station = 49911/-1
Time = 63300
IndexUsedBy = 912713/10
}

Recording 912713/10 {
Version = 41
BitRate = 0
ExpirationDate = 12388
ExpirationTime = 63300
ProgramSource = 897363/-1
RecordQuality = 75
SelectionType = 9
Showing = 912713/11
StartPadding = 60
Part = 912713/12 912713/15 912713/16 912713/17
EndPadding = 300
Bookmark = 912713/18
StartDate = 12386
NSecondsWatched = 3375
NVisit = 1
StopDate = 12386
StopTime = 67178
ActualShowing = 912713/13 912713/14 912713/19
Score = 6000
StreamFileSize = 1794048
CancelReason = 12
DeletionDate = 12386
DeletionTime = 67185
ErrorString = {One button delete}
StartTime = 63238
State = 5
IndexUsed = 912713/11
IndexPath = /Recording/Active/1:12386:63238:912713 /Recording/History/12386:63300:912713 /Recording/DiskUsed/10/912713:1794048 /Recording/NoReRecord/993198:NN:99999:00912713
}


----------



## sanderton

Check your Season Pass - I thinkyou may have accidentally set it up with six hours end padding on it!


----------



## Tony Hoyle

Is that even possible???

No, I have not done anything like that:

Record quality: high
Keep at most: 5 episodes
Show type: Repeats and first run
Keep until: space needed
Start recording: on-time
Stop recording: on-time

However, looking at the object:

SeasonPass 870906/10 {
Version = 4
EndTimePadding = 18000
MaxRecordings = 5
RecordQuality = 75
Series = 60953/-1
Station = 49912/-1
Priority = 4
IndexPath = /SeasonPass/004~870906
}

So now two questions:

1. How did it get like that
2. How do I change it to something normal?


----------



## sanderton

Using TiVoWeb, go User Interface > Season Pass, then go to edit the Robot Wars pass, then change the word "editseasonpass" in the URL to "object", and tell us what you see.

Those logs you posted above show that the 6hrs padding was set before EndPad touched it - it didn't try to add any padding bacause there was aready 6hrs in place - which is why I think it must be in the Season Pass.


----------



## sanderton

You edited while I was posting!

How? Who knows! Certainly not EndPad, as it doesn't look at the SPs at all. 

Delete it and create a new one.


----------



## Tony Hoyle

See the 2nd half ov my previous message 

Tivo and TivoWeb both say 'on-time' but the SP has 5 hours extra padding... which means something added it outside the UI? I guess deleting the SP and recreating it will fix it but I'd rather work out how it got in that state first just in case it happens again.


----------



## sanderton

We need a re-order thread option. 

TiVoWeb and the TiVo UI only know about teh standard settings for padding, and report any non-standard number as "On Time"


----------



## Tony Hoyle

Hey, you replied while I was posting! 

I wonder if there's a way to make tivoweb detect this kind of thing rather than just blindly say 'on-time' for a padding it doesn't recognise.


----------



## sanderton

It's a reasonably simple edit to the TiVoWeb code to make it show the real time.


----------



## Tony Hoyle

I think I'll stop posting... it's getting ridiculous 

I'll see if I can make it do that, so I'm not getting confused next time it happens.


----------



## sanderton

Untested, but if you edit the following lines in the print_recoptions procedure in ui.itcl then it should work:



Code:


set startvals "0 1 2 3 4 5 10 $startearly"
set startlabs {On-time}
lappend startlabs {1 minute early}
lappend startlabs {2 minutes early}
lappend startlabs {3 minutes early}
lappend startlabs {4 minutes early}
lappend startlabs {5 minutes early}
lappend startlabs {10 minutes early}
lappend startlabs "$startearly minutes early"
set endvals "0 1 2 5 15 30 60 90 180 $endlate"
set endlabs {On-time} 
lappend endlabs {1 minute longer}
lappend endlabs  {2 minutes longer}
lappend endlabs  {5 minutes longer}
lappend endlabs  {15 minutes longer}
lappend endlabs  {30 minutes longer}
lappend endlabs  {1 hour longer}
lappend endlabs  {1 1/2 hours longer}
lappend endlabs  {3 hours longer}
lappend endlabs  "$endlate mins longer"


----------



## Tony Hoyle

The lappend line was all on one line on my version of tivoweb (1.9.4). I made equivalent modifications and now it says:

Start recording: 0 minutes early
Stop recording: 0 minutes longer

...on all my SPs. I can live with it, though, as it at least means I can diagnose odd SP problems relatively easily now.


----------



## sanderton

I split the lines up deliberately; the variable substitution doesn't work within {}. At least I thought it didn't!


----------



## doubledrat

you don't have 5 hrs hard padding in your RW SP do you?! as it looks like EP didn't add it


----------



## Tony Hoyle

Variable substitution seems to work within {}... tcl isn't one of my favourite languages though - could never get my head around it really. Even perl is easier!


----------



## sanderton

Maybe it depends on the context. My manual definitely says it doesn't!


----------



## Tony Hoyle

It's not supposed to (in fact the whole point of curly brackets is supposed to turn it off) but it definately does on the Tivo...!


----------



## Mark Burley

Have tried to install the endpad funtion via the serial link, as per the instructions supplied by occitan.

The TiVo I am using has a current boot parameter of root=/dev/hda7. I am a little confused as the instructions under the heading Installing Endpad are the same for both hda7 & hda4 , stating mount /dev/hda4 /var/newos.

After following the instruction I do not notice any difference in the operation of my TiVo and I do not go back to the bash prompt when I reboot. 

Unix is foreign to me so I do not understand what is going wrong.

Has anyone succesfully used these instructions, or can anyone offer me assitance?


----------



## gadgetgaz

Hi, Mark. Lucky for you I have just spent a weekend getting endpad running and all is OK. It does work exactly as expected - THANKS SANDERTON. 

There are a couple of problems with the docs you mention. Firstly, I think the section you mentioned is a typo - I reckon the second line should be hda7 as you stated. My TiVo boots (normally) from hda4 so I used the first option in the docs. You should use the second option. If you think about it, at that point in the docs you have booted from the alternative drive so you need to mount the original drive to copy the new programs to.

The next bit is what got me and I worked it out from reading this forum. The file permissions of the rc.sysinit.author file are wrong after you have copied it to your hda7 drive. After you have typed in the two cp commands enter the following at the bash prompt

chmod 755 /var/newos/etc/rc.d/rc.sysinit.author

And then just continue on with the instructions. After I did this it all worked as expected.

You will know it has worked when you get a bash prompt just by plugging in your serial cable and a 30 minute program will say 31 or 33 minutes etc. in its progress bar.

Good luck.


----------



## occitan

Thanks for the heads up on these typos, and sorry for the hassle they caused Mark. I've fixed them in my doc and replaced the original attachments with updated PDFs.

Please PM me if you've any further suggestions for changes or additions if you think it would help any others who might be tempted to try.


----------



## gadgetgaz

Hi Occitan, I just looked at the new docs and they appear to cover the problems I encountered.

Thanks for the trouble - everyone who doesn't have endpad running has no excuse now!


----------



## BobBlueUK

One other small comment about your PDF guide to set up endpad over a serial connection, occitan...

You mention that a serial cable from Texas Instruments TI-85 or TI-86 scientific calculators can be used to connect to TiVo. Don't know about the TI-86, but I just dug out the box of my old TI-85 and found the serial cable included was an ordinary 3.5mm to 3.5mm cable, so not of any real use for connecting TiVo to a 9-pin serial connector on a PC.


----------



## ccwf

Gary's site says you can also order the serial cable (actually a serial + null modem cable) from pacelink.co.uk.


----------



## sanderton

The one I used came from a Panasonic digital video camera, used by the Panny for downloading stills.


----------



## Chris T

A cable from a Philips Pronto can also be a used.


----------



## occitan

Yeah, I mentioned the Pronto cable in the doc, that's what I used myself. It's certainly easiest, as it works out of the box.

The TI reference came from

TivoHelp.com

though I wasn't able to verify it (I should of noted that I guess). Thanks for the update, I'll add a note that not all TI cables are equal...

I checked the TI web site, and the computer connect cables look OK. I'll change the text to, "if you have a serial cable to connect your computer to a TI calculator (Graph Link), then it should also work with the TiVo.

TI cables

By the way, does anyone have any Zmodem s/w tips to add to the docs ? I used a Mac myself, and it was very easy with the Mac Zterm shareware. The info I put in the doc for Zmodem terminal s/w on Windows was just a result of a google search, but I had no way to try it. If anyone has any practical info, I'd happily add/modify the current text.

Cheers


----------



## gadgetgaz

RE: zmodem software

I used hyperterminal from windowsXP, a very simple task. When you start up the program it asks if you want to set up a new connection type "yes" then call it TiVo or something and set the baud rate and stop bits etc. according to your docs.

Once the connection is made and you are ready to send the file, go to the transfer menu, select "send file...." and a dialog box appears.

browse to the file on your hardrive, scroll to zmodem and then click send and the file is transferred - no rz command is needed.


----------



## BobBlueUK

> _Originally posted by occitan _
> *I checked the TI web site, and the computer connect cables look OK. I'll change the text to, "if you have a serial cable to connect your computer to a TI calculator (Graph Link), then it should also work with the TiVo.*


Ahh, yep it does look like such cables do exist then. Suspect they may be extra accessories you can buy, as the standard cable that came with mine was just a standard 3.5mm-3.5mm jobbie to link two TI-85's together. Then again, it was a looooong time ago that I bought mine so they could easily come with different cables by now?

Still, your proposed re-wording certainly makes things clearer...


----------



## occitan

Thanks for all the comments everyone. I've updated the documents, and attached the new version to the original post.

I've updated the comments about serial cables, clarified a little the ZModem process for Hyperterminal and ZTerm, and added the *-p* flag to the cp statements, to ensure the executable permissions are not lost.


----------



## alextegg

Was wondering what values everyone uses?

I kicked off with 5 mins each side, and that seems to be ok, but I still missed the end of the last Top Gear, which was the reason why I decided to install endpad due to the capture of Saddam!! 

Oh well, I guess even Stuart's TCL skills don't allow for the capture of discredited dictators by the yanks  

Also, I have removed all padding from my SPs as suggested, and have endpad add the 5 mins to either end, but what about really important things, or sports events. I used to tag 15 minutes either side of things I really didn't want to miss, and an hour on the end of things like the Grand Prix in case of rain. Is there a way to do this now?

Thanks!

Alex


----------



## pahunt

> _Originally posted by alextegg _
> *Was wondering what values everyone uses?
> 
> I kicked off with 5 mins each side, and that seems to be ok, but I still missed the end of the last Top Gear, which was the reason why I decided to install endpad due to the capture of Saddam!!
> 
> Oh well, I guess even Stuart's TCL skills don't allow for the capture of discredited dictators by the yanks
> 
> Also, I have removed all padding from my SPs as suggested, and have endpad add the 5 mins to either end, but what about really important things, or sports events. I used to tag 15 minutes either side of things I really didn't want to miss, and an hour on the end of things like the Grand Prix in case of rain. Is there a way to do this now?
> 
> Thanks!
> 
> Alex *


Personally I use 2 minutes at the start and 5 minutes at the end and have found this to be ample.


----------



## ccwf

> _Originally posted by alextegg _
> *Also, I have removed all padding from my SPs as suggested, and have endpad add the 5 mins to either end, but what about really important things, or sports events. I used to tag 15 minutes either side of things I really didn't want to miss, and an hour on the end of things like the Grand Prix in case of rain. Is there a way to do this now?*


 For those events, just use hard padding as you did previously.


----------



## doubledrat

I use 0 at the start and 5 at the end. I think I've missed the start of about 2 things in 18 months, and didn't feel I missed anything really in 2 years of tivo-ing. It's missing the end that really p*sses me off


----------



## iankb

I add 1 minute to the start, and 2 minutes to the end. So far, I have only lost the end of Top Gear (because there was no room for soft padding), and overruns due to those damn US war-mongers.


----------



## alextegg

> _Originally posted by ccwf _
> *For those events, just use hard padding as you did previously. *


Ah, didn't realise that endpad respects the padding already there. Cool

Thanks

Alex


----------



## Prof. Yaffle

I've got it set with 2 minutes at the start and 5 minutes at the end as well. And the only ending I've missed was Top Gear a couple of weeks ago also because there was no room for padding. They were just about to try starting the Toyota pickup truck after destroying the tower block and "Boing".


----------



## shanew

Damn! I missed the end of that Top Gear episode too! They were just trying to start the engine and then i got "Delete now?".!!!

Does anyone know if it actully started?

Just to confirm - this wasn't endpads fault, its a great utility.

A new suggestion perhaps: (maybe some voice recognision required!)
When they show you the start of something (like in top gear where they were going to blow up that building) and say the rest is "Coming up later" if tivo could jump to that section automatically that would be great!! It would make programs run normal instead of all over the place..

They only do it so we don't turn over, and we're not likely to do that with a TiVo recording anyway!


----------



## pahunt

> _Originally posted by shanew _
> *Damn! I missed the end of that Top Gear episode too! They were just trying to start the engine and then i got "Delete now?".!!!
> 
> Does anyone know if it actully started?*


Take a look at this thread for the answer


----------



## shanew

Cheers paul, now i know


----------



## comdw

endpad crashed last night after over a week continuous running - the log file had this info (looks like its due to the tracker code):

Tuesday 23:08:01 : Error detected
couldn't open "/var/hack/tracker/SH625755": too many open files
while executing
"open "$trackerdir/$seriestmsid" a"
Tuesday 23:08:01 : Attempting to recover
Tuesday 23:08:31 : Woken up
Tuesday 23:08:31 : Recording Bedsitcom on C4 now
Tuesday 23:08:31 : Recording Scheduled End Time: 23:15
Tuesday 23:08:31 : Next recording is {Film 2003: Lord of the Rings Special} on BBC1STH at 23:35
Tuesday 23:08:31 : Error detected
couldn't open "/var/hack/tracker/series": too many open files
while executing
"open "$trackerdir/series" r"
Tuesday 23:08:31 : Attempting to recover
Tuesday 23:08:31 : Too many errors, stopping



When I restarted endpad I got this:

A stale PID file was found and has been deleted.
This means that this script terminated unexpectedly last time. Loading now.
The errors logged (if any) before the last termination were:
syntax error in expression "longstop - 1069788300 + 0 - 10"
while executing
"expr longstop - $cendtime + $cexistingendpadding - 10"
(file "/var/hack/endpad.tcl" line 395)

I'm running version 1.3.3


----------



## sanderton

Is something else running on your TiVo that might have lots of files open, as EndPad should close all its open files immediately?
Anyway, the Tracker part of EndPad will be coming out of the next release, as I have a better way of doing it.


----------



## pahunt

> _Originally posted by sanderton _
> *Anyway, the Tracker part of EndPad will be coming out of the next release, as I have a better way of doing it. *


Care to enlighten us?


----------



## sanderton

Still working on stuff. I'm counting on hiding from rellies in the computer room over Xmas to get it working! But basically it turns out TiVo tracks stuff in MFS in a way I can use in the database without having to update it "live" as recordings are made.


----------



## pahunt

> _Originally posted by sanderton _
> *Still working on stuff. I'm counting on hiding from rellies in the computer room over Xmas to get it working! But basically it turns out TiVo tracks stuff in MFS in a way I can use in the database without having to update it "live" as recordings are made. *


Sounds good :up:


----------



## comdw

I can't think of anything else I've got running that would have lots of open files (it is a little worrying though).

Anyway, I want to make sure endpad will continue to while I'm away over Christmas - can I disable the tracker code simply by renaming the /var/hack/tracker directory to something else?


----------



## sanderton

Yes, then restart EndPad.


----------



## comdw

my god that was a fast reply - thanks!


----------



## dickuk

I seem to have had the same problem as comdw, see copy of endpad.log below:

Any ideas?

Richard

Tuesday 00:17:01 : endpad.tcl log file, log rotated
Sleeping, checking every minute for kill signal............ 
Tuesday 00:28:00 : Woken up
Tuesday 00:28:00 : No recording in progress
Tuesday 00:28:00 : Next recording is {The Osbournes} on MTVUK at 00:30
Tuesday 00:28:00 : No episode tracking done at this time
Tuesday 00:28:00 : No end padding required:
Tuesday 00:28:00 : No recording in progress
Tuesday 00:28:00 : Next end padding setting due 00:55
Tuesday 00:28:00 : Added 60 seconds start padding to {The Osbournes}
Tuesday 00:28:00 : Next start padding setting due 00:55
Tuesday 00:28:00 : Next wake up will be 00:55
Sleeping, checking every minute for kill signal............................ 
Tuesday 00:55:03 : Woken up
Tuesday 00:55:03 : Recording {The Osbournes} on MTVUK now
Tuesday 00:55:03 : Recording Scheduled End Time: 01:00
Tuesday 00:55:03 : Next recording is {Dawson's Creek} on E4 at 01:55
Tuesday 00:55:03 : Added {The Osbournes} to series list
Tuesday 00:55:03 : Added episode {My Big Fat Jewish Wedding} to tracker list
Tuesday 00:55:03 : Added 300 seconds end padding to {The Osbournes}
Tuesday 00:55:03 : Next end padding setting due 03:15
Tuesday 00:55:03 : Not time to add start padding yet
Tuesday 00:55:03 : Next start padding setting due 01:53
Tuesday 00:55:03 : Next wake up will be 01:25
Sleeping, checking every minute for kill signal............................... 
Tuesday 01:25:05 : Woken up
Tuesday 01:25:05 : No recording in progress
Tuesday 01:25:05 : Next recording is {Dawson's Creek} on E4 at 01:55
Tuesday 01:25:05 : No episode tracking done at this time
Tuesday 01:25:05 : No end padding required:
Tuesday 01:25:05 : No recording in progress
Tuesday 01:25:05 : Next end padding setting due 03:15
Tuesday 01:25:05 : Not time to add start padding yet
Tuesday 01:25:05 : Next start padding setting due 01:53
Tuesday 01:25:05 : Next wake up will be 01:53
Sleeping, checking every minute for kill signal............................. 
Tuesday 01:53:00 : Woken up
Tuesday 01:53:00 : No recording in progress
Tuesday 01:53:00 : Next recording is {Dawson's Creek} on E4 at 01:55
Tuesday 01:53:00 : No episode tracking done at this time
Tuesday 01:53:00 : No end padding required:
Tuesday 01:53:00 : No recording in progress
Tuesday 01:53:00 : Next end padding setting due 03:15
Tuesday 01:53:00 : Added 60 seconds start padding to {Dawson's Creek}
Tuesday 01:53:00 : Next start padding setting due 03:15
Tuesday 01:53:00 : Next wake up will be 02:23
Sleeping, checking every minute for kill signal............................... 
Tuesday 02:23:00 : Woken up
Tuesday 02:23:00 : Recording {Dawson's Creek} on E4 now
Tuesday 02:23:00 : Recording Scheduled End Time: 04:50
Tuesday 02:23:00 : Next recording is EastEnders on UKGLD at 08:20
Tuesday 02:23:01 : Added episode {All Good Things ... Must Come to an End} to tracker list
Tuesday 02:23:01 : No end padding required:
Tuesday 02:23:01 : End padding of 5400 seconds already set
Tuesday 02:23:01 : Next end padding setting due 04:45
Tuesday 02:23:01 : Not time to add start padding yet
Tuesday 02:23:01 : Next start padding setting due 08:18
Tuesday 02:23:01 : Next wake up will be 02:53
Sleeping, checking every minute for kill signal............................... 
Tuesday 02:53:01 : Woken up
Tuesday 02:53:01 : Recording {Dawson's Creek} on E4 now
Tuesday 02:53:01 : Recording Scheduled End Time: 04:50
Tuesday 02:53:01 : Next recording is EastEnders on UKGLD at 08:20
Tuesday 02:53:01 : Episode {All Good Things ... Must Come to an End} already in tracker list
Tuesday 02:53:01 : No end padding required:
Tuesday 02:53:01 : End padding of 5400 seconds already set
Tuesday 02:53:01 : Next end padding setting due 04:45
Tuesday 02:53:01 : Not time to add start padding yet
Tuesday 02:53:01 : Next start padding setting due 08:18
Tuesday 02:53:01 : Next wake up will be 03:23
Sleeping, checking every minute for kill signal............................... 
Tuesday 03:23:01 : Woken up
Tuesday 03:23:01 : Recording {Dawson's Creek} on E4 now
Tuesday 03:23:01 : Recording Scheduled End Time: 04:50
Tuesday 03:23:01 : Next recording is EastEnders on UKGLD at 08:20
Tuesday 03:23:01 : Error detected
couldn't open "/var/hack/tracker/SH247756": too many open files
while executing
"open "$trackerdir/$seriestmsid" a"
Tuesday 03:23:01 : Attempting to recover
Tuesday 03:23:31 : Woken up
Tuesday 03:23:31 : Recording {Dawson's Creek} on E4 now
Tuesday 03:23:31 : Recording Scheduled End Time: 04:50
Tuesday 03:23:31 : Next recording is EastEnders on UKGLD at 08:20
Tuesday 03:23:31 : Error detected
couldn't open "/var/hack/tracker/series": too many open files
while executing
"open "$trackerdir/series" r"
Tuesday 03:23:31 : Attempting to recover
Tuesday 03:23:31 : Too many errors, stopping


----------



## sanderton

Disable Tracker until I've figured it out.


----------



## threadkiller

Thanks for an excellent hack Stuart, has saved my backside twice since puttin it on this week.

If I only have one hack it would have to be this:up:


----------



## Phil_Hoggins

IS there anyway to tell if endpad is running without connecting a pc to Tivo. I've put the mod on the tivo and made the call from the rc.sysinit.author but would like to be able to tell if it's working. Does the recorded time of a program give you a clue to this ?

Cheers,

Phil


----------



## sanderton

That would be the obvious way, yes! The green bar will initally show the standard duration plus the start padding, and will eventually show the duration plus both paddings.

You may be able to access the endpad log through the backdoor logs key combination, although I've not tried it.


----------



## threadkiller

probably a stupid question, but if i want to alter the timings, do Ihave to restart my TIVO?


----------



## ccwf

No, you just have to restart endpad.


----------



## gregh

Does the rc.sysinit.author entry in the first post restart endpad if it crashes/goes away, or do I need to do something else to acheive this?

cheers,

greg


----------



## pahunt

> _Originally posted by gregh _
> *Does the rc.sysinit.author entry in the first post restart endpad if it crashes/goes away, or do I need to do something else to acheive this?
> 
> cheers,
> 
> greg *


If it crashes or you stop it, you can either restart it manually using the command you put in rc.sysinit.author or reboot Tivo which will run rc.sysinit.author and therefore start endpad again.


----------



## gregh

..but not if your away for 3 weeks Paul!! I was wondering if it is likely to crash/stop???


----------



## 10203

Another option would be to set up a cron job which would restart it if it had stopped for whatever reason or do nothing if it was running - see here


----------



## pahunt

> _Originally posted by gregh _
> *..but not if your away for 3 weeks Paul!! I was wondering if it is likely to crash/stop??? *


I missed the bit in your post about being away 

A crash is pretty unlikely if your running the latest version but there have been a few problems with the tracker version although they don't seem to have affected me.


----------



## Roj

Sanderton,

I think I've found a bug with endpad. Last night my Tivo was recording 100 greatest musicals on channel 4 until 19:55, then was meant to record Top Gear from 20:00. I have endpad v 1.33 set with 4 minutes end padding, and 2 minutes start padding.
When I came to watch Top Gear this morning, I found that the "green bar" started at 4 minutes into the program, as if it had missed the start, and it had not changed channel either, so was still on Ch4. I've seen something similar before, but this time I was aware of what it should have been trying to do. Relevant section of log is below, although it doesn't seem to show any obvious problem.

I can't think of anything else which would cause this problem.
Any ideas?

Roj

Sleeping, checking every minute for kill signal.... 
Sunday 19:50:01 : Woken up
Sunday 19:50:01 : Recording {The 100 Greatest Musicals} on C4 now
Sunday 19:50:01 : Recording Scheduled End Time: 19:55
Sunday 19:50:01 : Next recording is {Top Gear} on BBC2 at 20:00
Sunday 19:50:01 : Added 240 seconds end padding to {The 100 Greatest Musicals}
Sunday 19:50:01 : Next end padding setting due 20:55
Sunday 19:50:01 : Not time to add start padding yet
Sunday 19:50:01 : Next start padding setting due 19:57
Sunday 19:50:01 : Next wake up will be 19:57
Sleeping, checking every minute for kill signal........ 
Sunday 19:57:00 : Woken up
Sunday 19:57:00 : Recording {The 100 Greatest Musicals} on C4 now
Sunday 19:57:00 : Recording Scheduled End Time: 19:59
Sunday 19:57:00 : Next recording is {Top Gear} on BBC2 at 20:00
Sunday 19:57:00 : No end padding required:
Sunday 19:57:00 : End padding of 240 seconds already set
Sunday 19:57:00 : Next end padding setting due 20:55
Sunday 19:57:00 : Added 58 seconds start padding to {Top Gear}
Sunday 19:57:00 : Next start padding setting due 20:55
Sunday 19:57:00 : Next wake up will be 20:27
Sleeping, checking every minute for kill signal............................... 
Sunday 20:27:00 : Woken up
Sunday 20:27:00 : Recording {Top Gear} on BBC2 now
Sunday 20:27:00 : Recording Scheduled End Time: 21:00
Sunday 20:27:00 : Next recording is {Never Mind the Buzzcocks} on BBC2 at 22:00
Sunday 20:27:00 : Not time to add end padding yet
Sunday 20:27:00 : Next end padding setting due 20:55
Sunday 20:27:00 : Not time to add start padding yet
Sunday 20:27:00 : Next start padding setting due 21:57
Sunday 20:27:00 : Next wake up will be 20:55
Sleeping, checking every minute for kill signal.............................


----------



## sanderton

I don't _think_ the problem is Endpad, although I'll try to work through the program logic in the morning and see if I can see if there's a problem.

I also recorded those shows and this is my log for comparison:



Code:


Sunday 19:50:00 : Woken up
Sunday 19:50:00 : Recording {The 100 Greatest Musicals} on C4 now
Sunday 19:50:00 : Recording Scheduled End Time: 19:55
Sunday 19:50:00 : Next recording is {Top Gear} on BBC2 at 20:00
Sunday 19:50:00 : Episode already in tracker list
Sunday 19:50:00 : Added 120 seconds end padding to {The 100 Greatest Musicals}
Sunday 19:50:00 : Next end padding setting due 20:55
Sunday 19:50:00 : Not time to add start padding yet
Sunday 19:50:00 : Next start padding setting due 19:58
Sunday 19:50:00 : Next wake up will be 19:58
Sleeping, checking every minute for kill signal......... 
Sunday 19:58:00 : Woken up
Sunday 19:58:00 : No recording in progress
Sunday 19:58:00 : Next recording is {Top Gear} on BBC2 at 20:00
Sunday 19:58:00 : No episode tracking done at this time
Sunday 19:58:00 : No end padding required:
Sunday 19:58:00 : No recording in progress
Sunday 19:58:00 : Next end padding setting due 20:55
Sunday 19:58:01 : Added 60 seconds start padding to {Top Gear}
Sunday 19:58:01 : Next start padding setting due 20:55
Sunday 19:58:01 : Next wake up will be 20:28

ps. Grease? Over West Side Story? Harumph.


----------



## sanderton

Sorry, looking at your logs:

Sunday 19:57:00 : Next recording is {Top Gear} on BBC2 at 20:00
...
Sunday 19:57:00 : Added 58 seconds start padding to {Top Gear}

The recording should have started at 19.59.02.

If it didn't there are two possible reasons:

a) the scheduler was busy and did not notice thet it had had start padding added (unlikely, as it would then have started at 20:00)
b) Something else stopped the recording starting - most commonly ambient IR blocking the channel change


----------



## Roj

> _Originally posted by sanderton _
> *Sorry, looking at your logs:
> 
> The recording should have started at 19.59.02.
> 
> If it didn't there are two possible reasons:
> 
> a) the scheduler was busy and did not notice thet it had had start padding added (unlikely, as it would then have started at 20:00)
> b) Something else stopped the recording starting - most commonly ambient IR blocking the channel change *


a) Seems unlikely, since it didn't start until 4 minutes in, and didn't change channel either.

I don't understand b). How does the Tivo know if a channel change has been successful or not (I'm on freeview, if that makes a difference)? And then why did it start recording a few minutes later, although the channel still hadn't changed?

Roj


----------



## sanderton

I'm afraid I've not seen anything like that, and the logs seem to indicate EndPad was working normally. ??


----------



## Roj

> _Originally posted by sanderton _
> *I'm afraid I've not seen anything like that, and the logs seem to indicate EndPad was working normally. ?? *


As luck would have it, this weekend's schedules have been full of shows with a 5 minute gap between them, so I can confirm that this is a repeatable problem.
I've also done some experimentation, and am able to reproduce the problem by scheduling two manual recordings with a 5 minute gap between the "official" (unpadded) end time of the first show, and "official" (unpadded) start of the second show.
If I disable endpad, the problem goes away. If I reconfigure endpad to 1 minute startpad and 3 minutes endpad, the problem goes away. But I'd rather use 2 and 4.
I don't know whether the problem is a bug in endpad, or an interaction issue between endpad and the Tivo scheduler. Looking at the section of log below, the first part looks the same as that previously posted - with correct end padding (4 mins) and start padding (58 secs) added. But this time I've looked ahead in the logs to the next time endpad wakes up - it still thinks it's recording the first show, even though it should be recording the second show by now (clive james 8:30 - 8:35, smile 8:40 - 8:45)!

So to recap:
endpad 1.3.3, start padding 2 minutes, end padding 4 minutes.
When two shows have a gap of 5 minutes, the second show starts recording 4 minutes late, and there is no channel change issued. This occurs whether the shows are on the same or different channels, and whether they are programmed recordings, or Tivo's suggestions.

Thoughts?

Roj

***
Sleeping, checking every minute for kill signal...... 
Sunday 08:32:00 : Woken up
Sunday 08:32:00 : Recording {Clive James in Dallas} on SKYTRVD now
Sunday 08:32:00 : Recording Scheduled End Time: 08:35
Sunday 08:32:00 : Next recording is Smile on BBC2 at 08:40
Sunday 08:32:00 : Added 240 seconds end padding to {Clive James in Dallas}
Sunday 08:32:00 : Next end padding setting due 08:41
Sunday 08:32:00 : Not time to add start padding yet
Sunday 08:32:00 : Next start padding setting due 08:37
Sunday 08:32:00 : Next wake up will be 08:37
Sleeping, checking every minute for kill signal...... 
Sunday 08:37:00 : Woken up
Sunday 08:37:00 : Recording {Clive James in Dallas} on SKYTRVD now
Sunday 08:37:00 : Recording Scheduled End Time: 08:39
Sunday 08:37:00 : Next recording is Smile on BBC2 at 08:40
Sunday 08:37:00 : No end padding required:
Sunday 08:37:00 : End padding of 240 seconds already set
Sunday 08:37:00 : Next end padding setting due 08:41
Sunday 08:37:00 : Added 58 seconds start padding to Smile
Sunday 08:37:00 : Next start padding setting due 08:41
Sunday 08:37:00 : Next wake up will be 08:41
Sleeping, checking every minute for kill signal..... 
Sunday 08:41:00 : Woken up
Sunday 08:41:00 : Recording {Clive James in Dallas} on SKYTRVD now
Sunday 08:41:00 : Recording Scheduled End Time: 08:39
Sunday 08:41:00 : Next recording is {The Long Duel} on BBC2 at 13:20
Sunday 08:41:00 : No end padding required:
Sunday 08:41:00 : End padding of 240 seconds already set
Sunday 08:41:00 : Next end padding setting due 15:05
Sunday 08:41:00 : Not time to add start padding yet
Sunday 08:41:00 : Next start padding setting due 13:17
Sunday 08:41:00 : Next wake up will be 09:11
Sleeping, checking every minute for kill signal......... 
***


----------



## mark.stringer

Hi Stuart,

My /var directory got rebuild yesterday as a result of a disk error!!! I have reinstalled most items including endpad 1.3.3. Is it worth enabling the Tracker part of this or will the data it collects be worthless when you create the new program using a different method?

Thanks,
Mark.


----------



## Fatbloke

OK peeps, here's one for you. I tried adding endpad tonight to an unmodified Tivo via the serial link. All seemed to go well as I followed the guide from Occitan. However, although everything seemes to complete correctly, endpad doesn't seem to be running. 

I've checked back over the hyperterminal log and everything seems to have been typed correctly. I remembered the CHMOD 777s and did the CP -p as it showed.

I guess it's something to do with the rc.sysinit.author (I'm using the downloaded one) since I also can't get the bash prompt without going back through the diagnostics menu all the time. The rc.sysinit.author looks fine when I do the CAT command, no undesired line breaks etc. but of course it's not in it's final position at that point.

Can someone throw me a couple of linux commands that will allow me to check that rc.sysinit.author is in the correct location and has the correct authorisations whilst Im using the 'old' operating system?


----------



## sirfergy

Did you mod rc.sysinit.author to be +x?


----------



## sanderton

Sounds like a possible candidate for DOS line endings? A DOSsed file looks OK when you cat it IIRC.


----------



## Fatbloke

It's possible, but I was careful to edit it in Ultraedit, saying NO to 'reformat into DOS' when it asked me.

What's this +x bit all about then? I thought the chmod 777 was all I needed?


----------



## sanderton

> _Originally posted by mark.stringer _
> *Hi Stuart,
> 
> My /var directory got rebuild yesterday as a result of a disk error!!! I have reinstalled most items including endpad 1.3.3. Is it worth enabling the Tracker part of this or will the data it collects be worthless when you create the new program using a different method?
> 
> Thanks,
> Mark. *


I'm going to use a different method. Thanks anyway.


----------



## gl9500

hi,

I just started running endpad a couple of days ago and last night had a situation occur...

snippet of ToDo schedule was to record 3 30minute shows... "Cheers" SP at 4:30 and 5:00 and "Daily Show" manual SP at 5:30. endpad was started w/ "2 2". (I converted the times here to match the endpad.log)

Problem was, "Daily Show" did not record at all. 5:00 Cheers recording ends up w/ the 2 minute padding at the end, which it shouldn't. There should be no padding at the end since there was another schedule recording immediately after.

here is the log...

/var/log/endpad.log:
...
Wednesday 04:57:00 : Woken up
Wednesday 04:57:00 : Recording Cheers on TVLAND now
Wednesday 04:57:00 : Recording Scheduled End Time: 05:00
Wednesday 04:57:00 : Next recording is Cheers on TVLAND at 05:00
Wednesday 04:57:00 : No episode tracking done at this time
Wednesday 04:57:00 : Can't add end padding to Cheers
Wednesday 04:57:00 : Gap is 0 seconds
Wednesday 04:57:00 : Next end padding setting due 05:25
Wednesday 04:57:00 : Can't add start padding to Cheers
Wednesday 04:57:00 : Gap is only 0 seconds
Wednesday 04:57:00 : Next start padding setting due 05:25
Wednesday 04:57:00 : Next wake up will be 05:25
Sleeping, checking every minute for kill signal.............................
Wednesday 05:25:01 : Woken up
Wednesday 05:25:01 : Recording Cheers on TVLAND now
Wednesday 05:25:01 : Recording Scheduled End Time: 05:30
Wednesday 05:25:01 : Next recording is {The Daily Show With Jon Stewart} on COME
DY at 05:30
Wednesday 05:25:01 : No episode tracking done at this time
Wednesday 05:25:01 : Added 120 seconds end padding to Cheers
Wednesday 05:25:01 : Next end padding setting due 05:55
Wednesday 05:25:01 : Not time to add start padding yet
Wednesday 05:25:01 : Next start padding setting due 05:27
Wednesday 05:25:01 : Next wake up will be 05:27
Sleeping, checking every minute for kill signal...
Wednesday 05:27:00 : Woken up
Wednesday 05:27:00 : Recording Cheers on TVLAND now
Wednesday 05:27:00 : Recording Scheduled End Time: 05:32
Wednesday 05:27:00 : Next recording is {The Drew Carey Show} on WGN
at 06:00
Wednesday 05:27:00 : No episode tracking done at this time
Wednesday 05:27:00 : No end padding required:
Wednesday 05:27:00 : End padding of 120 seconds already set
Wednesday 05:27:00 : Next end padding setting due 06:25
Wednesday 05:27:00 : Not time to add start padding yet
Wednesday 05:27:00 : Next start padding setting due 05:57
Wednesday 05:27:00 : Next wake up will be 05:57
...


----------



## pahunt

> _Originally posted by Fatbloke _
> *It's possible, but I was careful to edit it in Ultraedit, saying NO to 'reformat into DOS' when it asked me.
> 
> What's this +x bit all about then? I thought the chmod 777 was all I needed? *


chmod 777 will give the file full permissions and so the +x won't help you.


----------



## sanderton

> _Originally posted by gl9500 _
> *hi,
> 
> I just started running endpad a couple of days ago and last night had a situation occur...
> 
> *


Are you absolutely sure that that particular The Daily Show was not a suggestion rather than from the SP? EndPad will cancel suggestions which clash with the intended padding.

Endpad had correctly picked up the start and end times as being the same, and the only situation when it would still cancel the following show would be if it was a suggestion.


----------



## gl9500

> _Originally posted by sanderton _
> *Are you absolutely sure that that particular The Daily Show was not a suggestion rather than from the SP? EndPad will cancel suggestions which clash with the intended padding.
> 
> Endpad had correctly picked up the start and end times as being the same, and the only situation when it would still cancel the following show would be if it was a suggestion. *


Definitely *not* a suggestion. But it was a regular recording, not part of a manual-SP. I had the DailyShow as a manual-SP, but then explicitly recorded the episodes for the week since the DailyShow was moving to a different timeslot the next week.

The recording history shows the 2 entries for manual and regular DailyShow recording...

----- from Tivo and Tivoweb
- Manual: DailyShow ... Conflict ... was not recorded because someone chose to record another program instead: "DailyShow"
- DailyShow ... Conflict ... was not recorded because someone chose to record another program instead: ""
-----

Note that the "conflict" for the regular DailyShow recording was *blank*. And it was a Conflict, not a Cancelled or otherwise.

ok, no big deal. The Tivo scheduling software does sometimes gets confused so it's probably not your bug, but I just thought I'd report it just FYI.

ps. similar ToDo list for last night and the DailyShow was recorded just fine. so who knows.

thanks for Endpad and for looking into this.

Regards

[edit]
pps. FWIW, I verified that the recording did exist in the ToDo list prior to the missed recording. Every morning I run my own script which dumps (using lynx), among other things, the ToDo list via Tivoweb. And the regular, single "DailyShow" recording was on the list.


----------



## sanderton

And you are using the lastest version of EndPad?

I'm at loss on this one; the code in EndPad only goes ahead if another programme is scheduled is the selectiontype = 6 (ie, a suggestion). Manual recordings should be fine.



Code:


if {$gap < $endpadding && $nselectiontype == 6} {

  DeleteSuggestion "$nextrecfsid"

  set endpadtoset $endpadding

}


----------



## gl9500

> _Originally posted by sanderton _
> *And you are using the lastest version of EndPad?
> ...
> *


I just downloaded a couple of days ago from the link on the first post here.

Must be a tivo schedule glitch then.

Altho I have to say I can't say that I trust the "selectiontype" code since you mentioned it for my "change to suggestions" post. Perhaps it works ok for reading the value, but it doesn't see to "set" it properly.

in case you missed my reply to your hints...

http://www.tivocommunity.com/tivo-vb/showthread.php?s=&postid=1626044#post1626044

thanks again. regards


----------



## sanderton

I'd forgotten that thread. I've replied over there.


----------



## gl9500

> _Originally posted by sanderton _
> *No, a suggestion before a scheduled recording will record as normal and the soft start padding will not be added to the scheduled recording. this because, as I feared, if you just try to add the start padding the scheduled recording gets cancelled, not the suggestion.
> 
> I'm personally inclined to leave it that way, rather than delete a perfectly good suggestion which has almost finished recording for the sake of the start padding.
> 
> But if others feel differently I can revisit that bit of code (once I figure out how to kill an in-progress recordng gracefully).
> 
> Let me know. *


First let me apologize for not reading all 31 pages (!) on this thread <g><ng>. But I did do a search and found the above post.

What was/is the resolution of this?? From what I can tell, the latest version 1.3.3 does not do this... so...

I would vote to trash the suggestion prior to a scheduled recording, in favor of adding padding to the start of the schedule recording. After all, I *really* want the scheduled recording; who knows if I want or care about the suggestion.

As it stands now, I've gone to turning off suggestions since I am trying to capture episodes to transfer to DVD and endpad works really well at grabbing as much of a recording as possible. Kudo's to you Stuart. I've only been using endpad for a few days, but it's really very cool!

ps. everytime I type "endpad" I feel like I should type it as "endpad(tm)" <g>.


----------



## mbriody

I started using it earlier this week and it works oaky except that it seems to die after a day or so.

Also if I try to restart it manually is appears to work but my TiVo reboots shortly afterwards, so putting it on a cron job is no good.

Any ideas?


----------



## iankb

> _Originally posted by mbriody _
> *... it seems to die after a day or so.*


Is that because it wasn't adding padding, or because you couldn't see the process, or because it stopped writing to the endpad log?

Maybe running a second copy caused the reboot. I would think that the endpad log would be the easiest indicator of whether it is running or not.


----------



## mbriody

All three.

The log entry stopped in the middle of a sentence, there is no process in the list and of course the padding stopped.



> _Originally posted by iankb _
> *Is that because it wasn't adding padding, or because you couldn't see the process, or because it stopped writing to the endpad log?
> 
> Maybe running a second copy caused the reboot. I would think that the endpad log would be the easiest indicator of whether it is running or not. *


----------



## kweller

This isn't exactly crritical and someone else may have reported it already although I couldn't see it in this thread - endpad crashes if there are fewer than two recordings in the todo list; see log below.

I've skip read through the thread but this is such a massive thread to come in to this late that I may have missed something. Is the current recommendation for endpad restarts after a crash a cron job or the amendment to rc.sysinit.author ((sleep 120 && while ! /var/hack/endpad.tcl n -run 2>>/var/hack/endpad.err) &).

Thanks.

Endpad log

***** NO RECORDINGS *****

Sunday 14:01:57 : endpad.tcl 1.3.3 log file, starting up
Sunday 14:01:57 : Start padding set to 60 seconds
Sunday 14:01:57 : End padding set to 120 seconds
Sunday 14:01:57 : Error detected
can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active

set isrec 1

# Get details of curently recording programme

RetryTransaction { 
set crec [db $d..."
Sunday 14:01:57 : Attempting to recover
Sunday 14:02:27 : Error detected
can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active

set isrec 1

# Get details of curently recording programme

RetryTransaction { 
set crec [db $d..."
Sunday 14:02:27 : Attempting to recover
Sunday 14:02:27 : Too many errors, stopping

***** ONE RECORDING *****
Sunday 14:27:07 : 
Sunday 14:27:07 : endpad.tcl 1.3.3 log file, starting up
Sunday 14:27:07 : Start padding set to 60 seconds
Sunday 14:27:07 : End padding set to 120 seconds
Sunday 14:27:08 : Error detected
can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Sunday 14:27:08 : Attempting to recover
Sunday 14:27:38 : Error detected
can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Sunday 14:27:38 : Attempting to recover
Sunday 14:27:38 : Too many errors, stopping


----------



## Fatbloke

Here's an update to the manual endpad load I was trying over the weekend.

I retraced my steps _carefully_ once more and this time changed the chmod from 777 to 755. Now I dont know whether this made a difference or that I corrected a typo from the other (two) times I tried it. But I managed to get endpad running via the serial connection.

Two small points to note, dont know if they have been mentioned before...

1) After installing, I rebooted and tried a 5 minute manual recording. This started about 4 minutes after my reboot, but of course this was only entered a minute or so after the reboot (endpad had ben running fo a short while by now). Anyway, the 5 min manual recording was not endpad'd at all. I could see in the log that it was waiting for the first to-do item in a few hours time.

2) The manual instructions mention that a serial prompt will appear without going through the x,p,root= method. This was certainly the case, only thing was I couldn't see what I was typing in! I was getting the bash prompt (although it wasn't line breaking) and any results from the commands I typed (echo * etc.) but I couldn't check for typos as I typed my commands :| I assume a hyperterminal settings problem but can anyone suggest what I could do?


----------



## doubledrat

fb: type

stty sane

to get an echo of what you type


----------



## LampyDave

> _Originally posted by Fatbloke _
> *
> 1) After installing, I rebooted and tried a 5 minute manual recording. This started about 4 minutes after my reboot, but of course this was only entered a minute or so after the reboot (endpad had ben running for a short while by now). Anyway, the 5 min manual recording was not endpad'd at all. I could see in the log that it was waiting for the first to-do item in a few hours time. *


Endpad wakes up every half hour to check for upcoming recordings. If it was watching for changes in the ToDo all the time then it would 'load' the processor too much.

Therefore a recording added after endpad last woke up, and starting before it wakes up again, will not be 'seen' and will not get padded.

Therefore it's as designed as far as I know.

Cheers,

Dave

Edited for poor grammar


----------



## sanderton

> _Originally posted by kweller _
> *This isn't exactly crritical and someone else may have reported it already although I couldn't see it in this thread - endpad crashes if there are fewer than two recordings in the todo list*


Yes, it will.  I'll fix that.


----------



## mbriody

My endpad has died again. This time a real error maybe?

Sunday 17:25:00 : Recording Futurama on SKYONE now
Sunday 17:25:00 : Recording Scheduled End Time: 17:30
Sunday 17:25:00 : Next recording is Futurama on SKYONE at 17:30
Sunday 17:25:00 : Added Futurama to series list
Sunday 17:25:00 : Added episode {My Problem With Popplers} to tracker list
Sunday 17:25:00 : Error detected
no space left on device
while executing
"close $episodelist"
Sunday 17:25:00 : Attempting to recover
Sunday 17:25:30 : Woken up
Sunday 17:25:30 : Recording Futurama on SKYONE now
Sunday 17:25:30 : Recording Scheduled End Time: 17:30
Sunday 17:25:30 : Next recording is Futurama on SKYONE at 17:30
Sunday 17:25:30 : Added episode {My Problem With Popplers} to tracker list
Sunday 17:25:30 : Error detected
no space left on device
while executing
"close $episodelist"
Sunday 17:25:30 : Attempting to recover
Sunday 17:25:30 : Too many errors, stopping


----------



## doubledrat

looks like your /var/tmp might be full?!


----------



## mbriody

Is there a maximum size for this then and is it configurable anywhere?

There's a lot a stuff in there - can I just delete it all?


----------



## sanderton

You can delete anything in /var/tmp - and I'd do it soon; if TiVo find's that /var is full it can decide to simply delete it and start again, and you'd lose all your hacks!


----------



## doubledrat

if you type 

ls -l /var/tmp

you will see how big things are. It might be interesting to establish what is hogging the space


----------



## mbriody

Deleted it now. This was the output from ls:

total 6219
drwxr-xr-x 3 0 0 3072 Jan 12 10:01 .
drwxr-xr-x 14 0 0 1024 Jan 1 1970 ..
-rw------- 1 0 0 12 Jan 10 12:23 EventSwitcher
srwxr-xr-x 1 0 0 0 Jan 10 12:23 EventSwitcherSocket106
-rw------- 1 0 0 12 Jan 10 12:23 EvtMaster::Run135
-rw------- 1 0 0 12 Jan 10 12:23 EvtMaster::Run145
-rw------- 1 0 0 12 Jan 10 12:23 EvtMaster::Run160
-rw------- 1 0 0 12 Jan 10 12:23 EvtMaster::Run163
-rw-r--r-- 1 0 0 1747 Jan 10 13:20 HServer.recv
-rw-r--r-- 1 0 0 2215 Jan 10 13:19 HServer.send
srwxr-xr-x 1 0 0 0 Jan 10 12:23 MasterSocket135
srwxr-xr-x 1 0 0 0 Jan 10 12:23 MasterSocket145
srwxr-xr-x 1 0 0 0 Jan 10 12:23 MasterSocket160
srwxr-xr-x 1 0 0 0 Jan 10 12:23 MasterSocket163
-rw------- 1 0 0 12 Jan 10 12:23 MyWorld
-rw------- 1 0 0 12 Jan 10 12:23 Osd
-rw-r--r-- 1 0 0 102400 Jan 12 01:33 Program.temp.0
-rw-r--r-- 1 0 0 102400 Jan 12 01:36 Program.temp.1
-rw-r--r-- 1 0 0 102400 Jan 12 01:53 Program.temp.10
-rw-r--r-- 1 0 0 102400 Jan 12 01:55 Program.temp.11
-rw-r--r-- 1 0 0 102400 Jan 12 01:57 Program.temp.12
-rw-r--r-- 1 0 0 102400 Jan 12 01:59 Program.temp.13
-rw-r--r-- 1 0 0 102400 Jan 11 08:10 Program.temp.14
-rw-r--r-- 1 0 0 102400 Jan 11 08:11 Program.temp.15
-rw-r--r-- 1 0 0 102400 Jan 11 08:12 Program.temp.16
-rw-r--r-- 1 0 0 102400 Jan 10 14:40 Program.temp.17
-rw-r--r-- 1 0 0 102400 Jan 10 14:41 Program.temp.18
-rw-r--r-- 1 0 0 102400 Jan 10 14:41 Program.temp.19
-rw-r--r-- 1 0 0 102400 Jan 12 01:37 Program.temp.2
-rw-r--r-- 1 0 0 102400 Jan 10 14:42 Program.temp.20
-rw-r--r-- 1 0 0 102400 Jan 10 14:42 Program.temp.21
-rw-r--r-- 1 0 0 102400 Jan 10 14:42 Program.temp.22
-rw-r--r-- 1 0 0 102400 Jan 10 14:43 Program.temp.23
-rw-r--r-- 1 0 0 102400 Jan 10 14:43 Program.temp.24
-rw-r--r-- 1 0 0 102400 Jan 10 14:44 Program.temp.25
-rw-r--r-- 1 0 0 102400 Jan 10 14:44 Program.temp.26
-rw-r--r-- 1 0 0 102400 Jan 10 14:45 Program.temp.27
-rw-r--r-- 1 0 0 102400 Jan 10 14:45 Program.temp.28
-rw-r--r-- 1 0 0 102400 Jan 10 14:45 Program.temp.29
-rw-r--r-- 1 0 0 102400 Jan 12 01:39 Program.temp.3
-rw-r--r-- 1 0 0 102400 Jan 12 01:41 Program.temp.4
-rw-r--r-- 1 0 0 102400 Jan 12 01:43 Program.temp.5
-rw-r--r-- 1 0 0 102400 Jan 12 01:44 Program.temp.6
-rw-r--r-- 1 0 0 102400 Jan 12 01:46 Program.temp.7
-rw-r--r-- 1 0 0 102400 Jan 12 01:48 Program.temp.8
-rw-r--r-- 1 0 0 102400 Jan 12 01:50 Program.temp.9
-rw-r--r-- 1 0 0 0 Jan 12 01:25 ProgramToSeries.temp.0
-rw-r--r-- 1 0 0 0 Jan 12 01:26 ProgramToSeries.temp.1
-rw-r--r-- 1 0 0 0 Jan 12 01:28 ProgramToSeries.temp.2
-rw-r--r-- 1 0 0 0 Jan 12 01:30 ProgramToSeries.temp.3
-rw-r--r-- 1 0 0 0 Jan 12 01:32 ProgramToSeries.temp.4
-rw-r--r-- 1 0 0 63216 Jan 11 07:59 ProgramToSeries.temp.8
-rw------- 1 0 0 12 Jan 10 12:23 Sark (mcp)
-rw-r--r-- 1 0 0 0 Jan 12 01:23 ShowcaseHasClipIndex.temp.0
-rw-r--r-- 1 0 0 1520 Jan 12 01:23 ShowcaseHasProgramIndex.temp.0
-rw-r--r-- 1 0 0 0 Jan 12 01:23 ShowcaseIdentToIdIndex.temp.0
-rw-r--r-- 1 0 0 0 Jan 12 01:44 Showing.temp.10
-rw-r--r-- 1 0 0 0 Jan 12 01:45 Showing.temp.11
-rw-r--r-- 1 0 0 0 Jan 12 01:46 Showing.temp.12
-rw-r--r-- 1 0 0 102396 Jan 12 01:48 Showing.temp.13
-rw-r--r-- 1 0 0 102396 Jan 12 01:49 Showing.temp.14
-rw-r--r-- 1 0 0 102396 Jan 12 01:50 Showing.temp.15
-rw-r--r-- 1 0 0 102396 Jan 12 01:52 Showing.temp.16
-rw-r--r-- 1 0 0 102396 Jan 12 01:53 Showing.temp.17
-rw-r--r-- 1 0 0 102396 Jan 12 01:54 Showing.temp.18
-rw-r--r-- 1 0 0 102396 Jan 12 01:56 Showing.temp.19
-rw-r--r-- 1 0 0 0 Jan 12 01:36 Showing.temp.2
-rw-r--r-- 1 0 0 102396 Jan 12 01:57 Showing.temp.20
-rw-r--r-- 1 0 0 102396 Jan 12 01:58 Showing.temp.21
-rw-r--r-- 1 0 0 97488 Jan 12 01:59 Showing.temp.22
-rw-r--r-- 1 0 0 102396 Jan 12 01:59 Showing.temp.23
-rw-r--r-- 1 0  0 129024 Jan 12 01:59 Showing.temp.24
-rw-r--r-- 1 0 0 161792 Jan 11 08:13 Showing.temp.25
-rw-r--r-- 1 0 0 614376 Jan 10 14:46 Showing.temp.30
-rw-r--r-- 1 0 0 695296 Jan 10 14:46 Showing.temp.36
-rw-r--r-- 1 0 0 102396 Jan 12 01:39 Showing.temp.5
-rw-r--r-- 1 0 0 102396 Jan 12 01:40 Showing.temp.6
-rw-r--r-- 1 0 0 49152 Jan 12 01:41 Showing.temp.7
-rw-r--r-- 1 0 0 0 Jan 12 01:42 Showing.temp.8
-rw-r--r-- 1 0 0 0 Jan 12 01:43 Showing.temp.9
-rw-r--r-- 1 0 0 317 Jan 10 13:19 TCD411.recv
-rw-r--r-- 1 0 0 364 Jan 10 13:19 TCD411.send
-rw-r--r-- 1 0 0 0 Jan 11 14:27 TClient.res
-rw------- 1 0 0 12 Jan 10 12:23 TclEvent138
-rw------- 1 0 0 12 Jan 10 12:24 TclEvent171
-rw-r--r-- 1 0 0 0 Jan 12 01:24 Tms.temp.0
-rw-r--r-- 1 0 0 0 Jan 12 01:25 Tms.temp.1
-rw-r--r-- 1 0 0 13200 Jan 11 07:59 Tms.temp.14
-rw-r--r-- 1 0 0 0 Jan 12 01:27 Tms.temp.2
-rw-r--r-- 1 0 0 0 Jan 12 01:28 Tms.temp.3
-rw-r--r-- 1 0 0 0 Jan 12 01:29 Tms.temp.4
-rw-r--r-- 1 0 0 0 Jan 12 01:30 Tms.temp.5
-rw-r--r-- 1 0 0 0 Jan 12 01:32 Tms.temp.6
-rw------- 1 0 0 12 Jan 10 12:23 dbgc-mcp
-rw------- 1 0 0 12 Jan 10 12:23 fsmem
-rw------- 1 0 0 1358 Jan 11 14:27 keyquery.post
-rw-r--r-- 1 0 0 4 Jan 10 13:20 keyquery.response
-rw------- 1 0 0 12 Jan 10 12:24 mom
-rw-r--r-- 1 0 0 0 Jan 10 12:24 mwstate
-rw-r--r-- 1 0 0 0 Jan 10 12:24 myworld.lck
srwxr-xr-x 1 0 0 0 Jan 10 12:24 serialPortArbitrator
-rw-r--r-- 1 0 0 131072 Jan 11 14:27 syslog
-rw-r--r-- 1 0 0 20455 Jan 11 18:58 tclIndex
-rw------- 1 0 0 12 Jan 10 12:23 tcphonehome
-rw-r--r-- 1 0 0 0 Jan 10 12:23 tcphonehome.lck
drwxr-xr-x 2 0 0 1024 Jan 10 13:28 unbundle
bash-2.02#

Looks like the showing.temp files and program.temp were taking the space. Any ideas what these are?

I've stll got a directory called unbundle. Is it safe to remove?


----------



## tivouser

sanderton - great addition to Tivo.

I have been running endpad for a week and it's a great improvement.
My only issue is with consecutive suggestions on the same channel, I think that the first suggestion gets end padding applied and the second suggestion is not recorded.
If this is so, is it possible to compare the channel for the 2 suggestions and records both of them adding the end padding to the last one as appropriate.


----------



## doubledrat

Perhaps it could even add double the end Padding!


----------



## Ashley

Endpad has stopped with this error:

Sleeping, checking every minute for kill signal............................ 
Sunday 20:55:00 : Woken up
Sunday 20:55:00 : Recording {Time Team} on DISC1 now
Sunday 20:55:00 : Recording Scheduled End Time: 21:00
Sunday 20:55:00 : Next recording is {Location, Location, Location} on DHL1 at 21:00
Sunday 20:55:01 : Error detected
couldn't open "/var/hack/tracker/SH339649": too many open files
while executing
"open "$trackerdir/$seriestmsid" a"
Sunday 20:55:01 : Attempting to recover
Sunday 20:55:31 : Woken up
Sunday 20:55:31 : Recording {Time Team} on DISC1 now
Sunday 20:55:31 : Recording Scheduled End Time: 21:00
Sunday 20:55:31 : Next recording is {Location, Location, Location} on DHL1 at 21:00
Sunday 20:55:31 : Error detected
couldn't open "/var/hack/tracker/series": too many open files
while executing
"open "$trackerdir/series" r"
Sunday 20:55:31 : Attempting to recover
Sunday 20:55:31 : Too many errors, stopping

So it's Tracker that seems to be the culprit. Can I just remove it?


----------



## sanderton

This was reported further up. Just delete or rename the /var/hack/tracker folder


----------



## pahunt

> _Originally posted by Ashley _
> *Endpad has stopped with this error:
> 
> snip....
> 
> So it's Tracker that seems to be the culprit. Can I just remove it? *


If you rename the Tracker folder that will disable it.


----------



## jonnydeath

Hello,
I looked through the entire thread and saw this question asked, but I am not sure if it has been implimented in 1.3.3. Sorry to repost if it has been answered.

Here is the US, NBC has decided to start a lot of shows a minute early.

Ie, 9:59 instead of 10:00

I have another show on another channel that goes from 9:30 to 10:00. Therefore, I loose the entire second show. Will this hack automatically negative pad the second show to start at 10:00?

I don't care which show is padded, I just want them both to be recorded.

Thanks a million,


----------



## sanderton

No, I'm afraid not.


----------



## jonnydeath

thanks for your quick-reply.

Is there anyway to hack your script so that if something has a begin or endtime +/- 1 minute to just change it? This would fix everything, and since it only removes time for recordings, it shoudn't mess anything up. (or will it?)

In my lame psuedo-code:

if($cstarttime % 60*60 == 59*60) // if starts at X:59
set cnewstarttime [$cstarttime + 60] // start at X+1:00

if($cendtime % 60*60 == 1*60) // if ends at X:01
set cnewendtime [$cendtime - 60] // end at X:00

This could either be an option or a second script. it would be great if it only does this if there is a conflict, bug beggers can't be choosers!!!

Thanks again for your hard-work,
Jon


----------



## sanderton

No, because EndPad merely manipulates start and end times of items in the To Do List; in the case you describe TiVo will never schedule the clashing programme so it's not ever in the TDL!

What you should be able to do is apply 2 mins of _negative padding_ to the SP for the one which starts at the odd time (there's a thread in the Underground on negative padding), so it doesn't cause a clash. EndPad would then add the start of the programme back if there was no preceding show.


----------



## doubledrat

just bumping this up to where it should be - near the top


----------



## racingclub

mebbe needs sticky-fying?


----------



## bobones

I have no serial cable or network access for my tivo. Can I install the endpad hack just by inserting the hard disk on my PC, copying the endpad script to /var/hack and making the appropriate edits to the rc files? Are there any other prerequisites, for example, do I need to install tcl first?


----------



## sanderton

You can indeed install it by taking your hard disk out and copying the files on, editing the startup script and setting the relevant file permissions. There are no prerequisites.

However your only way to restart EndPad should it stop for some reason will be to reboot.


----------



## bobones

Thanks. If only I could get the bloody lid off!

Would the easiest way for me to check that it's running be to schedule a manual recording, of say 10 minutes, then check that the duration of the actual recording is 10 + start pad + end pad minutes long?


----------



## sanderton

It only adds the end padding right at the end. If you play an "EndPadded" recording while it is still recording, you will seen a green bar of the programme duration + the start padding until about 5 mins before the end.

eg, I have it running on 1 min start and 2mins end, so a 1 hour programme with no clashes at either end has a green bar showing 1.01 for the first 55 mins, then 1.03 when it's done.

If you check it with a manual recording, remember EndPad only wakes up every 30 mins if it's not expecting a new recording to start, so it will miss your manual recording if you set it to start too soon.


----------



## iankb

> _Originally posted by bobones _
> *I have no serial cable or network access for my tivo. Can I install the endpad hack just by inserting the hard disk on my PC, copying the endpad script to /var/hack and making the appropriate edits to the rc files?*


Just in case (since you don't say) ...

I presume that you are going to boot into Linux, and not into Windows. Whatever you do, DON'T boot into Windows NT, 2000 or XP with your TiVo drive attached, since it will corrupt the drive.


----------



## bobones

Yes, I'm going to boot with Tiger's boot cd, do a backup, and then start hacking. Now I have discovered I can use my pronto serial cable, I'll set up a serial connection for testing and further hacks. Thanks for the advice.


----------



## Milhouse

Endpadding is running just fine on my UK SA! 

Suggestion:

Would it be possible to have endpadding modify the recording quality? For instance I have suggestions enabled and have set my default recording quality to MEDIUM so that they don't take up too much space - but for my scheduled recordings (SP, Wishlists etc.) I record in BEST quality.

Could endpad.tcl set the recording quality to BEST for all non-suggestion recordings at the same time it adds the start padding? Obviously this may not be to everyone's liking so it should be an optional feature... and could be extended to set different qualities according to genre (BEST only for Sport etc.)


----------



## dickuk

Stuart,

I have installed endpad and the free space display on a friends tivo which has no turbonet, and the free space is working, but endpad isnt.

Is there any way to look at the endpad.log file without removing the hard drive again? I have tried the backdoor log view but it isnt there.

Thanks


----------



## ljb.designs

I have been trying to install endpad via serial the port using occitan's instructions
I can't get it to work!
I havn't use unix in over 10 years and am rusty
can anybody help and what damage has been done so far
the tivo is still working.


----------



## bobones

dickuk, unless you have set up the tivo to get a bash prompt over a serial cable (pronto cable works), you'll need to remove the disk again. Check execute permissions and that file has been transferred correctly. You could create a hard link from tvdebuglog to endpad.log (ln tvdebuglog endpad.log) to make the log viewable with the backdoor. I'd also change the start up line so that standard error is appended to endpad.log, e.g.: 
/var/hack/endpad.tcl 1 4 -auto >>/var/log/endpad.log 2>&1 &

ljb.designs, need more detail of what you have done. Have you got a bash prompt and is it just endpad that doesn't work?


----------



## charliektm400exc

A couple of days ago, when I was changing the keep until date on a program, the TiVo locked up on the wait a short while screen. It maintained recording the program what was on at the time. I had to pull the plug to get it going again.

Tonight, the machine locked up part way through a fast forward of a program. The fast forward continued on, but he remote wouldn't work. In addition the display showing how far through the program I was stopped at the fourteen minute mark. It didn't start recording a program it should have been recording. Again, I had to pull the plug to get it going.

The only thing I have which is different, as far as I remember, from a standard oztivo 3.0 image is that I have endpad working, so I suspect that it's related.

Has anybody else had this problem?


----------



## sanderton

Not seen anything like that reported.

If you get it again, please post the relevant sections of the EndPad log and the kernel log showing the crash, so you can see if there's a relation between them.

My gut feel is that with 500-odd people using EndPad and no similar reports, that this is something else?


----------



## ljb.designs

bobones, after using occitan's instructions endpad does not work
I don't get a bash prompt by just connecting the serial cable but can get it if I follow instruction at the beginning


----------



## bobones

Reading occitan's instructions, I think you can just go through the whole procedure again. The only commands that will fail are the "mkdir /var/hack" and "mkdir /var/newos" since those directories will now already exist.

Make sure your sysinit.rc.author file has unix endlines, not dos ones. (Use the one I've attached to be sure). Upload with zmodem in binary mode. 

Make sure you run the chmod commands correctly, and pay attention to whether you need to mount /dev/hda4 or /dev/hda7.

The one extra step I would do before powering off would be:

umount /var/newos

to make sure the copied files are fully flushed onto the disk. (This may be the cause of your problem).

Once you've rebooted with the original boot parameters, you should get a bash prompt if all is well. 

I'd recommend that you install the "Joe" editor and other useful files for hacking so you can futher tune your tivo. See the hack faqs for details.


----------



## Milhouse

Is there a bug in endpad.tcl 1.3.3? Looking at the Tracking thread a "too many open files" error has been reported.

Looking at endpad.tcl it appears it may have a resource leak at about line 433:



Code:


	set episodelist [open "$trackerdir/$seriestmsid" r]

	while {![eof $episodelist]} {
		if {[lindex [gets $episodelist] 0] == $episodetmsid} {
			set isinlist 1
		}
	}
	
	set episodelist [open "$trackerdir/$seriestmsid" a]

The second "open" is overwriting the stream identifier for the first file without closing it - would this account for the error eventually occurring? I'm no TCL expert but suspect the code should be modified as follows:



Code:


	close $episodelist
	set episodelist [open "$trackerdir/$seriestmsid" a]

By the way - any progress on the tracker project?


----------



## sanderton

Yes, there she blows - a cut and paste error from the development code which closed the file!

I've got a couple of minor bug fixes to test up.

Tracker is still on the back burner while I work on a "shared Now Playing between networked TiVos" hack.


----------



## charliektm400exc

> _Originally posted by sanderton _
> *Not seen anything like that reported.
> 
> If you get it again, please post the relevant sections of the EndPad log and the kernel log showing the crash, so you can see if there's a relation between them.
> 
> My gut feel is that with 500-odd people using EndPad and no similar reports, that this is something else? *


I got another crash today, halfway through watching a program, but potentialy at a time when end pad might have woken up, but it's hard to tell.

The kernel's last message was about 13 minutes before the crash.

Endpad's last message was exactly (as close as I can remember from looking at the clock when it happened) 1 hour before the crash

Sleeping, checking every minute for kill signal.... Tuesday 19:58:00 : Next end padding setting due 20:25
Tuesday 19:58:01 : Added 60 seconds start padding to {Reality Bites}
Tuesday 19:58:01 : Next start padding setting due 20:25
Tuesday 19:58:01 : Next wake up will be 20:25
Sleeping, checking every minute for kill signal..Tuesday 21:23:26 : 
Tuesday 21:23:26 : endpad.tcl 1.3.3 log file, starting up

There appears to be no sign of endpad waking up at 20:25, and the crash happened at 20:58

What happened was that part way through the program, which we were watching about 10 minutes late it just reverted to the program description screen, and gave an option to resume playing, but nothing we could do would make any difference.

I left it running in the hope it would continue to record the program (didn't seem likely as I couldn't TiVoweb in or Telnet in to the TiVo at the time. After the end of the show I rebooted the TiVo and went back in to have a look at what had been recorded, and the recording ended at the 9 minute mark, which was about where it would have been when we started watching it. We certainly went a long way beyond this when we watched it, but that had all gone from the TiVo.

So could it be endpad?

If not, any other suggestions?

Thanks

Charlie


----------



## sanderton

There are two dots in the "Sleeping, checking every minute for kill signal.." line, which says that EndPad crashed at 20.00, not at 20.58.

The 9 minute thing suggests that it recored the first 512Mb block and then locked up. That block would have been set in motion at 8pm, so it looks like it came to create the next one at 10 past and myworld had fallen over so it couldn't.

This could happen for any number of reasons, including a hard disk problem. You'd tend to see this at a recording start and as endPad runs just before then it's tempting to think they are related - however EndPad was in its wait loop when the crash happened, and the recording did successfully start, so I don't think it's directly related.


----------



## dickuk

>> You could create a hard link from tvdebuglog to endpad.log (ln tvdebuglog endpad.log) to make the log viewable with the backdoor

Thanks bobones for the info, however how do I create this hard link?


----------



## bobones

Boot with appropriate cd
Mount /var:
# mkdir /mnt/var; mount /dev/hda9 /mnt/var
cd to the log directory:
# cd /mnt/var/log
remove any endpad.log that may exist there (have a look at it first!):
# rm endpad.log
create link:
# ln tvdebuglog endpad.log
unmount /mnt/var:
# umount /mnt/var


----------



## dickuk

Thanks, will give this a try.


----------



## charliektm400exc

Thanks for the analysis.

The recording started at 8:30, but I assume that doesn't change your conclusions.

I'll go looking elswhere.

Charlie


----------



## sanderton

It started recording Reality Bites at 8pm, according to the log, and EndPad crashed about then.


----------



## Fatbloke

Just a quick question about elongated padding at the end.

If, for example I ran endpad with 15 minutes padding at the end, would the program be padded for just 5 minutes if there was a program to record only 5 minutes after program 1 is scheduled to end? Or would you just get no padding?

tia.


----------



## ccwf

> _Originally posted by ccwf on Oct 9_
> *It looks like the current script is an all-or-nothing padding [].
> 
> The code below changes behavior so that [] less soft padding will be used if necessary.*


 [Stuart then further modified my code changes to deal with the two seconds TiVo uses for changing channels.]

So, you'll get as much padding as possible, assuming you aren't running an ancient version of EndPad.


----------



## tivo-onion

Hi,

I know that endpad will remove a suggestion scheduled before or after a non-suggestion if there is an overlap in time generated by endpad. However, what happens if you have 2 suggestions back-to-back. Will the second suggestion be discarded, or are both suggestions treat as equals and both recorded - much as two non-suggestions would be?

thanks for your help on this,

cheers

Chris


----------



## kitschcamp

I *think* it cancels one of the suggestions - I wish it didn't, but I've noticed a few times two back-to-back suggestions in the list, and only one getting recorded.


----------



## tivo-onion

> _Originally posted by kitschcamp _
> *I *think* it cancels one of the suggestions - I wish it didn't, but I've noticed a few times two back-to-back suggestions in the list, and only one getting recorded. *


Yeah,

I have just seen it happen actually, coincidentally ... it does seem to cancel the subsequent suggestion. You would thing suggestions would be equal - as are non suggestions - well anyway.....

thanks for your help,

cheers

Chris


----------



## sanderton

The logic is: better one suggestion with an ending than two without. 

Should be an option though.


----------



## PaulOckenden

> _Originally posted by sanderton _
> *Should be an option though. *


In an ideal world there would be a database of channels you trust (the mechanical stations driven by a playout system), and the channels you don't (those with live segments, and driven by humans).

The former can pretty much be guaranteed to run to time, so padding could be switched off. The latter can pretty much be guaranteed to start a minute early, and finish 3 minutes late!

P.


----------



## sanderton

Please note that falconx, the brains behind TiVoWeb Plus, has produced a version of EndPad which works correctly with dual tuners.

It also has optional treatment of back to back suggestions. 

He lives over at the database of deals, and I can't post a link, but the end bit of the url is:

/forum/showthread.php?t=31854


----------



## mrhatken

Firstly, hello Sanderton and thanks for creating EndPad, it is a fantastic utility for TiVo and I appreciate you sharing it with the community.

If I may please suggest a feature that you may like to consider for a future version of EndPad - I don't think it would be too difficult to implement.

I am not sure about the US, but in Aus most shows tend to run mostly on-time (within a few minutes) most of the day, but balloon off-time late in the night and very early morning.

I was thinking it would save disk space if EndPad could adjust its padding depending upon the time of day at which the show was running (e.g. less during the day, more late at night).

My Dad uses EndPad and he wants me to set it to 45 minutes so he doesn't miss one or two shows that he likes to record late a night (he could use specific padding for these shows ...).

I think this could be achieved simply by creating a "crontab" like file that specified different EndPad settings for different times of the day. If you want to get fancy it could even be channel-specific.

A file with a format something like this simple example:

# EndPad config file
# start-hour end-hour week-day channel startpad endpad
6 21 * * 1 5
21 6 * * 15 45

So this suggests that between 6am and 9pm on every day on every channel pad for 1 and 5 minutes. However, between 9pm and 6am on every day on every channel pad 15 and 45 minutes.

When EndPad wakes up to do its thing, it could just read this file, or refer to values it has cached, and determine the startpad and endpad times for the particular program it is padding.

I guess the only difficult part would be ensuring that the period, days, channels, etc in the configuration file are non-overlapping.

Perhaps if there is an overlap it could just take the first appropriate entry (the last line could just be a default for all times on all days on all channels)

Please consider and thanks again!

Cheers,
Ashley Aitken.


----------



## tivo-onion

> _Originally posted by sanderton _
> *Please note that falconx, the brains behind TiVoWeb Plus, has produced a version of EndPad which works correctly with dual tuners.
> 
> It also has optional treatment of back to back suggestions.
> 
> He lives over at the database of deals, and I can't post a link, but the end bit of the url is:
> 
> /forum/showthread.php?t=31854 *


This "endpadplus" treats suggestions the same as normal planned recordings. My preference would be to still have suggestions as second class citizens i.e. a suggestions would be knocked off in favour of padding a real recording, but all suggestions are equal i.e. one suggestion will not knock off another suggestion because of padding. "endpadplus", with the relevant option selected, just treats all recordings the same and pads where possible - it does not knock anything off - based on my observations yesterday! I was concerned for a while that "NEW" enterprise was not going to record, as a suggested simpsons was recording before it. SCAREY! ;-)

Suart, I have made a small modification to your endpad module to only delete the next "suggestion" if the current recording is not a "suggestion" in line with the regular padding rules. I have a window of opportunity tonight to test it poperly - so will pop it on the forum then.

cheers

Chris


----------



## sanderton

> _Originally posted by mrhatken _
> *I was thinking it would save disk space if EndPad could adjust its padding depending upon the time of day at which the show was running (e.g. less during the day, more late at night).
> 
> ...
> 
> I think this could be achieved simply by creating a "crontab" like file that specified different EndPad settings for different times of the day. *


You could do this with cron; set up a series of cron jobs to start and stop EndPad at various times each day with different padding settings.


----------



## manolan

> _Originally posted by mrhatken _
> *... snip ...
> I think this could be achieved simply by creating a "crontab" like file that specified different EndPad settings for different times of the day. If you want to get fancy it could even be channel-specific.
> 
> A file with a format something like this simple example:
> 
> # EndPad config file
> # start-hour end-hour week-day channel startpad endpad
> 6 21 * * 1 5
> 21 6 * * 15 45
> 
> So this suggests that between 6am and 9pm on every day on every channel pad for 1 and 5 minutes. However, between 9pm and 6am on every day on every channel pad 15 and 45 minutes.
> 
> ... snip ....*


As an experineced cron user, I can't believe anyone would actually suggest using the crontab format these days! It seems remarkably archaic. Surely something in XML would be called for.


----------



## mrhatken

Ok, ok, fair comment, XML is more easily parsed and more readable.

It's just when I think time, I think cron, and its a format I (sort of) know.

BTW, has cron been updated to use XML (as well as the old format) yet?

Cheers,
Ashley.


----------



## tivo-onion

Stuart,

excuse my ignorace....I have been inspecting the code of endpad and have a quick question surrounding start padding.

If there is a suggestion scheduled followed directly by a proper recording then does the suggestion get cancelled in order to make room for the proper recording start padding. I thought that it did, but I cannot see in the code where it would happen. Could you point to me to the right area in the code to find this functionaity if it exists.

The alternative is of course that the suggestion plays out with no end padding, and the proper scheduled recording starts with no start padding? is this the case? Is it therefore that it is only end-padding that causes the deletion of suggestions?

If this is the case, is there any reason why you could not cancel a preceding suggestion to make room for start padding of a proper scheduled recording?

cheers

Chris


----------



## sanderton

Basically, I don't know how to stop an in-progress suggestion in MFS. Adding the start padding anyway actually prevented the scheduled show form recording. So I played it safe and left alone.


----------



## tivo-onion

Stuart,

so does that mean that by default, adding start padding to a recording will automatically stop a prior suggestion being recorded?

In a scenario where tivo is planning to record the following programs.....

8.30 9.00 9.30
|<---------------------->|<---------------------->|
simpsons friends
(suggestion) (season pass)

..... at which point / time does the start padding for the episode of friends get added (if at all), and will the suggestion record or not,

thanks for your help,

cheers

Chris


----------



## kwangomango

I receive the following error when trying to run endpad.tcl manually

": no such file or directory

Any ideas?


----------



## Milhouse

FTP. BINARY MODE. (Most likely). Definately sounds like you've got DOS line endings.

Search


----------



## kwangomango

Cheers, i noticed the DOS line endings when i opened the file using joe. I have since saved and resaved in textpad (as UNIX) and ftp'd in binary mode but the line endings are still there. I am using SmartFTP which is set to always use binary.
Cheers for the search link, knew i'd seen the issue before but i couldn,t find it from my search.


----------



## Milhouse

If you've saved it in Unix format and are FTPing in Binary mode then either you are still uploading the old file or uploading the new file to the wrong place on the TiVo and not overwriting the old file. Can't think what else could be the problem!

Is the timestamp on the TiVo file changing after you upload the new file? Can you make an intentional change in the file on the PC and upload it to the TiVo - does the change appear on the TiVo?


----------



## njh

> _Originally posted by tivo-onion _
> 
> so does that mean that by default, adding start padding to a recording will automatically stop a prior suggestion being recorded?
> 
> Chris


No - I think you will find that in that the suggestion is recorded without end padding, and start padding will not be applied to the scheduled recording - the cut over between the suggestion recording and the scheduled recording happens at the time scheduled in the program guide, exactly as it would if endpad wasn't running.

If I read Sanderson correctly, any padding added at this point will risk cancellation of the scheduled recording - if adding padding creates a conflict which involves a recording in progress then that recording takes precedence.

Regards,


----------



## tivo-onion

> _Originally posted by njh _
> *No - I think you will find that in that the suggestion is recorded without end padding, and start padding will not be applied to the scheduled recording - the cut over between the suggestion recording and the scheduled recording happens at the time scheduled in the program guide, exactly as it would if endpad wasn't running.
> 
> If I read Sanderson correctly, any padding added at this point will risk cancellation of the scheduled recording - if adding padding creates a conflict which involves a recording in progress then that recording takes precedence.
> 
> Regards, *


Thanks for that. It seems then that only end-padding will result in a suggestion being cancelled! I will update my daily mail generator appropriately.

cheers

Chris


----------



## pahunt

Just noticed that Endpad crashed yesterday with these messages in the error log.



> Error detected
> commit failed (0x00030007)
> 
> while executing
> "transaction {uplevel $body}"
> (procedure "RetryTransaction" line 5)
> invoked from within
> "RetryTransaction {
> 
> # Alter the database record to add the padding
> set db [dbopen $dbPoolSize]
> set rec [db $db openid $recfsid]
> ..."
> Thursday 12:10:01 : Attempting to recover
> Thursday 12:10:31 : Error detected
> can't scan path (0x00070009)
> 
> while executing
> "mfs scan "/Recording/Active" -start "3:" -count 1"
> ("uplevel" body line 2)
> invoked from within
> "uplevel $body"
> invoked from within
> "transaction {uplevel $body}"
> (procedure "RetryTransaction" line 5)
> invoked from within
> "RetryTransaction {
> set currec [mfs scan "/Recording/Active" -start "3:" -count 1]
> set nextrec [mfs scan "/Recording/Active" -start "4:" -count 2]
> ..."
> Thursday 12:10:31 : Attempting to recover
> Thursday 12:10:31 : Too many errors, stopping


I've not seen an error like this before and a search in this thread didn't find anything similar either.


----------



## sanderton

I've occasionally seen that from an mfs scan. It either means that the database was exceptionally busy when it was being read, or possibly that there is a hard disk/data integrity problem.

Keep an eye out; if it doesn't recur I'd suspect teh former.


----------



## pahunt

> _Originally posted by sanderton _
> *I've occasionally seen that from an mfs scan. It either means that the database was exceptionally busy when it was being read, or possibly that there is a hard disk/data integrity problem.
> 
> Keep an eye out; if it doesn't recur I'd suspect teh former. *


I'll hope for the former 

Thanks Stuart


----------



## tivo_boj

Slightly ( maybe way) off subject I know, but my hard disk is S.M.A.R.T, but is not enabled. what command at the bash do I need to enable it to ensure hard disk problems are captured early


----------



## Fozzie

See this thread


----------



## tivo_boj

Thanks. Should have used search


----------



## russellg

Hello, thanks for such a great program.

I'm seeing this problem... It appears that it added time to the end of a Suggestion, thus causing a scheduled show starting just afterwards to not be recorded. Note that the scheduled recording wasn't an SP, it was just a show that I had told Tivo to record. I found a similar post from "gl9500" on Jan. 8th (post 1634960 - sorry, won't let me hyperlink) saying the same thing, so I'm wondering if there really is a problem here somewhere.

I installed version 1.3.3 ok, and set all SPs back to zero minutes extra time before and after. I also reorganized the SPs to cause them to be re-indexed. This was all done several hours before the problem happened.

The day before, I had told Tivo to record a show called Air Force One, which started at 9:30pm. At 9:55pm, I noticed it wasn't recording. I checked the Recording History page on Tivo and it said it wasn't recorded because someone in the household chose to record something else (definitely not true).

I then checked the EndPad log via TivoWeb, and found the section included below. From what I can tell, it looks like a suggestion called Modern Marvels was being recorded from 8:30pm to 9:30pm (I've verified that it shows up now as a suggestion in the Now Playing list). At 9:25pm, EndPad added 15 minutes to the end of it, even though Air Force One was due to start at 9:30. It was my understanding that EndPad would give priority to the scheduled recording. Certainly it should, or you'd never know when a suggestion would cause you to lose a show you actually wanted.

Here's my EndPad entry from /etc/rc.d/rc.sysinit.author:

/hack/endpad.tcl 0 15 -auto > /dev/null 2>&1 &

Any ideas? Thanks!

Russell

=====================

Wednesday 20:40:00 : Woken up
Wednesday 20:40:00 : Recording {Modern Marvels} on HIST now
Wednesday 20:40:00 : Recording Scheduled End Time: 21:30
Wednesday 20:40:00 : Next recording is {Air Force One} on NGEO at 21:30
Wednesday 20:40:00 : No episode tracking done at this time
Wednesday 20:40:00 : Not time to add end padding yet
Wednesday 20:40:00 : Next end padding setting due 21:25
Wednesday 20:40:00 : Can't add start padding to {Air Force One}
Wednesday 20:40:00 : No start padding requested
Wednesday 20:40:00 : Start padding of 0 seconds already set
Wednesday 20:40:00 : Next start padding setting due 21:40
Wednesday 20:40:00 : Next wake up will be 21:10
Sleeping, checking every minute for kill signal............................... 
Wednesday 21:10:00 : Woken up
Wednesday 21:10:00 : Recording {Modern Marvels} on HIST now
Wednesday 21:10:00 : Recording Scheduled End Time: 21:30
Wednesday 21:10:00 : Next recording is {Air Force One} on NGEO at 21:30
Wednesday 21:10:00 : No episode tracking done at this time
Wednesday 21:10:00 : Not time to add end padding yet
Wednesday 21:10:00 : Next end padding setting due 21:25
Wednesday 21:10:00 : Can't add start padding to {Air Force One}
Wednesday 21:10:00 : No start padding requested
Wednesday 21:10:00 : Start padding of 0 seconds already set
Wednesday 21:10:00 : Next start padding setting due 21:40
Wednesday 21:10:00 : Next wake up will be 21:25
Sleeping, checking every minute for kill signal................ 
Wednesday 21:25:01 : Woken up
Wednesday 21:25:01 : Recording {Modern Marvels} on HIST now
Wednesday 21:25:01 : Recording Scheduled End Time: 21:30
Wednesday 21:25:01 : Next recording is {Air Force One} on NGEO at 21:30
Wednesday 21:25:01 : No episode tracking done at this time
Wednesday 21:25:01 : Added 900 seconds end padding to {Modern Marvels}
Wednesday 21:25:01 : Next end padding setting due 22:25
Wednesday 21:25:01 : Can't add start padding to {Air Force One}
Wednesday 21:25:01 : No start padding requested
Wednesday 21:25:01 : Start padding of 0 seconds already set
Wednesday 21:25:01 : Next start padding setting due 21:40
Wednesday 21:25:01 : Next wake up will be 21:40
Sleeping, checking every minute for kill signal................ 
Wednesday 21:40:00 : Woken up
Wednesday 21:40:00 : Recording {Modern Marvels} on HIST now
Wednesday 21:40:00 : Recording Scheduled End Time: 21:45
Wednesday 21:40:00 : Next recording is {A Stranger In Our Home} on ABN2 at 23:00
Wednesday 21:40:00 : No episode tracking done at this time
Wednesday 21:40:00 : No end padding required:
Wednesday 21:40:00 : End padding of 900 seconds already set
Wednesday 21:40:00 : Next end padding setting due 23:40
Wednesday 21:40:00 : Can't add start padding to {A Stranger In Our Home}
Wednesday 21:40:00 : No start padding requested
Wednesday 21:40:00 : Start padding of 0 seconds already set
Wednesday 21:40:00 : Next start padding setting due 23:10
Wednesday 21:40:00 : Next wake up will be 22:10
Sleeping, checking every minute for kill signal...............................


----------



## sanderton

EndPad will only delete the subsequent show if it has a Type of 6, which is a Suggestion.

Could you go to Recording History in TivoWeb, find the cancelled show and post the text that TivoWeb has on it. It would also be useful to see the "object" data - when you have the recording history page up for the show, change "showing" in the URL to "object".

Also, what version of the TiVo software are you running?


----------



## russellg

Hi sanderton, thanks for the reply.

Unfortunately, after I realized it wasn't recording, I tried to start recording it from the middle of the show, and it ended up not getting it all. That in itself changed the entry in the recording history. But then I ended up deleting the partial recording this morning, so now the only entry in recording history is "deleted", and there's no longer any info about why it wasn't recorded -- at least not on that page -- maybe there's a log somewhere else?

You said EndPad will only delete the subsequent show if it has a type of 6, which is a suggestion. However, keep in mind that it appears that EndPad never actually cancelled the recording of the second show -- Tivo did, because it saw that "the user" (actually EndPad) had changed the end time of the first show, thus overlapping with the start time of the second show. The original message in the recording history was something along the lines of, "it wasn't recorded because someone in the household chose to record something else."

I believe EndPad is somehow not seeing the scheduled non-SP recording correctly. It's apparently not seeing it as a suggestion, because as you said, it would have been cancelled, and it wasn't. But it's also somehow not seeing it as a scheduled recording, because it should have cancelled the first show. (actually if I hadn't set EndPad to start shows 1 minute early, it could have just let the suggestion record without any modification -- but since I did, I believe it should have cancelled it, or possibly cut it off early)

If you take another look at the article I mentioned, I think the other guy was saying the same thing. He was recording two SP shows back-to-back, followed immediately by a scheduled non-SP recording, and instead of only modifying the end time of the last show, EndPad modified the end time of the second show, and then it was actually Tivo that cancelled the recording of the third -- not EndPad. Here's the relative URL for his post:

/tivo-vb/showthread.php?postid=1634960#post1634960

Also, here's the object data of the show that got skipped in my case:

Showing 665862/25 {
Date = 12487
Duration = 3600
Program = 657111/-1
Reason = 2
Station = 611991/-1
Time = 77400
TvRating = 4
IndexUsedBy = 665862/10
}

You asked which version of Tivo I'm running. I'm actually in Australia, using their 3.0 Release 1 software on a US Tivo (that's the most common setup for our group here actually).

Thanks!

Russell


----------



## Dunkwho

Hi all ...

my endpad died again yesterday ... programs recorded yesterday evening & during the night don't have any padding - the bottom of the log file is:

Sleeping, checking every minute for kill signal............................ 
Wednesday 11:57:00 : Woken up
Wednesday 11:57:00 : No recording in progress
Wednesday 11:57:00 : Next recording is {Bargain Hunt} on BBC1SE at 12:00
Wednesday 11:57:00 : No end padding required:
Wednesday 11:57:00 : No recording in progress
Wednesday 11:57:00 : Next end padding setting due 12:25
Wednesday 11:57:00 : Added 120 seconds start padding to {Bargain Hunt}
Wednesday 11:57:00 : Next start padding setting due 12:25
Wednesday 11:57:00 : Next wake up will be 12:25
Sleeping, checking every minute for kill signal............................. 
Wednesday 12:25:00 : Woken up
Wednesday 12:25:00 : Recording {Bargain Hunt} on BBC1SE now
Wednesday 12:25:00 : Recording Scheduled End Time: 12:30
Wednesday 12:25:00 : Next recording is {Let it Rain} on C4 at 12:30

Theres a endpad.err sitting on my tivo date stamped at 12:25 10/3/04 (same time as last entry in endpad.log) but I can't get at it right now (need to mod some tivo settings to allow me to ftp mfs - god damn securemote) ... if its needed for proper debug pls let me know, I'll try and get at it tonight and post it.

Duncan


----------



## sanderton

Russell - don't know, basically. If the TiVo is deleting the show it's because EndPad has forged ahead and added the padding regardless. But it can see the next show's start time, as is shown by the log.

It can't be something generic wrong in the script, as EndPad must have supervised thousands of back-to-back recordings.

My best guess would be the well known and utterly unrepeatable MFS bug where a database contentiom means that instead of returning an id it returns and stores an error value, so the the start time of the second showing was in some way corrupted. Maybe.


Dunkwo - need to see the .err file.


----------



## dave h-j

My endpad had also died today. couldnt find it on a ps, so ran the -stop argument. It complained of having a stale pid file and deleted it.

I started it up again and it seems to be running. endpad.err was blank (date stamped back in February)..

Thursday 10:25:01 : Next start padding setting due 12:52
Thursday 10:25:01 : Next wake up will be 10:55
Sleeping, checking every minute for kill signal............................Thursday 13:24:59 : 
Thursday 13:24:59 : endpad.tcl 1.3.3 log file, starting up
Thursday 13:24:59 : Start padding set to 120 seconds
Thursday 13:24:59 : End padding set to 120 seconds
Thursday 13:25:01 : Woken up


----------



## sanderton

It's the weather.


----------



## Dunkwho

Here we are ... managed to remember the hoops I need to jump to just to get ftp running ... grrr 

This is the 2nd time endpad has stopped working ... grateful for any info .


----------



## gl9500

Stuart, (et. al.)

I believe this situation described in this post is the same "bug" that I stumbled across...

http://www.tivocommunity.com/tivo-vb/showthread.php?postid=1798463#post1798463

It is because we are using US Tivo software version 3.x and selectionType's are different for version3. I've hardcoded my endpad.tcl to correctly check in version3...



Code:


set cselectiontype [dbobj [dbobj $crec get RecordingBehavior] get PresentationBehavior]
...
set nselectiontype [dbobj [dbobj $nrec get RecordingBehavior] get PresentationBehavior]


----------



## gl9500

I've also hacked Stuart's endpad 1.3.3 to "stop" suggestions recording where it would interfere w/ adding startpadding to a "real" recording.

here're the mods to make in v1.3.3 endpad.tcl

after the first line, add these...



Code:


source $tcl_library/tv/sendkey.tcl
# disable keyname echoing to controling tty
set verboseSendKeyG 0

then find the first and last line of this next mod and insert...



Code:


      # if there's a "real" recoding going on we need to see if there is space a
vailable

      ## supposed to stop a suggestion rec... (works for my tivo, US version3.x, YMMV)
      ## if can add startpad to next "real" rec
      if {$isrec == 1 && $cselectiontype == 6 && $nselectiontype != 6} {
        puts $logchan "[clock format [clock seconds] -format $datestamp] : current recording is a SUGGESTION $ctitle"
        ## stop suggestion recording
        SendKey livetv
        after 2000
        SendKey clear
        after 2000
        SendKey enter
        after 2000
        #
        set isrec 0
      }

      if {$isrec == 1} {

As you can see, it "stops" the suggestion recording by changing channels (flipping to previous channel). This should work under most circumstances. One side-effect is, if your Tivo is in Standby mode, it will not be after this code runs. And just about the only time the "previous" channel won't be available is immediately after a Restart.

Works for me, YMMV.


----------



## sanderton

> _Originally posted by Dunkwho _
> *Here we are ... managed to remember the hoops I need to jump to just to get ftp running ... grrr
> 
> This is the 2nd time endpad has stopped working ... grateful for any info . *


Hmm. The syntax error reported in the error log is not there in my copy of 1.3.3 - I can only think that the endpad.tcl file has somehow become corrupted. Re-install it.


----------



## Dunkwho

ahem ... 1.2.6 on my machine ... updated now, thanks!


----------



## sanderton

Aha. That will also cure the other errors listed in your log file (or rather, EndPad will recover from them instead of just stopping).


----------



## Milhouse

A small modification to Endpad 1.3.3....

Endpad 1.3.4 will change the recording quality of Suggested recordings to the quality level specified by a configurable option (suggestionRecQuality). I find this useful as now I can set my default recording quality to Best and thanks to Endpad 1.3.4 my suggested recordings will record at Medium.

If you specify a setting of -1 then Endpad 1.3.4 will behave identically to 1.3.3 - ie. no change of recording quality for Suggestions.

The default recording quality for Suggestions is Medium.

Edit: Attachment removed, now available from first post in this thread (thanks Stuart!)


----------



## sanderton

I've incorpoporated the code into 1.3.4 in the top post.

Please only post the mods you make, not complete versions - with so many people using EndPad (?1000) I'm trying to keep version control reasonably tight.

Thanks for the mod though.


----------



## Fozzie

Stuart,

You left this line in 1.3.4:

puts $logchan "[clock format [clock seconds] -format $datestamp] : endpad.tcl 1.3.3 log file, starting up"


----------



## sanderton

D'oh. I'm alwayss doing that. My later hacks have a variable right at the top to change all references!


----------



## Mike Laskey

Stuart,

Just wanted to add my thanks to you for the endpad extension. My Tivo is now recording 2 minutes of pre-padding and 5 minutes of end padding. I've no idea why Tivo didn't do this themselves!

Mike.


----------



## jasch

Sanderton, great work and a great idea! Altough I think I found a bug with two tuners...

If there is nothing recording at the same time on the other tuner, the recording get's softwadded perfectly... but if the other tuner is recording whatever, the softpaddin does not occur.

For example, I record a program every day at 7:30am. The recording is normally 32 minutes (1 minute of before and after padding).

Yesterday I was recording a movie on the other tuner from 7am -> 9am. The 7:30 recording did not get softpadded, even tough it could have been, since the 1st tuner was not being used...

I was using 1.3.3, I just upgradedd to 1.3.4, but I don't think this problem has been solved.

Thanks again, and keep the great work.


----------



## sanderton

For a two tuner machine, falconx has added full two tuner support; you can find his version on Deal Database.


----------



## Fletch

I just started testing the latest version (1.3.4) on a Series 1 SA and had the following occur:

The following were in the TDL:
Show 1, 4-4:30PM, SP
Show 2, 4:30-5PM, SP
Show 3, 5-5:30PM, Sugg

endpad is running with start=5 and end=15

The result (verified by the endpad loffile):
Show 1 was start padded and Show 3 was endpadded. Shouldn't the suggestion have been deleted to allow for end padding of Show 2?


----------



## sanderton

Yes. Could you post the actual log?

What version of the TiVo software are you using?


----------



## Fletch

Thanks for your help.

TiVo Information:


Code:


Current Channel
Channel:	301 TV Land
Program:	Love Boat
Episode:	April's Love; Happy Ending; We Three
Description:	April returns with her fiance; two writers decide to finish their marriage with their script; a girl unknowingly befriends her father.
Recording Status:	Not Recording
TiVo Box Information
Current Temperature:	38C
Software System:	3.0-01-1-010
Remote Address	1
Uptime	12d 23h 52m 45s
Kernel Information

Version 2.1.24-TiVo-2.5
Compile #8 Wed May 8 15:38:27 PDT 2002

Memory Information

Memory Statistics:
        total:    used:    free:  shared: buffers:  cached:
Mem:  14278656 14114816   163840 68431872    77824  3923968
Swap: 133165056  7598080 125566976
MemTotal:     13944 kB
MemFree:        160 kB
MemShared:    66828 kB
Buffers:         76 kB
Cached:        3832 kB
SwapTotal:   130044 kB
SwapFree:    122624 kB

Space Used - 123839 MB
Expired Suggestion 	16 	45393 MB 	36.7% 	17:31:57
Single 	1 	1294 MB 	1.0% 	0:30:00
Season Pass 	1 	1512 MB 	1.2% 	0:35:01
Suggestion 	28 	72596 MB 	58.6% 	28:00:52
Invisible 	1 	72 MB 	0.1% 	0:21:00
Live Cache 	1 	1632 MB 	1.3% 	0:38:17
Total 	48 	122499 MB 	98.9% 	47:37:07

Relevant portion of logs:


Code:


Sleeping, checking every minute for kill signal...............................
Wednesday 03:24:00 : Woken up
Wednesday 03:24:00 : Recording {Screech Owls} on DCKIDS now
Wednesday 03:24:00 : Recording Scheduled End Time: 03:30
Wednesday 03:24:00 : Next recording is Nightcap on MOMAX at 04:00
Wednesday 03:24:00 : No episode tracking done at this time
Wednesday 03:24:00 : Not time to add end padding yet
Wednesday 03:24:00 : Next end padding setting due 03:25
Wednesday 03:24:00 : Not time to add start padding yet
Wednesday 03:24:00 : Next start padding setting due 03:54
Wednesday 03:24:00 : Next wake up will be 03:25
Sleeping, checking every minute for kill signal..
Wednesday 03:25:00 : Woken up
Wednesday 03:25:00 : Recording {Screech Owls} on DCKIDS now
Wednesday 03:25:00 : Recording Scheduled End Time: 03:30
Wednesday 03:25:00 : Next recording is Nightcap on MOMAX at 04:00
Wednesday 03:25:00 : No episode tracking done at this time
Wednesday 03:25:00 : Added 900 seconds end padding to {Screech Owls}
Wednesday 03:25:00 : Next end padding setting due 04:25
Wednesday 03:25:00 : Not time to add start padding yet
Wednesday 03:25:00 : Next start padding setting due 03:54
Wednesday 03:25:00 : Next wake up will be 03:54
Sleeping, checking every minute for kill signal..............................
Wednesday 03:54:00 : Woken up
Wednesday 03:54:00 : No recording in progress
Wednesday 03:54:00 : Next recording is Nightcap on MOMAX at 04:00
Wednesday 03:54:00 : No episode tracking done at this time
Wednesday 03:54:00 : No end padding required:
Wednesday 03:54:00 : No recording in progress
Wednesday 03:54:00 : Next end padding setting due 04:25
Wednesday 03:54:00 : Added 300 seconds start padding to Nightcap
Wednesday 03:54:00 : Next start padding setting due 04:25
Wednesday 03:54:00 : Next wake up will be 04:24
Sleeping, checking every minute for kill signal...............................
Wednesday 04:24:00 : Woken up
Wednesday 04:24:00 : Recording Nightcap on MOMAX now
Wednesday 04:24:00 : Recording Scheduled End Time: 04:30
Wednesday 04:24:00 : Next recording is Nightcap on MOMAX at 04:30
Wednesday 04:24:00 : No episode tracking done at this time
Wednesday 04:24:00 : Can't add end padding to Nightcap
Wednesday 04:24:00 : Gap is 0 seconds
Wednesday 04:24:00 : Next end padding setting due 04:25
Wednesday 04:24:00 : Can't add start padding to Nightcap
Wednesday 04:24:00 : Gap is only 0 seconds
Wednesday 04:24:00 : Next start padding setting due 04:25
Wednesday 04:24:00 : Next wake up will be 04:25
Sleeping, checking every minute for kill signal..
Wednesday 04:25:00 : Woken up
Wednesday 04:25:00 : Recording Nightcap on MOMAX now
Wednesday 04:25:00 : Recording Scheduled End Time: 04:30
Wednesday 04:25:00 : Next recording is Nightcap on MOMAX at 04:30
Wednesday 04:25:00 : No episode tracking done at this time
Wednesday 04:25:00 : Can't add end padding to Nightcap
Wednesday 04:25:00 : Gap is 0 seconds
Wednesday 04:25:00 : Next end padding setting due 04:55
Wednesday 04:25:00 : Can't add start padding to Nightcap
Wednesday 04:25:00 : Gap is only 0 seconds
Wednesday 04:25:01 : Next start padding setting due 04:55
Wednesday 04:25:01 : Next wake up will be 04:55
Sleeping, checking every minute for kill signal...............................
Wednesday 04:55:00 : Woken up
Wednesday 04:55:00 : Recording Nightcap on MOMAX now
Wednesday 04:55:00 : Recording Scheduled End Time: 05:00
Wednesday 04:55:00 : Next recording is M*A*S*H on HALMRK at 05:00
Wednesday 04:55:00 : No episode tracking done at this time
Wednesday 04:55:00 : Can't add end padding to Nightcap
Wednesday 04:55:00 : Gap is 0 seconds
Wednesday 04:55:00 : Next end padding setting due 05:25
Wednesday 04:55:00 : Can't add start padding to M*A*S*H
Wednesday 04:55:00 : Gap is only 0 seconds
Wednesday 04:55:00 : Next start padding setting due 05:25
Wednesday 04:55:00 : Next wake up will be 05:25
Sleeping, checking every minute for kill signal...............................
Wednesday 05:25:00 : Woken up
Wednesday 05:25:00 : Recording M*A*S*H on HALMRK now
Wednesday 05:25:00 : Recording Scheduled End Time: 05:30
Wednesday 05:25:00 : Next recording is Friends on KTLA at 07:00
Wednesday 05:25:00 : No episode tracking done at this time
Wednesday 05:25:00 : Added 900 seconds end padding to M*A*S*H
Wednesday 05:25:00 : Next end padding setting due 07:25
Wednesday 05:25:00 : Not time to add start padding yet
Wednesday 05:25:00 : Next start padding setting due 06:54
Wednesday 05:25:00 : Next wake up will be 05:55
Sleeping, checking every minute for kill signal...............................


----------



## sanderton

And MASH was a suggestion?

Can you use TiVoweb to extract the data about it:

Find the episode details from Now Showing (or Recording history if you've deleted it), change the word showing to object in the URL, eg:

http://xxx.xxx.xxx.xxx/showing/688505/11

to

http://xxx.xxx.xxx.xxx/object/688505/11

there should be a link named "IndexusedBy", follow it and cut and paste the page of data here. Thanks!


----------



## Fletch

> _Originally posted by sanderton _
> *And MASH was a suggestion?*


Yes.

From http://tivo.lan/object/3223321/10:


Code:


Recording 3223321/10 {
  Version        = 28
  BitRate        = 0
  ExpirationDate = 12506
  ExpirationTime = 18000
  ProgramSource  = 1388534/-1
  RecordingBehavior = 3223321/12
  Score          = 0
  SelectionType  = 3
  Showing        = 3223321/11
  SubPriority    = 268632575
  UsedBy         = 1
  StartDate      = 12501
  StartTime      = 17999
  EndPadding     = 900
  ActualShowing  = 3223321/14 3223321/18
  Part           = 3223321/13 3223321/15 3223321/16 3223321/17 3223321/19
  StopDate       = 12501
  StopTime       = 20701
  State          = 4
  DeletionDate   = 24855
  StreamFileSize = 1990656
  IndexUsed      = 3223321/11 3223321/12
  IndexPath      = /Recording/Active/1:12501:17999:3223321 /Recording/NoReRecord/99465:1:99999:03223321 
/Recording/SeasonPass/01388534/87498:81999:3223321 /Recording/TmsId/EP0027100076:87498:82000:3223321 
/Recording/NowShowingByClassic/6:87498:82000:3223321 /Recording/NowShowingByExpiration/5:12506:18000:3223321 
/Recording/NowShowingByTitle/1:MASH:87498:82000:3223321 /Recording/DiskUsed/10/3223321:1990656
}


----------



## sanderton

I can see the problem.

I'll work on a fix over the weekend.


----------



## Fletch

Cool, thanks. Let me know if I can provide additional data. In the meantime, do you have any hints on how to avoid this?


----------



## sanderton

Switching suggestions off?


----------



## sanderton

New version of EndPad is in the top post.

Changes:

Fixed bug which did not pad if a suggestion immediately followed a show on some US TiVos
Back to back suggestions on same channel no longer cancels the second one
You can now prevent suggestions cancelling other suggestions with a command line switch
You can change the recording quality used by suggestions with a command line switch
EndPad can now be placed anywhere, not just /var/hack
Code tidied and speeded up a little
Logfile tidied up with clearer info
The syntax to launch EndPad has been regularised to allow future additions - this means that if you install the new version and you have EndPad launched from a startup script you will need to edit that script for the new commands.

Has run for 24hrs on my two TiVos with no problems, but please report bugs etc.


----------



## ddub

Seems to work fine here Stuart. Thanks !

- had to delete the pid file from /var/run/ before I could run it though, got "endpad is already running". Even though I'd killed the process.

good work!
Darren


----------



## russellg

> Fixed bug which did not pad if a suggestion immediately followed a show on some US TiVos


Hi, thanks for the update. Sorry to nitpick, but I wonder if this also fixes the problem I mentioned, which is that if a show immediately follows a suggestion, the suggestion was padded, thus cancelling the show (on a US Tivo). I believe the problem you mention above is the opposite, where a suggestion comes after a show, and the show wasn't padded.

Here's the relative URL to my original post:
/tivo-vb/showthread.php?postid=1798463#post1798463

Thanks,

Russell


----------



## Fozzie

Good work Stuart. Thanks.


----------



## Fletch

What does "-sugqual 0" do?


----------



## Fozzie

> _Originally posted by Fletch _
> *What does "-sugqual 0" do? *


Hmmm, you did read the first post? 

"Note 3: EndPad has the ability to alter the recording quality of any suggestions, allowing you to, say record suggestions at Medium while leaving the default at Best, making setting up SPs faster. Use the optional -sugqual switch with values of 0 (Basic), 40 (Medium), 75 (High) or 100 (Best)"


----------



## Fletch

Thanks. Somehow I confused myself into thinking there were only three recording qualities...


----------



## sanderton

> _Originally posted by ddub _
> *Seems to work fine here Stuart. Thanks !
> 
> - had to delete the pid file from /var/run/ before I could run it though, got "endpad is already running". Even though I'd killed the process.
> 
> good work!
> Darren *


Did you stop it with endpad.tcl -stop or just kill it?


----------



## sanderton

> _Originally posted by russellg _
> *Hi, thanks for the update. Sorry to nitpick, but I wonder if this also fixes the problem I mentioned, which is that if a show immediately follows a suggestion, the suggestion was padded, thus cancelling the show (on a US Tivo). I believe the problem you mention above is the opposite, where a suggestion comes after a show, and the show wasn't padded.
> 
> Here's the relative URL to my original post:
> /tivo-vb/showthread.php?postid=1798463#post1798463
> 
> Thanks,
> 
> Russell *


Yes, it will (I hope, not having a US TiVo to test it on). It wasn't correctly identifying some shows as suggestions under 3.x - it should now.


----------



## ddub

> Did you stop it with endpad.tcl -stop or just kill it?


Yes, i tried that, It told me that it might take a minute. I also noticed a new file in var/hack called endpad.kill

I waited a few more mins, and tried starting endpad again, and got the same message "endpad is already running".

so sweat anyway, once I'd deleted the PID file, it started anyway.

thanks
DArren


----------



## orange

Just to let you know I had the same issue with getting the still running message and also had to delete the PID file.

My TiVo was restarted which caused this problem, so endpad.tcl -stop was not used. I was just testing to see if it would came back to life after a power failure or tivo provoked reboot. As I found the answer appears to be no.

I am running version 2.5.5a-01-1-023 of the software. If you need any more help please contact me. Apart from that top work!


----------



## sanderton

What command line is in your start up script?

You need to have the -auto flag in it to run it at startup.


----------



## mark.stringer

My endpad.log is showing all times as GMT so everything is actually one hour less than it should be. For instance, for Holiday which is on at 19:00 BST this evening I get:

Monday 17:30:06 : endpad.tcl 1.4.0 log file, starting up
Monday 17:30:06 : Start padding set to 60 seconds
Monday 17:30:06 : End padding set to 180 seconds
Monday 17:30:06 : Suggestions will not be padded if another suggestion immediately follows them
Monday 17:30:06 : Detected TiVo software version 2.5.5-01-1-023
Monday 17:30:06 : Suggestions will be recorded in High
Monday 17:30:06 : Woken up
Monday 17:30:07 : No recording in progress
Monday 17:30:07 : Next recording is Holiday on BBC1NI at 18:00
Monday 17:30:07 : No end padding required:
Monday 17:30:07 : No recording in progress
Monday 17:30:07 : Next end padding setting due 18:25
Monday 17:30:07 : Not time to add start padding yet
Monday 17:30:07 : Next start padding setting due 17:58
Monday 17:30:07 : Next wake up will be 17:58
Sleeping, checking every minute for kill signal.........................


When I type date on the Tivo I also get the GMT time.

Does endpad need a fix for this or is there something up with my Tivo? The time on the Tivo screens and on the TivoWeb info page shows correctly with the +1 hour for BST added.

Thanks,
Mark.


----------



## sanderton

This is "as designed". TiVo's internal clock runs on GMT. I left the log in GMT partly for ease of debugging as the other log files in /var/log are also in GMT; but mainly because I couldn't be arsed to write the code to make it local time.


----------



## mark.stringer

OK Stuart, thanks, as long as I know it is as designed. Whilst I have your attention can I be cheeky enough to ask how the tracker module is going? Or is your development time limited/on other projects at the moment?

Thanks,
Mark.


----------



## sanderton

Development time is spouse-limited at thet the moment!


----------



## SteveJones

I've been running endpad since about the first version with little problem. What an excelent utility!

However I am having problems with the latest version 1.4.0 running from rc.sysinit.author.

It starts, and stops, fine from a Telnet session and all the parameters work as they should, but try as I might I can't get this version to run from a reboot.

The line in my rc.sysinit.author file is:
/var/hack/endpad.tcl -s 1 -e 5 -sugqual 40 -sugeq -auto >> dev/null &

All the other progs in rc.sysinit.author start up OK as did previous versions of endpad.

Any ideas what's wrong?

Steve


----------



## iankb

I don't know what effect it would have but I think 'dev/null' should be '*/*dev/null'.


----------



## SteveJones

Thanks Ian, I'll give that a try tomorrow.

I notice in the startup line for autospace.tcl it is /dev/null but I'm sure I had dev/null running earlier versions of endpad with no problems.

Steve


----------



## Fozzie

I use /dev/null


----------



## sanderton

Steve - without the first / the command will fail.

You don't actually need all of the stuff after the endpad command as EndPad backgrounds itself; belt and braces!


----------



## kitschcamp

> _Originally posted by sanderton _
> *Development time is spouse-limited at thet the moment! *


Sounds like you have plans to change that


----------



## sanderton

It's more that the rugby season is approaching its end too - I don't know what to do with myself in the summer months!


----------



## davestretty

Hi Stuart,
I'm new to tivocommunity, but have been reading your posts on soft padding to cure tivo's most annoying fault i.e missing prog ends. Brilliant solution!!!!!! Unfortunately the actions described may as well be in swahili as i have no tivo hacking experience! Is an idiots guide available? Please help as you appear to be my only hope of avoiding continual spousal earache! A larger harddrive would also be useful but again a uk tivo based idiots guide is needed. 
ps my tivo is 18months old and has 2.5.5a software 
cheers
Dave E


----------



## sanderton

There are step by step walkthroughs on installing EndPad in the thread above. If they don't seem frantically simple I'm afraid it's because it isn't!

There are step by steps for upgrading your hard disk in this forum too.

You need to do plenty of reading until the fog begins to clear. It will! I don't recommend doing anything other than a hard disk upgrade "blind" ie with a set of instructions you don't understand. Do that first; maybe have a read of "Linux for congenital morons" or whatever.


----------



## racingclub

I'm running the latest version with the switch to record sugg. in Medium. This is confirmed in the enpad log file.

However, suggestions are still being recorded in High (my default setting) - any ideas?


----------



## doubledrat

davestretty: you can also buy pre-upgraded disks, so you just have to swap for the old ones. much easier for the uninitiated.

getting your machine to the state where you can endpad is not easy esp. if you are not familiar with linux. maybe you can impose on a knowledgeable friend? it's well worth it 

I can't remember the last time I got a "bong of death"!


----------



## Mike Jones

Yes!!!

I've managed to install endpad on both my TIVO's and from the logs it appears that I've done it right, and without having to ask for help. Hey, I'm learning


----------



## orange

> _Originally posted by racingclub _
> *I'm running the latest version with the switch to record sugg. in Medium. This is confirmed in the enpad log file.
> 
> However, suggestions are still being recorded in High (my default setting) - any ideas? *


I am experiencing the same. I have over come the rebooting issue, without changing any settings it just seemed to correct itself ... one of the great things about software! 

Would be great to be able to have this working on the suggestions so I can get more on the drive.


----------



## Mike Jones

I've installed endpad on both my TIVO's with the instructions at the start of this thread, and put them into rc.sysinit.author

I think this in part might be due to missing "/" in start up file as referred to above by IanKB. Start post needs editing to reflect this.

However problem still exists, as endpad is definately on at present, but log shows:

Saturday 19:27:00 : Next wake up will be 19:57
Sleeping, checking every minute for kill signal......

It's 20:30 and it hasn't woken up.


----------



## Mike Jones

Deleted


----------



## sanderton

Endpad's log in in GMT.


----------



## Mike Jones

I was just starting to think it was something to do with BST! I was about to do a search to see if there was a problem with TIVOweb and the time change.

I guess that means there are no problems. THanks


----------



## marcdbl

Ok, I'm a bit behind the game on this thread, having only just seen it!

I'm hoping someone can clear up a question for me, as I'm baffled by this soft/hard padding business, and exactly how endpad deals with different scenarios

I'm sure this question has been answered at least once already I expect, but I'll ask my question by example to try and make it clearer (to me at least ;-)):

Situation is:

- I haven't yet installed endpad
- Currently I have no padding on any of my SPs (apart from one) because of the problem with conflicts
- The one SP that does have padding is my Formula 1 SP, which has 1 hour of padding (I'd rather risk clobbering other recordings than risk missing the end of a race)
- I want to install endpad and have it add 2 mins to all my recordings 

Question is:

- If I run endpad, with a 2 min pad configured, will the Formula 1 record with a pad of 2 mins, 60 mins, or 62 mins?


Thanks in advance, and nice work sanderton!


----------



## bobnick

Hmmm, not sure now. Will have to double check!


----------



## ccwf

Unless Stuart's changed the behaviour, you'll get 60 minutes since Endpad uses the larger of the two paddings. There's code early in this thread on how to change the paddings to add instead for those who desire that.


----------



## sanderton

As Charles says, you'll get 60.


----------



## mebrown

Dear all
I hope that someone can help a newbie to the TiVo hacking lark. I followed Hinsdale excellent upgrade instructions and am now the proud owner of a 120 Gb Hard drive in my TiVo. To resolve "her indoor's" main gripe about missing the end of programs i tried to install endpad following the instructions outlined in this forum and pinedragon.com. Unfortunately, i dont have a partition 7 on the new drive and no instructions on what to do in that eventuallity were around! So endpad doesnt work.
Can someone help and please can they give me some guidance in terms that i can follow reasonably straightforwardly?
Many thanks in advance
Mike


----------



## sanderton

Try partition 4 instead.


----------



## mebrown

I created the rc.sysinit.author on 9 then copied it to 4. I then did the chmod thing on 9 - should i have done that on 4? Instructions followed slavishly i'm afraid. Do we need to set the permissions on the file i copied to partition 4?
Thanks for your support and quick response
Mike


----------



## sanderton

The version on 4 is the "real" one - it's that one that must be made executable.


----------



## pmk

Hi

I am looking for instructions on how to install if you do not have ftp access etc. Does anyone know of a guide on how to do this? (e.g. install TiVo disk into PC, boot somehow, copy files over, add to appropriate scripts etc?)

I am led to believe they are in this thread somewhere but I have no idea what to search for to even have a chance of finding it in 750 replies.

TIA.


----------



## Fletch

How does endpad handle the TiVo "invisible" programs on the Discovery channel? (I don't know if this een takes place in the UK but I assume you are familiar with what I'm talking about.)


----------



## bignoise

I have an odd one.. I have a manual repeating recording set up every weekend from 6.30am to 6.55am, and a season pass for a show which comes on the same days at 7am, running for half an hour. With EndPad running, asked to record 2 minutes early and 5 minutes past the end. I find that my recording of the 7am show is 37 minutes long, as I'd expect - but the first 4 minutes are always missing! 

It's not worrying me but I thought it was a curiosity. Here's something from the log files:

Sunday 05:27:00 : Woken up
Sunday 05:27:00 : Recording {Three Friends & Jerry} on UKPANI now
Sunday 05:27:00 : Recording Scheduled End Time: 05:30
Sunday 05:27:00 : Next recording is {Rocko's Modern Life} on UKPANI at 05:30
Sunday 05:27:00 : Gap to next programme is 0 seconds
Sunday 05:27:00 : Can't add end padding to {Three Friends & Jerry}
Sunday 05:27:01 : Next end padding setting due 05:50
Sunday 05:27:01 : Gap to previous recording is 0 seconds
Sunday 05:27:01 : Can't add start padding to {Rocko's Modern Life}
Sunday 05:27:01 : Next start padding setting due 05:50
Sunday 05:27:01 : Next wake up will be 05:50
Sleeping, checking every minute for kill signal........................ 
Sunday 05:50:00 : Woken up
Sunday 05:50:00 : Recording {Rocko's Modern Life} on UKPANI now
Sunday 05:50:00 : Recording Scheduled End Time: 05:55
Sunday 05:50:00 : Next recording is Spider-Man on UKPANI at 05:58
Sunday 05:50:00 : Gap to next programme is 180 seconds
Sunday 05:50:00 : Added 178 seconds end padding to {Rocko's Modern Life}
Sunday 05:50:00 : Next end padding setting due 06:23
Sunday 05:50:00 : Can't add start padding to Spider-Man
Sunday 05:50:00 : Start padding of 120 seconds already set
Sunday 05:50:00 : Next start padding setting due 06:08
Sunday 05:50:00 : Next wake up will be 06:08
Sleeping, checking every minute for kill signal................... 
Sunday 06:08:00 : Woken up
Sunday 06:08:00 : Recording Spider-Man on UKPANI now
Sunday 06:08:00 : Recording Scheduled End Time: 06:30
Sunday 06:08:00 : Next recording is {The Golden Girls} on LIVINGR (Suggestion) at 09:00
Sunday 06:08:00 : Not time to add end padding yet
Sunday 06:08:00 : Next end padding setting due 06:25
Sunday 06:08:00 : Not time to add start padding yet
Sunday 06:08:00 : Next start padding setting due 08:57
Sunday 06:08:00 : Next wake up will be 06:25
Sleeping, checking every minute for kill signal.................. 
Sunday 06:25:00 : Woken up
Sunday 06:25:00 : Recording Spider-Man on UKPANI now
Sunday 06:25:00 : Recording Scheduled End Time: 06:30
Sunday 06:25:00 : Next recording is {The Golden Girls} on LIVINGR (Suggestion) at 09:00
Sunday 06:25:00 : Gap to next programme is 9000 seconds
Sunday 06:25:00 : Added 300 seconds end padding to Spider-Man
Sunday 06:25:00 : Next end padding setting due 09:25
Sunday 06:25:00 : Not time to add start padding yet
Sunday 06:25:00 : Next start padding setting due 08:57
Sunday 06:25:00 : Next wake up will be 06:55
Sleeping, checking every minute for kill signal...............................


----------



## pmk

> _Originally posted by pmk _
> *
> I am led to believe they are in this thread somewhere but I have no idea what to search for to even have a chance of finding it in 750 replies.
> *


Answering my own question but thought it would be useful...

See post dated 11-09-2003 11:03 PM by alphabeta for details. I suggest if you understand shell commands reading the thread from this point for more information but http://www.pinedragon.com/tivo/endpad_instructions.html gives you the main points.

I do have a couple of queries on this URL if anyone is familiar with shell commands who can help me?

1. Do I need to make the "make partition editable" with the commands already posted to this thread?

2. Is a chmod needed after the rc.sysinit.author file is copied to part7?

3. When the echo command is being used to create the rc.sysinit.author field is the &" and &" correct? These seem like strange combinations of letters together - no space needed?

4. I have an upgraded TiVo (120GB hard disk). Will the rc.sysinit.author file exist if it does do I need to do any extra chmods etc? I am assuming I will have either part4 *OR* part7 because of the upgrade - not both?

5. I am not planning on adding the line to get bash working but is there anything I can add to be able to check that endpad is running - e.g. view the log file etc after the TiVo is put back together?

Any help with the above would be greatly appreciated. TIA.


----------



## sanderton

> _Originally posted by bignoise _
> *Sunday 05:50:00 : Next recording is Spider-Man on UKPANI at 05:58
> Sunday 05:50:00 : Gap to next programme is 180 seconds
> Sunday 05:50:00 : Added 178 seconds end padding to {Rocko's Modern Life}
> Sunday 05:50:00 : Next end padding setting due 06:23
> Sunday 05:50:00 : Can't add start padding to Spider-Man
> Sunday 05:50:00 : Start padding of 120 seconds already set
> Sunday 05:50:00 : Next start padding setting due 06:08
> *


Very odd bit of log.

Your SP already has 2 mins of hard start padding, so EndPad won't touch it.

But why is the next start padding check time 6.08 when the recording starts at 6am?

Deeply odd. If anyone can see why that might happen please post!


----------



## alphabeta

For PMK:


> 1. Do I need to make the "make partition editable" with the commands already posted to this thread?


No - you only need to do this if the partition is running under Tivo's OS. If its running on a PC Linux disk then you are fine.



> 2. Is a chmod needed after the rc.sysinit.author file is copied to part7?


No - the copy will copy the permissions as well, but see point 4 as you have upgraded.



> 3. When the echo command is being used to create the rc.sysinit.author field is the &" and &" correct? These seem like strange combinations of letters together - no space needed?


Yes they are right. The quote pairs with the one at the start of the line to delimit the string to go in the rc.sysinit.author file. The & at the end of the line tells Linux to run the command in its own process so that the script will continue to execute and not wait for that command to terminate before moving on to the next one.



> 4. I have an upgraded TiVo (120GB hard disk). Will the rc.sysinit.author file exist if it does do I need to do any extra chmods etc? I am assuming I will have either part4 *OR* part7 because of the upgrade - not both?


A normal upgrade won't have created an rc.sysinit.author. However you will find only one of the 4/7 partitions exists. You will get an error when you try and mount the one that doesn't exist. In this case just make the changes to the one that does exist and ignore the other.



> 5. I am not planning on adding the line to get bash working but is there anything I can add to be able to check that endpad is running - e.g. view the log file etc after the TiVo is put back together?


The easiest is probably to just set something to record and see if it gets padded! You can view the log files via backdoors, but I can't remember how to set it all up.


----------



## sanderton

> _Originally posted by alphabeta _
> *The easiest is probably to just set something to record and see if it gets padded! *


But remember that EndPad only checks for new, unscheduled recordings every 30 mins, so if you just hit record then it's quite possible that that particular show might be missed.


----------



## pmk

Thanks alphabeta / sanderton.


----------



## smokie

I have 2 minutes start padding and 5 minutes end padding set.

My DailyMailJazz has a new icon against a program starting at 20:30, and the microhelp says "Soft padding makes this recording unlikely. Adding end-padding to the previous recording will cause this suggestion to be cancelled". There is a Season Pass ending at 8:30. The Season Pass specifies off-time.

Will my program record? I thought that was how soft padding worked - if it could pad, it would, whereas if it couldn't it wouldn't...? Or is it because programme 2 is a Suggestion rather than a SP?

btw I don't know where I'd be without these hacks now - again, thanks!


----------



## Fozzie

The programme will not be recorded. As the help says, padding will be added to the previous (scheduled) recording which will cause the suggestion to be cancelled. By scheduled recordings I mean those setup by wishlists, SPs or manual recordings. Padding of these takes precedence over any suggestions.

As an aside, don't forget there is now an option with endpad to allow the padding of suggestions to cancel other suggestions.


----------



## pmk

> _Originally posted by pmk _
> *Thanks alphabeta / sanderton. *


I installed last night and after thinking it was not working (either scheduled a recording too quickly for EndPad to pick it up, or EndPad does not work with manual recordings) this morning all my programmes recorded over night do have start and end padding. Fantastic! Thanks again.


----------



## davedixson

Same thing happened to me when I installed it a while back. Its not the fact that the recording was manual, because my first recording was not. It just seems to take a while to sort itself out. 

It has worked flawlessly since though, and it has stopped the wife moaning about chopped off coronation street!


----------



## sanderton

When it starts up it read the to do list; if nothing is scheduled for a while it goes to sleep for half an hour. If you set a "practice" recording for it, it will not realise that you have done that for 30 mins.


----------



## pmk

Quick question:

Early this morning with "EndPad -s 2 -e 15"

All Channel4
---------------
Title Wishlist -> Stargate SG1 02:40
Title Wishlist -> Stargate SG1 03:25
Suggestion -> Andromeda 04:10
Suggestion -> Andromeda 04:55

The second Stargate was not padded with 15 minutes - is this because the following suggestion was on the same channel? Would it have normally ignored the suggestion and padded the second Stargate instead if the suggestion was on another channel?

TIA


----------



## sanderton

Hmm. Yes, you are correct, but now I think of it, I'm not sure that's the right behaviour, since the Sugestion could have been nuked by the time you watch the SP's show.

I'll do a revised version.


----------



## pmk

> _Originally posted by sanderton _
> *Hmm. Yes, you are correct, but now I think of it, I'm not sure that's the right behaviour, since the Sugestion could have been nuked by the time you watch the SP's show. I'll do a revised version. *


I have a few of other items to report:

1. If you have a Suggestion followed by a Recording the recording does not get X minutes start padding. This is related to what is reported above but for the start instead of end padding. I am not sure of the best solution on either of these but I think I agree that the Recording should take priority and be padded over the suggested programme.

2. On two occassions instead of a programme being recorded from 0-30mins or 0-60mins etc the first 5 minutes of the program has not been recorded (i.e. black space on the time bar). The rest of the program has been fine. It is like the end padding of the immediately preceeding show has taken priority over the start of another showing but then gone missing.

10:00-10:50 Programme1
11:00-12:00 Programme2

What was recorded:

Programme1 = 59 minutes
Programme2 = [first five minutes missing - black bar] then 55 minutes of actual program

3. On several occassions programmes that are 30mins or 60mins long and are still not recording (e.g. 1 day old etc) have been incorrectly reported as 29mins or 59mins on the time bar.

TIA


----------



## sanderton

1 - yes, that's because if you add start padding Tivo's internal clash mechanism will cancel the scheduled recording, not the suggestion. There may be a workaround, but I've not found it.

2 & 3 - I don't believe these are anything to do with Endpad. If you added end padding which then overlapped with another show, TiVo would cancel the second show, not start it late. Several people have requested that as a function, but I've not added it, honest! Sounds like an IR realted problem to me. If it happens again please post the log just to be sure.


----------



## pmk

> _Originally posted by sanderton _
> *2 & 3 - I don't believe these are anything to do with Endpad. If you added end padding which then overlapped with another show, TiVo would cancel the second show, not start it late. Several people have requested that as a function, but I've not added it, honest! Sounds like an IR realted problem to me. If it happens again please post the log just to be sure. *


It is using the internal tuner so its not IR related.

Never had 2 or 3 problems before installing EndPad but as the numbers being affected change the length of the programme and/or match up directly with start/end padding I thought it was worth reporting.

It is always 5 mins of "black" bar at the start of a programme this would be a massive coincidence that the TiVo has failed to lock onto the signal for exactly the same time, for the same duration and 5 minutes of End Padding of the previous recording have gone missing matching up to the 5 minutes of the "black" bar.

If it becomes a huge issue I will get the hard drive out so I can get at the log just thought I would post in case anyone else has similar problems.

TIA/HTH


----------



## sanderton

Huge co-incidence I think it is though!

When the end padding is added Endpad does not touch the start padding of the subsequent recording; that is done several minutes later in a completely separate operation. If the end padding had through some bug been set to 15 mins even though there was a programme after, that programme would be cancelled by TiVo, not started late.

The first recording is the correct length - it should indeed be 59 mins - so the end padding addition is working fine. The code which adds the start padding is in blissful ignorance of the Endpad end padding setting; it reads the end point of the previous show directly from the TiVo database, and it's coded to do nothing unless the gap is >0.

Having said that, I doubt there are many folks using 15 mins end padding, so the pool of people to report problems is a bit low.


----------



## pmk

> _Originally posted by sanderton _
> *Huge co-incidence I think it is though!*


Yes it probably is or with my luck my TiVo is in a bad mood but it happened again last night:

Friday Night With Jonathan Ross 01:55->02:50
CD:UK 03:00->03:50

Jonathan Ross was fine (EndPad did its job correctly - nothing could save me from BBC1 running 25mins late however due to a concert or something!)

However CD:UK had the first 5 minutes of the programme lost with a black area on the time bar. Again exactly 5 minutes, at the start of a programme and the last 5 minutes of the 15 minutes of padding lost in the ether somewhere (that should have been CD:UK anyway).

Interestingly the scenario is exactly the same as the one reported yesterday except at different hours of the day. I think these programmes are on at the same time next week so I will see if it does it again.

[Saturday mornings - Dawsons Creek (10:00-10:50 - maybe 10:55 next week so probably not an exact test, Five) and TOTP Saturday (11:00-12:00, BBC1]

TIA/HTH


----------



## sanderton

Unless your TiVo is psychic and knew that EndPad was set for 15 mins of padding even though only 10 were added, I don't see how the two things can be connected.


----------



## pmk

Thanks clearly it must be something on my set-up that is does not like which is a bit strange or it just does not like s 2 and e 15. 

I had another recording with 5 minutes blank at the beginning others were fine from last night.


----------



## pmk

A quick update on my problem I have further information.

For the past couple of weeks the problem has hardly occurred probably had a couple of recordings where the first 5 minutes have not recorded but I have hardly changed any recordings in my To Do / Conflict Manager lists. Over the past 3/4 days I have made several corrections however.

Over the past couple of days I have had several recordings that have had the first 5 minutes missed off (i.e. there is space in the time bar but it is black - the recording starts playing at 5 mins).

On a couple of occassions my TiVo has totally stopped responding to the remote control. After approx 5 minutes any cached IR signals are executed and TiVo comes back to life and if I check the currently recording program it has the first 5 minutes missed.

The best way I can describe it it its like the TiVo is stuck in a loop using all/remaining CPU time. i.e. if it happens when a recording is playing it still plays but no remote control commands are executed.

I know I appear to be the only one experiencing these problems but as everything was fine before I installed EndPad and it is always affecting start of programmes which EndPad has control over to me it is pointing to an incompatibility with EndPad on my TiVo? It is not like it is missing 5 minutes in the middle of recordings it is always the first 5 minutes.

I do have 140 SPs, and I am using 2 mins start padding and 15 mins end padding perhaps its related to when TiVo is doing some indexing or the To Do list changes or something and perhaps EndPad is not getting enough CPU time.

Interestingly my TiVo has started doing its phone call around the midnight time again over the past few days and problems have started to occur again. When it has been phoning around the 06:00-08:00 time (i.e. last couple of weeks) not noticed many problems as not many programmes are recorded around that time.

Any ideas would be greatly appreciated.

[It may also affect the end of recordings when EndPad is adding extra time but it never black lines the time bar - it just does not add the correct amount of extra minutes - I will try to find a pattern, see previous posts]

TIA


----------



## sanderton

Are you running one of the red dot removers?

It all sounds like an IR related problem, and EndPad does nothing with regard to IR or sending channel changes. EndPad does not have 2control" over these programmes al ity does is add start and end padding in exactly the same way as if you did it manually yourself; the triggering of the recording start etc is entirely under TiVo standard software control.

You seem to be the only person experiencing this, however you do have a very high end padding setting so your usage of EndPad is a little unusual in that respect. Most people will rarely if ever have the situation where Endpad adds a reduced amount of padding - it's typically all or nothing.

Could you post a section of EndPad log around the time of one of the missing 5 mins recordings, and also the tvlog from the same time period.


----------



## pmk

Thanks for replying. 

Its a bog standard TiVo set-up really. The HD was upgraded to 120GB over a year ago and I record off aerial channels 1-5 and an old Philips Freebox box for others. No Red Dot remover etc. I have checked my other remotes and no buttons seem to be depressed. When the problem happens the TV remote works fine.

I can only get to the logs by getting the case off the TiVo and setting it all up in my PC I think.

Is it possible to display the EndPad logs via a Backdoor command? 
Are EndPad logs kept for a few days? 
Could you post which directory the logs should be found in?

EndPad is great and I would not do without it I just wished I could track down this 5 minute problem. I was thinking I could try to change settings to s 2 and e 5 and see if the problem continues but as I record many programmes from early morning BBC/ITV the 15 mins end padding is a necessity.

TIA


----------



## sanderton

Suggest you set your TiVo up so that you can connect to it wit a serial cable, saves hoiking disks out.

Logs are in /var/log and are kept for up to 48 hrs.


----------



## doubledrat

off topic, but any idea why additional logs (eg endpad) don't show up with the backdoor log viewing?


----------



## sanderton

The log file names must be hardwired in the backdoor code.


----------



## pmk

> _Originally posted by sanderton _
> *Suggest you set your TiVo up so that you can connect to it wit a serial cable, saves hoiking disks out. Logs are in /var/log and are kept for up to 48 hrs. *


Yes I think I have no option - the benefits far out way the disadvantages.

Can you recommend a guide for getting the serial cable working and anything else that needs installing to send/retrieve and setup files off the TiVo?

Cheers


----------



## P63B

New HD with EndPad?

At some point in the future, I'm going to want to replace my 40 + 30 GB drives with a single larger drive (120 GB probably). My Tivo is not networked, and I don't really want to get into this, but having Endpad functionality would certainly be useful. 

Does anyone supply replacement drives with Tivo software and Endpad (with default padding lengths added for particular channels)? Or is this a non-starter because Endpad needs a networked Tivo to be managed/tweaked/to view logs etc?

Many thanks in advance.


----------



## sanderton

No-one offers it as a paid service, because that would be against the terms and conditions of use for EndPad.

If you have the disks "out" to do the upgrade it is relatively straightforward to add EndPad in at that point, assuming you are reasonably Linux literate. You don't need to be networked to install or run it - indeed you don't even need to take the disks out (there are guides further up the thread).


----------



## pmk

> _Originally posted by sanderton _
> *Suggest you set your TiVo up so that you can connect to it wit a serial cable, saves hoiking disks out. Logs are in /var/log and are kept for up to 48 hrs. *


Okay I took the plunge and bought a TurboNET card so I can easy get access to the log files in the hope it may point to what the problem is. Everything is installed and I have my first report of the black bar problem.

Dawsons Creek 10:00-11:00 (may have been 10:55 however)
Details Of Recording Duration 1:05
Timebar indicates 0:00-0:59
(Duration 5/6 minutes too long that matches up with 5 minutes of black in next recording)

Top Of The Pops Saturday 11:00-12:00
Recording indicates Duration 1:10
Timebar indicates 00:05-1:15
(i.e. first 5 minutes of black at beginning)

My EndPad logs follow I hope that it allows you to help me out with my problem?

Thanks.

Saturday 07:27:00 : Woken up
Saturday 07:27:00 : No recording in progress
Saturday 07:27:00 : Next recording is {The Saturday Show} on BBC1NW (Suggestion) at 07:30
Saturday 07:27:00 : No end padding required:
Saturday 07:27:00 : No recording in progress
Saturday 07:27:00 : Next end padding setting due 08:55
Saturday 07:27:00 : Added 120 seconds start padding to {The Saturday Show}
Saturday 07:27:00 : Next start padding setting due 08:55
Saturday 07:27:00 : Next wake up will be 07:57
Sleeping, checking every minute for kill signal............................... 
Saturday 07:57:00 : Woken up
Saturday 07:57:00 : Recording {The Saturday Show} on BBC1NW (Suggestion) now
Saturday 07:57:00 : Recording Scheduled End Time: 09:00
Saturday 07:57:00 : Next recording is {Dawson's Creek} on FIVE at 09:00
Saturday 07:57:00 : Not time to add end padding yet
Saturday 07:57:00 : Next end padding setting due 08:55
Saturday 07:57:00 : Not time to add start padding yet
Saturday 07:57:00 : Next start padding setting due 08:57
Saturday 07:57:00 : Next wake up will be 08:27
Sleeping, checking every minute for kill signal............................... 
Saturday 08:27:00 : Woken up
Saturday 08:27:00 : Recording {The Saturday Show} on BBC1NW (Suggestion) now
Saturday 08:27:00 : Recording Scheduled End Time: 09:00
Saturday 08:27:00 : Next recording is {Dawson's Creek} on FIVE at 09:00
Saturday 08:27:00 : Not time to add end padding yet
Saturday 08:27:00 : Next end padding setting due 08:55
Saturday 08:27:00 : Not time to add start padding yet
Saturday 08:27:00 : Next start padding setting due 08:57
Saturday 08:27:00 : Next wake up will be 08:55
Sleeping, checking every minute for kill signal............................. 
Saturday 08:55:00 : Woken up
Saturday 08:55:01 : Recording {The Saturday Show} on BBC1NW (Suggestion) now
Saturday 08:55:01 : Recording Scheduled End Time: 09:00
Saturday 08:55:01 : Next recording is {Dawson's Creek} on FIVE at 09:00
Saturday 08:55:01 : Gap to next programme is 0 seconds
Saturday 08:55:01 : Can't add end padding to {The Saturday Show}
Saturday 08:55:01 : Next end padding setting due 09:50
Saturday 08:55:01 : Not time to add start padding yet
Saturday 08:55:01 : Next start padding setting due 08:57
Saturday 08:55:01 : Next wake up will be 08:57
Sleeping, checking every minute for kill signal... 
Saturday 08:57:00 : Woken up
Saturday 08:57:00 : Recording {The Saturday Show} on BBC1NW (Suggestion) now
Saturday 08:57:00 : Recording Scheduled End Time: 09:00
Saturday 08:57:00 : Next recording is {Dawson's Creek} on FIVE at 09:00
Saturday 08:57:00 : Gap to next programme is 0 seconds
Saturday 08:57:00 : Can't add end padding to {The Saturday Show}
Saturday 08:57:00 : Next end padding setting due 09:50
Saturday 08:57:00 : Gap to previous recording is 0 seconds
Saturday 08:57:00 : Can't add start padding to {Dawson's Creek}
Saturday 08:57:00 : Next start padding setting due 09:50
Saturday 08:57:00 : Next wake up will be 09:27
Sleeping, checking every minute for kill signal............................... 
Saturday 09:27:00 : Woken up
Saturday 09:27:01 : Recording {Dawson's Creek} on FIVE now
Saturday 09:27:01 : Recording Scheduled End Time: 09:55
Saturday 09:27:01 : Next recording is {Top of the Pops Saturday} on BBC1NW at 10:00
Saturday 09:27:01 : Not time to add end padding yet
Saturday 09:27:01 : Next end padding setting due 09:50
Saturday 09:27:01 : Not time to add start padding yet
Saturday 09:27:01 : Next start padding setting due 09:57
Saturday 09:27:01 : Next wake up will be 09:50
Sleeping, checking every minute for kill signal........................ 
Saturday 09:50:00 : Woken up
Saturday 09:50:00 : Recording {Dawson's Creek} on FIVE now
Saturday 09:50:00 : Recording Scheduled End Time: 09:55
Saturday 09:50:00 : Next recording is {Top of the Pops Saturday} on BBC1NW at 10:00
Saturday 09:50:00 : Gap to next programme is 300 seconds
Saturday 09:50:00 : Added 298 seconds end padding to {Dawson's Creek}
Saturday 09:50:00 : Next end padding setting due 10:55
Saturday 09:50:00 : Not time to add start padding yet
Saturday 09:50:00 : Next start padding setting due 09:57
Saturday 09:50:00 : Next wake up will be 09:57
Sleeping, checking every minute for kill signal........ 
Saturday 09:57:00 : Woken up
Saturday 09:57:00 : Recording {Dawson's Creek} on FIVE now
Saturday 09:57:00 : Recording Scheduled End Time: 09:59
Saturday 09:57:00 : Next recording is {Top of the Pops Saturday} on BBC1NW at 10:00
Saturday 09:57:00 : Gap to next programme is 300 seconds
Saturday 09:57:01 : Added 298 seconds end padding to {Dawson's Creek}
Saturday 09:57:01 : Next end padding setting due 10:55
Saturday 09:57:01 : Gap to previous recording is 2 seconds
Saturday 09:57:01 : Can't add start padding to {Top of the Pops Saturday}
Saturday 09:57:01 : Next start padding setting due 10:55
Saturday 09:57:01 : Next wake up will be 10:27
Sleeping, checking every minute for kill signal............................... 
Saturday 10:27:01 : Woken up
Saturday 10:27:01 : Recording {Top of the Pops Saturday} on BBC1NW now
Saturday 10:27:01 : Recording Scheduled End Time: 11:00
Saturday 10:27:01 : Next recording is Xcalibur on FIVE (Suggestion) at 11:25
Saturday 10:27:01 : Not time to add end padding yet
Saturday 10:27:01 : Next end padding setting due 10:55
Saturday 10:27:01 : Not time to add start padding yet
Saturday 10:27:01 : Next start padding setting due 11:22
Saturday 10:27:01 : Next wake up will be 10:55
Sleeping, checking every minute for kill signal............................. 
Saturday 10:55:00 : Woken up
Saturday 10:55:00 : Recording {Top of the Pops Saturday} on BBC1NW now
Saturday 10:55:00 : Recording Scheduled End Time: 11:00
Saturday 10:55:00 : Next recording is Xcalibur on FIVE (Suggestion) at 11:25
Saturday 10:55:00 : Gap to next programme is 1500 seconds
Saturday 10:55:00 : Added 900 seconds end padding to {Top of the Pops Saturday}
Saturday 10:55:00 : Next end padding setting due 11:55
Saturday 10:55:00 : Not time to add start padding yet
Saturday 10:55:00 : Next start padding setting due 11:22
Saturday 10:55:00 : Next wake up will be 11:22
Sleeping, checking every minute for kill signal............................ 
Saturday 11:22:00 : Woken up
Saturday 11:22:00 : No recording in progress
Saturday 11:22:00 : Next recording is Xcalibur on FIVE (Suggestion) at 11:25
Saturday 11:22:00 : No end padding required:
Saturday 11:22:00 : No recording in progress
Saturday 11:22:00 : Next end padding setting due 11:55
Saturday 11:22:00 : Added 120 seconds start padding to Xcalibur
Saturday 11:22:00 : Next start padding setting due 11:55
Saturday 11:22:00 : Next wake up will be 11:52
Sleeping, checking every minute for kill signal............................... 
Saturday 11:52:00 : Woken up
Saturday 11:52:01 : Recording Xcalibur on FIVE (Suggestion) now
Saturday 11:52:01 : Recording Scheduled End Time: 12:00
Saturday 11:52:01 : Next recording is {Even Stevens} on CBBC at 14:00
Saturday 11:52:01 : Not time to add end padding yet
Saturday 11:52:01 : Next end padding setting due 11:55
Saturday 11:52:01 : Not time to add start padding yet
Saturday 11:52:01 : Next start padding setting due 13:57
Saturday 11:52:01 : Next wake up will be 11:55
Sleeping, checking every minute for kill signal.... 
Saturday 11:55:00 : Woken up
Saturday 11:55:00 : Recording Xcalibur on FIVE (Suggestion) now
Saturday 11:55:00 : Recording Scheduled End Time: 12:00
Saturday 11:55:00 : Next recording is {Even Stevens} on CBBC at 14:00
Saturday 11:55:00 : Gap to next programme is 7200 seconds
Saturday 11:55:00 : Added 900 seconds end padding to Xcalibur
Saturday 11:55:00 : Next end padding setting due 14:45
Saturday 11:55:00 : Not time to add start padding yet
Saturday 11:55:00 : Next start padding setting due 13:57
Saturday 11:55:00 : Next wake up will be 12:25


----------



## shanew

> _Originally posted by P63B _
> *New HD with EndPad?
> 
> At some point in the future, I'm going to want to replace my 40 + 30 GB drives with a single larger drive (120 GB probably). My Tivo is not networked, and I don't really want to get into this, but having Endpad functionality would certainly be useful.
> 
> Does anyone supply replacement drives with Tivo software and Endpad (with default padding lengths added for particular channels)? Or is this a non-starter because Endpad needs a networked Tivo to be managed/tweaked/to view logs etc?
> 
> Many thanks in advance. *


I installed endpad on my parents TiVo which doesn't have network access.

With the knowledge that there wouldn't be a new tivo version in the UK (ie the OS partition wouldn't change) but occasionally the /var partition can be rebuilt I wrote a simple bash script which was called at the end of /etc/rc.d/rc.sysinit

It checked for the existance of the endpad.tcl file and the /var/hack directory. If they didn't exist it would create /var/hack then copy endpad.tcl from /etc/rc.d to /var/hack directory then run it with the default options.

I checked it worked by getting the script to copy the file on the first boot up.

Living a long way from my parents I didn't want to go back and reinstall it when the var partition was rebuilt.

Hope this helps

Shane.


----------



## sanderton

> _Originally posted by pmk _
> *My EndPad logs follow I hope that it allows you to help me out with my problem?
> *


The logs show EndPad doing what its supposed to do I'm afraid.

It doesn't touch the TOTP recording at all, and adds 2 seconds under 5 mins padding to the Dawsons Creek, taking its stop time to 2 seconds short of 11am - ie, no overlap.

I can't see anything different to how it normally operates.

Are the two recordings still on your TIVo?

If they are, can you use TivoWeb to extract the details please; browse to the recordings in Now Playing, then change the URL from "showing" to "object" and post the output here.

It would also be useful if you could post the section of tvlog from the 15 mins around the time of the oddity (remember the log is GMT). Yesterdays logs are prefaced with an O.


----------



## pmk

Thanks for replying Stuart.

>The logs show EndPad doing what its supposed to do I'm afraid.
Yes I thought it would. Probably pure coincidence this 5mins black bar problem started to happen after I installed EndPad. I guess I can easily try 5 mins end padding and see if the problem disappears but at a last resort.

You probably noticed but when looking at the details of the Dawsons Creek recording in the Now Playing it says Duration 1:05 - i.e. this should have been only 1hour the extra 5 minutes on this recording is what has created the 5 mins of black bar on TOTP Sat but this 5 mins does not exist in the Dawson Creek recording either (i.e. only 59 mins in timebar).

>Are the two recordings still on your TIVo?

Unfortunately both are not anymore but the next time it happens I will post what you suggest. It usually happens to a programme I have manually forced to record due to a conflict. e.g. TOTP Saturday but not always.

>tvlog from the 15 mins around the time of the oddity

See below. The 5 minutes of black in the time line was at the beginning of TOTP Sat that was 11:00 so I am guessing you need the log times around 10:00. The "VERY_LATE" entries look like they may be pointing to something with the milliseconds equating to around 5 mins?

May 22 09:45:20 (none) Recorder[144]: Adding check schedule task
May 22 09:45:21 (none) Scheduler[146]: Done ProcessProgramSources
May 22 09:45:21 (none) Scheduler[146]: Done Checking normal priority Capture Requests
May 22 09:45:21 (none) Scheduler[146]: FUZZY SOURCE
May 22 09:45:56 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:46:24 (none) Recorder[144]: Adding check schedule task
May 22 09:46:34 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:46:51 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:47:08 (none) Scheduler[146]: Done ProcessSpecialProgramSources
May 22 09:47:08 (none) Scheduler[146]: DataChanged:Completed
May 22 09:47:36 (none) Scheduler[146]: Mempool highwater 150108
May 22 09:47:36 (none) Scheduler[146]: DISK SPACE: Total: 103698 Live cache: 1277 Overhead: 396
May 22 09:47:36 (none) Scheduler[146]: TIVO CLIPS DISK SPACE: Total: 9765 Overhead: 42
May 22 09:47:38 (none) Scheduler[146]: Done Checking high priority Capture Requests
May 22 09:49:10 (none) Recorder[144]: Adding check schedule task
May 22 09:49:19 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:50:00 (none) Recorder[144]: Adding check schedule task
May 22 09:50:05 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:50:31 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:50:45 (none) Recorder[144]: Adding check schedule task
May 22 09:50:53 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:51:33 (none) Recorder[144]: Adding check schedule task
May 22 09:51:41 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:52:34 (none) Recorder[144]: Adding check schedule task
May 22 09:52:35 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:52:45 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:53:03 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:54:10 (none) Recorder[144]: Adding check schedule task
May 22 09:54:18 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1105
May 22 09:55:00 (none) VideoGuts[148]: InputState processing took 660 msecs 
May 22 09:55:00 (none) VideoGuts[148]: Total Heartbeat processing took 661 msecs 
May 22 09:55:14 (none) Recorder[144]: found showing 426553/78 (program 229943)
May 22 09:55:15 (none) Recorder[144]: Adding check schedule task
May 22 09:55:18 (none) Recorder[144]: IncrementalAlloc rec 433209
May 22 09:55:18 (none) Recorder[144]: Allocating new recording file. Size 61440
May 22 09:55:18 (none) Recorder[144]: Two small clips in a row!
May 22 09:55:18 (none) Recorder[144]: Live cache size 1671168
May 22 09:55:18 (none) Recorder[144]: Recording Id 433209 size 726016
May 22 09:55:18 (none) Recorder[144]: User recording 104515968 free 22912 
May 22 09:55:18 (none) Recorder[144]: TivoClip total 10000000 free 9712256 
May 22 09:55:18 (none) Recorder[144]: DeleteSomething fUserSaidOk=1
May 22 09:55:18 (none) Recorder[144]: allocate: 14:00000000:40b1b990 rec 433209
May 22 09:55:19 (none) Recorder[144]: live cache: 22:00000000:00000000
May 22 09:55:27 (none) Recorder[144]: candidate: 1:00000000:00000000 430605
May 22 09:55:27 (none) Recorder[144]: deleting rec 430605
May 22 09:55:27 (none) Recorder[144]: Abr--Now: rec 430605
May 22 09:55:28 (none) Recorder[144]: Live cache size 1671168
May 22 09:55:28 (none) Recorder[144]: Recording Id 433209 size 726016
May 22 09:55:28 (none) Recorder[144]: User recording 104515968 free 414080 
May 22 09:55:28 (none) Recorder[144]: TivoClip total 10000000 free 9712256 
May 22 09:55:28 (none) Recorder[144]: Allocated stream Id 439523, size 61440
May 22 09:55:28 (none) mediamgr[144]: AddRecordFile input#0
May 22 09:55:28 (none) Deadline[144]: Task CheckSchedule started late by 3465ms
May 22 09:55:28 (none) Deadline[144]: Tasks run 5300
May 22 09:55:28 (none) Deadline[144]: Existed for 0:63611:194612
May 22 09:55:28 (none) Deadline[144]: Overhead time 0:1:574264
May 22 09:55:43 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:56:06 (none) Recorder[144]: Adding check schedule task
May 22 09:56:11 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:56:18 (none) TmkTransform::Trace[143]: ClipCache 0x300113cc Secondary Reset
May 22 09:56:18 (none) ClipCache[139]: 0x300113cc in Entry(), thread 139
May 22 09:57:01 (none) Recorder[144]: Adding check schedule task
May 22 09:57:06 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:57:23 (none) TmkMediaswitch::Trace[143]: Drift = 4 
May 22 09:57:35 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:58:03 (none) Recorder[144]: Adding check schedule task
May 22 09:58:14 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:58:30 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 09:58:51 (none) Recorder[144]: Adding check schedule task
May 22 09:58:56 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 09:58:58 (none) Recorder[144]: StopPending rec 433209
May 22 09:58:58 (none) VideoGuts[144]: RecordingStopPending 266
May 22 09:59:06 (none) Recorder[144]: Adding check schedule task
May 22 09:59:06 (none) Recorder[144]: CheckSchedule: creating action for: rec 435565
May 22 09:59:06 (none) Recorder[144]: Creating normal action
May 22 09:59:06 (none) Recorder[144]: Creating normal action
May 22 09:59:06 (none) Recorder[144]: CheckSchedule: next creation at 12560 41046: rec 439518
May 22 09:59:06 (none) Recorder[144]: InitialAction rec 435565
May 22 09:59:06 (none) Recorder[144]: InitialAction RecId 435565
May 22 09:59:06 (none) Recorder[144]: Item 435565: estimate kb per second: 219
May 22 09:59:07 (none) Recorder[144]: RequestTuner rec 435565
May 22 09:59:07 (none) TvVideoPolicy[144]: RecordingTunerRequest on 267 
May 22 09:59:07 (none) VideoGuts[144]: RecordingTunerResult ALLOWED 267
May 22 09:59:07 (none) Recorder[144]: Got EVT_VIDEO_SESSION 3
May 22 09:59:07 (none) Recorder[144]: AquiredTunerLock event received
May 22 09:59:46 (none) Recorder[144]: Adding check schedule task
May 22 09:59:48 (none) Recorder[144]: Allocate rec 435565
May 22 09:59:48 (none) Recorder[144]: Allocating new recording file. Size 524288
May 22 09:59:48 (none) Recorder[144]: Live cache size 1671168
May 22 09:59:48 (none) Recorder[144]: Recording Id 433209 size 787456
May 22 09:59:48 (none) Recorder[144]: Recording Id 435565 size 0
May 22 09:59:48 (none) Recorder[144]: User recording 104515968 free 352640 
May 22 09:59:48 (none) Recorder[144]: TivoClip total 10000000 free 9712256 
May 22 09:59:48 (none) Recorder[144]: DeleteSomething fUserSaidOk=1
May 22 09:59:48 (none) Recorder[144]: allocate: 12:00002328:40b1c7a0 rec 435565
May 22 09:59:48 (none) Recorder[144]: live cache: 22:00000000:00000000
May 22 09:59:51 (none) mempool[138]: MyWorld block: 1191kB/1650kB chunk: 264kB/733kB unused: 1259kB search: 1 (size=3731424)
May 22 09:59:51 (none) mempool[138]: Osd block: 96kB/111kB chunk: 947kB/1244kB unused: 1623kB search: 0 (size=3051488)
May 22 09:59:56 (none) Recorder[144]: candidate: 1:00000000:00000000 430613
May 22 09:59:56 (none) Recorder[144]: deleting rec 430613
May 22 09:59:56 (none) Recorder[144]: Abr--Now: rec 430613
May 22 09:59:57 (none) Recorder[144]: Live cache size 1671168
May 22 09:59:57 (none) Recorder[144]: Recording Id 433209 size 787456
May 22 09:59:57 (none) Recorder[144]: Recording Id 435565 size 0
May 22 09:59:57 (none) Recorder[144]: User recording 104515968 free 962944 
May 22 09:59:57 (none) Recorder[144]: TivoClip total 10000000 free 9712256 
May 22 09:59:57 (none) Recorder[144]: Allocated stream Id 439524, size 524288
May 22 09:59:57 (none) Recorder[144]: Allocate success! Adding START task
May 22 09:59:58 (none) Recorder[144]: Stop rec 433209
May 22 09:59:58 (none) VideoGuts[144]: StopRecording 266
May 22 09:59:58 (none) InputState[144]: StartCaching 0
May 22 09:59:58 (none) TmkMediaswitch::Trace[143]: using CBR, bitRate=5960000, maxBitrate=5960000
May 22 09:59:58 (none) Recorder[144]: Start rec 435565
May 22 09:59:58 (none) VideoGuts[144]: StartRecording 267
May 22 09:59:58 (none) InputState[144]: StartRecording 0
May 22 09:59:58 (none) TmkTransform::Trace[143]: ClipCache 0x30017140 Secondary Reset
May 22 09:59:58 (none) ClipCache[139]: 0x30017140 in Entry(), thread 139
May 22 10:04:42 (none) TmkMediaswitch::Trace[143]: using CBR, bitRate=1700000, maxBitrate=1700000
May 22 10:04:42 (none) VideoGuts[148]: Starved of heartbeats for 289 secs
May 22 10:04:42 (none) TmkTransform::Trace[143]: ClipCache 0x300176e4 Secondary Reset
May 22 10:04:42 (none) ClipCache[139]: 0x300176e4 in Entry(), thread 139
May 22 10:04:42 (none) Deadline[144]: VERY_LATE:Task Start ran late by 283879ms
May 22 10:04:42 (none) Deadline[144]: VERY_LATE:Task CheckSchedule started late by 292062ms
May 22 10:04:42 (none) VideoGuts[148]: InputState processing took 499 msecs 
May 22 10:04:42 (none) VideoGuts[148]: Total Heartbeat processing took 499 msecs 
May 22 10:04:43 (none) Deadline[144]: VERY_LATE:Task CheckSchedule ran late by 282340ms
May 22 10:04:43 (none) Deadline[144]: VERY_LATE:Task LiveCache started late by 290061ms
May 22 10:04:43 (none) Deadline[144]: VERY_LATE:Task LiveCache ran late by 288062ms
May 22 10:04:43 (none) Deadline[144]: VERY_LATE:Task IncrementalAlloc started late by 265853ms
May 22 10:04:43 (none) Deadline[144]: VERY_LATE:Task IncrementalAlloc ran late by 255854ms
May 22 10:04:43 (none) Recorder[144]: Deadline scheduler took 290469 milliseconds
May 22 10:04:43 (none) Recorder[144]: Heartbeat took 290 seconds
May 22 10:04:43 (none) Recorder[144]: SecondaryEventCallback took 290 seconds
May 22 10:04:43 (none) Recorder[144]: Got EVT_VIDEO_SESSION 9
May 22 10:04:43 (none) Recorder[144]: Got EVT_VIDEO_SESSION 15
May 22 10:04:43 (none) Recorder[144]: ScheduleCleanup rec 433209
May 22 10:04:43 (none) Recorder[144]: AquiredTunerLock event received
May 22 10:04:43 (none) Recorder[144]: Got EVT_VIDEO_SESSION 9
May 22 10:04:43 (none) Recorder[144]: Got EVT_VIDEO_SESSION 10
May 22 10:04:43 (none) Deadline[144]: Task Cleanup started late by 3082ms
May 22 10:04:43 (none) Recorder[144]: Cleanup rec 433209
May 22 10:04:43 (none) Recorder[144]: FRecordingEmpty: probing...
May 22 10:04:43 (none) Deadline[144]: Task Cleanup ran late by 564ms
May 22 10:04:43 (none) Recorder[144]: Adding check schedule task
May 22 10:04:53 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:05:10 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:05:10 (none) Recorder[144]: found showing 426567/72 (program 435005)
May 22 10:05:11 (none) Recorder[144]: Adding check schedule task
May 22 10:05:21 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:05:30 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:05:39 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:06:37 (none) Recorder[144]: Adding check schedule task
May 22 10:06:47 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:07:03 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:07:31 (none) Recorder[144]: Adding check schedule task
May 22 10:07:42 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:07:59 (none) Recorder[144]: Adding check schedule task
May 22 10:08:27 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:08:59 (none) Recorder[144]: Adding check schedule task
May 22 10:09:09 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:09:23 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:09:57 (none) Recorder[144]: Adding check schedule task
May 22 10:10:08 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:10:18 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:10:46 (none) Recorder[144]: Adding check schedule task
May 22 10:10:57 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:11:14 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:11:41 (none) Recorder[144]: Adding check schedule task
May 22 10:11:42 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:11:52 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:12:10 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:12:41 (none) Recorder[144]: Adding check schedule task
May 22 10:12:52 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:13:06 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:13:23 (none) Recorder[144]: Adding check schedule task
May 22 10:13:31 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:14:14 (none) Recorder[144]: Adding check schedule task
May 22 10:14:24 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1018
May 22 10:14:58 (none) Recorder[144]: Adding check schedule task
May 22 10:15:05 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:15:42 (none) Recorder[144]: Adding check schedule task
May 22 10:15:50 (none) RecordingList[146]: Err errTmBackgroundHoldoff at line 1026
May 22 10:16:46 (none) Deadline[144]: Tasks run 5400


----------



## sanderton

Hmm. The tvlog shows Dawons Creek ending successfully, the Live TV buffer starting up successfully at 2 seconds to 11 and then everything locking up for nearly 5 mins.

That 2 seconds gap doesn't happen on most setups, as the typical usage of EndPad is 5 mins or less. It's possible I guess that doing three swiches in 2 seconds is locking up myworld somehow.


----------



## pmk

Thanks Stuart. 

Could you point out the time stamps where these switches are happening?

So do you think its EndPad? If yes can it be fixed? 

If no what else could it be and do you have any suggestions on how it could be fixed?

Cheers


----------



## sanderton

I'm completely guessing pmk.

It's possible that scheduling a two second recording just makes Tivo trip over itself.

This is an edited version of EndPad which does not create the 2-second recordings.

Please report back if it fixed your problem.


----------



## pmk

Thanks Stuart. I will give it a try tonight and report back the next time a problem occurs (or hopefully not as the case may be!). 

I noticed that someone else has posted very similar problems good news I guess in some way.

I guess the more log files we can gather the better chance we have of capturing the actual cause.


----------



## nexstar

I've recently installed endpad and I only decided to take a look at the logs for it when I noticed that a couple of recordings finished a bit prematurely.

I have it set to add 1 minute at the start and 3 minutes at the end and I'm using the -sugeq switch.

I was too late for the logs of the suspect recordings but I've included some of today's log for prior to a couple of scheduled recordings:

Tuesday 08:58:00 : Woken up
Tuesday 08:58:00 : Recording {Take Three Gardeners} on UKBRID (Suggestion) now
Tuesday 08:58:00 : Recording Scheduled End Time: 09:00
Tuesday 08:58:00 : Next recording is {City Hospital} on BBC1STH at 09:00
Tuesday 08:58:00 : Gap to next programme is 0 seconds
Tuesday 08:58:00 : Can't add end padding to {Take Three Gardeners}
Tuesday 08:58:00 : Next end padding setting due 09:55
Tuesday 08:58:00 : Gap to previous recording is 0 seconds
Tuesday 08:58:00 : Can't add start padding to {City Hospital}
Tuesday 08:58:00 : Next start padding setting due 09:55
Tuesday 08:58:00 : Next wake up will be 09:28
Sleeping, checking every minute for kill signal............................... 
Tuesday 09:28:00 : Woken up
Tuesday 09:28:00 : Recording {City Hospital} on BBC1STH now
Tuesday 09:28:00 : Recording Scheduled End Time: 10:00
Tuesday 09:28:00 : Next recording is {WW2 Revisited} on UKHSTY (Suggestion) at 10:00
Tuesday 09:28:00 : Not time to add end padding yet
Tuesday 09:28:00 : Next end padding setting due 09:55
Tuesday 09:28:00 : Not time to add start padding yet
Tuesday 09:28:00 : Next start padding setting due 09:58
Tuesday 09:28:00 : Next wake up will be 09:55
Sleeping, checking every minute for kill signal............................ 
Tuesday 09:55:00 : Woken up
Tuesday 09:55:00 : Recording {City Hospital} on BBC1STH now
Tuesday 09:55:00 : Recording Scheduled End Time: 10:00
Tuesday 09:55:00 : Next recording is {WW2 Revisited} on UKHSTY (Suggestion) at 10:00
Tuesday 09:55:00 : Gap to next programme is 0 seconds
Tuesday 09:55:00 : Can't add end padding to {City Hospital}
Tuesday 09:55:00 : Next end padding setting due 10:55
Tuesday 09:55:00 : Not time to add start padding yet
Tuesday 09:55:00 : Next start padding setting due 09:58
Tuesday 09:55:00 : Next wake up will be 09:58
Sleeping, checking every minute for kill signal.... 
Tuesday 09:58:00 : Woken up
Tuesday 09:58:00 : Recording {City Hospital} on BBC1STH now
Tuesday 09:58:00 : Recording Scheduled End Time: 10:00
Tuesday 09:58:00 : Next recording is {WW2 Revisited} on UKHSTY (Suggestion) at 10:00
Tuesday 09:58:00 : Gap to next programme is 0 seconds
Tuesday 09:58:00 : Can't add end padding to {City Hospital}
Tuesday 09:58:00 : Next end padding setting due 10:55
Tuesday 09:58:00 : Gap to previous recording is 0 seconds
Tuesday 09:58:00 : Can't add start padding to {WW2 Revisited}
Tuesday 09:58:00 : Next start padding setting due 10:55
Tuesday 09:58:00 : Next wake up will be 10:28
Sleeping, checking every minute for kill signal.............

.....................
.....................
.....................

Tuesday 13:55:00 : Woken up
Tuesday 13:55:00 : No recording in progress
Tuesday 13:55:00 : Next recording is Countdown on C4 at 14:15
Tuesday 13:55:00 : No end padding required:
Tuesday 13:55:00 : No recording in progress
Tuesday 13:55:00 : Next end padding setting due 14:55
Tuesday 13:55:00 : Not time to add start padding yet
Tuesday 13:55:00 : Next start padding setting due 14:13
Tuesday 13:55:00 : Next wake up will be 14:13
Sleeping, checking every minute for kill signal................... 
Tuesday 14:13:00 : Woken up
Tuesday 14:13:00 : No recording in progress
Tuesday 14:13:00 : Next recording is Countdown on C4 at 14:15
Tuesday 14:13:00 : No end padding required:
Tuesday 14:13:00 : No recording in progress
Tuesday 14:13:00 : Next end padding setting due 14:55
Tuesday 14:13:00 : Added 60 seconds start padding to Countdown
Tuesday 14:13:00 : Next start padding setting due 14:55
Tuesday 14:13:00 : Next wake up will be 14:43
Sleeping, checking every minute for kill signal............................... 
Tuesday 14:43:00 : Woken up
Tuesday 14:43:00 : Recording Countdown on C4 now
Tuesday 14:43:00 : Recording Scheduled End Time: 15:00
Tuesday 14:43:00 : Next recording is {The Essential History of the Troubles} on UKHSTY (Suggestion) at 15:00
Tuesday 14:43:00 : Not time to add end padding yet
Tuesday 14:43:00 : Next end padding setting due 14:55
Tuesday 14:43:00 : Not time to add start padding yet
Tuesday 14:43:00 : Next start padding setting due 14:58
Tuesday 14:43:00 : Next wake up will be 14:55
Sleeping, checking every minute for kill signal............. 
Tuesday 14:55:00 : Woken up
Tuesday 14:55:00 : Recording Countdown on C4 now
Tuesday 14:55:00 : Recording Scheduled End Time: 15:00
Tuesday 14:55:00 : Next recording is {The Essential History of the Troubles} on UKHSTY (Suggestion) at 15:00
Tuesday 14:55:00 : Gap to next programme is 0 seconds
Tuesday 14:55:00 : Can't add end padding to Countdown
Tuesday 14:55:00 : Next end padding setting due 15:55
Tuesday 14:55:00 : Not time to add start padding yet
Tuesday 14:55:00 : Next start padding setting due 14:58
Tuesday 14:55:00 : Next wake up will be 14:58
Sleeping, checking every minute for kill signal.... 
Tuesday 14:58:00 : Woken up
Tuesday 14:58:00 : Recording Countdown on C4 now
Tuesday 14:58:00 : Recording Scheduled End Time: 15:00
Tuesday 14:58:00 : Next recording is {The Essential History of the Troubles} on UKHSTY (Suggestion) at 15:00
Tuesday 14:58:00 : Gap to next programme is 0 seconds
Tuesday 14:58:00 : Can't add end padding to Countdown
Tuesday 14:58:00 : Next end padding setting due 15:55
Tuesday 14:58:00 : Gap to previous recording is 0 seconds
Tuesday 14:58:00 : Can't add start padding to {The Essential History of the Troubles}
Tuesday 14:58:00 : Next start padding setting due 15:55
Tuesday 14:58:00 : Next wake up will be 15:28
Sleeping, checking every minute for kill signal............................... 

In the first section, there was no start or end padding of City Hospital even though the previous and subsequent recordings were Tivo suggestions.

In the later section, there was start padding of Countdown but no end padding. This is with version 1.4.0 of endpad.

I've read through most of this thread (phew!) but I apologise for probably missing some obvious point in relation to this. Any enlightenment would be greatly appreciated


----------



## sanderton

Ah, yes now I can either claim that's poor documentation, or a bug. Which would you prefer?

The -sugeq option actually turns off all suggestion deletion for padding.

In the first instance, however, a suggestion running up to a scheduled show will prevent start padding being added to the scheduled show; this is due to my not knowing how to kill an in-progress recording safely.


----------



## nexstar

> _Originally posted by sanderton _
> *Ah, yes now I can either claim that's poor documentation, or a bug. Which would you prefer?
> *


Entirely up to you....you can even blame me if it helps as I'd convinced myself I was at fault anyway 

I tested it out again this evening after re-running it without -sugeq and the following suggestion wasn't recorded to make way for the endpadding (making up new verbs now) of a scheduled recording.

Excellent stuff :up: and many thanks.


----------



## johala_reewi

> _Originally posted by sanderton _
> *I'm completely guessing pmk.
> 
> It's possible that scheduling a two second recording just makes Tivo trip over itself.
> 
> This is an edited version of EndPad which does not create the 2-second recordings.
> 
> Please report back if it fixed your problem. *


Seems to have fixed the problem for me  has worked two nights on the trot with programmes 5 and 10mins apart and 20 mins endpad time.


----------



## sanderton

Version 1.4.1 is in the top post.

Fixes problem with long end padding causing delayed start to a programme which overlapped the desired padding length.


----------



## pmk

Just thought I would post that everything has been fine with mine so far also but I did manage to go over a week (nearly two) with the old release with no problems so I am not 100% sure if my actual problem has been solved until more time has passed.


----------



## pmk

Arrhh well I do not think this has been fixed completely yet.

Jay Leno Show (FTN)
Thursday 27th 10:00-10:50

TiVO Detail Displays 59min duration
Timebar displays 1:05min but with the LAST 6mins as black in the timebar

Unfortunately no logs as more than a couple of days ago now but the next time it happens and I still have the logs I will post them.


----------



## sanderton

If it's the last six minutes it will be a different issue.

Was there a program on after it?


----------



## pmk

I have had to pull the power cord three times (TiVo totally hung on menus) since installing the PMK release (probably coincidence) so I have just updated to the official latest release, disabled/deleted all unused hacks etc and see how it goes.

It is possible that I pulled plug around the time where Jay Leno was black timelined. 

Never had to pull plug on my TiVo since getting it 2 years ago so I am a bit concerned.

Thanks for your help and for the update that seems to address the problem with it missing the start of recordings.


----------



## dialanothernumb

I think your HD is wrecked


----------



## pmk

>I think your HD is wrecked

Do not know if this is aimed at me but I have not experienced any other issues of a wrecked HD. My /var partition has not been wiped due to "chkdsk" failing twice, no video corruption, no skipping or audio issues etc.

I have tidied up my hack folder and removed several things from the .author script to stop things running at startup thats not needed and everything has been fine so far. Much faster menus etc with just TiVoweb / Endpad running.

Is there anything specific I should be looking for in log files which may indicate a hard drive that is failing?

TIA


----------



## gyre

Dumb question... I installed the latest version cos I was seeing the 4 minute blank beginning problem with the older one... and just noticed something in the logfile which confused me.

It seemed that endpad was telling me that it couldn't add padding to a season pass recording since there was a suggestion scheduled immediately afterwards.

If that is true, it isn't exactly what I wanted. Is there a way of telling endpad that it should always pad non-suggestions, even if this means it can't schedule a suggestion?

Thanks!

-- gyre --


----------



## dommac2000

I think this is what the optional -sugeq parameter controls.


----------



## gyre

Oh, OK, I'd just assumed that it applied to padding suggestions.

-- gyre --


----------



## Aerotec

Help!

Have installed my Cachecard last night and am on a roll getting to grips with all these Tivo Add Ons!

I have downloaded the latest endpad and the instructions say to copy endpad.tcl on to the TiVo but where are you meant to copy it to? The root directory? /var/hack/? TivoWeb/Modules/?

Can someone point me in the right direction?

Thanks. Rich


----------



## 10203

/var/hack is a good place


----------



## Aerotec

I did that but when I run chmod 755 etc I get...

No Such File

??


----------



## pmk

try

cd /var/hack
chmod 755 ./endpad.tcl

I also remember for some reason I had to do this via telnet as ftp did not like it? First try via FTP if that does not work try it via telnet.

Obviously double check that endpad.tcl is in the /var/hack directory by doing a ls or something. I think pwd displays the current directory.

Also make sure if you are already running EndPad to stop it first according to instructions in first post.

HTH


----------



## sanderton

EndPad will run from any directory; I use /var/hack

tivoftpd does nor support chmod.


----------



## Olly

Thank you Stuart for a fantastic feature. I'm kicking myself for not installing it ages ago!

Oliver


----------



## johala_reewi

Just come back from holiday and discovered a lack of padding on recordings. Checked the endpad log and it looks like endpad just died.
Have restarted endpad and it cleaned up a stale PID. Will keep an eye on it (this is the pmk edit version).

edit: Just checking the tivo uptime and it looks like tivo rebooted at about the time endpad died. Maybe someone pulled the plug ?? Will still keep an eye on it.


----------



## Aerotec

Has anyone managed to install Endpad using...

http://www.pinedragon.com/tivo/endpad_instructions.html

I have tried on a standard 40GB drive and get errors when trying to mount hda4 and a few other things. I guess I should have noted what did and didn't work!

Is there an updated guide anywhere that I can follow? I have endpad running on my networked Tivo but would love to set it up on my parents machine.

Thanks, Rich


----------



## sanderton

> _Originally posted by johala_reewi _
> *Just come back from holiday and discovered a lack of padding on recordings. Checked the endpad log and it looks like endpad just died.
> Have restarted endpad and it cleaned up a stale PID. Will keep an eye on it (this is the pmk edit version).
> 
> edit: Just checking the tivo uptime and it looks like tivo rebooted at about the time endpad died. Maybe someone pulled the plug ?? Will still keep an eye on it. *


Is Endpad in your startup script?

Was there an error message alog with the stale PID?


----------



## pmk

> _Originally posted by johala_reewi _
> *(this is the pmk edit version*


Doubt there are any changes but the "pmk" version is no longer the latest there is a newer version in the first item of this thread. HTH.


----------



## sanderton

No changes (beyond the version numbering).


----------



## pmk

> _Originally posted by Aerotec _
> *Has anyone managed to install Endpad using...
> 
> http://www.pinedragon.com/tivo/endpad_instructions.html
> *


Yes, I installed endpad using this guide (the main tip is make sure you use the correct boot CD and ensure you connect up your drives as indicated) before I got a TurboNET card. It worked fine but I am on a 120GB drive so I believe one of the partitions should not work.

If you had some error messages I guess the more Linux knowledgable members will be able to point you in the correct direction.

HTH


----------



## Aerotec

Was it the Kazmyr Boot CD you used? I am gathering a few different boot CDs this past week so it is getting a bit confusing!

I attempted this on a 40GB and a 120GB.

I take it one of the partitions will give me an error message if it is the dormant partitions used for software upgrades? I will reattempt it and copy over the error messages.

Oneof them when mounting was that it wanted me to specify the File System?

Rich


----------



## johala_reewi

> _Originally posted by sanderton _
> *Is Endpad in your startup script?
> 
> Was there an error message alog with the stale PID? *


Endpad wasn't in the startup script but it is now. No errors were reported when endpad was restarted. Looks like tivo decided to reboot but it was so long ago, the log files have nothing from that time. Have noticed that my Tivo seems a bit unstable with tivowebplus so maybe it was something to do with that.


----------



## ywu

how do you clean up a stale PID? My endpad has stopped working too.


----------



## pmk

> _Originally posted by Aerotec _
> *Was it the Kazmyr Boot CD you used? I am gathering a few different boot CDs this past week so it is getting a bit confusing!
> 
> I attempted this on a 40GB and a 120GB.
> 
> I take it one of the partitions will give me an error message if it is the dormant partitions used for software upgrades? I will reattempt it and copy over the error messages.
> 
> Oneof them when mounting was that it wanted me to specify the File System?
> 
> Rich *


I can't remember whether it was Kazymyrs or MFSToolsv2 as I have written both my gut feeling is Kazymyrs.

If its asking for a file system type you have probably got the drives mixed up / on wrong channel. This is what had me scratching my head for hours. You have to connect the drives up as indicated in the guide because whatever is needed to be done to get the TiVo drive readable is only done on certain channels.

If I understand correctly:

40GB original drive -> Partitions 4 and 7 should be available and the instructions should be followed and both partitions adjusted appropriately.

120GB upgraded drive -> Only one of the partitions will be mountable. Adjust the instructions appropriately and ignore the "#now do the same to partition X bit". Continue with "#now copy to /var/hack".

And do not forget never allow to boot to Win2K etc with your TiVo drive attached etc.

HTH


----------



## sanderton

> _Originally posted by ywu _
> *how do you clean up a stale PID? My endpad has stopped working too. *


You don't have to. It tells you as a courtesy so you know the previous instance ended abnormally.


----------



## Fozzie

> _Originally posted by Aerotec _
> *One of them when mounting was that it wanted me to specify the File System?
> 
> Rich *


See my post here for a possible explanation.


----------



## gyre

A thought that arrived in a different thread.

Would it be sensible/possible for endpad to convert the "type" of a recording to a suggestion?

-- gyre --


----------



## sanderton

Yes, easy to do. You could have it change all kids programmes to Suggestions with a couple of lines of code.


----------



## gyre

What's your paypal address Stu? 

-- gyre --


----------



## sanderton

Insert this code before the line "# Check if end padding can be added"



Code:


set db [dbopen]
RetryTransaction {
set crec [db $db openid $recfsid]
set cshowing [dbobj $crec get Showing]
set cprogram [dbobj $cshowing get Program]
set cgenre [dbobj $cprogram get Genre]
set match [lsearch -exact $cgenre 22]
if {$match >= 0} {
dbobj $crec set SelectionType 6
}
}
dbclose $db

Just written down, untested, may cause your TiVo to record Big Brother or other faults.


----------



## gyre

Thanks Stu!

Trying it out now. I'm guessing that a genre of 22 is 'children'.

Is there a way of saying "if this type of recording has 3 thumbs up and is part of a season pass?" That might be a better/more generic way for me to mark the ones I'd like converted to suggestions.

Alternatively "if this recording is 'basic'"... cos I record all the kids stuff in basic to save space 

I've got Jeff's book... but haven't got to the tcl section yet 

Thanks again.

-- gyre --


----------



## ccwf

> _Originally posted by gyre _
> *Is there a way of saying "if this type of recording has 3 thumbs up and is part of a season pass?" That might be a better/more generic way for me to mark the ones I'd like converted to suggestions.*


 Certainly, it should be possible to write code to do that.

However, although more difficult, I think WishLists are the way to go for leveraging the existing user interface to make special requests of EndPad.

For example, suppose you could request that all UEFA events be recorded with up to sixty seconds of start padding and one hour of end padding but to make them all suggestions by creating an Advanced WishList as follows: 
UEFA
*START PAD 1M
*END PAD 1H
*AS SUGGESTION
 (You could, of course, also have a higher priority, non-suggestion WishList for particular teams. The * at the start of a word is to ensure that TiVo's scheduler ignores the line.)


----------



## sanderton

Yes; the same code will work but replacing the Genre retrieve and test with whatever you like. 

Thumbs are stored in a rather complex way in the Series object - you'd need to have a look at LJ's modules to see how they work.

Season Pass status is in the SelectionType property of the Recording object - I think 9 is usually SP, but there are a number of alternatives.

Recording Quality is the RecordQuality property of the Recording object. Basic is 0.


----------



## sanderton

> _Originally posted by ccwf _
> *Certainly, it should be possible to write code to do that.
> 
> However, although more difficult, I think WishLists are the way to go for leveraging the existing user interface to make special requests of EndPad.
> 
> For example, suppose you could request that all UEFA events be recorded with up to sixty seconds of start padding and one hour of end padding but to make them all suggestions by creating an Advanced WishList as follows:
> UEFA
> *START PAD 1M
> *END PAD 1H
> *AS SUGGESTION
> (You could, of course, also have a higher priority, non-suggestion WishList for particular teams. The * at the start of a word is to ensure that TiVo's scheduler ignores the line.) *


Yes, you could add that functionality. Anyone interested?


----------



## gyre

ccwf: neat idea.
stu: thanks again... all worked great this morning... "suggestions" starting to fill up the hard drive.

-- gyre --


----------



## ccwf

> _Originally posted by sanderton _
> *Yes, you could add that functionality. Anyone interested? *


 I'm interested in coding it (but don't have a lot of time).  If no one else steps forward (I know you're busy, too, Stuart, with various things), I'll probably get around to it eventually.


----------



## gyre

Stu, it may not be related, but would the code I've added to endpad cause the following two things to happen.

Firstly, a recording split itself into two parts, the first part was 5 minutes long.

Secondly, the tivo just rebooted with a BlockFailure error message.

May just be a coincidence.

-- gyre --


----------



## sanderton

1 & 2 are the same I should think - a reboot would split a recording.

It's possible that it's those changes doing it - anything that touches MFS can reboot the machine - however that code would only run when padding was actually being added, ie 5 mins before the end or 2 mins before the start of the next programme - if the reboot was at another time, I'd say it was unlikley. Comparing the times in the endpad log to the entries in the kernel log should clear that up.

I have seen people report that changing the specs on a recording while its recoding (through the TiVo menus) has rebooted their machine, but I do it so rarely I wouldn't know.


----------



## gyre

I know that reboots split the recording. However, this one was split before the reboot. Well wierd.

Anyway, it hasn't happened again since then, in fact has been sorting my stuff into suggestions just fine.

Thanks.

-- gyre --


----------



## RichyClarke

Stuart,
Thanks for endpad - don't know how I got by without it!!

My Tivo rebooted last night and I am trying to determine why. I noticed a line in my tvlog log file just before it happened which may (or may not) be relevant and related to endpad...

Before the reboot I was getting lots of 'VERY_LATE' messages and messages of heartbeat processing taking +++ msec, which I am not sure are are related.

The fifth line below indicates 'Two small clips in a row'. Do you know if this indicates 2 short recordings in a row, or am I way off track.
If it is 2 recordings, would this have thrown endpad???

If it's not endpad, I would appreciate anybodys view on what caused it.

relevant sections of tvlog, endpad.log and kernel are listed below:



Code:


Jun 14 01:01:56 (none) Deadline[147]: VERY_LATE:Task CheckSchedule ran late by 42933ms
Jun 14 01:01:56 (none) Deadline[147]: VERY_LATE:Task IncrementalAlloc started late by 50671ms
Jun 14 01:01:57 (none) Recorder[147]: IncrementalAlloc rec 204938
Jun 14 01:01:57 (none) Recorder[147]: Allocating new recording file. Size 458752
Jun 14 01:01:57 (none) Recorder[147]: Two small clips in a row!
Jun 14 01:02:00 (none) Recorder[147]: Live cache size 1880064
Jun 14 01:02:00 (none) Recorder[147]: Recording Id 204938 size 1504256
Jun 14 01:02:00 (none) Recorder[147]: User recording 221501824 free 220544 
Jun 14 01:02:00 (none) Recorder[147]: TivoClip total 10000000 free 9712256 
Jun 14 01:02:00 (none) Recorder[147]: DeleteSomething fUserSaidOk=1
Jun 14 01:02:00 (none) Recorder[147]: allocate: 22:00000000:00000000 rec 204938
Jun 14 01:02:00 (none) Recorder[147]: live cache: 3:00000000:00000000
Jun 14 01:01:51 (none) VideoGuts[151]: Starved of heartbeats for 73 secs
Jun 14 01:01:54 (none) VideoGuts[151]: OutputState processing took 1858 msecs 
Jun 14 01:01:55 (none) VideoGuts[151]: Total Heartbeat processing took 2253 msecs 
Jun 14 01:02:02 (none) VideoGuts[151]: OutputState processing took 542 msecs 
Jun 14 01:02:02 (none) VideoGuts[151]: Total Heartbeat processing took 552 msecs 
Jun 14 01:02:04 (none) VideoGuts[151]: InputState processing took 1256 msecs 
Jun 14 01:02:04 (none) VideoGuts[151]: Total Heartbeat processing took 1258 msecs 
Jun 14 01:02:07 (none) ClipCache[142]: 0x300177ac in Entry(), thread 142
Jun 14 01:02:22 (none) VideoGuts[151]: OutputState processing took 856 msecs 
Jun 14 01:02:22 (none) VideoGuts[151]: Total Heartbeat processing took 1310 msecs 
Jun 14 01:02:27 (none) VideoGuts[151]: InputState processing took 475 msecs 
Jun 14 01:02:27 (none) VideoGuts[151]: Total Heartbeat processing took 544 msecs 
Jun 14 01:02:31 (none) mempool[141]: MyWorld block: 932kB/1547kB chunk: 325kB/499kB unused: 1595kB search: 1 (size=3731424)
Jun 14 01:02:32 (none) mempool[141]: Osd block: 70kB/78kB chunk: 1257kB/1511kB unused: 1388kB search: 0 (size=3051488)
Jun 14 01:02:33 (none) VideoGuts[151]: InputState processing took 631 msecs 
Jun 14 01:02:33 (none) VideoGuts[151]: Total Heartbeat processing took 634 msecs 
Jun 14 01:03:14 (none) VideoGuts[151]: InputState processing took 1569 msecs 
Jun 14 01:03:16 (none) VideoGuts[151]: OutputState processing took 1116 msecs 
Jun 14 01:03:16 (none) VideoGuts[151]: Total Heartbeat processing took 3087 msecs 
Jun 14 01:03:22 (none) VideoGuts[151]: InputState processing took 519 msecs 
Jun 14 01:03:22 (none) VideoGuts[151]: Total Heartbeat processing took 733 msecs 
Jun 14 01:03:39 (none) VideoGuts[151]: InputState processing took 437 msecs 
Jun 14 01:03:39 (none) VideoGuts[151]: Total Heartbeat processing took 622 msecs 
Jun 14 01:03:41 (none) VideoGuts[151]: InputState processing took 663 msecs 
Jun 14 01:03:41 (none) VideoGuts[151]: Total Heartbeat processing took 665 msecs 
Jun 14 01:03:43 (none) VideoGuts[151]: InputState processing took 982 msecs 
Jun 14 01:03:43 (none) VideoGuts[151]: Total Heartbeat processing took 984 msecs 
Jun 14 01:03:45 (none) VideoGuts[151]: InputState processing took 342 msecs 
Jun 14 01:03:45 (none) VideoGuts[151]: Total Heartbeat processing took 345 msecs 
Jun 14 01:04:41 (none) VideoGuts[151]: InputState processing took 1014 msecs 
Jun 14 01:04:43 (none) VideoGuts[151]: OutputState processing took 656 msecs 
Jun 14 01:04:43 (none) VideoGuts[151]: Total Heartbeat processing took 3686 msecs 
Jun 14 01:05:27 (none) VideoGuts[151]: OutputState processing took 363 msecs 
Jun 14 01:05:27 (none) VideoGuts[151]: Total Heartbeat processing took 1107 msecs 
Jun 14 01:05:58 (none) Recorder[147]: candidate: 5:00000000:40b8cfa0 186568
Jun 14 01:05:59 (none) Recorder[147]: cache is lower than recording
Jun 14 01:05:59 (none) mediamgr[147]: RemoveUnwrittenLiveFile input#0
Jun 14 01:05:59 (none) MultiMpegCache[147]: Delete stream 206415(inx = 1, read = 0, write =0) totalCount 9
Jun 14 01:06:02 (none) TmkMediaswitch::Trace[146]: CHECK_VIDEO_LOCK took too long: 291
Jun 14 01:06:17 (none) Recorder[147]: Free live cache chunk: 206415
Jun 14 01:06:22 (none) VideoGuts[151]: InputState processing took 4401 msecs 
Jun 14 01:06:23 (none) VideoGuts[151]: OutputState processing took 925 msecs 
Jun 14 01:06:23 (none) VideoGuts[151]: Total Heartbeat processing took 6226 msecs 
Jun 14 01:06:49 (none) TmkTransform::Trace[146]: ClipCache 0x30006948 Secondary Reset
Jun 14 01:07:23 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 01:07:25 (none) VideoGuts[151]: InputState processing took 1876 msecs 
Jun 14 01:07:26 (none) VideoGuts[151]: OutputState processing took 1197 msecs 
Jun 14 01:07:26 (none) VideoGuts[151]: Total Heartbeat processing took 3352 msecs 
Jun 14 01:07:31 (none) VideoGuts[151]: OutputState processing took 417 msecs 
Jun 14 01:27:53 (none) EvtSwitcher[74]: EventSwitcher is starting up
Jun 14 01:27:53 (none) MfsDaemon[75]: MFS Daemon started, id is 75
Jun 14 01:27:53 (none) MfsDaemon[75]: Initializing MFS

endpad



Code:


Monday 00:25:02 : endpad.tcl 1.4.0 log file, log rotated
Monday 00:25:02 : Start padding set to 120 seconds
Monday 00:25:02 : End padding set to 600 seconds
Monday 00:25:02 : Suggestions will not be padded if another suggestion immediately follows them
Monday 00:25:02 : Detected TiVo software version 2.5.5-01-1-023
Monday 00:25:02 : Suggestion quality change disabled
Sleeping, checking every minute for kill signal... 
Monday 00:27:00 : Woken up
Monday 00:27:00 : No recording in progress
Monday 00:27:00 : Next recording is {Ship to Shore} on FXKIDS (Suggestion) at 00:30
Monday 00:27:00 : No end padding required:
Monday 00:27:00 : No recording in progress
Monday 00:27:00 : Next end padding setting due 00:55
Monday 00:27:00 : Added 120 seconds start padding to {Ship to Shore}
Monday 00:27:00 : Next start padding setting due 00:55
Monday 00:27:00 : Next wake up will be 00:55
Sleeping, checking every minute for kill signal............................. 
Monday 00:55:00 : Woken up
Monday 00:55:04 : Recording {Ship to Shore} on FXKIDS (Suggestion) now
Monday 00:55:04 : Recording Scheduled End Time: 01:00
Monday 00:55:04 : Next recording is {The Adventures of Sherlock Holmes} on BBCR7 (Suggestion) at 10:00
Monday 00:55:04 : Gap to next programme is 32400 seconds
Monday 00:55:05 : Added 600 seconds end padding to {Ship to Shore}
Monday 00:55:05 : Next end padding setting due 10:40
Monday 00:55:05 : Not time to add start padding yet
Monday 00:55:05 : Next start padding setting due 09:57
Monday 00:55:05 : Next wake up will be 01:25
Sleeping, checking every minute for kill signal.........Monday 01:28:11 : 
Monday 01:28:11 : endpad.tcl 1.4.0 log file, starting up
Monday 01:28:11 : Start padding set to 120 seconds
Monday 01:28:11 : End padding set to 600 seconds
Monday 01:28:11 : Suggestions will not be padded if another suggestion immediately follows them
Monday 01:28:11 : Detected TiVo software version 2.5.5-01-1-023
Monday 01:28:11 : Suggestion quality change disabled
Monday 01:28:11 : Woken up

and Kernel



Code:


Jun 14 01:05:34 (none) kernel: 
Jun 14 01:05:47 (none) last message repeated 1187 times
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805dace0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805daa00) 
Jun 14 01:05:47 (none) kernel: tcp_keepopen_proc on 0x805daa00 - needs a tickle 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da720) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da440) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da160) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x80b59900) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a2300) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a2ba0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a28c0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x8091f480) 
Jan 1 00:00:16 (none) kernel: hda: ST3120026A, TiVo-realtime enabled ATA DISK drive 
Jan 1 00:00:16 (none) kernel: hdb: ST3120026A, TiVo-realtime enabled ATA DISK drive 
Jan 1 00:00:16 (none) kernel: ide0 at 0xffd00400-0xffd00407,0xffd00438 on irq 32 
Jan 1 00:00:16 (none) kernel: idinfo 82=346B 83=7D01 85=3469 86=3C01 87=4003


----------



## sanderton

Doesn't apprear to be directly EndPad related - the crash happened while EndPad was inactive:



> Monday 00:55:05 : Next wake up will be 01:25
> Sleeping, checking every minute for kill signal.........
> Monday 01:28:11 :
> Monday 01:28:11 : endpad.tcl 1.4.0 log file, starting up


It looks like it got itself very confused because the Task Scheduler ran late and therefore didn't see the 5 mins padding had been added until after the show had finished. Why the Task Scheduler ran late - impossible to say from that - do you have the logs for 10 mins before?


----------



## gyre

Stuart... progress report... your fix to convert kids show recordings into suggestions has been working flawlessly since the first probably unrelated glitch.

Thanks d00d.

-- gyre --


----------



## RichyClarke

Stuart, 
Thanks for the prompt reply.
the reference to '2 small clips in a row' made me think about endpad, after reading some of the previous postings. Also the fact that that it was due to wake at 01:25 - about the time of the reboot. If it is not endpad, then great - I don't want to lose endpad!!!

Here are the logs for the previous 10 mins..
Thanks again for your time to look at this.
Rich

endpad.log


Code:


Monday 00:25:02 : endpad.tcl 1.4.0 log file, log rotated
Monday 00:25:02 : Start padding set to 120 seconds
Monday 00:25:02 : End padding set to 600 seconds
Monday 00:25:02 : Suggestions will not be padded if another suggestion immediately follows them
Monday 00:25:02 : Detected TiVo software version 2.5.5-01-1-023
Monday 00:25:02 : Suggestion quality change disabled
Sleeping, checking every minute for kill signal... 
Monday 00:27:00 : Woken up
Monday 00:27:00 : No recording in progress
Monday 00:27:00 : Next recording is {Ship to Shore} on FXKIDS (Suggestion) at 00:30
Monday 00:27:00 : No end padding required:
Monday 00:27:00 : No recording in progress
Monday 00:27:00 : Next end padding setting due 00:55
Monday 00:27:00 : Added 120 seconds start padding to {Ship to Shore}
Monday 00:27:00 : Next start padding setting due 00:55
Monday 00:27:00 : Next wake up will be 00:55
Sleeping, checking every minute for kill signal............................. 
Monday 00:55:00 : Woken up
Monday 00:55:04 : Recording {Ship to Shore} on FXKIDS (Suggestion) now
Monday 00:55:04 : Recording Scheduled End Time: 01:00
Monday 00:55:04 : Next recording is {The Adventures of Sherlock Holmes} on BBCR7 (Suggestion) at 10:00
Monday 00:55:04 : Gap to next programme is 32400 seconds
Monday 00:55:05 : Added 600 seconds end padding to {Ship to Shore}
Monday 00:55:05 : Next end padding setting due 10:40
Monday 00:55:05 : Not time to add start padding yet
Monday 00:55:05 : Next start padding setting due 09:57
Monday 00:55:05 : Next wake up will be 01:25
Sleeping, checking every minute for kill signal.........Monday 01:28:11 : 
Monday 01:28:11 : endpad.tcl 1.4.0 log file, starting up
Monday 01:28:11 : Start padding set to 120 seconds
Monday 01:28:11 : End padding set to 600 seconds
Monday 01:28:11 : Suggestions will not be padded if another suggestion immediately follows them
Monday 01:28:11 : Detected TiVo software version 2.5.5-01-1-023
Monday 01:28:11 : Suggestion quality change disabled
Monday 01:28:11 : Woken up

kernel (prior to this snippet there there are just keepopens and the odd tickle) 


Code:


Jun 14 01:01:46 (none) kernel: tcp_keepalive: call keepopen(0x809a2ba0) 
Jun 14 01:01:46 (none) kernel: tcp_keepalive: call keepopen(0x809a28c0) 
Jun 14 01:01:46 (none) kernel: tcp_keepalive: call keepopen(0x8091f480) 
Jun 14 01:02:59 (none) kernel: tcp_keepalive: call keepopen(0x805dace0) 
Jun 14 01:03:33 (none) kernel: tcp_keepalive: call keepopen(0x805daa00) 
Jun 14 01:03:56 (none) kernel: tcp_keepopen_proc on 0x805daa00 - needs a tickle 
Jun 14 01:04:12 (none) kernel: tcp_keepalive: call keepopen(0x805da720) 
Jun 14 01:04:38 (none) kernel: tcp_keepalive: call keepopen(0x805da440) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805da160) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x80b59900) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a2300) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a2ba0) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a28c0) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x8091f480) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805dace0) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805daa00) 
Jun 14 01:04:49 (none) kernel: tcp_keepopen_proc on 0x805daa00 - needs a tickle 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805da720) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805da440) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x805da160) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x80b59900) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a2300) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a2ba0) 
Jun 14 01:04:49 (none) kernel: tcp_keepalive: call keepopen(0x809a28c0) 
Jun 14 01:04:50 (none) kernel: tcp_keepalive: call keepopen(0x8091f480) 
Jun 14 01:05:34 (none) kernel: 
Jun 14 01:05:47 (none) last message repeated 1187 times
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805dace0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805daa00) 
Jun 14 01:05:47 (none) kernel: tcp_keepopen_proc on 0x805daa00 - needs a tickle 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da720) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da440) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x805da160) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x80b59900) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a2300) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a2ba0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x809a28c0) 
Jun 14 01:05:47 (none) kernel: tcp_keepalive: call keepopen(0x8091f480) 
Jan 1 00:00:16 (none) kernel: hda: ST3120026A, TiVo-realtime enabled ATA DISK drive 
Jan 1 00:00:16 (none) kernel: hdb: ST3120026A, TiVo-realtime enabled ATA DISK drive

tvlog (sorry abou the size - not sure how far back to go)


Code:


Jun 14 00:39:51 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:40:22 (none) last message repeated 277 times
Jun 14 00:41:23 (none) last message repeated 554 times
Jun 14 00:42:07 (none) last message repeated 402 times
Jun 14 00:42:07 (none) Deadline[147]: Task Check ran late by 1984ms
Jun 14 00:42:07 (none) Recorder[147]: Adding check schedule task
Jun 14 00:42:07 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:42:38 (none) last message repeated 220 times
Jun 14 00:42:51 (none) last message repeated 111 times
Jun 14 00:42:51 (none) ContextMgr[151]: ##### Context::OnHeartbeat(): context 6 said NOT to time out to Live TV. (idle time 15:00) #####
Jun 14 00:42:51 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:43:22 (none) last message repeated 229 times
Jun 14 00:43:36 (none) last message repeated 128 times
Jun 14 00:43:41 (none) mempool[141]: MyWorld block: 935kB/1547kB chunk: 319kB/487kB unused: 1607kB search: 1 (size=3731424)
Jun 14 00:43:41 (none) mempool[141]: Osd block: 70kB/78kB chunk: 1257kB/1511kB unused: 1388kB search: 0 (size=3051488)
Jun 14 00:43:54 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:44:25 (none) last message repeated 279 times
Jun 14 00:44:58 (none) last message repeated 282 times
Jun 14 00:44:58 (none) Deadline[147]: Task Check ran late by 1898ms
Jun 14 00:44:58 (none) Recorder[147]: Adding check schedule task
Jun 14 00:44:58 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:46:41 (none) last message repeated 142 times
Jun 14 00:47:26 (none) last message repeated 407 times
Jun 14 00:47:45 (none) VideoGuts[151]: InputState processing took 438 msecs 
Jun 14 00:47:45 (none) VideoGuts[151]: Total Heartbeat processing took 439 msecs 
Jun 14 00:47:50 (none) Deadline[147]: Task Check ran late by 3204ms
Jun 14 00:47:50 (none) Recorder[147]: Adding check schedule task
Jun 14 00:48:47 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:49:05 (none) last message repeated 32 times
Jun 14 00:49:27 (none) Deadline[147]: Tasks run 21200
Jun 14 00:49:27 (none) Deadline[147]: Existed for 4:32206:903096
Jun 14 00:49:27 (none) Deadline[147]: Overhead time 0:4:519636
Jun 14 00:50:39 (none) Deadline[147]: Task Check ran late by 968ms
Jun 14 00:50:39 (none) Recorder[147]: Adding check schedule task
Jun 14 00:50:43 (none) Recorder[147]: IncrementalAlloc rec 204938
Jun 14 00:50:43 (none) Recorder[147]: Allocating new recording file. Size 455680
Jun 14 00:50:43 (none) Recorder[147]: Live cache size 1880064
Jun 14 00:50:43 (none) Recorder[147]: Recording Id 204938 size 1048576
Jun 14 00:50:43 (none) Recorder[147]: User recording 221501824 free 676224 
Jun 14 00:50:43 (none) Recorder[147]: TivoClip total 10000000 free 9712256 
Jun 14 00:50:43 (none) Recorder[147]: Allocated stream Id 206435, size 455680
Jun 14 00:50:43 (none) mediamgr[147]: AddRecordFile input#0
Jun 14 00:51:40 (none) TmkMediaswitch::Trace[146]: Drift = 7 
Jun 14 00:51:43 (none) TmkTransform::Trace[146]: ClipCache 0x3001991c Secondary Reset
Jun 14 00:51:43 (none) ClipCache[142]: 0x3001991c in Entry(), thread 142
Jun 14 00:53:28 (none) VideoGuts[151]: InputState processing took 530 msecs 
Jun 14 00:53:28 (none) VideoGuts[151]: Total Heartbeat processing took 567 msecs 
Jun 14 00:53:30 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:53:33 (none) last message repeated 33 times
Jun 14 00:53:33 (none) Deadline[147]: Task Check ran late by 4436ms
Jun 14 00:53:33 (none) Recorder[147]: Adding check schedule task
Jun 14 00:53:34 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:54:05 (none) last message repeated 280 times
Jun 14 00:55:05 (none) last message repeated 546 times
Jun 14 00:55:05 (none) Recorder[147]: Adding check schedule task
Jun 14 00:55:05 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:55:09 (none) last message repeated 42 times
Jun 14 00:55:09 (none) VideoGuts[151]: InputState processing took 702 msecs 
Jun 14 00:55:10 (none) VideoGuts[151]: Total Heartbeat processing took 949 msecs 
Jun 14 00:55:10 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 00:55:41 (none) last message repeated 275 times
Jun 14 00:55:53 (none) last message repeated 98 times
Jun 14 00:56:28 (none) Deadline[147]: VERY_LATE:Task Check ran late by 5289ms
Jun 14 00:56:28 (none) Recorder[147]: Adding check schedule task
Jun 14 00:56:49 (none) VideoGuts[151]: InputState processing took 366 msecs 
Jun 14 00:56:49 (none) VideoGuts[151]: Total Heartbeat processing took 629 msecs 
Jun 14 00:59:26 (none) Deadline[147]: VERY_LATE:Task Check ran late by 9234ms
Jun 14 00:59:26 (none) Recorder[147]: Deadline scheduler took 11392 milliseconds
Jun 14 00:59:26 (none) Recorder[147]: Heartbeat took 11 seconds
Jun 14 00:59:26 (none) Recorder[147]: SecondaryEventCallback took 11 seconds
Jun 14 00:59:26 (none) Recorder[147]: Adding check schedule task
Jun 14 01:00:02 (none) VideoGuts[151]: InputState processing took 2956 msecs 
Jun 14 01:00:03 (none) VideoGuts[151]: Total Heartbeat processing took 3169 msecs 
Jun 14 01:00:06 (none) VideoGuts[151]: OutputState processing took 2924 msecs 
Jun 14 01:00:06 (none) VideoGuts[151]: Total Heartbeat processing took 2926 msecs 
Jun 14 01:00:05 (none) TmkMediaswitch::Trace[146]: CHECK_VIDEO_LOCK took too long: 123
Jun 14 01:00:08 (none) VideoGuts[151]: InputState processing took 1446 msecs 
Jun 14 01:00:08 (none) VideoGuts[151]: Total Heartbeat processing took 1447 msecs 
Jun 14 01:00:09 (none) VideoGuts[151]: InputState processing took 841 msecs 
Jun 14 01:00:09 (none) VideoGuts[151]: Total Heartbeat processing took 842 msecs 
Jun 14 01:00:20 (none) VideoGuts[151]: InputState processing took 570 msecs 
Jun 14 01:00:20 (none) VideoGuts[151]: Total Heartbeat processing took 851 msecs 
Jun 14 01:00:23 (none) Deadline[147]: Task Check started late by 620ms
Jun 14 01:00:39 (none) Recorder[147]: found showing 183503/14 (program 161732)
Jun 14 01:00:21 (none) VideoGuts[151]: InputState processing took 549 msecs 
Jun 14 01:00:21 (none) VideoGuts[151]: Total Heartbeat processing took 551 msecs 
Jun 14 01:00:24 (none) VideoGuts[151]: InputState processing took 402 msecs 
Jun 14 01:00:24 (none) VideoGuts[151]: Total Heartbeat processing took 403 msecs 
Jun 14 01:00:25 (none) VideoGuts[151]: InputState processing took 603 msecs 
Jun 14 01:00:25 (none) VideoGuts[151]: Total Heartbeat processing took 604 msecs 
Jun 14 01:00:31 (none) VideoGuts[151]: InputState processing took 855 msecs 
Jun 14 01:00:31 (none) VideoGuts[151]: Total Heartbeat processing took 857 msecs 
Jun 14 01:00:37 (none) VideoGuts[151]: InputState processing took 1301 msecs 
Jun 14 01:00:37 (none) VideoGuts[151]: Total Heartbeat processing took 1763 msecs 
Jun 14 01:00:38 (none) VideoGuts[151]: InputState processing took 357 msecs 
Jun 14 01:00:38 (none) VideoGuts[151]: Total Heartbeat processing took 358 msecs 
Jun 14 01:00:52 (none) Deadline[147]: VERY_LATE:Task Check ran late by 28057ms
Jun 14 01:00:53 (none) Deadline[147]: VERY_LATE:Task LiveCache started late by 17600ms
Jun 14 01:00:53 (none) Deadline[147]: VERY_LATE:Task LiveCache ran late by 16137ms
Jun 14 01:00:53 (none) Recorder[147]: Deadline scheduler took 31696 milliseconds
Jun 14 01:00:53 (none) Recorder[147]: Heartbeat took 31 seconds
Jun 14 01:00:53 (none) Recorder[147]: SecondaryEventCallback took 31 seconds
Jun 14 01:00:53 (none) Recorder[147]: Adding check schedule task
Jun 14 01:02:07 (none) TmkTransform::Trace[146]: ClipCache 0x300177ac Secondary Reset
Jun 14 01:01:56 (none) Deadline[147]: VERY_LATE:Task CheckSchedule ran late by 42933ms
Jun 14 01:01:56 (none) Deadline[147]: VERY_LATE:Task IncrementalAlloc started late by 50671ms
Jun 14 01:01:57 (none) Recorder[147]: IncrementalAlloc rec 204938
Jun 14 01:01:57 (none) Recorder[147]: Allocating new recording file. Size 458752
Jun 14 01:01:57 (none) Recorder[147]: Two small clips in a row!
Jun 14 01:02:00 (none) Recorder[147]: Live cache size 1880064
Jun 14 01:02:00 (none) Recorder[147]: Recording Id 204938 size 1504256
Jun 14 01:02:00 (none) Recorder[147]: User recording 221501824 free 220544 
Jun 14 01:02:00 (none) Recorder[147]: TivoClip total 10000000 free 9712256 
Jun 14 01:02:00 (none) Recorder[147]: DeleteSomething fUserSaidOk=1
Jun 14 01:02:00 (none) Recorder[147]: allocate: 22:00000000:00000000 rec 204938
Jun 14 01:02:00 (none) Recorder[147]: live cache: 3:00000000:00000000
Jun 14 01:01:51 (none) VideoGuts[151]: Starved of heartbeats for 73 secs
Jun 14 01:01:54 (none) VideoGuts[151]: OutputState processing took 1858 msecs 
Jun 14 01:01:55 (none) VideoGuts[151]: Total Heartbeat processing took 2253 msecs 
Jun 14 01:02:02 (none) VideoGuts[151]: OutputState processing took 542 msecs 
Jun 14 01:02:02 (none) VideoGuts[151]: Total Heartbeat processing took 552 msecs 
Jun 14 01:02:04 (none) VideoGuts[151]: InputState processing took 1256 msecs 
Jun 14 01:02:04 (none) VideoGuts[151]: Total Heartbeat processing took 1258 msecs 
Jun 14 01:02:07 (none) ClipCache[142]: 0x300177ac in Entry(), thread 142
Jun 14 01:02:22 (none) VideoGuts[151]: OutputState processing took 856 msecs 
Jun 14 01:02:22 (none) VideoGuts[151]: Total Heartbeat processing took 1310 msecs 
Jun 14 01:02:27 (none) VideoGuts[151]: InputState processing took 475 msecs 
Jun 14 01:02:27 (none) VideoGuts[151]: Total Heartbeat processing took 544 msecs 
Jun 14 01:02:31 (none) mempool[141]: MyWorld block: 932kB/1547kB chunk: 325kB/499kB unused: 1595kB search: 1 (size=3731424)
Jun 14 01:02:32 (none) mempool[141]: Osd block: 70kB/78kB chunk: 1257kB/1511kB unused: 1388kB search: 0 (size=3051488)
Jun 14 01:02:33 (none) VideoGuts[151]: InputState processing took 631 msecs 
Jun 14 01:02:33 (none) VideoGuts[151]: Total Heartbeat processing took 634 msecs 
Jun 14 01:03:14 (none) VideoGuts[151]: InputState processing took 1569 msecs 
Jun 14 01:03:16 (none) VideoGuts[151]: OutputState processing took 1116 msecs 
Jun 14 01:03:16 (none) VideoGuts[151]: Total Heartbeat processing took 3087 msecs 
Jun 14 01:03:22 (none) VideoGuts[151]: InputState processing took 519 msecs 
Jun 14 01:03:22 (none) VideoGuts[151]: Total Heartbeat processing took 733 msecs 
Jun 14 01:03:39 (none) VideoGuts[151]: InputState processing took 437 msecs 
Jun 14 01:03:39 (none) VideoGuts[151]: Total Heartbeat processing took 622 msecs 
Jun 14 01:03:41 (none) VideoGuts[151]: InputState processing took 663 msecs 
Jun 14 01:03:41 (none) VideoGuts[151]: Total Heartbeat processing took 665 msecs 
Jun 14 01:03:43 (none) VideoGuts[151]: InputState processing took 982 msecs 
Jun 14 01:03:43 (none) VideoGuts[151]: Total Heartbeat processing took 984 msecs 
Jun 14 01:03:45 (none) VideoGuts[151]: InputState processing took 342 msecs 
Jun 14 01:03:45 (none) VideoGuts[151]: Total Heartbeat processing took 345 msecs 
Jun 14 01:04:41 (none) VideoGuts[151]: InputState processing took 1014 msecs 
Jun 14 01:04:43 (none) VideoGuts[151]: OutputState processing took 656 msecs 
Jun 14 01:04:43 (none) VideoGuts[151]: Total Heartbeat processing took 3686 msecs 
Jun 14 01:05:27 (none) VideoGuts[151]: OutputState processing took 363 msecs 
Jun 14 01:05:27 (none) VideoGuts[151]: Total Heartbeat processing took 1107 msecs 
Jun 14 01:05:58 (none) Recorder[147]: candidate: 5:00000000:40b8cfa0 186568
Jun 14 01:05:59 (none) Recorder[147]: cache is lower than recording
Jun 14 01:05:59 (none) mediamgr[147]: RemoveUnwrittenLiveFile input#0
Jun 14 01:05:59 (none) MultiMpegCache[147]: Delete stream 206415(inx = 1, read = 0, write =0) totalCount 9
Jun 14 01:06:02 (none) TmkMediaswitch::Trace[146]: CHECK_VIDEO_LOCK took too long: 291
Jun 14 01:06:17 (none) Recorder[147]: Free live cache chunk: 206415
Jun 14 01:06:22 (none) VideoGuts[151]: InputState processing took 4401 msecs 
Jun 14 01:06:23 (none) VideoGuts[151]: OutputState processing took 925 msecs 
Jun 14 01:06:23 (none) VideoGuts[151]: Total Heartbeat processing took 6226 msecs 
Jun 14 01:06:49 (none) TmkTransform::Trace[146]: ClipCache 0x30006948 Secondary Reset
Jun 14 01:07:23 (none) TmkMediaswitch::Trace[146]: Lost VBI lock
Jun 14 01:07:25 (none) VideoGuts[151]: InputState processing took 1876 msecs 
Jun 14 01:07:26 (none) VideoGuts[151]: OutputState processing took 1197 msecs 
Jun 14 01:07:26 (none) VideoGuts[151]: Total Heartbeat processing took 3352 msecs 
Jun 14 01:07:31 (none) VideoGuts[151]: OutputState processing took 417 msecs 
Jun 14 01:27:53 (none) EvtSwitcher[74]: EventSwitcher is starting up
Jun 14 01:27:53 (none) MfsDaemon[75]: MFS Daemon started, id is 75


----------



## sanderton

That's the log of a Tivo struggling with its workload - do you have anything else running?

Anyway, I doubt it's EndPad stressed it out like that, although it's always possible. Certainly my logs have never looked like that!


----------



## pmk

> _Originally posted by RichyClarke _
> *Stuart,
> Thanks for the prompt reply.
> the reference to '2 small clips in a row' made me think about endpad, after reading some of the previous postings. Also the fact that that it was due to wake at 01:25 - about the time of the reboot. If it is not endpad, then great - I don't want to lose endpad!!!
> *


The latest EndPad 1.4.1 fixes an issue with TiVo creating 2 second long clips. It solved the problem I was having. Perhaps try the latest version?

HTH


----------



## ccwf

> _Originally posted by gyre _
> *Stuart... progress report... your fix to convert kids show recordings into suggestions has been working flawlessly since the first probably unrelated glitch.*


 Endpad does its magic five minutes before a recording. It occurs to me that if TiVo happens to recalculate suggestions during that five minute span (and maybe or maybe not while the show is recording), then your kid show recording as a suggestion might be removed. However, even if I'm correct, this should be an uncommon occurrence.


----------



## gyre

ccwf... that makes sense... however, that's something I can live with. I'm happy for the kids to fill up my hard drive with cartoons and stuff... but only if it doesn't impact stuff I want to watch 

-- gyre --


----------



## sanderton

> _Originally posted by ccwf _
> *Endpad does its magic five minutes before a recording. It occurs to me that if TiVo happens to recalculate suggestions during that five minute span (and maybe or maybe not while the show is recording), then your kid show recording as a suggestion might be removed. However, even if I'm correct, this should be an uncommon occurrence. *


It changes it to a suggestion 5 mins from the END of the recording, not before it begins - I think it's unlikely that it would decide not to record a show its already recorded. Possible though.


----------



## russellg

Stuart,

I wonder if you can help with this... I'm seeing a problem in the log where a show should have had 15 minutes of end padding added, but for some reason it wasn't.

I'm running endpad 1.4.0, and have it set to add zero minutes to the beginning, and 15 minutes to the end. It was recording Big Brother from 19:00 to 19:30, and a suggestion was scheduled (by Tivo) to record from 19:30 to 20:30. The result was that it didn't add any end padding to Big Brother, and didn't record the suggestion either. (see highlighted text below) My understanding is that it should cancel the suggestion in order to add end padding to a scheduled show -- have I misunderstood?

I should also mention that this is a US Tivo, in case it makes a difference.

Thanks!
Russell

Tuesday 18:55:01 : Woken up
Tuesday 18:55:01 : No recording in progress
Tuesday 18:55:01 : Next recording is {Big Brother} on TEN10 at 19:00
Tuesday 18:55:01 : No end padding required:
Tuesday 18:55:01 : No recording in progress
Tuesday 18:55:01 : Next end padding setting due 19:25
Tuesday 18:55:01 : Can't add start padding to {Big Brother}
Tuesday 18:55:01 : No start padding requested
Tuesday 18:55:01 : Start padding of 0 seconds already set
Tuesday 18:55:01 : Next start padding setting due 19:10
Tuesday 18:55:01 : Next wake up will be 19:10
Sleeping, checking every minute for kill signal................ 
Tuesday 19:10:00 : Woken up
Tuesday 19:10:00 : Recording {Big Brother} on TEN10 now
Tuesday 19:10:00 : Recording Scheduled End Time: 19:30
Tuesday 19:10:00 : Next recording is {Law & Order} on CLAS (Suggestion) at 19:30
Tuesday 19:10:00 : Not time to add end padding yet
Tuesday 19:10:00 : Next end padding setting due 19:25
Tuesday 19:10:00 : Can't add start padding to {Law & Order}
Tuesday 19:10:00 : No start padding requested
Tuesday 19:10:00 : Start padding of 0 seconds already set
Tuesday 19:10:00 : Next start padding setting due 19:40
Tuesday 19:10:00 : Next wake up will be 19:25
Sleeping, checking every minute for kill signal................ 
Tuesday 19:25:00 : Woken up
*Tuesday 19:25:00 : Recording {Big Brother} on TEN10 now
Tuesday 19:25:00 : Recording Scheduled End Time: 19:30
Tuesday 19:25:00 : Next recording is {Law & Order} on CLAS (Suggestion) at 19:30
Tuesday 19:25:00 : Gap to next programme is 0 seconds
Tuesday 19:25:00 : Can't add end padding to {Big Brother}*
Tuesday 19:25:00 : Next end padding setting due 20:25
Tuesday 19:25:00 : Can't add start padding to {Law & Order}
Tuesday 19:25:00 : No start padding requested
Tuesday 19:25:00 : Start padding of 0 seconds already set
Tuesday 19:25:00 : Next start padding setting due 19:40
Tuesday 19:25:00 : Next wake up will be 19:40
Sleeping, checking every minute for kill signal............


----------



## sanderton

Do you have the -sugeq flag set?

EndPad didn't cancel the suggestion, or the log would say "Cancelling {Law and Order}"


----------



## RichyClarke

Stuart,
I am not running anything out of the ordinary, just Tivoweb, ftp, telnet and endpad. 

Thanks for looking, I suspected it was down to heavy load as there were lots of references to heartbeats taking too long etc. But I don't know what caused it.

I will keep an eye on it and see if it happens again.
Thanks
Rich
:up:


----------



## russellg

> _Originally posted by sanderton _
> *Do you have the -sugeq flag set?
> 
> EndPad didn't cancel the suggestion, or the log would say "Cancelling {Law and Order}" *


Yes, that flag is set. Here's the startup line I'm using:

/hack/endpad.1.4.0.tcl -s 0 -e 15 -auto -sugeq > /dev/null 2>&1 &

If I understand correctly, that option prevents EndPad from cancelling a suggestion by padding another one. But since the first show was a show scheduled by a Season Pass, shouldn't the suggestion have been cancelled by Endpad so it could add end padding to the scheduled show? I'm not sure why the suggestion wasn't recorded, but my main concern is why the end padding didn't get added. Sorry if I've misunderstood what Endpad is supposed to do in this case.

Thanks,
Russell


----------



## sanderton

Read back through this thread a dozen posts or so. The -sugeq flag prevents suggestions being cancelled for padding.


----------



## russellg

> _Originally posted by sanderton _
> *Ah, yes now I can either claim that's poor documentation, or a bug. Which would you prefer?
> 
> The -sugeq option actually turns off all suggestion deletion for padding. *


 Ah ha!

Ok, either way is fine now that I understand how it works. I'll remove the -sugeq option, and hopefully it'll solve the problem.

Thanks,
Russell


----------



## ccwf

> _Originally posted by sanderton _
> *It changes it to a suggestion 5 mins from the END of the recording, not before it begins - I think it's unlikely that it would decide not to record a show its already recorded. Possible though. *


 I've seen many instances of TiVo starting to record a suggestion and then aborting for no apparent reason before the end. I don't know if this behaviour was due to space or suggestion recalculation or something else.

gyre, I just posted out of academic interest (I'm always curious to learn more about TiVo's internals) and not because I think this is an issue that needs to be fixed. If you do notice a suggestion aborting just before the end, please post a note about it.


----------



## fysmd

Well, after having dailymail work when called interactively I poped it into my crontab and waited....

I now have a new problem:

18:47:18-debug-checkpoint conflict 000
18:47:18-debug-just inside catch area
18:47:18-debug-name : >>12586:73500:1664548<<
18:47:18-debug-recdate : >>12586 73500 1664548<<
18:47:18-debug-thetime : >>73500<<
18:47:18-debug-rectime : >>1087503900<<
18:47:18-debug-prior to check for time ahead
18:47:18-debug-conflict item success
18:47:18-debug------------------------------------------------------------------
----
18:47:18-debug-quit out of conflict loop
18:47:18-debug==================================================================
===
Dumping mempool to /tmp/BlockFailure.183
Tmk Assertion Failure:
BlockFailure, line 1771 ()
Tmk Fatal Error: Thread tivosh <183> died due to signal -2
1a344ec 1a32a44 1a2ed70 1b95e0c 1c4d5e8 1c85a50 1c89438 1c79a8c 1c61a10 1c8e4e0
1c77e7c 1c61a10 1c849c0 1c85ec8 1c4d248 1c28cac 1800134

I didn't change anything - HONEST!
I've tried switching 6.5 to and from zero but no apparent change...


----------



## Fozzie

> _Originally posted by fysmd _
> *Well, after having dailymail work when called interactively I poped it into my crontab and waited....*


Cough, cough. This is the Endpad thread. Suggest you re-post in the Dailymail thread


----------



## gyre

> _Originally posted by ccwf _
> *gyre, I just posted out of academic interest (I'm always curious to learn more about TiVo's internals) and not because I think this is an issue that needs to be fixed. If you do notice a suggestion aborting just before the end, please post a note about it.  *


Sure thing.

-- gyre --


----------



## Andy C

> _Originally posted by sanderton _
> *Read back through this thread a dozen posts or so. The -sugeq flag prevents suggestions being cancelled for padding. *


Must admit I was confused by this today after installing endpad and it never added end padding to 'Mutant X' due to a suggestion (Friends) on E4.

I had assumed from the docs and log messages that the -sugeq flag only prevented suggestions from stopping other suggestions being recorded, but season passes or manual recordings would still have end padding and cancel suggestions. After all, the log file only says...

"Suggestions will not be padded if another suggestion immediately follows them"

and not...

"Any recordings or suggestions will not be padded if another suggestion immediately follows them"



Andy.


----------



## sanderton

Like I said: bug or documentation error, you choose.


----------



## Cainam

Can I just check on the correct way to start endpad from rc.sysinit.author?

In various posts I have seen:

/var/hack/endpad.tcl 1 2 -auto >> /dev/null &
/var/hack/endpad.tcl -s 1 -e 2 -auto >> /dev/null &

Do I need the '-s' and '-e' bits? I tried it without them but endpad did not seem to work for me...


----------



## iankb

You need the -s and -e with the later versions which, presumably, you are using one of.


----------



## NiShfiSh

somewhat insignificant bug (given that it only occurs when nothing is in the scheduled recordings list), but reported all the same. discovered after rebuilding a tivo after a fatal GSOD.

With nothing in the todo list

Friday 22:41:25 : endpad.tcl 1.4.1 log file, starting up
Friday 22:41:25 : Start padding set to 60 seconds
Friday 22:41:25 : End padding set to 300 seconds
Friday 22:41:25 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Friday 22:41:25 : Detected TiVo software version 2.5.5-01-1-023
Friday 22:41:25 : Suggestion quality change disabled
Friday 22:41:25 : Woken up
Friday 22:41:25 : Error detected
Friday 22:41:25 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
R..."
Friday 22:41:25 : Attempting to recover
Friday 22:41:55 : Woken up
Friday 22:41:55 : Error detected
Friday 22:41:55 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
R..."
Friday 22:41:55 : Attempting to recover
Friday 22:41:55 : Too many errors, stopping

Then with something to all is okay...

Friday 22:51:51 : endpad.tcl 1.4.1 log file, starting up
Friday 22:51:51 : Start padding set to 60 seconds
Friday 22:51:51 : End padding set to 300 seconds
Friday 22:51:51 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Friday 22:51:51 : Detected TiVo software version 2.5.5-01-1-023
Friday 22:51:51 : Suggestion quality change disabled
Friday 22:51:51 : Woken up
Friday 22:51:51 : No recording in progress
Friday 22:51:51 : Next recording is {The Essential Mix} on BBCR1 at 01:00
Friday 22:51:51 : No end padding required:
Friday 22:51:51 : No recording in progress
Friday 22:51:51 : Next end padding setting due 02:55
Friday 22:51:51 : Not time to add start padding yet
Friday 22:51:51 : Next start padding setting due 00:58
Friday 22:51:51 : Next wake up will be 23:21
Sleeping, checking every minute for kill signal..

thanks for a very useful tool btw


----------



## Adder

Could this error occur if there was no next recording? As I suspect it is?



Code:


Tuesday 19:00:20 : endpad.tcl 1.4.1 log file, starting up
Tuesday 19:00:20 : Start padding set to 60 seconds
Tuesday 19:00:20 : End padding set to 180 seconds
Tuesday 19:00:20 : Suggestions will not be padded if another suggestion immediately follows them
Tuesday 19:00:20 : Detected TiVo software version 2.5.5-01-1-023
Tuesday 19:00:20 : Suggestion quality change disabled
Tuesday 19:00:20 : Woken up
Tuesday 19:00:20 : Error detected
Tuesday 19:00:20 : can't read "nextrecfsid": no such variable
while executing
"db $db openid $nextrecfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set nrec [db $db openid $nextrecfsid]
if {$version >= 3} {
set nrecbeh [dbobj $nrec get RecordingBehavior..."
Tuesday 19:00:20 : Attempting to recover
Tuesday 19:00:50 : Woken up
Tuesday 19:00:50 : Error detected
Tuesday 19:00:50 : can't read "nextrecfsid": no such variable
while executing
"db $db openid $nextrecfsid"
("uplevel" body line 2)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set nrec [db $db openid $nextrecfsid]
if {$version >= 3} {
set nrecbeh [dbobj $nrec get RecordingBehavior..."
Tuesday 19:00:50 : Attempting to recover
Tuesday 19:00:50 : Too many errors, stopping


----------



## sanderton

Yes, same error as the previous post basically. It didn't occur to me that EndPad would be installed on an entirely virgin TiVo.


----------



## Adder

Cheers Stuart, have added a few more recordings and rebooting now, still haven't recreated my manual padding error... yet!


----------



## aerialplug

> Note 2: if you try and add a recording as it is actually starting and get the clash warning because of EndPad's padding of the previous show, manually stop the current recording before adding the new one. TiVo's built in conflict resolution can result in the whole prior programme being deleted in some circumstances.


Oh *&@!. I wish I'd paid more attention to this rule - I did exactly this last night. I wanted to record the local news as there was a story of interest on it but I wasn't sure if the BBC would overrun the programme, as it started 3 1/2 minutes late. I waited to ensure The Grid had finished and then booked the extra programme.

Result - no episode 1 of The Grid in either the now showing list, or in the deleted list on Tivoweb (which is quite long as I had a good old cleanup yesterday).

I realise that this isn't really a bug - it's a "feature" of TiVo not understanding what endpad was doing. I'll have to be more vigilent and remember this in future. I was really looking forward to watching this programme too


----------



## TivoTown

Done some searching but haven't found an answer:

In the Endpad description:

_"Note 1: By default, when EndPad looks at the next recording it takes suggestions as being disposable and deletes them to accommodate end padding if needed. If two back to back suggestions are scheduled, EndPad pads the first one and deletes the second. You can use the -sugeq switch to turn off the deletion of suggestions"_

Does this still happen if the previous recording is on the same channel?

I currently SP 'Working Lunch' on BBC2 everyday, and find that I sometimes get the odd welcome suggestion that follows on BBC2. Would Endpad kill those ?

It's just a question - I'm not trying to knock the obviously excellent Endpad, just wondering what will happen when I finally get to install it.


----------



## sanderton

Good question; I had to go and look in the code to check!

If there is a scheduled suggestion immediately after a user recording _on the same channel_ then no padding is added and the suggestion is recorded.


----------



## TivoTown

Thanks Stuart !


----------



## Gavin

Now I don't profess to be a unix expert, but how do I "upgrade" end pad to the latest version?
My guess is stop it, delete the files and put the new ones in and restart it but is it that simple?


----------



## sanderton

Yes.


----------



## SolidTechie

'Fraid so, yup!


----------



## Gavin

what about the line that runs it on startup on tivo, do I need to remove the old one and put a new one in place?


----------



## sanderton

Depends how old the one there is. The syntax of the command line changed with 1.4.x


----------



## aleks

Please forgive this newbie question: I've searched but can't find the answer.

I bought a cachecard mainly so I could install endpad. I can telnet into it and get a bash prompt - but cd /var/hack gives "no such file or directory". Should it be there before I transfer the file across? If yes then how do I create it. I've tried ls and mb but they both don't appear to exist.

Thanks for your help.

Aleks


----------



## 10203

Try this:


Code:


cd /var
mkdir hack


----------



## aleks

Thanks - I get "bash: cd/var: No such file or directory" 

But if I put a space between cd and \var it seems to work. How daft of me!

Is there anything else I should download while I'm at it or will just the contents of the zip file do the trick?


----------



## 10203

Yup, you'll need the space. Directory names in Linux are separated by forward slashes rather than backslashes as in DOS/Windows.

There're a ton of good resources around, but this one's a good'un to start with:

http://alt.org/wiki/index.php/TivoHackingLinks

TiVoWeb(Plus) is a must have - then you can download my modules too


----------



## alphabeta

> TiVoWeb(Plus) is a must have


 Though you might want to read this thread first


----------



## cashew1970

Hello Stuart.

I am looking to install your padding hack.... However I am a complete novice, and this would be the first thing that I do with my New webbed up tivo.

As far as I am aware, I have no FTP utility installed. I know nothing of all these new commands, and was wondering if it would be possible to do a bit of hand holding.

I am on a tivo with upgraded HD to 120gb, Cachecard with 512mbram Networked via wireless bridge.
Have Tivo web istalled (It came on the drive) and thats about all i know....

I can do all the networky bits, and have had a little play with TivoWeb other than that it is all dutch to me!


Can you help?

Martin


----------



## sanderton

If the networking software has been installed, chances are FTP has too - try using a FTP client to see.


----------



## cashew1970

Will do Stuart, thanks......

Will any do?

Martin

PS will ahve to try tonight as I have not yet worked out how to drive everything from work!


----------



## sanderton

I use SmartFTP. But pretty much any will work, including Internet Explorer or the command line FTP built in to Windows.


----------



## alphabeta

> including Internet Explorer


 As I recall the Tivo FTP server only supports a single session, and you might have to be a bit careful as IE often opens several.


----------



## aitcheff

I guess this is Off Topic, but I use CoreFTP Lite from www.coreftp.com. It is free, works well with TIVO, easy to use and supports FXP (for those interested in hacks from the 'other' place).


----------



## cashew1970

Thanks for all of your help on this.....
Got it installed yesterday from the command line, and all looks as if it is working great.....
Cheers


----------



## Fatbloke

Stuart - I'm having to turn to you for your thoughts!

OVer the last month, my Tivo has regularly failed to record Friday Night with Jonathan Ross (Friday showing). Well, actually Tivo does record it, but when you watch it, there's no channel changeover and I get Newsnight instead.
Anyway, this morning it's the same thing and this time I notice that as well as no changeover, there's also 4 minutes missing from the beginning of the recording.
Now, here's my theory...
The previous item to record before JR is IQ (which always works OK) and that _ends_ 5 minutes before JR starts.

I'm running endpad with 1 minute pre-pad and 10 minutes post-pad.

ISTR, when I used to use 1pre and 5post, I was getting no problem but I'm wondering whether endpad might be throwing a wobbler and causing Tivo to reboot (the missing 4 minutes of recording).

Can someone elso possibly try this scenario, record 2 programs that end 5 minutes apart with a 1 min pre and 10 min post pad. I'd do it myself but my airnet is out of action and I'm awaiting my cachecard, so no direct access to tivoweb or endpad atm.


----------



## gyre

IIRC, there was an older version of endpad that gave those symptoms under certain scenarios.

Have you tried the latest version of endpad?

-- gyre --


----------



## pmk

> _Originally posted by gyre _
> *IIRC, there was an older version of endpad that gave those symptoms under certain scenarios.
> 
> Have you tried the latest version of endpad?
> 
> -- gyre -- *


I also experienced this problem with an older version of EndPad (using 2 mins and 15 mins padding). Interestingly I am using the latest version of EndPad (have been for ages now) and this fixed the "Black Time Bar Problem" but I did experience this again on one programme earlier this week. I just put it down to a one off (not occurred again).

I am suddenly experiencing many suggestions not being recorded however when the suggestion immediately follows a recorded program. The recorded program is not end padded but the suggestion is not recorded for some unknown reason. Again this has never been a problem until recently.

For reference (not changed for many months): 
/var/hack/endpad.tcl -s 2 -e 15 -sugeq -auto >> /dev/null &

I was unfortunately too late to catch the relevant log files.

HTH


----------



## sanderton

> _Originally posted by Fatbloke _
> *Stuart - I'm having to turn to you for your thoughts!
> 
> *


This is a known bug which was fixed in the most recent release - suggest you update your copy of EndPad.


----------



## sanderton

> _Originally posted by pmk _
> *I
> 
> I was unfortunately too late to catch the relevant log files.
> *


That's the key I'm afraid; without those I can't do anything.


----------



## Fatbloke

> _Originally posted by sanderton _
> *This is a known bug which was fixed in the most recent release - suggest you update your copy of EndPad. *


 Thought I was on the last release... but then again I've not been looking at this thread for a few months now. I'll update as I do the cache card thingy. Won't be long before it's here


----------



## pmk

> _Originally posted by Fatbloke _
> * Thought I was on the last release... but then again I've not been looking at this thread for a few months now. I'll update as I do the cache card thingy. Won't be long before it's here  *


This is why I have reported a similar problem so Stuart knew it was not isolated to one user. I am 100% positive I am on the very latest version as I reported the initial problem and have been running the latest fix 141 for several months.

It has not happened again since, if it does and I watch the recording in time I will post the logs.

HTH


----------



## pmk

Just had a black bar problem again. It was Countdown C4 15:15->16:00. The timebar 0:00->1:00 but the last 14-15mins or so are black instead of green. As TiVo was recording a program before hand there is no 2 min start padding but there should be 15 mins end padding (i.e. 45 mins + 15mins padding = 1 hour). Everything has been working perfectly (i.e. no black bars) for months. The only recent change (approx 3 weeks ago) is dailymail is now installed and run via cron at 08:30hrs.

Are there any clues in the log files on what is causing this problem?

I have noticed _Nov 8 16:00:34 (none) Recorder[146]: Two small clips in a row! has been reported. I think small clips caused the last black bar problem is this a different case that need trapping?

TIA

*endpad.log*
Monday 00:25:02 : endpad.tcl 1.4.1 log file, log rotated
Monday 00:25:02 : Start padding set to 120 seconds
Monday 00:25:02 : End padding set to 900 seconds
Monday 00:25:02 : Suggestions will not be padded if another suggestion immediately follows them
Monday 00:25:02 : Detected TiVo software version 2.5.5-01-1-023
Monday 00:25:02 : Suggestion quality change disabled
Sleeping, checking every minute for kill signal............................... 
Monday 00:55:01 : Woken up
Monday 00:55:01 : No recording in progress
<--cut-->
Sleeping, checking every minute for kill signal.................. 
Monday 15:12:00 : Woken up
Monday 15:12:00 : Recording {The Practice} on ITVTHREE (Suggestion) now
Monday 15:12:00 : Recording Scheduled End Time: 15:15
Monday 15:12:00 : Next recording is Countdown on C4 at 15:15
Monday 15:12:00 : No end padding required:
Monday 15:12:00 : End padding of 900 seconds already set
Monday 15:12:00 : Next end padding setting due 15:55
Monday 15:12:00 : Gap to previous recording is 0 seconds
Monday 15:12:00 : Can't add start padding to Countdown
Monday 15:12:00 : Next start padding setting due 15:55
Monday 15:12:00 : Next wake up will be 15:42
Sleeping, checking every minute for kill signal............................... 
Monday 15:42:00 : Woken up
Monday 15:42:00 : Recording Countdown on C4 now
Monday 15:42:00 : Recording Scheduled End Time: 16:00
Monday 15:42:00 : Next recording is {The Simpsons} on C4 at 18:00
Monday 15:42:00 : Not time to add end padding yet
Monday 15:42:00 : Next end padding setting due 15:55
Monday 15:42:00 : Not time to add start padding yet
Monday 15:42:00 : Next start padding setting due 17:57
Monday 15:42:00 : Next wake up will be 15:55
Sleeping, checking every minute for kill signal.............. 
Monday 15:55:00 : Woken up
Monday 15:55:00 : Recording Countdown on C4 now
Monday 15:55:00 : Recording Scheduled End Time: 16:00
Monday 15:55:00 : Next recording is {The Simpsons} on C4 at 18:00
Monday 15:55:00 : Gap to next programme is 7200 seconds
Monday 15:55:00 : Added 900 seconds end padding to Countdown
Monday 15:55:00 : Next end padding setting due 18:25
Monday 15:55:00 : Not time to add start padding yet
Monday 15:55:00 : Next start padding setting due 17:57
Monday 15:55:00 : Next wake up will be 16:25
Sleeping, checking every minute for kill signal............................... 
Monday 16:25:00 : Woken up
Monday 16:25:00 : No recording in progress
Monday 16:25:00 : Next recording is {The Simpsons} on C4 at 18:00
Monday 16:25:00 : No end padding required:
Monday 16:25:00 : No recording in progress
Monday 16:25:00 : Next end padding setting due 18:25
Monday 16:25:00 : Not time to add start padding yet
Monday 16:25:00 : Next start padding setting due 17:57
Monday 16:25:00 : Next wake up will be 16:55
Sleeping, checking every minute for kill signal............

*tvlog*
Nov 8 15:55:00 (none) last message repeated 52 times
Nov 8 15:55:00 (none) Recorder[146]: Adding check schedule task
Nov 8 15:55:00 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:55:10 (none) last message repeated 83 times
Nov 8 15:55:10 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 15:55:16 (none) TmkMediaswitch::Trace[145]: Drift = 4 
Nov 8 15:55:38 (none) Scheduler[148]: ShortenRecording[565674 <?>(1140 MB)(12734 36000)(3300):F:40]Time(12735 60000)
Nov 8 15:55:38 (none) Recorder[146]: Adding check schedule task
Nov 8 15:55:46 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1026
Nov 8 15:55:51 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:11 (none) last message repeated 179 times
Nov 8 15:56:11 (none) Recorder[146]: Adding check schedule task
Nov 8 15:56:11 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:11 (none) last message repeated 4 times
Nov 8 15:56:14 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 15:56:21 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 15:56:21 (none) LogTime[150]: Lineup: make new RecordingsOnDisk obj: 0.000 sec
Nov 8 15:56:27 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:28 (none) last message repeated 7 times
Nov 8 15:56:28 (none) LogTime[150]: Lineup: update the OSD: 6.935 sec
Nov 8 15:56:28 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:29 (none) last message repeated 8 times
Nov 8 15:56:29 (none) VideoGuts[150]: PlayRecording for Proxy 337
Nov 8 15:56:29 (none) OutputState[150]: PlayRecording 0
Nov 8 15:56:29 (none) LogTime[150]: WatchTV: setup cached: 0.314 sec
Nov 8 15:56:29 (none) ContextMgr[150]: WATCHTV::LOCK (mode COMPLETED (via NS))
Nov 8 15:56:29 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:41 (none) last message repeated 109 times
Nov 8 15:56:41 (none) Scheduler[148]: Abr-- reason changed from 'None' to 'UI'
Nov 8 15:56:41 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:56:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:56:56 (none) last message repeated 127 times
Nov 8 15:57:33 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 15:57:33 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:57:46 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:58:04 (none) last message repeated 150 times
Nov 8 15:58:04 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 15:58:04 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:58:04 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:58:31 (none) last message repeated 126 times
Nov 8 15:58:31 (none) Recorder[146]: Adding check schedule task
Nov 8 15:58:31 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:58:36 (none) last message repeated 43 times
Nov 8 15:58:36 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 15:58:36 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:58:36 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:01 (none) last message repeated 221 times
Nov 8 15:59:07 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 15:59:07 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:59:12 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:12 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:16 (none) LogTime[150]: WatchTV: show description box: 0.277 sec
Nov 8 15:59:27 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:34 (none) last message repeated 67 times
Nov 8 15:59:34 (none) mempool[140]: MyWorld block: 1184kB/1645kB chunk: 152kB/375kB unused: 1621kB search: 1 (size=3731424)
Nov 8 15:59:34 (none) mempool[140]: Osd block: 119kB/135kB chunk: 964kB/1260kB unused: 1582kB search: 0 (size=3051488)
Nov 8 15:59:34 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:38 (none) last message repeated 36 times
Nov 8 15:59:38 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 15:59:38 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 15:59:39 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 15:59:58 (none) last message repeated 170 times
Nov 8 15:59:58 (none) TmkSink::Trace[143]: Video out of A/V window. Resyncing, Diff=-2691161
Nov 8 15:59:58 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:00:09 (none) last message repeated 93 times
Nov 8 16:00:10 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:00:10 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:00:23 (none) Recorder[146]: found showing 550784/90 (program 558358)
Nov 8 16:00:23 (none) Recorder[146]: Adding check schedule task
Nov 8 16:00:24 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:00:32 (none) last message repeated 37 times
Nov 8 16:00:34 (none) Recorder[146]: IncrementalAlloc rec 563602
Nov 8 16:00:34 (none) Recorder[146]: Allocating new recording file. Size 307200
Nov 8 16:00:34 (none) Recorder[146]: Two small clips in a row!
Nov 8 16:00:34 (none) Recorder[146]: Live cache size 1880064
Nov 8 16:00:34 (none) Recorder[146]: Recording Id 563602 size 962560
Nov 8 16:00:34 (none) Recorder[146]: User recording 104307072 free 225664 
Nov 8 16:00:34 (none) Recorder[146]: TivoClip total 10000000 free 9712256 
Nov 8 16:00:34 (none) Recorder[146]: DeleteSomething fUserSaidOk=1
Nov 8 16:00:34 (none) Recorder[146]: allocate: 22:00000000:00000000 rec 563602
Nov 8 16:00:34 (none) Recorder[146]: live cache: 3:00000000:00000000
Nov 8 16:00:40 (none) Recorder[146]: candidate: 1:00000000:00000000 561684
Nov 8 16:00:40 (none) Recorder[146]: deleting rec 561684
Nov 8 16:00:40 (none) Recorder[146]: Abr--Now: rec 561684
Nov 8 16:00:40 (none) Recorder[146]: Live cache size 1880064
Nov 8 16:00:40 (none) Recorder[146]: Recording Id 563602 size 962560
Nov 8 16:00:40 (none) Recorder[146]: User recording 104307072 free 848256 
Nov 8 16:00:40 (none) Recorder[146]: TivoClip total 10000000 free 9712256 
Nov 8 16:00:40 (none) Recorder[146]: Allocated stream Id 565689, size 307200
Nov 8 16:00:41 (none) mediamgr[146]: AddRecordFile input#0
Nov 8 16:00:41 (none) Recorder[146]: Adding check schedule task
Nov 8 16:00:42 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:00:42 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:00:45 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:14 (none) last message repeated 219 times
Nov 8 16:01:14 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:01:14 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:01:14 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:15 (none) last message repeated 14 times
Nov 8 16:01:17 (none) Recorder[146]: Adding check schedule task
Nov 8 16:01:20 (none) LogTime[150]: Lineup: make new RecordingsOnDisk obj: 0.014 sec
Nov 8 16:01:22 (none) LogTime[150]: Lineup: update the OSD: 1.943 sec
Nov 8 16:01:25 (none) Deadline[146]: Tasks run 6600
Nov 8 16:01:25 (none) Deadline[146]: Existed for 1:8419:508858
Nov 8 16:01:25 (none) Deadline[146]: Overhead time 0:1:688782
Nov 8 16:01:26 (none) LogTime[150]: FindActions: entering: 4.001 sec
Nov 8 16:01:28 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:28 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:28 (none) Recorder[146]: Got EVT_VIDEO_SESSION 9
Nov 8 16:01:28 (none) VideoGuts[150]: StopRecording 326
Nov 8 16:01:28 (none) InputState[150]: StartCaching 0
Nov 8 16:01:28 (none) TmkMediaswitch::Trace[145]: using CBR, bitRate=5960000, maxBitrate=5960000
Nov 8 16:01:28 (none) MultiMpegCache[150]: Delete stream 565689(inx = 2, read = 1, write =1) totalCount 3
Nov 8 16:01:28 (none) TmkTransform::Trace[145]: ClipCache 0x30010808 Secondary Reset
Nov 8 16:01:28 (none) ClipCache[141]: 0x30010808 in Entry(), thread 141
Nov 8 16:01:29 (none) Recorder[146]: Got EVT_VIDEO_SESSION 15
Nov 8 16:01:29 (none) Recorder[146]: ScheduleCleanup rec 563602
Nov 8 16:01:29 (none) Recorder[146]: AquiredTunerLock event received
Nov 8 16:01:29 (none) Deadline[146]: Task Cleanup started late by 3038ms
Nov 8 16:01:29 (none) Recorder[146]: Cleanup rec 563602
Nov 8 16:01:29 (none) TvDbUtil[146]: Remove part 2
Nov 8 16:01:29 (none) Recorder[146]: FRecordingEmpty: probing...
Nov 8 16:01:30 (none) Deadline[146]: Task Cleanup ran late by 701ms
Nov 8 16:01:30 (none) Recorder[146]: Adding check schedule task
Nov 8 16:01:30 (none) LogTime[150]: Lineup: make new RecordingsOnDisk obj: 0.060 sec
Nov 8 16:01:33 (none) LogTime[150]: Lineup: update the OSD: 2.358 sec
Nov 8 16:01:34 (none) LogTime[150]: Lineup: page up/down: 0.481 sec
Nov 8 16:01:35 (none) LogTime[150]: Lineup: page up/down: 0.494 sec
Nov 8 16:01:36 (none) LogTime[150]: Lineup: page up/down: 0.464 sec
Nov 8 16:01:37 (none) LogTime[150]: Lineup: page up/down: 0.555 sec
Nov 8 16:01:37 (none) LogTime[150]: Lineup: page up/down: 0.639 sec
Nov 8 16:01:39 (none) LogTime[150]: Lineup: page up/down: 0.566 sec
Nov 8 16:01:40 (none) LogTime[150]: Lineup: page up/down: 0.588 sec
Nov 8 16:01:44 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:55 (none) last message repeated 92 times
Nov 8 16:01:55 (none) mediamgr[146]: RemoveUnwrittenLiveFile input#0
Nov 8 16:01:55 (none) MultiMpegCache[146]: Delete stream 565660(inx = 1, read = 7, write =0) totalCount 9
Nov 8 16:01:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:55 (none) Recorder[146]: Free live cache chunk: 565660
Nov 8 16:01:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:01:55 (none) Recorder[146]: Adding check schedule task
Nov 8 16:01:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:02:23 (none) last message repeated 247 times
Nov 8 16:02:23 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:02:23 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:02:23 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:02:29 (none) last message repeated 52 times
Nov 8 16:02:55 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:02:55 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:03:21 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:03:26 (none) last message repeated 41 times
Nov 8 16:03:26 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:03:26 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:03:26 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:03:57 (none) last message repeated 165 times
Nov 8 16:03:58 (none) last message repeated 13 times
Nov 8 16:03:58 (none) Scheduler[148]: Mempool highwater 170544
Nov 8 16:03:58 (none) Scheduler[148]: Abr-- reason changed from 'UI' to 'None'
Nov 8 16:03:58 (none) Scheduler[148]: DISK SPACE: Total: 103698 Live cache: 1277 Overhead: 396
Nov 8 16:03:58 (none) Scheduler[148]: TIVO CLIPS DISK SPACE: Total: 9765 Overhead: 42
Nov 8 16:03:58 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:04:10 (none) last message repeated 97 times
Nov 8 16:04:10 (none) Scheduler[148]: Done Checking high priority Capture Requests
Nov 8 16:04:10 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:04:27 (none) last message repeated 151 times
Nov 8 16:04:43 (none) Recorder[146]: Adding check schedule task
Nov 8 16:05:01 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:05:11 (none) last message repeated 95 times
Nov 8 16:05:11 (none) Recorder[146]: Adding check schedule task
Nov 8 16:05:11 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:05:22 (none) last message repeated 93 times
Nov 8 16:05:22 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:05:22 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:05:38 (none) last message repeated 119 times
Nov 8 16:05:38 (none) Recorder[146]: Adding check schedule task
Nov 8 16:05:38 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:05:48 (none) last message repeated 83 times
Nov 8 16:05:48 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:05:49 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:06:06 (none) last message repeated 155 times
Nov 8 16:06:06 (none) Recorder[146]: Adding check schedule task
Nov 8 16:06:06 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:06:12 (none) last message repeated 51 times
Nov 8 16:06:13 (none) TmkTransform::Trace[145]: ClipCache 0x300114b0 Secondary Reset
Nov 8 16:06:13 (none) ClipCache[142]: 0x300114b0 in Entry(), thread 142
Nov 8 16:06:14 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:06:16 (none) last message repeated 16 times
Nov 8 16:06:16 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1026
Nov 8 16:06:16 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:06:31 (none) last message repeated 133 times
Nov 8 16:06:31 (none) Recorder[146]: Adding check schedule task
Nov 8 16:06:31 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:06:39 (none) last message repeated 70 times
Nov 8 16:06:42 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:06:59 (none) Recorder[146]: Adding check schedule task
Nov 8 16:07:02 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:07:09 (none) last message repeated 20 times
Nov 8 16:07:09 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:07:09 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:07:13 (none) last message repeated 32 times
Nov 8 16:07:24 (none) Recorder[146]: Adding check schedule task
Nov 8 16:07:25 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:07:53 (none) last message repeated 227 times
Nov 8 16:07:53 (none) Recorder[146]: Adding check schedule task
Nov 8 16:08:04 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:08:18 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:08:23 (none) last message repeated 42 times
Nov 8 16:08:23 (none) Recorder[146]: Adding check schedule task
Nov 8 16:08:23 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:08:52 (none) last message repeated 212 times
Nov 8 16:08:52 (none) Recorder[146]: Adding check schedule task
Nov 8 16:08:52 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:08:59 (none) last message repeated 65 times
Nov 8 16:09:02 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:09:05 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:09:07 (none) last message repeated 16 times
Nov 8 16:09:23 (none) Recorder[146]: Adding check schedule task
Nov 8 16:09:25 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:09:34 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:09:49 (none) Recorder[146]: Adding check schedule task
Nov 8 16:09:49 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:09:59 (none) last message repeated 91 times
Nov 8 16:09:59 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:09:59 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:10:16 (none) last message repeated 122 times
Nov 8 16:10:16 (none) Recorder[146]: Adding check schedule task
Nov 8 16:10:16 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:10:26 (none) last message repeated 95 times
Nov 8 16:10:26 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:10:26 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:10:42 (none) last message repeated 99 times
Nov 8 16:10:42 (none) Recorder[146]: Adding check schedule task
Nov 8 16:10:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:10:56 (none) last message repeated 71 times
Nov 8 16:10:56 (none) TmkTransform::Trace[145]: ClipCache 0x30018490 Secondary Reset
Nov 8 16:10:56 (none) ClipCache[141]: 0x30018490 in Entry(), thread 141
Nov 8 16:11:03 (none) Recorder[146]: Adding check schedule task
Nov 8 16:11:14 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:11:15 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:11:33 (none) last message repeated 129 times
Nov 8 16:11:33 (none) Recorder[146]: Adding check schedule task
Nov 8 16:11:33 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:12:00 (none) last message repeated 174 times
Nov 8 16:12:02 (none) Recorder[146]: Adding check schedule task
Nov 8 16:12:11 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:12:12 (none) last message repeated 8 times
Nov 8 16:12:12 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:12:12 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:12:31 (none) last message repeated 169 times
Nov 8 16:12:31 (none) Recorder[146]: Adding check schedule task
Nov 8 16:12:31 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:12:42 (none) last message repeated 91 times
Nov 8 16:12:42 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:12:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:12:59 (none) last message repeated 157 times
Nov 8 16:12:59 (none) Recorder[146]: Adding check schedule task
Nov 8 16:12:59 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:13:15 (none) last message repeated 139 times
Nov 8 16:13:29 (none) Recorder[146]: Adding check schedule task
Nov 8 16:13:39 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:13:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:13:43 (none) last message repeated 6 times
Nov 8 16:13:54 (none) Recorder[146]: Adding check schedule task
Nov 8 16:14:05 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:14:12 (none) last message repeated 63 times
Nov 8 16:14:23 (none) Recorder[146]: Adding check schedule task
Nov 8 16:14:28 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:14:34 (none) last message repeated 49 times
Nov 8 16:14:34 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:14:34 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:14:48 (none) last message repeated 57 times
Nov 8 16:14:49 (none) Recorder[146]: Adding check schedule task
Nov 8 16:14:59 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:15:08 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:15:15 (none) last message repeated 65 times
Nov 8 16:15:15 (none) Recorder[146]: Adding check schedule task
Nov 8 16:15:17 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:15:40 (none) last message repeated 182 times
Nov 8 16:15:40 (none) TmkTransform::Trace[145]: ClipCache 0x30011e8c Secondary Reset
Nov 8 16:15:40 (none) ClipCache[142]: 0x30011e8c in Entry(), thread 142
Nov 8 16:15:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:15:43 (none) last message repeated 11 times
Nov 8 16:15:43 (none) Recorder[146]: Adding check schedule task
Nov 8 16:15:43 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:15:54 (none) last message repeated 94 times
Nov 8 16:15:54 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:15:54 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:16:09 (none) last message repeated 135 times
Nov 8 16:16:09 (none) Recorder[146]: Adding check schedule task
Nov 8 16:16:09 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:16:27 (none) last message repeated 157 times
Nov 8 16:16:37 (none) Recorder[146]: Adding check schedule task
Nov 8 16:16:40 (none) ContextMgr[150]: ##### Context::OnHeartbeat(): context 7 timing out to Live TV! (idle time 15:00) #####
Nov 8 16:16:41 (none) VideoGuts[150]: PlayLive for Proxy 343
Nov 8 16:16:41 (none) TvVideoPolicy[150]: LiveTunerRequest on 343 
Nov 8 16:16:41 (none) VideoGuts[150]: LiveTunerResult ALLOWED 343
Nov 8 16:16:41 (none) InputState[150]: AttachProxyForOutput 0
Nov 8 16:16:41 (none) OutputState[150]: PlayLive 0
Nov 8 16:16:41 (none) LogTime[150]: WatchTV: setup live: 0.182 sec
Nov 8 16:16:41 (none) ContextMgr[150]: WATCHTV::LOCK (mode COMPLETED (via LiveTV))
Nov 8 16:16:43 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:17:07 (none) last message repeated 75 times
Nov 8 16:17:09 (none) Recorder[146]: Adding check schedule task
Nov 8 16:17:23 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:17:27 (none) last message repeated 38 times
Nov 8 16:17:36 (none) Recorder[146]: Adding check schedule task
Nov 8 16:17:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:17:43 (none) last message repeated 7 times
Nov 8 16:17:57 (none) mempool[140]: MyWorld block: 1206kB/1645kB chunk: 152kB/375kB unused: 1621kB search: 1 (size=3731424)
Nov 8 16:17:57 (none) mempool[140]: Osd block: 119kB/135kB chunk: 964kB/1260kB unused: 1582kB search: 0 (size=3051488)
Nov 8 16:18:07 (none) Recorder[146]: Adding check schedule task
Nov 8 16:18:56 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:19:07 (none) last message repeated 88 times
Nov 8 16:19:07 (none) Recorder[146]: Adding check schedule task
Nov 8 16:19:07 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:19:17 (none) last message repeated 90 times
Nov 8 16:19:17 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:19:17 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:19:41 (none) last message repeated 215 times
Nov 8 16:19:41 (none) Recorder[146]: Adding check schedule task
Nov 8 16:19:41 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:19:56 (none) last message repeated 11 times
Nov 8 16:19:59 (none) Recorder[146]: Adding check schedule task
Nov 8 16:20:10 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:20:15 (none) last message repeated 50 times
Nov 8 16:20:15 (none) Recorder[146]: Adding check schedule task
Nov 8 16:20:15 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:20:19 (none) last message repeated 33 times
Nov 8 16:20:24 (none) TmkTransform::Trace[145]: ClipCache 0x3001514c Secondary Reset
Nov 8 16:20:24 (none) ClipCache[141]: 0x3001514c in Entry(), thread 141
Nov 8 16:20:26 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:20:41 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:20:45 (none) last message repeated 36 times
Nov 8 16:20:45 (none) Recorder[146]: Adding check schedule task
Nov 8 16:20:45 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:20:55 (none) last message repeated 91 times
Nov 8 16:20:55 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1026
Nov 8 16:20:55 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:21:08 (none) last message repeated 120 times
Nov 8 16:21:19 (none) Recorder[146]: Adding check schedule task
Nov 8 16:21:30 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:21:41 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:21:45 (none) last message repeated 34 times
Nov 8 16:21:45 (none) Scheduler[148]: Done ProcessProgramSources
Nov 8 16:21:45 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:21:45 (none) Scheduler[148]: Done Checking normal priority Capture Requests
Nov 8 16:21:45 (none) Scheduler[148]: FUZZY SOURCE
Nov 8 16:21:45 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:21:53 (none) last message repeated 70 times
Nov 8 16:22:01 (none) Scheduler[148]: Done ProcessSpecialProgramSources
Nov 8 16:22:01 (none) Scheduler[148]: Done Checking high priority Capture Requests
Nov 8 16:22:03 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:22:29 (none) last message repeated 97 times
Nov 8 16:22:29 (none) Recorder[146]: Adding check schedule task
Nov 8 16:22:29 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:23:00 (none) last message repeated 241 times
Nov 8 16:23:02 (none) last message repeated 21 times
Nov 8 16:23:02 (none) Recorder[146]: Adding check schedule task
Nov 8 16:23:02 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:23:09 (none) last message repeated 61 times
Nov 8 16:23:09 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:23:09 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:23:40 (none) last message repeated 165 times
Nov 8 16:23:49 (none) last message repeated 87 times
Nov 8 16:23:49 (none) Recorder[146]: Adding check schedule task
Nov 8 16:23:49 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:24:18 (none) last message repeated 252 times
Nov 8 16:24:18 (none) Recorder[146]: Adding check schedule task
Nov 8 16:24:18 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:24:28 (none) last message repeated 88 times
Nov 8 16:24:28 (none) RecordingList[148]: Err errTmBackgroundHoldoff at line 1018
Nov 8 16:24:28 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:24:50 (none) last message repeated 200 times
Nov 8 16:24:50 (none) Recorder[146]: Adding check schedule task
Nov 8 16:24:50 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:08 (none) last message repeated 160 times
Nov 8 16:25:08 (none) TmkTransform::Trace[145]: ClipCache 0x30017a18 Secondary Reset
Nov 8 16:25:08 (none) ClipCache[142]: 0x30017a18 in Entry(), thread 142
Nov 8 16:25:08 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:33 (none) last message repeated 217 times
Nov 8 16:25:33 (none) Promo[150]: Promo errNmNameNotFound: line 557
Nov 8 16:25:33 (none) Promo[150]: PromoRotation::NextValid cannot find valid promotion. 
Nov 8 16:25:33 (none) Promo[150]: PromoRotation::SetupPromotion Could not find a valid Promotion
Nov 8 16:25:33 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:33 (none) last message repeated 2 times
Nov 8 16:25:33 (none) Scheduler[148]: Abr-- reason changed from 'None' to 'UI'
Nov 8 16:25:33 (none) Scheduler[148]: Abr-- DataChanged:0x00090009
Nov 8 16:25:33 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:35 (none) last message repeated 16 times
Nov 8 16:25:35 (none) LogTime[150]: Lineup: make new RecordingsOnDisk obj: 0.000 sec
Nov 8 16:25:35 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:42 (none) last message repeated 65 times
Nov 8 16:25:42 (none) LogTime[150]: Lineup: update the OSD: 7.556 sec
Nov 8 16:25:42 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:44 (none) last message repeated 12 times
Nov 8 16:25:44 (none) LogTime[150]: Lineup: page up/down: 0.641 sec
Nov 8 16:25:44 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:44 (none) last message repeated 4 times
Nov 8 16:25:44 (none) LogTime[150]: Lineup: page up/down: 0.571 sec
Nov 8 16:25:44 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:45 (none) last message repeated 7 times
Nov 8 16:25:45 (none) LogTime[150]: Lineup: page up/down: 0.558 sec
Nov 8 16:25:45 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:46 (none) last message repeated 3 times
Nov 8 16:25:45 (none) LogTime[150]: Lineup: page up/down: 0.443 sec
Nov 8 16:25:46 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:46 (none) last message repeated 3 times
Nov 8 16:25:46 (none) LogTime[150]: Lineup: page up/down: 0.463 sec
Nov 8 16:25:46 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:46 (none) last message repeated 2 times
Nov 8 16:25:46 (none) LogTime[150]: Lineup: page up/down: 0.516 sec
Nov 8 16:25:46 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:47 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:47 (none) LogTime[150]: Lineup: page up/down: 0.429 sec
Nov 8 16:25:47 (none) LogTime[150]: Lineup: page up/down: 0.014 sec
Nov 8 16:25:47 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:48 (none) last message repeated 15 times
Nov 8 16:25:48 (none) VideoGuts[150]: PlayRecording for Proxy 347
Nov 8 16:25:48 (none) OutputState[150]: PlayRecording 0
Nov 8 16:25:48 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:25:49 (none) last message repeated 3 times
Nov 8 16:25:49 (none) LogTime[150]: WatchTV: setup cached: 0.390 sec
Nov 8 16:25:49 (none) ContextMgr[150]: WATCHTV::LOCK (mode COMPLETED (via NS))
Nov 8 16:25:49 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:26:02 (none) last message repeated 92 times
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: CHECK_VIDEO_LOCK took too long: 48
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: CHECK_VIDEO_LOCK took too long: 41
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: Lost VBI lock
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: CHECK_VIDEO_LOCK took too long: 48
Nov 8 16:26:02 (none) TmkMediaswitch::Trace[145]: Lost VBI lock_


----------



## sanderton

Nothing unusual in Endpad's log. The previous bug occurred when the requested end padding overlappped the start of the next programme, which is not the case here.

The Tivo got a "Stop recording" event at 16.01:



> Nov 8 16:01:28 (none) Recorder[146]: Got EVT_VIDEO_SESSION 9
> Nov 8 16:01:28 (none) VideoGuts[150]: StopRecording 326
> Nov 8 16:01:28 (none) InputState[150]: StartCaching 0


Then 15 minutes later it timed out to Live TV:



> Nov 8 16:16:40 (none) ContextMgr[150]: ##### Context::OnHeartbeat(): context 7 timing out to Live TV! (idle time 15:00) #####


Since it times out after 15 mins unattended, the clock for which runs from the last user interaction on a menu screen, I'd have to conclude that someone stopped the recording from Now Playing at 16.01.

You might want to check the other log file which records keypresses?


----------



## pmk

Thanks Stuart you are correct I think perhaps this is what I did on my previous recent black bar problem. I probably finished watching at 16:00 and wanted to delete the recording but as it was still recording it does not allow you so I cancelled the recording but forgot to delete. TIA.


----------



## Couch Potatoe

I understand that EndPad determines the next time it is required to wake up based on recording times and also wakes up every 30 mins to check for changes. This seems to mean that if you add any program that starts or ends within the next 30 mins then EndPad may miss padding it. This is a performance nod.

I guess we use our Tivo a little differently - often panicing when two programs are about to start and creating an instant recording of one - or recording one already in progress in the buffer. The effect is that EndPad doesn't adjust the pad times and we occasionally lose the endings .

I just wondered if there was any other approach that might trap these types of additions eg an event driven rather than poll type operation. It would really be nice to get padding added on these instant recordings somehow. Is there a lot of work every 30 mins and would it be impractical for it to be more frequent , perhaps set in the command line parameters ?

Kevin

(Having recently just convinced someone that I will record the end of a thriller they were watching whilst we watched the footy live only to find the end was cut off. Yeah I know I should have added a manual padding and I now have the bruises / bow legs to prove it.)


----------



## sanderton

If you're doing it "live" why not just add the padding while you're at it?

You can mod the code to make the wake ups more frequent than 30 minutes if you want. The key line is:



Code:


# Max 30 mins between wake ups to catch new recordings
      if {[expr $nexttime - [clock seconds]] > 1800} {
        set nexttime [expr [clock seconds] + 1800]
      }

Change the 1800 (30 mins in seconds) to whatever you like.


----------



## Couch Potatoe

> _Originally posted by sanderton _
> *If you're doing it "live" why not just add the padding while you're at it?
> 
> *


Oh I did mention that I >should< have done this in my post but it sort of seems you shouldn't have to if you have true "automatic soft padding" running - plus that's an extra step and one the other members of the family would find awkward and will forget.

Thanks for the script edit pointers - I might try it at 5 min intervals and see how it works out. Is it a real cpu hog ?

Kevin


----------



## sanderton

Don't know. Shouldn't be. Try it!

I put it in at 30 mins, as the number of shows that should miss will be very small - shows which are shorter the 30 mins, whose recording was set less than 30 mins ago and which a wake up doesn't happen to fall in. Ireckoned you'd be unlucky if one a year got missed.


----------



## bradleyem

I've had a crash which wiped my /var folder. So I've reinstalled TW, and also endpad 1.4.1, but when I go to the tracker module, I've get "tracking directory not found".

Have I lost all my data? If so, is there a way of backing it up every so often (even manually)?
(or is it just copy /var/hack/tracker)

Otherwise, it's a fabulous tool, especially the tracking bit.

TIA
Brad


----------



## sanderton

Tracker isn't part of Endpad any more, it's a stand-alone TW module.

If /var got wiped, then yes you lost your database. You can indeed just make a copy (tar-ing it up first might make it quicker).


----------



## bradleyem

bugger. 

(I'd added the tracker module, just didn't mention it. )

is tar on the tivo, or do I need to find the bin? (no tivo to hand to check!)


----------



## sanderton

You need to find the binary. There is a built in command, cpio, but its syntax is a bit of buggar.


----------



## bradleyem

Tar is on this thread if anyone else is interested.
http://www.tivocommunity.com/tivo-vb/showthread.php?s=&postid=2351541#post2351541


----------



## ericd121

I've only read the first *9* pages, so can I ask if the following question has been answered:-

*Can Endpad be installed, and configured, using a PC in the manner of Hinsdale?*

I don't have a serial cable (did one come with?  If so, it must still be in the box(es) )


----------



## kitschcamp

Yes, using the types of boot discs you would use to install TivoWeb you can mount the drives and the partition and use pico/nano to edit the config file.

I've done it in the past when I've accidentally screwed up my tivo with unthoughtful editing.


----------



## 6022tivo

> _Originally posted by ericd121 _
> *
> I don't have a serial cable (did one come with?  If so, it must still be in the box(es) ) *


Interesting that is, in the US, series 1 tivos did come with a serial lead, in the UK they did not.

But as a buyer and seller of tivo's in the early days the cable sets that came with a new tivo has a small incision in them as if either a cable has been removed (serial??) or a cable inserted (UK Telephone cable)..

To answer your question they did not come with the UK tivo..

Can be easily made, there is a diagram on this forum have a search, or ebay.


----------



## alphabeta

> Can Endpad be installed, and configured, using a PC in the manner of Hinsdale?


Yes, there are instructions here which I hope are still right. It may need some tweaks if your Tivo has already been upgraded or scripted though.


----------



## ericd121

> _Originally posted by kitschcamp _
> *Yes, using the types of boot discs you would use to install TivoWeb you can mount the drives and the partition and use pico/nano to edit the config file.
> 
> I've done it in the past when I've accidentally screwed up my tivo with unthoughtful editing. *


 I've still got the *MFS Tools * boot floppy that I used for my Hinsdale upgrade to 120Gb.

Would that be OK to use? 
(I vaguely remember that boots to a Bash prompt)

I can then follow the command from Page One of this thread, presumably?


----------



## kitschcamp

Er, not sure. I can't remember what the MFS tools disc did and didn't let you do.


----------



## sanderton

The boot CD which has the turbonet drivers on works.


----------



## ericd121

Thanks, guys.

The old PC that I'll be using doesn't see its CD Drive until after booting (despite being told to do so in the BIOS!), but I've managed to boot it to a Bash prompt using the *MFS Tools boot floppy *, so I'll read and digest Hinsdale (again) and Steve Jenkins Network Hack How-To Guide, both of which I have in printed form, before diving in tomorrow.

The PineDragon EndPad Page looks very useful, too. :up:


----------



## Goshdarnit

Thank you! Just stripped Tivo down again after my padding seemed to be missing on most shows. Turned out I had -sugeq set and Tivo was stripping padding from lots of recordings because of the suggestions. Often, suggestions which it never bothered recording after all! Anyway, one HD removal and joe session later, all seems well. This is THE killer hack for Tivo, IHMO. Nothing else worth taking it apart for. Of course, I installed bufferhack while I was at it! 

Can I just check on the latest state of play of Manual padding vs Endpad? If I set 30 min padding on a sports program, will Endpad strip it now (1.4.1 installed)? I would ideally want 5 mins on most things, but I tend to set BBC rugby to +1/2 hour and Formula 1 to +1 hr (in case of red flags and restarts), so would ideally prefer Endpad to leave any manual padding alone, as I have removed it from all my season passes. Either way though, it is still a million times better than Tivo without Endpad! I know the answer to this is in the thread, but I worked through them all once, and have kind of lost track of the whole plot!

Once again, congratulations on the succes of this hack, and THANK YOU!!!


----------



## ericd121

I, too, am using the PC method to install Endpad.

I've made all the changes on my partition 4, but can't mount partition 7

Can someone tell what I need to do?


----------



## doubledrat

it'll either be partition 7 or 9. if 7 won't mount, try 9


----------



## ericd121

> _Originally posted by doubledrat _
> *it'll either be partition 7 or 9. if 7 won't mount, try 9 *


 Now you're just trying to confuse me! 

I understood it was 4 or 7 which are the same, and 9 which is something different entirely.


----------



## alphabeta

> I understood it was 4 or 7 which are the same, and 9 which is something different entirely.


 You are right 4 and 7 are basically the same and 9 is different. If you are following the instructions on pinedragon.com then they only apply for a vanilla unupgraded Tivo. If you have done a disk upgrade then one of the 4 or 7 partitions won't mount. This is OK - just work on the one that does mount and ignore the other.


----------



## alphabeta

> only apply for a vanilla unupgraded Tivo


 Also related to this, the instructions overwrite rc.sysinit.author. If you have created an rc.sysinit.author file for any other reason then you will need to make suitable modifications.


----------



## doubledrat

sorry, maybe I'm misremembering...


----------



## ericd121

> _Originally posted by alphabeta _
> *Also related to this, the instructions overwrite rc.sysinit.author. If you have created an rc.sysinit.author file for any other reason then you will need to make suitable modifications. *


 Just trying to expand my knowledge...
which bit overwrites *rc.sysinit.author*? Is it


Code:


echo "/bin/bash < /dev/ttyS3 >& /dev/ttyS3 &" >> rc.sysinit.author
echo "/var/hack/endpad.tcl -s 2 -e 5 -auto >> /dev/null &" >> rc.sysinit.author

I thought this would only write to the file, not overwite it, if it existed?

But what do I know, I've been trying to get EndPad to work for two days now...


----------



## doubledrat

>> means append to the file that follows the >>

if you put > it will zap the file (unless the > is in "")

i.e. make sure you type the command very carefully or the results might not be what you want!


----------



## ericd121

> _Originally posted by doubledrat _
> *>> means append to the file that follows the >>
> 
> if you put > it will zap the file (unless the > is in "")
> 
> i.e. make sure you type the command very carefully or the results might not be what you want! *


 Thanks, Bob. 
Looks like I did everything right, but I'll pull the HDD tomorrow to double check.

After I did the echo command, I discovered I could have used *Joe*, which is on the HDD as supplied by Blindlemon. 
I had a look inside *rc.sysinit.author* and all looked acceptable (yes, I quit without saving the file).

I *chmod 755*ed it, and then did *ls -l* and the permissions looked fine.

If anyone can point out anything to be done, or not done, to get EndPad to work, I'd be very grateful.


----------



## doubledrat

the key thing is -

echo "/bin/bash < /dev/ttyS3 >& /dev/ttyS3 &" >> rc.sysinit.author

with that in your rc.sysinit.author you can access your tivo using the serial connection and make any necessary changes without having to pull it apart.


----------



## alphabeta

> I thought this would only write to the file, not overwite it, if it existed?


 Humm, yes that would be right for partition 7. If you followed the instructions the rc.sysinit.author on partition 4 would be zapped.

In any case, the instructions certainly don't backup any old rc.sysinit.author file, or make sure that the commands you add don't conflict with any that are already there.


----------



## ericd121

> _Originally posted by doubledrat _
> *the key thing is -
> 
> echo "/bin/bash < /dev/ttyS3 >& /dev/ttyS3 &" >> rc.sysinit.author
> 
> with that in your rc.sysinit.author you can access your tivo using the serial connection and make any necessary changes without having to pull it apart. *


 Unfortunately, I don't have a Tivo Serial Cable. 

I'm thinking of taking advantage of George Bush's mis-management of the U.S. economy (i.e. the dollar is in freefall) to buy a couple of CacheCards.


----------



## gyre

Now's a good time to buy, I think. $125 shipped... which is like 65 quid or something.

-- gyre --


----------



## doubledrat

it's the same as the pronto serial cable. there's one one ebay for 99p at the moment...


----------



## ericd121

I now have *EndPad* running. 
I'd mistyped its parameters! 

Luckily, I was accessing a *Blindlemon* supplied disk, which had all the TiVo binaries installed, so I edited *rc.sysinit.author* in *Joe *and all was well.

Thought I'd pass on something to those who, like me, are merely following, parrot-fashion, the instructions of others.

When you're backing up using Hinsdale or PineDragon using a variant of this command


Code:


/mnt/dos/mfstool backup -l 32 -6 -s -o /mnt/dos/tivo.bak /dev/hdb

 be aware that, of course, *tivo.bak* is the filename of your backup, and if you change that, you can have as many backups as you have room for.

I have 
*tivo.bak* which is my original 40Gb HDD backup from my first HDD upgrade.
*tivobl.bak* which is the 160 Gb HDD backup as supplied by *Blindlemon* with Cachecard drivers, TivoWeb, Mode 0 and upgraded kernal
and 
*tivoep.bak* which is all the above with EndPad enabled.


----------



## Filw

Hi all,

Earlier in this thread a missing slash from the *rc.sysinit.author* line was highlighted.. Just to let you know that the readme in the endpad gzip has the same omission.

The line should read
/var/hack/endpad.tcl -s x -e y -sugqual z -sugeq -auto >> */*dev/null &

It's only a problem if you're lazy like me and just paste it in - that'll teach me! It probably won't though.

Phil

PS Fantastic program sanderton- I'll never miss the last 5 minutes of Sky at Night again!


----------



## Goshdarnit

> _Originally posted by doubledrat _
> *it's the same as the pronto serial cable. there's one one ebay for 99p at the moment... *


*lol* Wish I'd known that! I have a Pronto and just waited several days for my Tivo cable to be delivered!


----------



## doubledrat

doh!


----------



## LaupSavea

Just downloaded and installed V1.4.1 - never installed before.

I have installed endpad.tcl exisitng in Hack directory
then
chmod 755 endpad.tcl - which seemed OK
then

./endpad.tcl 1 1

from which I get......

./endpad.tcl: t: command not found

./endpad.tcl: line 13: syntax error near unexpected token `}'

./endpad.tcl: line 13: ` }'

I have tried various combinations of syntax but no success?

Any ideas??

Thanks

Laup

160Gb TiVo with CacheCard + TiVoWeb


----------



## Rob Nespor Bellis

That's because your command is wrong......

Perhaps it should be ./endpad.tcl -s 1 -e 1 ?

You *may* wish to read the first post in this thread ( by Sanderton ) where he explains exactly how to use endpad.

Rgds,

R.


----------



## Rob Nespor Bellis

Thank-you Stuart for your great module, it just saved my bacon ( yet again. ) BBC3 are running fast ( again ) tonight and without your module I ( meaning the wife of course  ) would have missed the start of Two Pints etc... the new series.

Rgds,

R.


----------



## PaulOckenden

> _Originally posted by RobBellis _
> *Thank-you Stuart for your great module, it just saved my bacon *


Mine too. endpad has to be the most useful tivo hack ever.

P.

p.s Wasn't that impressed with the 1st episode of the new series of 2POL - it seems to have lost its edge.


----------



## LaupSavea

My FTP Wanderer seems to screw up the file - I ftp using IE and all is well.

Anyone know of a TIVO friendly FTP prog?

EXCEPT for occassionally lock up when using Season Pass Manager which requires a switch off and on. Only started since installing - I am trying different s and e variables. Still, it works mostly and thats the rub - nice one!!


----------



## iankb

> _Originally posted by LaupSavea _
> *... I ftp using IE ...*


Not a good idea. The TiVo FTP server can only handle one connection, and programs such as IE will try and use multiple connections. I use the command-line FTP client in Windows XP with no problems.


----------



## Fozzie

> _Originally posted by LaupSavea _*
> Anyone know of a TIVO friendly FTP prog?*


Just pull up a command prompt and type 'ftp _IP address_'.

Make sure you type 'bin' (for binary mode) after connecting.


----------



## hedwig-0101

What is wrong with using IE for FTP.

It is the only FTP prog I use and it has never let me down.


----------



## LaupSavea

Fozzie,IanKB, Hedwig - Many thanks.


----------



## dave h-j

I take it endpad runs with the default priority - anybody running with a lower priority? (I've got problems with sound warbles sometimes, which doesn't seem to affect me when endpad is not running).


----------



## kitschcamp

What other hacks are you running? For example, Tivoweb or Tivoweb+? Any of the IR programs?


----------



## dave h-j

nope only run endpad/tivoweb/cron (for dailymail)

I can't see whats cauing it, so it's a case of stopping things to see. so far without endpad I haven't seen it reoccur.


----------



## B33K34

having finally got tivoweb working over the interweb i was browsing the logs and noticed that endpad doesnt seem to be working quite as i expected.
I've edited my startup file using Startup editor and it reads:
/var/local/tivoweb-tcl/tivoweb >> /dev/null &
/var/hack/endpad.tcl -s 1 -e 5 >> /dev/null &

Tivoweb and endpad both start after a reboot. 

I thought that endpad would pad the end of a scheduled recording rather than record a suggestion but the logs seem to say otherwise. Am I wrong or is this a switchable option?

Sleeping, checking every minute for kill signal....
Sunday 19:58:00 : Woken up
Sunday 19:58:00 : Recording {Channel 4 News} on C4 now
Sunday 19:58:00 : Recording Scheduled End Time: 20:00
Sunday 19:58:00 : Next recording is {Seven Days that Shook the Weathermen} on C4 (Suggestion) at 20:00
Sunday 19:58:00 : Gap to next programme is 0 seconds
Sunday 19:58:00 : Can't add end padding to {Channel 4 News}
Sunday 19:58:00 : Next end padding setting due 20:55
Sunday 19:58:00 : Gap to previous recording is 0 seconds
Sunday 19:58:00 : Can't add start padding to {Seven Days that Shook the Weathermen}
Sunday 19:58:00 : Next start padding setting due 20:55
Sunday 19:58:00 : Next wake up will be 20:28


----------



## sanderton

Can you check which version of EendPad you are using and copy and paste the log fiel header where it announces its settings.


----------



## B33K34

Sorry - i did check the version and meant to include it. The only thing that occured to me is that this might be because the suggestion was on the same channel as the recording.

Sunday 00:25:01 : endpad.tcl 1.4.1 log file, log rotated
Sunday 00:25:01 : Start padding set to 60 seconds
Sunday 00:25:01 : End padding set to 300 seconds
Sunday 00:25:01 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Sunday 00:25:01 : Detected TiVo software version 2.5.5a-01-1-023
Sunday 00:25:01 : Suggestion quality change disabled
Sleeping, checking every minute for kill signal......


----------



## ericd121

> _Originally posted by B33K34 _
> *The only thing that occured to me is that this might be because the suggestion was on the same channel as the recording.*


 As I posted in the Endpad and suggestions over Christmas...

When I first installed EndPad, it failed to pad *Channel 4 News*, but instead padded the following 5 minute Channel 4 prog *The Political Slot*.


----------



## B33K34

That looks like the same problem on the same programme.... Fine in principle (if you want to see the end of the first prog you watch the start of the second) but poor in practice (you need to identify that the other prog exists, what it is and that it hasn't been deleted in the meantime).

As an aside, what does -auto do? I'm running from the startup script without it and it seems fine.


----------



## sanderton

-auto tells it to ignore the "Endpad is already running" flag, which may remain set if your TiVo crashes.


----------



## a_tivo_noob

i really do apologise if this has already been asked somewhere in this (48 page!) thread 

I have endpad running on my Tivo, which was included on an image kindly donated to me by a member of this forum back in April 2004 (IIRC) and it was working like a dream, up until the last couple of months, whereby, due to BT, poor little Tivo could no longer dial in and, was struggling for a couple of weeks with no guide data...

now, since then, it's been dialling back in regularly, however, EndPad has stopped working... i'll be honest, i haven't a clue what to do... I really would appreciate any help - tried many resets and all sorts but to no avail...

your patience and replies are much appreciated! 

cheers


----------



## mike0151

Sounds like your /var directory has been recreated, thus you have lost all or most of your hacks. This can happen from time to time. Do a search for more info. You'll need to reinstall the hacks to get them working again. This will also happen if you request the 2.5.5.a version of the software to overcome the teletext problem.

HTH

Mike


----------



## lcsneil

Having probs with endpad. 

Noticed the other night it didn't pad a prog I had recorded. Checked out the logs and saw this...

Tuesday 23:11:18 :
Tuesday 23:11:18 : endpad.tcl 1.3.3 log file, starting up
Tuesday 23:11:18 : Start padding set to 60 seconds
Tuesday 23:11:18 : End padding set to 300 seconds
Tuesday 23:11:19 : Error detected
can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Tuesday 23:11:19 : Attempting to recover
Tuesday 23:11:49 : Error detected
can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Tuesday 23:11:49 : Attempting to recover
Tuesday 23:11:49 : Too many errors, stopping

Ran it again from the Bash Prompt and got the same thing - one thing to do in my ToDo list (for 3/2) before anyone suggest that might be the prob.

Any ideas??

Neil


----------



## Fozzie

Have you tried running the latest version (1.4.1) ?


----------



## sanderton

It's a known bug, but figured that the occasions where you only have one thing in the entire To Do List was so rare I didn't fix it.


----------



## sanderton

It's a known bug, but figured that the occasions where you only have one thing in the entire To Do List was so rare I didn't fix it.


----------



## paul_J2

Is there an idiots guide somewhere to how to install this software on the TiVo? I see nothing in the FAQ or on the sticky links, just lots of references to cron jobs and the like in this thread. Just WTF do I need to do? Surely this should be a stickly link? Or did I miss it???


----------



## Fozzie

The first post of this thread and the readme.txt in the endpad.zip file explain how to install it.

You don't need to do anything with cron - just follow the instructions.

(What exactly is a "stickly link"? )


----------



## lcsneil

> _Originally posted by sanderton _
> *It's a known bug, but figured that the occasions where you only have one thing in the entire To Do List was so rare I didn't fix it. *[/QUOTE
> 
> Are there any plans to fix it?
> 
> <update now got it running - newer version has differnt cmd line param -Doh >
> 
> Neil


----------



## sanderton

It will be unrelated.

Hmm, I could pull out the code, figure out a fix, test it, upload it, cause 1,000-odd people to upgrade their software 'case they haven't got the altest version anymore or... you could just hit the record button in the guide to put a second item in the TDL. 

Close call.


----------



## lcsneil

OK I'll rephrase that then. Any plans to incoroporate a fix in the next release (if there is one...) 

Hmmm I got the "Close call" response from the 'pooter help desk at work today as well when summit still wasn't working. Completely different matter though! 

2nd item now scheduled.....


Neil


----------



## paul_J2

Sorry, I downloaded the zip file, but all it says is

"Copy to the TiVo using binary mode FTP then"

This is the heart of my question. How do I set up a binary mode ftp connection to the TiVo - what connectors do I need (RS232 serial cable? )? Do I need to open the TiVo? I can probably handle the ftp part from my PC, but it is the _connectivity_ that I am asking about, and which I can't find any details for.


----------



## alextegg

Paul,

The connectivity is provided either using a serial cable, or ethernet if you have installed a turbonet or cachecard to provide the ethernet interface.

This is the easiest option if you are going to add more hacks in the future. Once a network card is installed, you can install hacks easily, all of which are detailed on this forum.

HTH,

Alex


----------



## Fozzie

@paul_J2 - without wishing to sound rude, this thread is about endpad and not fairly basic questions about how to hack Tivo. Most hack installation instructions assume a certain base level of knowledge. Without this, all the threads would end up getting bogged down answering the same questions and important information pertaining to the hack itself ends up getting lost in the noise.

Have a quick search and I guarantee you'll find all your questions (and more) already answered in quite a few other threads. Good luck


----------



## Greg.Steele

Thanks for posting this. I hate to ask a stupid question, but how do I get a TELNET session to the Tivo unit? I have it set up to use my wireless home network and I can ping the IP address it says it's using, but I can't open a TELNET session to the address.


----------



## gregh

Greg,

Use a terminal emulator, or under XP open a command prompt and type telnet!

Greg


----------



## Greg.Steele

Thanks for the response. I had tried a terminal emulator first, then telnet from the DOS prompt in W2k. I was getting a "connection refused" message. 

I did a little more googling and it appears that telnet isn't enabled in the software as delivered and you have to hack it up to enable it. The unit I have is a Toshiba with a DVD player in it (no floppy) and I don't even know if the BIOS will boot from it. Even if it does, I'm not sure that I want to take a chance on screwing something up and winding up with nothing. I'm not exactly a Linux hacker. 

I guess I'll just have to stay mad at Tivo. I've already told my kids to get their DVRs from the cable company. I think it's sad that a company can ignore their customers so thoroughly. They don't appear to even read this forum.

Thanks again.

Greg


----------



## AMc

Greg.Steele - Are you using a UK Thompson Scenium Tivo?
These are the only units available to the UK market, you may find better help in the US forums if you have a US Tivo.


----------



## pahunt

If it's a series 2, which it sounds like it is, then you are best off looking for hacking info at the "other" forum that we can't mention here but google will find if you search for "database hacking tivo". Be prepared for a steep learning curve though.


----------



## Keris

First, endpad is really useful, thanks for it!

I'd like an extra feature, though, I don't know whether it is possible.

On most of the cable channels (NTL UK) it seems that programmes finish early, then have commercials, and the next program starts "on time" (which can be up to a minute early). This means that if there are programmes to be recorded back-to-back the first one runs for the whole time, including the first bit of the second programme, then the TiVo changes channel (which the cable box causes a glitch so it takes several seconds to settle down) and then starts recording the second programme, minus the bit which has started.

What I want is a way to automatically shorten the previous programme, a sort of reverse end padding. Can this be done? I've looked at endpad.tcl, and I have a suspicion that if it can be done it will involve altering the 'Duration' of the current programme in the database, but (a) I haven't used TCL for many years (I'm a C/C++ programmer) and (b) I don't know what the database commands really do (is there a list somewhere?).

Any suggestions?


----------



## a_tivo_noob

mike0151 said:


> Sounds like your /var directory has been recreated, thus you have lost all or most of your hacks. This can happen from time to time. Do a search for more info. You'll need to reinstall the hacks to get them working again. This will also happen if you request the 2.5.5.a version of the software to overcome the teletext problem.
> 
> HTH
> 
> Mike


 here we go then... never tried this before - wish me luck!


----------



## a_tivo_noob

stumbling block no.1 - i cant' mount to partition 7... I can mount to 4 and 9 tho... on 7, it says "you must specify the file system type"

is this because i am using an upgraded 120GB harddrive?


----------



## a_tivo_noob

ignore, read back and found this:
http://www.tivocommunity.com/tivo-vb/showthread.php?p=2411016&&#post2411016


----------



## sanderton

Keris said:


> First, endpad is really useful, thanks for it!
> 
> I'd like an extra feature, though, I don't know whether it is possible.
> 
> On most of the cable channels (NTL UK) it seems that programmes finish early, then have commercials, and the next program starts "on time" (which can be up to a minute early). This means that if there are programmes to be recorded back-to-back the first one runs for the whole time, including the first bit of the second programme, then the TiVo changes channel (which the cable box causes a glitch so it takes several seconds to settle down) and then starts recording the second programme, minus the bit which has started.
> 
> What I want is a way to automatically shorten the previous programme, a sort of reverse end padding. Can this be done? I've looked at endpad.tcl, and I have a suspicion that if it can be done it will involve altering the 'Duration' of the current programme in the database, but (a) I haven't used TCL for many years (I'm a C/C++ programmer) and (b) I don't know what the database commands really do (is there a list somewhere?).
> 
> Any suggestions?


Sadly it's not quite that simple, as ever.  This is an often requested feature, but would require quite a bit of work. The main problem is if you set a second recording to start early, then it tends to obilterate (not just cancel) the first recording, even if it has stopped early though negative end padding.

It's possible you could get something to work through also altering the Duration - I don't know.

I didn't persue it because for every time you get the last minute of a show on the start of the next recording at present, I think you'd create a new instance of the same thing with an EndPad working this way (from when the programmes actually ended on time.)


----------



## bobones

Endpad crashes if there are no recordings in the database (e.g. after using DeleteAll .tcl and clearing the todo list). It all kicks off when $rectype is used (if $rectype == 3) when it hasn't been set in the main loop.


----------



## sanderton

Yes, it does. Known bug. Fixes itself when you add two shows to the TDL.


----------



## somegeeza

I'm having trouble downloading Endpad from the link on the first page of this thread.

Having same problem downloading Autospace 2.5.5 too from this forum.

Is anyone else getting this problem?


----------



## Fozzie

Right click, 'Save Target As' works fine here.


----------



## MikeMcr

I have the same problem. Ever since they upgraded the forum software, left-clicking on attachments no longer works for me. However, you can right-click and select "Save Target As" instead.


----------



## iankb

I reported the download problem as a bug, but I didn't get much sympathy.


----------



## somegeeza

Many thanks, right-clicking and saving to target works fine.

Andy


----------



## maxwells_daemon

Hi sanderton,

Thanks for the nice module. I just installed it, so I'll have to see how it goes, but from your documentation it looks just the sort of thing I've always wanted - and nicely coded too. 

If I understand it correctly, endpad applies the same padding to all programs (where it can), regardless of what channel they are on. Right? I was wondering whether one could apply different padding to different channels, eg. -e 15 for BBC and -s 1 for SKYONE (that's like what I usually used when I did it by hand).

If you like, I could give it a go. I know tcl quite well, but haven't done anything for the TiVo, so I don't know how easy that might be. What do you think? Sorry if this has already been discussed and I didn't notice among the 991 posts!

Thanks,
Tim.


----------



## sanderton

It has been; it is perfectly possible; I don't need it (and not that many folks seemed bothered) so haven't done it.

Feel free!


----------



## maxwells_daemon

Hi Stuart,

OK, my modified version is attached (or if, like me, you prefer to be able to download and unpack directly on the TiVo, you can get the tar.gz file here). It has run OK on my TiVo for the last couple of days, so I thought I'd post it for you and other people to try if you are interested.

This new version can read an endpad.config file (from the same directory as endpad.tcl - or you can specify another location with the -config option) with lines like


Code:


endpad 2
channel BBC1STH,BBC2STH,BBC4 endpad 15
channel SKYONE startpad 1

which adds 15 minutes' end padding on BBC programs, and 2 minutes for everything else. It also adds 1 minute's start padding on SKYONE programs. The global "endpad 2" line is equivalent to the "-e 2" command-line option. This means that all the settings can go in endpad.config so it can be started without any options (except, if needed, -auto -stop -debug or -config, of course).

The configuration file allows you to specify any of the endpad options separately for each channel, ie. "startpad", "endpad", "sugqual" (suggestion recording quality), and "sugeq" (disabling soft padding-prompted suggestion cancellation). Any that aren't specified, default to the command-line or global options.

I also took the liberty of making a few other small improvements to endpad.tcl.

1) Explicit help option (-? or -help).

2) Separate activity summary log in /var/log/endpad.msg. This shows just the actions that EndPad took, so you don't have wade past all the details of its calculations in endpad.log. This logfile is rotated weekly, so you get a longer view. The activity messages now include the channel name and whether the program is a suggestion.

3) New -debug option runs in the foreground with messages going to the screen and a kill signal check every 5 seconds.

4) For compatibility between the configuration file and the command-line options, -s and -e can be specified as -startpad and -endpad respectively (and vice versa for the configuration file).

5) When spawning into the background, use the same tivosh as was used to run endpad.tcl. This allows one to do a few tests on a PC by specifying tclsh explicitly.

I named this version 1.4.1-md1 to distinguish it from your latest. If you approve of these changes, feel free to include them in any future version you make (and you can drop the "-md1" suffix).

This probably does all I wanted for the moment. The configuration file format was designed to allow additional selections (eg. by time period, season pass, or wishlist). One possibility would be to allow TivoWeb to update the file and hence schedule soft padding from the Season Pass or To Do list. I might take a look at that if there were sufficient interest (anyone?) - and if you didn't want to run with it (I don't want to tread on your toes, Stuart).

Tim.


----------



## maxwells_daemon

To give an example, here is a snippet from my /var/log/endpad.msg (with the endpad.config settings I gave in my last post).


Code:


Tuesday 16:25:00 :  Added 120 seconds end padding to Seinfeld on PARCOM2 (Suggestion)
Tuesday 17:00:00 :  Added 900 seconds end padding to {Party Election Broadcast by the Conservative Party} on BBC2STH 
Tuesday 18:58:00 :  Added 60 seconds start padding to {Star Trek: Enterprise} on SKYONE 
Tuesday 21:45:00 :  Added 120 seconds end padding to {Judge John Deed} on UKDRMA

It would have added 120 seconds end padding to _Enterprise_, but _Judge John Deed_ came immediately after.

I should point out that my TiVo is usually a good left-wing PVR and the Conservatives' election broadcast was only included for political balance. 

Tim.


----------



## sanderton

No toe-treading Tim; as far as I'm concerned EndPad development is complete. Free free to take it on and run with extra features, so long as the licence is not changed. I'm happy for you to increment version numbers.

I will however leave the version in the top post as-is, as it's stable, tested with over 1,000 users for over a year, and therefore useful for people who don't want development code controlling their TiVo.


----------



## iankb

Just in case you're wondering, there is interest in allowing for variable time-slots. e.g. Increase the padding on ITV after 8pm.

Of course, what I really want is increased padding on ITV after they show a routinely (and intentionally) overrun episode of 'Who Wants to be a Millionaire'.


----------



## pmk

For some reason last night Hit More Baby 1 More Time result show was not recorded at 20:15. This show was in my To Do list and the EndPad log below mentions it once but it was ignored and Doctor Who Confidential got 15 mins of end padding instead of HMB1MT being recorded?

Can anyone suggest a method of finding out what happened?

TIA

Saturday 18:42:00 : Woken up
Saturday 18:42:00 : Recording {Doctor Who} on BBC1NW now
Saturday 18:42:00 : Recording Scheduled End Time: 18:45
Saturday 18:42:00 : Next recording is {Doctor Who Confidential} on BBC3 at 18:45
Saturday 18:42:00 : Gap to next programme is 0 seconds
Saturday 18:42:00 : Can't add end padding to {Doctor Who}
Saturday 18:42:00 : Next end padding setting due 19:10
Saturday 18:42:00 : Gap to previous recording is 0 seconds
Saturday 18:42:00 : Can't add start padding to {Doctor Who Confidential}
Saturday 18:42:00 : Next start padding setting due 19:10
Saturday 18:42:00 : Next wake up will be 19:10
Sleeping, checking every minute for kill signal............................. 
Saturday 19:10:00 : Woken up
Saturday 19:10:00 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:10:00 : Recording Scheduled End Time: 19:15
Saturday 19:10:00 : Next recording is {Hit Me Baby One More Time} on ITV1GRA at 19:15
Saturday 19:10:00 : Gap to next programme is 0 seconds
Saturday 19:10:00 : Added 870 seconds end padding to {Doctor Who Confidential}
Saturday 19:10:00 : Next end padding setting due 19:25
Saturday 19:10:00 : Not time to add start padding yet
Saturday 19:10:00 : Next start padding setting due 19:12
Saturday 19:10:00 : Next wake up will be 19:12
Sleeping, checking every minute for kill signal... 
Saturday 19:12:00 : Woken up
Saturday 19:12:00 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:12:00 : Recording Scheduled End Time: 19:29
Saturday 19:12:00 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:12:00 : Not time to add end padding yet
Saturday 19:12:00 : Next end padding setting due 19:24
Saturday 19:12:00 : Not time to add start padding yet
Saturday 19:12:00 : Next start padding setting due 19:27
Saturday 19:12:00 : Next wake up will be 19:24
Sleeping, checking every minute for kill signal.............. 
Saturday 19:24:30 : Woken up
Saturday 19:24:30 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:24:30 : Recording Scheduled End Time: 19:29
Saturday 19:24:30 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:24:30 : Gap to next programme is 900 seconds
Saturday 19:24:30 : Added 900 seconds end padding to {Doctor Who Confidential}
Saturday 19:24:30 : Next end padding setting due 19:55
Saturday 19:24:30 : Not time to add start padding yet
Saturday 19:24:30 : Next start padding setting due 19:27
Saturday 19:24:30 : Next wake up will be 19:27
Sleeping, checking every minute for kill signal.... 
Saturday 19:27:00 : Woken up
Saturday 19:27:01 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:27:01 : Recording Scheduled End Time: 19:30
Saturday 19:27:01 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:27:01 : No end padding required:
Saturday 19:27:01 : End padding of 900 seconds already set
Saturday 19:27:01 : Next end padding setting due 19:55
Saturday 19:27:01 : Gap to previous recording is 0 seconds
Saturday 19:27:01 : Can't add start padding to {Click Online}
Saturday 19:27:01 : Next start padding setting due 19:55
Saturday 19:27:01 : Next wake up will be 19:55
Sleeping, checking every minute for kill signal............................. 
Saturday 19:55:00 : Woken up
Saturday 19:55:00 : Recording {Click Online} on BBC24 now
Saturday 19:55:00 : Recording Scheduled End Time: 20:00
Saturday 19:55:00 : Next recording is {Crazy Drivers} on FTN (Suggestion) at 20:30
Saturday 19:55:00 : Gap to next programme is 1800 seconds
Saturday 19:55:00 : Added 900 seconds end padding to {Click Online}
Saturday 19:55:00 : Next end padding setting due 20:55
Saturday 19:55:00 : Not time to add start padding yet
Saturday 19:55:00 : Next start padding setting due 20:27
Saturday 19:55:00 : Next wake up will be 20:25
Sleeping, checking every minute for kill signal...............................


----------



## lcsneil

I suppose the question is what version of EndPad? 

Sanderton's or Maxwells_deamon?


Neil


----------



## sanderton

No idea at all. That log looks very odd. Seems to have added 14 and half minutes padding, then added another 15 on top (making 29 and half in total), while cancelling non suggestions.

It shouldn't do that, and I've never seen it, or seen it reported before.

I haven't the least idea why it would do that. I can only think that the guide data for Dr Who Confidential was really, really odd in some way, or some kind of memeory glitch screwed up EndPad's varaiables.


----------



## maxwells_daemon

lcsneil said:


> I suppose the question is what version of EndPad?
> Sanderton's or Maxwells_deamon?


It's Sanderton's (the log messages would have been different - I added the channel name to some of them), though I doubt the bug is restricted to that version, since I only made small changes to the logic.


----------



## 6022tivo

Could it be it is running twice one time with 14 mins padding and another with 15, both ammending to the log file??


----------



## pmk

Can anyone tell me what command I should use to see what processes are running via telnet? I can then check if nothing is running more than once. I doubt this however as nothing has been changed for months.

TIA


----------



## 6022tivo

at a bash prompt type 

ps -ax



to kill a process type

kill -9 ****

where **** is the process ID


----------



## maxwells_daemon

As 6022tivo suggests, you can use


Code:


ps ax

to list processes. One of them should have "endpad.tcl" as part of the command string. There shouldn't be two.

However I would urge you *not* to kill endpad with the kill command. That can cause your TiVo to reboot. Instead, create a file endpad.kill in the directory where endpad.tcl is located. After a few minutes, all endpad processes should have stopped (you can see in the logfile).

If you don't have "ps" installed on your TiVo, you can get it from Craig Leres' page (or a newer port from my page, but that comes as part of a bigger package).


----------



## sanderton

The 14 1/2 minutes is a/the clue I think. 

Endpad checks the start time of the next but one show as well when adding padding. For it have reduced that time by 30 seconds, there must have been a show scheduled to start 14:30 after the start of Hit me Baby One More Time. That show would have forced the recording of HMB1MT to be cancelled as it is 15 mins long. 

Looks to me like the datbase got itself well confused over a period of minutes. I don't think that was directly caused by EndPad - I can't see how it could "imagine" a show starting 14.30 later - but it being busy accessing the database at the time may have added to the confusion.

I'd just restart your Tivo.


----------



## pmk

ps showed only one copy of endpad running.

Thanks I will restart my TiVo just in case - luckily I noticed HMB1T had not started recording and managed to see the last 2 minutes so I know who won. 

Cheers


----------



## pmk

pmk said:


> luckily I noticed HMB1T had not started recording and managed to see the last 2 minutes so I know who won.


Same problem happened yesterday except this time I did not manage to catch it so I do not know who won. I use 2 min starting and 15 min end padding. Could there be a problem if the program you are trying to record matches the length of the end padding? Appears funny the problem seems to be reproducible?

TIA

Saturday 18:42:00 : Woken up
Saturday 18:42:00 : Recording {Doctor Who} on BBC1NW now
Saturday 18:42:00 : Recording Scheduled End Time: 18:45
Saturday 18:42:00 : Next recording is {Doctor Who Confidential} on BBC3 at 18:45
Saturday 18:42:00 : Gap to next programme is 0 seconds
Saturday 18:42:00 : Can't add end padding to {Doctor Who}
Saturday 18:42:00 : Next end padding setting due 19:10
Saturday 18:42:00 : Gap to previous recording is 0 seconds
Saturday 18:42:00 : Can't add start padding to {Doctor Who Confidential}
Saturday 18:42:00 : Next start padding setting due 19:10
Saturday 18:42:00 : Next wake up will be 19:10
Sleeping, checking every minute for kill signal............................. 
Saturday 19:10:00 : Woken up
Saturday 19:10:00 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:10:00 : Recording Scheduled End Time: 19:15
Saturday 19:10:00 : Next recording is {Hit Me Baby One More Time} on ITV1GRA at 19:15
Saturday 19:10:00 : Gap to next programme is 0 seconds
Saturday 19:10:00 : Added 870 seconds end padding to {Doctor Who Confidential}
Saturday 19:10:00 : Next end padding setting due 19:25
Saturday 19:10:00 : Not time to add start padding yet
Saturday 19:10:00 : Next start padding setting due 19:12
Saturday 19:10:00 : Next wake up will be 19:12
Sleeping, checking every minute for kill signal... 
Saturday 19:12:00 : Woken up
Saturday 19:12:01 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:12:01 : Recording Scheduled End Time: 19:29
Saturday 19:12:01 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:12:01 : Not time to add end padding yet
Saturday 19:12:01 : Next end padding setting due 19:24
Saturday 19:12:01 : Not time to add start padding yet
Saturday 19:12:01 : Next start padding setting due 19:27
Saturday 19:12:01 : Next wake up will be 19:24
Sleeping, checking every minute for kill signal.............. 
Saturday 19:24:30 : Woken up
Saturday 19:24:30 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:24:30 : Recording Scheduled End Time: 19:29
Saturday 19:24:30 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:24:30 : Gap to next programme is 900 seconds
Saturday 19:24:30 : Added 900 seconds end padding to {Doctor Who Confidential}
Saturday 19:24:30 : Next end padding setting due 19:55
Saturday 19:24:30 : Not time to add start padding yet
Saturday 19:24:30 : Next start padding setting due 19:27
Saturday 19:24:30 : Next wake up will be 19:27
Sleeping, checking every minute for kill signal.... 
Saturday 19:27:00 : Woken up
Saturday 19:27:00 : Recording {Doctor Who Confidential} on BBC3 now
Saturday 19:27:00 : Recording Scheduled End Time: 19:30
Saturday 19:27:00 : Next recording is {Click Online} on BBC24 at 19:30
Saturday 19:27:00 : No end padding required:
Saturday 19:27:00 : End padding of 900 seconds already set
Saturday 19:27:00 : Next end padding setting due 19:55
Saturday 19:27:00 : Gap to previous recording is 0 seconds
Saturday 19:27:00 : Can't add start padding to {Click Online}
Saturday 19:27:00 : Next start padding setting due 19:55
Saturday 19:27:00 : Next wake up will be 19:55
Sleeping, checking every minute for kill signal............................. 
Saturday 19:55:00 : Woken up
Saturday 19:55:00 : Recording {Click Online} on BBC24 now
Saturday 19:55:00 : Recording Scheduled End Time: 20:00
Saturday 19:55:00 : Next recording is {CSI: NY} on FIVE (Suggestion) at 20:25
Saturday 19:55:00 : Gap to next programme is 1500 seconds
Saturday 19:55:00 : Added 900 seconds end padding to {Click Online}
Saturday 19:55:00 : Next end padding setting due 21:20
Saturday 19:55:00 : Not time to add start padding yet
Saturday 19:55:00 : Next start padding setting due 20:22
Saturday 19:55:00 : Next wake up will be 20:22
Sleeping, checking every minute for kill signal............................


----------



## sanderton

Got it! Found the bug-ger. 1.4.2 is now in the top post.

For those who have forked the code, the issue in line 439:



Code:


if {[expr $cendtime - $cexistingendpadding + $endpadding] >= [expr $longstop - 30]} {

which should read:



Code:


if {[expr $cendtime - $cexistingendpadding + $endpadtoset] >= [expr $longstop - 30]} {

The bug would only manifest itself if a recording was followed by another the EXACT length of the padding AND another recording was due IMMEDIATELY after that.

Sorry Pmk! For the 1,355 folks who downloaded 1.4.1 - if your padding is only a few mins this is incredibly unlikley to happen, so you are pretty safe sticking with the old version if you want.


----------



## pmk

sanderton said:


> Sorry Pmk!


No problem, I love EndPad and could not live without it. I am just pleased I could help in some little way by providing feedback. Thats two odd bugs solved for people who use long end padding. Who counting though


----------



## sanderton

You may remember that I asked that if you use EndPad you consider making an appropriate donation to charity.

There is now a link through which you can make a donation to Cancer Reasearch if you use and enjoy EndPad:

http://www.justgiving.com/brigid

This link is for donations in memory of a friend of mine who died from breast cancer just before Christmas. She was 39 and had two young children.

Please put "EndPad" in the comment if you make a donation.

Thank you.


----------



## Fozzie

Done. (Thanks for the reminder Stuart). A worthy cause.


----------



## 6022tivo

I lost my wife earlier this year after she contracted MRSA during a stay in hospital. We also have two children, one who is my avartar (with a wig on!!). Don't know the full family situation, but we are dealing with this, best we can, and I can understand in some small way what Brigid's family are going though. I have sent across a donation, only small, but every little helps I suppose. 

Thanks again for the great module Stuart.


----------



## staffie2001uk

I had an unexpected reboot whilst fine tuning DailyMail and cron since when EndPad will not run. I am getting the following when I run it from the command line. 
Any help will be greatly appreciated. 

> exec /tvbin/tivosh /var/hack/endpad/endpad.tcl -s 1 -e sugqual 75 -sugeq
EndPad v1.4.1 (c) 2004 Stuart Anderton
Strictly no commercial distribution
See file header for terms of use and distribution
Switching to background...
couldn't execute "/var/hack/endpad/endpad.tcl": no such file or directory
while executing
"exec $argv0 $argv -run >>& $errfile &"
(file "/var/hack/endpad/endpad.tcl" line 521)


----------



## sanderton

The clue is in the error: "couldn't execute "/var/hack/endpad/endpad.tcl": no such file or directory" - have you checked to see if you still have a /var /hack directiory?


----------



## staffie2001uk

Stuart 

Yes, /var/hack is still there. In fact, it is an error from a line in the file it is claiming is not there! It is the line that calls EndPad in the background. 

I don't have a clue what the problem is, but I'm certain it's not a fault with EndPad, it's a linux issue. I could be wrong though. 

When I first installed EndPad, I am pretty certain I could run in from the bash prompt in telnet without having to use exec and specify the shell. Again. my memory could be faulty. 

Colin.


----------



## maxwells_daemon

staffie2001uk said:


> Code:
> 
> 
> > exec /tvbin/tivosh /var/hack/endpad/endpad.tcl -s 1 -e sugqual 75 -sugeq
> EndPad v1.4.1 (c) 2004 Stuart Anderton
> Strictly no commercial distribution
> See file header for terms of use and distribution
> Switching to background...
> couldn't execute "/var/hack/endpad/endpad.tcl": no such file or directory
> while executing
> "exec $argv0 $argv -run >>& $errfile &"
> (file "/var/hack/endpad/endpad.tcl" line 521)


Perhaps your /var/hack/endpad/endpad.tcl doesn't have execute mode. Try


Code:


chmod 755 /var/hack/endpad/endpad.tcl

Also, I'm not sure about the way you are running the command. Why exec it? Why specify /tvbin/tivosh explicitly (except as a way of trying to get round the lack of execute mode)? And I think you are missing the number on the -e option. I would use something like


Code:


/var/hack/endpad/endpad.tcl -s 1 -e 5 -sugqual 75 -sugeq

By the way, in my modified endpad.tcl, I changed the background switch to use


Code:


exec [info nameofexecutable] [info script] $argv -run >>& $errfile &

to ensure that the background process was started in the same way as the main one. That works even if endpad.tcl doesn't have execute mode (assuming you got it to run in the first place with /tvbin/tivosh).

Tim.


----------



## staffie2001uk

endpad should have execute mode, I have chmodded it.



maxwells_daemon said:


> By the way, in my modified endpad.tcl, I changed the background switch to use
> 
> 
> Code:
> 
> 
> exec [info nameofexecutable] [info script] $argv -run >>& $errfile &
> 
> to ensure that the background process was started in the same way as the main one. That works even if endpad.tcl doesn't have execute mode (assuming you got it to run in the first place with /tvbin/tivosh).
> 
> Tim.


As shown below, the file error goes if substitute your code for the original, but the after "switching to background..." appears the prompt does not reappear until I hit [Return].

TiVo: {/var/hack/endpad} > ls
endpad.err endpad.tcl
TiVo: {/var/hack/endpad} > chmod 755 ./endpad.tcl
TiVo: {/var/hack/endpad} > ls -l
total 25
-rw-r--r-- 1 0 0 0 May 31 20:44 endpad.err
-rwxr-xr-x 1 0 0 23951 Jun 9 16:03 endpad.tcl
TiVo: {/var/hack/endpad} > exec /tvbin/tivosh /var/hack/endpad/endpad.tcl -s 1 -
e 10 -sugqual 75 -sugeq
EndPad v1.4.1 (c) 2004 Stuart Anderton
Strictly no commercial distribution
See file header for terms of use and distribution
Switching to background...
TiVo: {/var/hack} >



maxwells_daemon said:


> Also, I'm not sure about the way you are running the command. Why exec it? Why specify /tvbin/tivosh explicitly (except as a way of trying to get round the lack of execute mode)?


I agree, I don't think I should need to specify exec or the shell, I just get a "No such file or directory" error. When I can see the file is present, has execute set and can be run specifically by specifiying the shell.

TiVo: {/var/hack/endpad} > ls -l
total 25
-rw-r--r-- 1 0 0 0 May 31 20:44 endpad.err
-rwxr-xr-x 1 0 0 23951 Jun 9 16:03 endpad.tcl
TiVo: {/var/hack/endpad} > ./endpad.tcl -s 1 -e 10 -sugqual 75 -sugeq
bash: ./endpad.tcl: No such file or directory
TiVo: {/var/hack/endpad} > /var/hack/endpad/endpad.tcl -s 1 -e 10 -sugqual 75 -sugeq
bash: /var/hack/endpad/endpad.tcl: No such file or directory
TiVo: {/var/hack/endpad} >

Very, very puzzled, but I am sure it is a linux issue and I know to little to figure it out.

Colin.


----------



## 10203

Try deleting the file from the TiVo and then re-FTPing it across making sure you're in binary mode.

Something like this should run it ok:

/var/hack/endpad.tcl -s 1 -e 3 -auto >> /dev/null &


----------



## sanderton

I think, Mr J, that you may have identified the problem.


----------



## staffie2001uk

sanderton said:


> I think, Mr J, that you may have identified the problem.


*sigh* Sadly not.

I had copied my archived endpad.tcl across as soon as it failed to run, and I deleted it from the TiVo and copied it back just to be certain. The result was as below, using Mr J's suggested command line. It hung at the point I've marked with ********** until I hit "return" and then gave me the exit line.

> /var/hack/endpad.tcl -s 1 -e 3 -auto >> /dev/null &
[1] 430
> bash: /var/hack/endpad.tcl: No such file or directory
**********

[1]+ Exit 127 /var/hack/endpad.tcl -s 1 -e 3 -auto >>/dev/null
>


----------



## 10203

Maybe your archived copy is corrupt too. I'd try downloading a fresh one.

"No such file or directory" might mean that the file has DOS line endings... it's been a while since I've seen that error first hand...


----------



## sanderton

Yes, it usually means that there is ^M at the end of the line. Bash tries to interpret it as part of the command and you get a "No such file or directory" error.


----------



## staffie2001uk

LJ said:


> Maybe your archived copy is corrupt too. I'd try downloading a fresh one.
> 
> "No such file or directory" might mean that the file has DOS line endings... it's been a while since I've seen that error first hand...


Downloaded v1.4.2 from the head of the thread and copied it across, chmod'ed and got the same file error.

Don't know if I can live without EndPad! Don't know how I'll cope if you can't fix this for me. Do you think I can get the donation back  [That was a joke, I'm just trying to keep myself cheerful]


----------



## 10203

Describe every step you're doing to get the file from the website to the TiVo (are you using IE, how do you FTP etc etc)

And what's the size of the file once it's on the TiVo?


----------



## staffie2001uk

LJ said:


> Describe every step you're doing to get the file from the website to the TiVo (are you using IE, how do you FTP etc etc)
> 
> And what's the size of the file once it's on the TiVo?


Looks like it was the FTP (Filezilla). The file size was increasing when copied across. Strange, as I have had no previous problems with FileZilla. I went through the settings and changed and reset all the options and it copied with no size increase. Then EndPad ran.

Was the file size increase due to DOS carriage returns getting added?

Thanks to everyone who contributed. I think a moderate drink is in order, ah heck, maybe a large one 

However, what I really don't understand is how the TiVo file got corrupted in the first place to get DOS characters into it?


----------



## ncjok

v.1.4.2 is giving me the following errors in /var/log/endpad.log :



TiVo said:


> Monday 01:00:25 : endpad.tcl 1.4.2 log file, starting up
> Monday 01:00:25 : Start padding set to 120 seconds
> Monday 01:00:25 : End padding set to 300 seconds
> Monday 01:00:25 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
> Monday 01:00:25 : Detected TiVo software version 2.5.5-01-1-023
> Monday 01:00:25 : Suggestions will be recorded in Best
> Monday 01:00:26 : Woken up
> Monday 01:00:26 : Error detected
> Monday 01:00:26 : can't read "rectype": no such variable
> while executing
> "if {$rectype == 3} {
> 
> # Recording active
> set isrec 1
> 
> # Get details of currently recording programme
> R..."
> Monday 01:00:26 : Attempting to recover
> Monday 01:00:56 : Woken up
> Monday 01:00:56 : Error detected
> Monday 01:00:56 : can't read "rectype": no such variable
> while executing
> "if {$rectype == 3} {
> 
> # Recording active
> set isrec 1
> 
> # Get details of currently recording programme
> R..."
> Monday 01:00:56 : Attempting to recover
> Monday 01:00:56 : Too many errors, stopping



downloaded endpad.1.4.2.zip using IE6
unzipped it with WinZip
copied to TiVo using FlashFXP, binary
didn't chmod it (already appears as 755)
/etc/rc.d/rc.sysinit.author line is
/var/hack/endpad.tcl -s 2 -e 5 -sugqual 100 -auto >> /dev/null &
Any help welcome 

edit: fixed by re-transferring endpad.tcl via a DOS window 

Good script, thanks!


----------



## ncjok

spoke too soon..

Since the last post I've got dailymail working (minor error in dailymail.cfg) and installed the cron-3.0pl1_TiVo-2.tar.gz package. However, from that point on, endpad.tcl refuses to run at startup, and when run manually is only there (ps) for a few seconds.

/var/log/endpad.log says:

Wednesday 01:26:02 : endpad.tcl 1.4.2 log file, starting up
Wednesday 01:26:02 : Start padding set to 120 seconds
Wednesday 01:26:02 : End padding set to 300 seconds
Wednesday 01:26:02 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Wednesday 01:26:02 : Detected TiVo software version 2.5.5-01-1-023
Wednesday 01:26:02 : Suggestion quality change disabled
Wednesday 01:26:02 : Woken up
Wednesday 01:26:02 : Error detected
Wednesday 01:26:02 : can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Wednesday 01:26:02 : Attempting to recover
Wednesday 01:26:32 : Woken up
Wednesday 01:26:32 : Error detected
Wednesday 01:26:32 : can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Wednesday 01:26:32 : Attempting to recover
Wednesday 01:26:32 : Too many errors, stopping

I've redownloaded the endpad zip, retransferred it, etc. No luck this time. I've removed the cron entry from rc.sysinit.author, which atm reads:

#!/bin/bash
/var/hack/bin/tivoftpd &
/var/hack/tivoweb-tcl/tivoweb
/var/hack/autospace/autospace.tcl start > /dev/null 2>&1
#/var/hack/bin/cron &
/var/hack/endpad.tcl -s 2 -e 5 -sugqual 100 -auto >> /dev/null &


----------



## sanderton

Are there at least two items in the To Do List?


----------



## ncjok

Stuart,
It had one item in the To Do List at the time of my last post. I added a second show, and sure enough it worked :up: Sorry if this had been discussed elsewhere in the thread.

If TiVo reboots for whatever reason in the future, does this mean that Endpad is again likely to fail if I have an insufficient number of planned recordings?

Regards


----------



## sanderton

It will fail unless there are at least two items in the TDL. I really ought to fix that sometime, but as most people's TDLs are full to overflowing it only really effects brand new or cleaned out machines.


----------



## Bakdraft

Hi,

For some reason my endpad no longer wants to play ball...

If you start from a fresh boot and manually start endpad it at first glance runs fine.. deleting the old pid and then waiting as normal.

But on examination of the log it clearly stops but I do not know why?

/var/log/endpad.log/ 
Friday 08:26:57 : endpad.tcl 1.4.0 log file, log rotated
Friday 08:26:57 : Start padding set to 300 seconds
Friday 08:26:57 : End padding set to 300 seconds
Friday 08:26:57 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Friday 08:26:57 : Detected TiVo software version 2.5.5-01-1-023
Friday 08:26:57 : Suggestion quality change disabled
Sleeping, checking every minute for kill signal.. 
Friday 08:27:57 : Stopped due to kill signal 


running ps ax shows end pad is not running.

can anyone give me some reasons as to why it received the kill signal and suggest some ways to troubleshoot it...

I miss my endpad.

.....you don't know what you got till it's gone.....  

Dave


----------



## sanderton

The kill signal is a file in the same directory as Endpad called something like endpad.kill; delete it.


----------



## Bakdraft

sanderton said:


> The kill signal is a file in the same directory as Endpad called something like endpad.kill; delete it.


Hi Sanderton,

Thanks for your reply...

I have checked the endpad directory /var/hack but there is no endpad.kill file or any kill file see below

bash-2.02# ls -a
. cron joerc tivoir.cfg tytools
.. endpad.tcl scripts tivoir.cfg~
RecStatus.tcl etc sendbackup tivoweb-tcl
bin joe tivoir tmp
bash-2.02#

Do you have any other suggestions?


----------



## sanderton

No idea! You're a couple of version out of date, so try installing the latest one.


----------



## Bakdraft

sanderton said:


> No idea! You're a couple of version out of date, so try installing the latest one.


Interestingly, i did not have any problems with this version until now. After a few weeks of Airnet failure I upgraded to cache card, but then found my complete hack directory had gone!

I had to recreate it.

Also since then I have added Tytools, which has a program that runs in the background.

Do you think either of these may be responsible?

I will try the latest version now..


----------



## sanderton

Shouldn't. The kill signal is quite explicit; not sure how it can be given accidentally!


----------



## Bakdraft

Hi

New version loaded... Message change but no padding done. Log shows:
Friday 23:03:59 : 
Friday 23:03:59 : endpad.tcl 1.4.2 log file, starting up
Friday 23:03:59 : Start padding set to 300 seconds
Friday 23:03:59 : End padding set to 300 seconds
Friday 23:03:59 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Friday 23:03:59 : Detected TiVo software version 2.5.5-01-1-023
Friday 23:03:59 : Suggestion quality change disabled
Friday 23:03:59 : Woken up
Friday 23:04:00 : No recording in progress
Friday 23:04:00 : Next recording is {Big Brother} on C4 at 20:10
Friday 23:04:00 : No end padding required:
Friday 23:04:00 : No recording in progress
Friday 23:04:00 : Next end padding setting due 21:00
Friday 23:04:00 : Not time to add start padding yet
Friday 23:04:00 : Next start padding setting due 20:04
Friday 23:04:00 : Next wake up will be 23:34
Sleeping, checking every minute for kill signal...................

but 20 mins later this log has not changed despite scheduled recording

ps ax does show endpad :

bash-2.02# ps ax 
PID TTY STAT TIME COMMAND 
1 ? S 0:00 (init) 
2 ? SW 0:01 (kflushd) 
3 ? SW 0:04 (kswapd) 
59 ? S 0:00 update (bdflush) 
67 ? S 1:12 syslogd -p /var/dev/log -m 10000 
69 ? S 0:01 klogd 
77 ? S 0:05 EventSwitcher 
78 ? S 4:48 MfsDaemon 
79 ? S 0:00 fancontrol 
106 ? S 0:00 Sark (mcp) 
108 ? S 0:00 /var/hack/tytools/tserver -s /var/hack/tytools/NowShowing.tc 

111 ? S 0:01 Sark (mcp) 
113 ? S 0:00 PipeListen 
114 ? S 0:01 Mcp event 
115 ? S 0:00 tcphonehome 
116 ? S 0:00 (bash) 
119 ? S 0:00 (tcphonehome) 
121 ? S 0:00 /sbin/tnlited 23 /bin/bash -login 
123 ? S 0:00 (tivoftpd) 
124 ? S 0:00 PipeListener 
125 ? S 0:00 FsMpStream 
126 ? S 0:01 (tcphonehome) 
128 ? S 0:00 dbgc-mcp 
129 ? S 9:59 dbgc-mcp 
130 ? S 0:00 PipeListener 
131 ? S 0:00 MyWorld 
132 ? R 0:09 MyWorld
133 ? S 0:00 PipeListener
134 ? S 0:00 FsMpStream
135 ? S 0:32 EventLog event
136 ? S 0:00 TmkSinkMixAud
137 ? R 0:02 UI Timer Heart
138 ? R 0:27 TmkClipCache0
139 ? S 0:25 TmkClipCache1
140 ? R 44:10 TvMomMpegSink
141 ? S 0:00 TvMomMpegSink
142 ? R 0:51 Mediaswitch0
143 ? S 1:44 TvRecorder
144 ? R 0:50 TmkTaskManager
145 ? S 1:14 Scheduler
146 ? S 1:26 Prioritizer
147 ? S 3:49 ContextMgr eve
158 ? R 0:48 tivosh /var/hack/tivoweb-tcl/httpd-tt.tcl
217 ? S 0:01 tivosh ./endpad.tcl -s 5 -e 5 -run
222 ? S 0:00 sh -c $TIVO_ROOT/tvbin/tivosh $TIVO_ROOT/tvbin/TClient -bac

223 ? S 2:16 /tvbin/tivosh /tvbin/TClient -backup -auto
259 ? S 0:00 /bin/bash -login
260 ? R 0:00 ps ax

How much time after loading is needed before endpad should work, i.e. is 5 mins enough?

Dave


----------



## sanderton

> Friday 23:04:00 : Next wake up will be 23:34
> 
> but 20 mins later this log has not changed despite scheduled recording


Er, 20 minutes after 23.04 being before 23.34, yes?


----------



## Bakdraft

Fixed!  

Thanks for your patience Sanderton.

Your help is very much appreciated by us all

By the way...... does this mean if you add a recording thats due to tostart before the wakeup signal time, then that recording will not be padded, If so I will need to start the endpad program at 10 mins to the hour so as to capture the majority of late requests.

Dave


----------



## Fozzie

Bakdraft said:


> By the way...... does this mean if you add a recording thats due to tostart before the wakeup signal time, then that recording will not be padded...


It won't get any start padding but should still get end padding due to Endpad waking up during the recording.



Bakdraft said:


> If so I will need to start the endpad program at 10 mins to the hour so as to capture the majority of late requests.


Why? I don't follow


----------



## sanderton

Endpad checks every 30 minutes for any new programmes in the schedule, so shows where you hit record while watching may be missed if under 30 mins to go.

I was concerned not to make EndPad have a significant performance overhead.


----------



## Fozzie

sanderton said:


> Endpad checks every 30 minutes for any new programmes in the schedule, so shows where you hit record while watching may be missed if under 30 mins to go.
> 
> I was concerned not to make EndPad have a significant performance overhead.


But the time that it wakes up moves around doesn't it, depending on when it last checked, according to when things are being recorded etc.? Hence, I didn't see the point of trying to start it at a specific time


----------



## sanderton

Correct, there is no point starting it a particular time.


----------



## Bakdraft

Fozzie said:


> It won't get any start padding but should still get end padding due to Endpad waking up during the recording.
> 
> Why? I don't follow


According to my log Endpad was waking up at 5mins to the hour and 25 mins past the hour.. regular as clockwork....

so if it woke up and say 25 mins to the hour and 5 mins past the hour, then anything I wanted recording that is on the hour or 30 mins past the hour that I requested at late in the day i.e. after 25 mins etc would not be padded. Thus by setting a wakeup for say 6 mins before the hour, would mean it would see it and still be able to pad it..... Err I think!!?? 

This would not happen if it happen to be at 25 mins before... OK it gonna happen rarely but if setting the wakeup time to this point helps then....

Of course all this theory is probably a load of b******t! as I am sure Sanderton is about to tell me!

Dave


----------



## Fozzie

It is a load of b******t  Endpad will wake up just before a recording is about to start or just before it is about to end or half an hour; whichever is the shortest time interval.

It doesn't matter what time you start it it will wake up at different times, according to your recording schedule.


----------



## sanderton

Indeed. If a recording doesn't require a wake up at a particular time, it will set one for 30 minutes after the current time, whatever that may be.


----------



## Bakdraft

sanderton said:


> Indeed. If a recording doesn't require a wake up at a particular time, it will set one for 30 minutes after the current time, whatever that may be.


OK..OK.... I believe you both...

But my understanding was based on Sandertons answer just a few replies ago.....



> Endpad checks every 30 minutes for any new programmes in the schedule, so shows where you hit record while watching may be missed if under 30 mins to go.
> 
> I was concerned not to make EndPad have a significant performance overhead.


Dave


----------



## Fozzie

... which remains correct. If there's no recording scheduled during the next half an hour when Endpad has woken up, it will sleep for 30 minutes before waking up again. If you hit record during that 30 minutes, or schedule a recording to start within that 30 minutes, then Endpad will only know about it when it wakes up (and the recording is in progress) and so will only be able to apply end padding, if it can.

Trust the several hundred (maybe even into 4 figures?) of people that have downloaded and are using Endpad - it works


----------



## tivo_boj

IT DOES WORK. AND BL**DY WELL TOO!!!. ITs Still the Best Addition to TIVO, Bar None. I beleive the best that could be achieved without Tivo puting in smart padding in their UK software. ( sanderson can correct me on this, as he is the king!!!)


----------



## magistral

I too have a problem with endpad stopping. Not sure if its related. Can anyone suggest a cure. This is my log file:

Mike

Monday 20:35:33 :
Monday 20:35:33 : endpad.tcl 1.4.2 log file, starting up
Monday 20:35:33 : Start padding set to 60 seconds
Monday 20:35:33 : End padding set to 300 seconds
Monday 20:35:33 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Monday 20:35:33 : Detected TiVo software version 2.5.5-01-1-023
Monday 20:35:33 : Suggestion quality change disabled
Monday 20:35:33 : Woken up
Monday 20:35:33 : Error detected
Monday 20:35:33 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
R..."
Monday 20:35:33 : Attempting to recover
Monday 20:36:03 : Woken up
Monday 20:36:03 : Error detected
Monday 20:36:03 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
R..."
Monday 20:36:03 : Attempting to recover
Monday 20:36:03 : Too many errors, stopping


----------



## sanderton

Odd; it seems there is a show recording when you launched EndPad, but it can't access the details of it from the database. 

It might be that the database was very busy and rejecting requests.

Have you tried starting it manually?

Alternatively, is your TiVo'd To Do List completely empty?


----------



## magistral

Thanks for the reply Stuart. I just started it manually and got a different failure. Maybe I will reboot the box when it's not in use and see if that helps. This is the latest log:

Mike

Tuesday 18:54:50 :
Tuesday 18:54:50 : endpad.tcl 1.4.2 log file, starting up
Tuesday 18:54:50 : Start padding set to 60 seconds
Tuesday 18:54:50 : End padding set to 240 seconds
Tuesday 18:54:50 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Tuesday 18:54:50 : Detected TiVo software version 2.5.5-01-1-023
Tuesday 18:54:50 : Suggestion quality change disabled
Tuesday 18:54:50 : Woken up
Tuesday 18:54:51 : Error detected
Tuesday 18:54:51 : can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Tuesday 18:54:51 : Attempting to recover
Tuesday 18:55:21 : Woken up
Tuesday 18:55:21 : Error detected
Tuesday 18:55:21 : can't read "nextbutonerecstartdate": no such variable
while executing
"expr $nextbutonerecstartdate * 86400 + $nextbutonerecstarttime"
Tuesday 18:55:21 : Attempting to recover
Tuesday 18:55:21 : Too many errors, stopping


----------



## sanderton

Looks to me like you've installed it on a "blank" TiVo - EndPad will fail if there are less than two things in the Now Playing list. Add some schedules recordings and it should be OK.

Really Really Must Fix That.


----------



## magistral

You could be right. There was only one scheduled recording for Top Gear that evening. I will schedule some more and try again.

Thanks,

Mike


----------



## mesaka

Just a quick thank-you. This has been installed less than 48hours and has already saved me from the wrath of SWMBO!


----------



## wsware

I'm running endpad on my 6.2 and it working good.

I do have one question. Should it be trying to add time to recordings I am inserting with mfs_ftp?


Code:


Sleeping, checking every minute for kill signal............................... 
Tuesday 05:55:05 : Woken up
Tuesday 05:55:07 : Recording {CSI: NY} on CT3 now
Tuesday 05:55:07 : Recording Scheduled End Time: 03:00
Tuesday 05:55:07 : Next recording is {TiVo Service Data} on TIVOR at 06:30
Tuesday 05:55:07 : Gap to next programme is 8911800 seconds
Tuesday 05:55:07 : Added 180 seconds end padding to {CSI: NY}
Tuesday 05:55:07 : Next end padding setting due 06:55
Tuesday 05:55:07 : Not time to add start padding yet
Tuesday 05:55:07 : Next start padding setting due 06:27
Tuesday 05:55:07 : Next wake up will be 06:25
Sleeping, checking every minute for kill signal............................... 
Tuesday 06:25:07 : Woken up
Tuesday 06:25:07 : Recording {CSI: NY} on CT3 now
Tuesday 06:25:07 : Recording Scheduled End Time: 04:00
Tuesday 06:25:07 : Next recording is {TiVo Service Data} on TIVOR at 06:30
Tuesday 06:25:07 : Gap to next programme is 11932200 seconds
Tuesday 06:25:07 : Added 180 seconds end padding to {CSI: NY}
Tuesday 06:25:07 : Next end padding setting due 06:55
Tuesday 06:25:07 : Not time to add start padding yet
Tuesday 06:25:07 : Next start padding setting due 06:27
Tuesday 06:25:07 : Next wake up will be 06:27
Sleeping, checking every minute for kill signal... 
Tuesday 06:27:00 : Woken up
Tuesday 06:27:01 : Recording {CSI: NY} on CT3 now
Tuesday 06:27:01 : Recording Scheduled End Time: 04:03
Tuesday 06:27:01 : Next recording is {TiVo Service Data} on TIVOR at 06:30
Tuesday 06:27:01 : No end padding required:
Tuesday 06:27:01 : End padding of 180 seconds already set
Tuesday 06:27:01 : Next end padding setting due 06:55
Tuesday 06:27:01 : Gap to previous recording is 11932020 seconds
Tuesday 06:27:01 : Added 120 seconds start padding to {TiVo Service Data}
Tuesday 06:27:01 : Next start padding setting due 06:55
Tuesday 06:27:01 : Next wake up will be 06:55
Sleeping, checking every minute for kill signal.............................

Also some requests is you ever make any updates.
I do my own log rolling so it would be nice if there was a flag to disable that. I just commented it out in the code. Also I run it from /usr/local/bin so I had to change where it writes the endpad.err to /var/tmp it would be nice if we had only one log file.


----------



## sanderton

It does attempt to pad mfs_ftp inserts, but it didn't seem to have any ill effects when I tested it so I didn't bother making it ignore them.

I suspect that anyone who needs a non-standard setup is probably well capable of making the code alterations.


----------



## terryeden

Bit of a complex one, this. I've set the Soft Padding so that any suggestion is recorded at Medium.

What I'd like is for any suggestion recorded off BBC Radio 2, 4 and 7 be recorded in Basic.

I can't find any way to easily specify channel quality.

I suspect that this is beyond the scope of this program... but I'd like to be proved wrong!

T


----------



## iankb

I'm guessing here, but if you were to use VBR bitrates, I would expect the static picture to use a very low bitrate.


----------



## sanderton

You could adapt the code easily enough to choose a quality based on station. There are commenets in the code if you want to try and work it out!

Ian's suggestion is easier.


----------



## Gavin

Is there any easy way of putting or a tutorial walking me through) the endpad startup line into the rc.sysint.author?

I know PC's I don't know linux and all this changing mode malarky is probably simple but seems complex to me. All I want is to make endpas start up on bootup, I have Tivoweb and Endpad on the tivo, and to be honest I don't want to add a text editor to add one line to a boot file...


----------



## dogsbody

This is how I did it without a text editor...



Code:


mount -o remount,rw /
echo "/var/hack/scripts/endpad.tcl -s 1 -e 3 -auto >> dev/null &" >> /etc/rc.d/rc.sysinit
mount -o remount,ro /
sync


----------



## Milhouse

I think it would be a better idea to add endpad to */etc/rc.d/rc.sysinit.author*

If you're going to append it to rc.sysinit using the commands in the previous post *please* remember to use two chevrons and not one otherwise you'll zap your main startup script and be left with a doorstop!!!!


----------



## maxwells_daemon

sanderton said:


> Got it! Found the bug-ger. 1.4.2 is now in the top post.
> 
> For those who have forked the code, the issue in line 439...


I've applied this fix to my version of endpad (adds channel-specific padding and a few other improvements). You can find it here or attached to this message.

Sorry for the delay in posting. I wanted to check that it didn't cause any new problems and then forgot about it. It should also have been tried by someone who asked for the update in a private e-mail some time ago.

Stuart, would you now consider updating the standard version with my changes? It has worked for me without problems for the last 3+ months. It should be entirely upwardly compatible with your version. The changes in the code are mostly "round the edges". The core logic is the same, it just picks up the parameters in a different (possibly channel-specific) way. It does all I want and I have now moved onto other projects (teletext decoding at the moment), so don't plan any continued development in the near future. However I'm happy to help support it (though you're doing a pretty good job of that!) - particularly the new features.

This would mean that bug fixes need only be applied once, and would allow people to find it without wading through 1000+ posts. It would be nice to avoid another fork (or should I have started with EndPadPlus in the first place?).

However if you really don't want to take on this version, would you alternatively consider posting a separate link and/or attachment to the top of the thread ("extended version with channel-specific settings"), so at least people can find it if they want to.

Thanks,
Tim.


----------



## maxwells_daemon

terryeden said:


> Bit of a complex one, this. I've set the Soft Padding so that any suggestion is recorded at Medium.
> 
> What I'd like is for any suggestion recorded off BBC Radio 2, 4 and 7 be recorded in Basic.
> 
> I can't find any way to easily specify channel quality.


This should be possible with my modified version endpad. See the last post for the latest version, and my earlier post for some documentation. To set the suggestion recording quality to Basic for those radio stations, you can put


Code:


channel BBCR2,BBCR4FM,BBCR7 sugqual 0

in a file endpad.config. You can either specify the other options in the file (see my post for details), or keep them on the command line. Suggestions on other channels will be recorded with the global 'sugqual' setting that you have already set.

I record everything in Basic anyway, so I haven't tried this option. Let me know how you get on.

Tim.


----------



## schwinn

Sanderton:

Excellent program - can't wait to see it in action!

One thing - the readme file still calls for an incorrect rc.sysinit.author line - the readme calls for "dev/null" while it should be "/dev/null" of course... might want to fix that.


----------



## shanew

Following a period of anger from my partner regarding the end missing off Sundays recording of "Where the heart is" (because TiVo was recording "Pelican Brief" straight after on C5) this morning I decided to have a go at the negative padding problem.

If you want to try it bear the following in mind:
1. Can't say how stable it is (though its been working fine for the last hour on my tivo)
2. Can't say if it'll work ok on a US tivo (as i haven't got one!)
3. Not sure if its going to affect the 28 day rule (though with the implementation i don't see why it would)
4. I'm happy to address any bugs/modifications but don't hold me responsible for any adverse affects.
5. Give major thanks (which i do) to Stuart Anderton, author of the original & awsome code :up: 

So here it is 

P.S. Use the same syntax as the original. 
eg stop endpad with "endpad.tcl -stop"
and start endpad with "endpad.tcl -s 2 -e 2 -n 1" (where n = negative start padding)


----------



## iankb

shanew said:


> ... start endpad with "endpad.tcl -s 2 -e 2 -n 1" (where n = negative start padding)


Wouldn't *n* have to be at least as large as (if not equal to) *e*? Or will *e* be automatically reduced to the same value as *n*, if an overlap occurs.


----------



## shanew

iankb said:


> Or will *e* be automatically reduced to the same value as *n*, if an overlap occurs.


Exactly. Basically what happens is that if the gap is smaller than 'n' then the start of the following program gets delayed so the gap is exactly 'n'. Then endpad's default process continues by adding as much endpadding as possible - in this case, only 1 minute.


----------



## petestrash

Tim,

Someone had asked a few pages back, but was not responded to, would it be possible to include some sort of configuration by time of day.

We have problems with stations running mostly to time during the day, but running well over starting at 7:30pm and continue right through to 6am. Some days they can be up to 20 minutes late.

Using your example it would be good if we could alter the config file to something like:



Code:


endpad 2
channel BBC1STH,BBC2STH,BBC4 endpad 5
time 1930 0000 channel BBC1STH,BBC2STH,BBC4 endpad 20
time 0000 0600 channel BBC1STH,BBC2STH,BBC4 endpad 20
channel SKYONE startpad 1

Peter.


----------



## Ian_m

Also how about adding padding depending on programme name ?

eg


Code:


endpad 2
channel BBC1STH,BBC2STH,BBC4 endpad 5
Casualty endpad 15

ie add endpadding of 15 minutes to a programme call casualty.


----------



## iankb

Ian_m said:


> Also how about adding padding depending on programme name ?


Or adding padding to the end of that, plus all subsequent programmes on the same channel until (say) 6am.


----------



## maxwells_daemon

petestrash said:


> Someone had asked a few pages back, but was not responded to, would it be possible to include some sort of configuration by time of day.


Hi Peter,

OK, this new version should do what you want. You can now specify a validity period in the endpad.config file.


Code:


validity 17-23 startpad 1
channel BBC1STH,BBC2STH validity 19:30-06:00 endpad 20

The former is for all channels, while the latter is only for the BBC, and wraps around midnight (7:30pm to 6am). If the programme is scheduled to start within the validity period, then those options come into effect (channel-specific settings take precedence over time-dependent settings, which take precedence over global settings).

One restriction, that I hope won't be too onerous, is that the validity period is given in a fixed time zone. You can now specify a time zone with the -tz option (eg. -tz 01:00 for BST) and this is used for the validity period and also for EndPad's log file messages. However this will not be automatically changed when BST ends next month. That shouldn't be serious: if you miss this, you'll just get the different padding applied an hour earlier or later, but I guess the definition of "evening schedules" is anyway not so precise.

For the record, I also improved the methods used for options parsing and background task invocation. See [POST=2768468]my earlier post for a summary of my other changes[/POST].

I'm still concerned that EndPad is branching into different versions: apart from mine and Stuart's original, there's also [POST=3105832]shanew's negative padding[/POST] and EndPadPlus (a rewrite to support dual tuners), and perhaps more. Stuart, what did you think of my [POST=3094097]previous suggestion[/POST] to update the version at the head of this thread, or to at least to reference the other versions? shanew, should we try to merge our versions?

Anyway, enjoy!

Tim.

PS. Stuart, the Cancer Research donation page doesn't seem to work any more. Should I donate direct? Sorry, I know it's taken me long enough (6 months!) to get round to it.


----------



## petestrash

Wow, thanks Tim.

Endpad has certainly been developed into a very flexible add-on.

I will download your new version and give it a run over the next week.

At the moment I am wasting a lot of hard drive space by endpadding all shows an extra 18min, when really only the late night shows need it.

Thanks, I'll report back after a week of usage.

Peter.


----------



## iankb

Great Tim. It was probably me who was subtly-pleading for time-based padding.

I would be interested in the merging of Shanew's negative padding, but has anybody tried it and found it stable in the long-term? I always knew that negative padding wasn't going to be that simple, or Stuart would have included it in his version.


----------



## sanderton

Good stuff Tim.

Thank's for pointing out the expired link. The URL still gets you to a Cancer Research donation page, so if anyone would like to make a doantion for their EndPad use, please use that.


----------



## mrtickle

I'm strongly in favour of merging versions - I found the dailymail mail thread a nightmare!


----------



## sanderton

Tim - are you happy thet the latest mods are stable?

If so let's rechristen this 1.5 and I'll amend the top post.


----------



## maxwells_daemon

sanderton said:


> Tim - are you happy thet the latest mods are stable?


Yes, I'm happy with them. However since petestrash (and maybe iankb?) said they'd give it a go, why don't we wait a week to check that it works for someone other than me.

The only other change I have considered in detail was to make the timezone setting automatic. I guess I could borrow the code from TivoWeb, but that looks pretty haphazard.


sanderton said:


> If so let's rechristen this 1.5 and I'll amend the top post.


That would be great. Thanks!

What do you think about merging in shanew's negative padding changes? I haven't tried it out yet, but the code changes look like they are fairly self-contained, so won't be activated unless someone specifies negative padding.

Tim.


----------



## sanderton

I haven't got the time to be code merging - if you and shanew want to do that then great.


----------



## maxwells_daemon

Don't worry, Stuart, I wasn't trying to dragoon you into doing the work. I was just interested to hear what you thought of the idea.


----------



## iankb

maxwells_daemon said:


> Yes, I'm happy with them. However since petestrash (and maybe iankb?) said they'd give it a go, why don't we wait a week to check that it works for someone other than me.


I'm currently using it and, according to the endpad.msg log, it's got everything right so far. However, since I haven't recorded more than one program from the 'exceptional' channels, it could take a little longer to soak-test it. Will keep you posted.


----------



## petestrash

Hi,

I am having some trouble with endpad-1.4.2-md2

With the suggested /var/hack/endpad.tcl -sugeq -auto >> dev/null & in rc.sysinit.author endpad did not start. Replacing with /var/hack/endpad.tcl -auto worked ok.

But the more major issue I believe is it's handling of station names.

In endpad.conf I have the following:


Code:


startpad 1
endpad 5
channel Ten-WA,Seven-WA,Nine-WA validity 19:30-06:00 endpad 18
sugeq

When endpad starts it shows:


Code:


Sunday 19:22:44 : endpad.tcl 1.4.2-md2 log file, starting up
Sunday 19:22:44 : Start padding set to 60 seconds
Sunday 19:22:44 : End padding set to 300 seconds
Sunday 19:22:44 : Suggestions will not be padded if another suggestion immediately follows them
Sunday 19:22:44 : Detected TiVo software version 3.0-01-1-000
Sunday 19:22:44 : Suggestion quality change disabled
Sunday 19:22:44 : Timezone 00:00
Sunday 19:22:44 : Configuration options:-
Sunday 19:22:44 : default: endpad 5 sugeq 0 sugqual -1 startpad 1
Sunday 19:22:44 : channel NINE-WA validity 19:30-06:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Sunday 19:22:44 : channel SEVEN-WA validity 19:30-06:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Sunday 19:22:44 : channel TEN-WA validity 19:30-06:00 endpad 18 sugeq 0 sugqual -1 startpad 1

When it came time to pad a show in the validity period, only the default padding was added:


Code:


Sunday 20:55:00 : Woken up
Sunday 20:55:01 : Recording {60 Minutes} on Ten-WA now
Sunday 20:55:01 : Recording Scheduled End Time: 21:00
Sunday 20:55:01 : Next recording is {Backyard Science} on ABC-WA at 10:20
Sunday 20:55:01 : Gap to next programme is 48000 seconds
Sunday 20:55:01 : Added 300 seconds end padding to {60 Minutes} on Ten-WA 
Sunday 20:55:01 : Next end padding setting due 10:25
Sunday 20:55:01 : Not time to add start padding yet
Sunday 20:55:01 : Next start padding setting due 10:18
Sunday 20:55:01 : Next wake up will be 21:25

I am guessing the reason it's happening is because the station name in endpad.conf had been converted to Caps by endpad (Ten-WA to TEN-WA), but it might be something else.

Peter


----------



## iankb

You don't show a location but, from the station names, I assume that you are based in Western Australia. I don't know about the US, but in the UK EPG data all station names are uppercase.

Since your EPG slices are home-cut, it's possible that your 'provider' has chosen to use mixed-case station names whereas official TiVo data always uses uppercase. Hence the problem, although I'm sure that it is easily solvable.


----------



## maxwells_daemon

Hi Peter,

Thanks for testing it out.


petestrash said:


> I am having some trouble with endpad-1.4.2-md2
> 
> With the suggested /var/hack/endpad.tcl -sugeq -auto >> dev/null & in rc.sysinit.author endpad did not start. Replacing with /var/hack/endpad.tcl -auto worked ok.


I can't reproduce your problem with specifying -sugeq. Can you post what's in your endpad.err file? That can be a little confusing because new runs are appended to old ones, so one can't tell which time gave an error. To be sure, you could move or delete endpad.err and try again.


petestrash said:


> But the more major issue I believe is it's handling of station names.
> 
> I am guessing the reason it's happening is because the station name in endpad.conf had been converted to Caps by endpad (Ten-WA to TEN-WA), but it might be something else.


You are right. I didn't know that channel names could be mixed case (maybe that's a feature of version 3). Here is a new version that doesn't force all names to be upper case. This does mean that everyone has to be careful to specify the correct case, but that's par for the course on Linux.

I don't know where you are located, but I guess (from the channel names and the fact that you are using TiVo software version 3) it's not in the UK. Please be aware that the validity times you specify are in GMT, unless you specify a different timezone with the new -tz option. I only mention this because your example looks like you are trying to specify an evening validity.

Tim.


----------



## petestrash

maxwells_daemon said:


> Thanks for testing it out.I can't reproduce your problem with specifying -sugeq. Can you post what's in your endpad.err file? That can be a little confusing because new runs are appended to old ones, so one can't tell which time gave an error. To be sure, you could move or delete endpad.err and try again.


Thanks Tim, I tried again and there is nothing showing in endpad.err as endpad just doesn't start at all with '/var/hack/endpad.tcl -sugeq -auto >> dev/null &' in rc.sysinit.author, but '/var/hack/endpad.tcl -sugeq -auto' it starts fine.

This doesn't bother me, just thought I'd point it out.

I am in Australia, and since TiVo isn't here we run our own emulator.

Your new version now works fine with our channel assignments.

I don't think Timezone will be an issue for us as it is handled differently here because there is no native tivo support for our timezones. So far it seem ok.

Thanks, I'll leave it for a week and drop a note back here.

Peter.


----------



## 10203

Maybe it's a typo when posting here, but there's a "/" missing before the "dev".


----------



## sanderton

My bad, I still haven't fiexed the docs. The end of the line should be:

/dev/null &


----------



## petestrash

sanderton said:


> My bad, I still haven't fiexed the docs. The end of the line should be:
> 
> /dev/null &


Doh, I should have picked that.

I was following the readme.

Needless to say starts fine now.

Thanks,

Peter.


----------



## petestrash

sanderton said:


> My bad, I still haven't fixed the docs.


Seems to be working fine so far.

I might have a go at updating the readme to include all the new features.

I assume global options set at the command line are overruled by global options in the config file.

Peter


----------



## mrtickle

petestrash said:


> I assume global options set at the command line are overruled by global options in the config file.


Other way around surely?


----------



## petestrash

I'll leave it for Tim to confirm, 

But the way I read it is that command line switches set a default unless something in the config file overrides it. 

So a global setting in the config file will override a command line global setting. 

Peter.


----------



## tym

Command line options override config file default options.

BTW. I'm currently testing an enhanced version of 1.4.2-md3 that adds matching based on program title.

Tym


----------



## maxwells_daemon

petestrash said:


> Seems to be working fine so far.
> 
> I might have a go at updating the readme to include all the new features.


That would be very kind. Writing the documentation always seems to be the most painful bit for me 

Since this is to replace the standard 1.4.2, I guess the settings in the packaged endpad.config should be commented out so if people upgrade from 1.4.2, they don't see any unexpected change of behaviour.

When that's done, we can bump the version number to 1.5.



petestrash said:


> I assume global options set at the command line are overruled by global options in the config file.


No, the order of precedence is (highest to lowest, with higher overruling lower)

1) time-dependent, channel-specific settings (in config file)
2) channel-specific settings (in config file)
3) time-dependent settings (in config file)
4) command-line settings (all global)
5) global settings in config file

Although it's probably not much use, if there happens to be more than one setting that applies at any one level, the last one specified (in the config file or on the command line) is used.

Tim.


----------



## petestrash

Ok, I'll have a go at putting some docs together over the weekend.

Peter.


----------



## Ian_m

tym said:


> Command line options override config file default options.
> 
> BTW. I'm currently testing an enhanced version of 1.4.2-md3 that adds matching based on program title.
> 
> Tym


1. Does this mean the start line in rc.sysinit.author.edit (or eqiv) could be:-

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

with start and end values being taken from the .config file ?

2. Excellent. Casualty is the only prog I have added padding to as it sometimes runs about 10mins late on Saturday, thats why I mentioned it.


----------



## Fozzie

Ian_m said:


> Casualty is the only prog I have added padding to as it sometimes runs about 10mins late on Saturday, thats why I mentioned it.


Why not just add 10 mins to the stop time in the SP itself?


----------



## Ian_m

Fozzie said:


> Why not just add 10 mins to the stop time in the SP itself?


I have done (actually 15mins), but this "hardpadding" often stops the subsequent programme, usually on the same side, recording, which is why Endpad is better.


----------



## Fozzie

I don't know what region you're in, but the most I've ever had Casualty overrun is a couple of minutes.

The only way to be sure of catching the end is to hard-pad. I've already been through the dilema of soft-padding vs. hard-padding and missing the next recording; I went for the hard-padding


----------



## tym

This attached version adds program name based padding and auto config reloading to maxwells_daemon's 1.4.2-md3 endpad. There are a couple of minor bugfixes as well.

I've also added an integrated shanew's negative padding mods with a few additions that allow finer control of negative padding based on the current and next programs (eg. don't negative pad into specific programs).

Unfortunately shanew's negative padding doesn't work on my ozTiVo (TiVo v3 - failed when trying to create manual recording) so I've used some code from the manrec tivoweb module to truncate the recording - this should work in UK and other tivos.

I've tested this for a couple of days, but obviously it needs more diverse testing (especially the negative padding feature).



Code:


startpad 1 endpad 10  # Global defaults
# Hi-5 is almost always on time, and I don't want my child watching next prog
channel Nine-Mel program {Hi-5} -s 0 -e 0
# Temptation always runs over, see the end rather than start of the next prog
channel Nine-Mel program {^Temptation$} negpad 4
# Never take off start of any CSI program
channel Nine-Mel program CSI maxneg 0

Tym


----------



## maxwells_daemon

tym said:


> This attached version adds program name based padding and auto config reloading to maxwells_daemon's 1.4.2-md3 endpad. There are a couple of minor bugfixes as well.


Very impressive! So far, I've just had a look at the code changes without trying it out on the TiVo. I found a few minor problems, which are corrected in the attached version.

1) The program can crash if a time-specific setting line follows a programme-specific setting line ("can't read newopt(program)"). Eg.


Code:


program Buffy endpad 20
validity 18-05 endpad 10

2) Command-line configuration options are ignored!

3) The timezone setting on the command-line was overridden by a setting in the config file. Command-line global options should always take precedence.

4) Up here, the spelling is "programme", not "program"  (for a TV programme, as distinct from a computer program). I set it to allow both spellings in the config file.

I also tidied up the code and comments a little further. If you look at the differences, you might prefer diff -b to skip all the spacing-only cleanups.

One remaining oddity is that if both programme-specific and time-specific setting lines match, then the last one specified in the config file is the one used. Eg. in the example config above, if Buffy us on between 6pm and 5am, then an end padding of 10 minutes is used.

Ideally I guess, the programme-specific setting should take precedence, but implementing that is a little cumbersome. I think it's easier just to document this wrinkle and suggest people put the programme-specific settings at the end.

Tim.

PS. I called it 1.4.2-md4 because 1.4.2-md3-tk1-md1 would be a bit much. But it is based on your version 1.4.2-md3-tk1.


----------



## tym

Tim,

Looks good.

I notice now that I forgot to remove the warning comment from the code regarding v3 tivos and negative padding (this isn't an problem now).

A few other ideas...:
- For completeness you should be able to enable or disable sugeq (rather than just enable it with no ability to disable). I don't know why you would want to do this though - it'd probably be only used globally anyway.
- It would be nice to have rules based on day of week rather than just time of day. We have stations here which are notorious for running late on specific evenings.

Tym


----------



## maxwells_daemon

tym said:


> - For completeness you should be able to enable or disable sugeq (rather than just enable it with no ability to disable). I don't know why you would want to do this though - it'd probably be only used globally anyway.


Great minds think alike. I considered the same thing while I was admiring your improvements. The change could be a little confused, because enabling sugeq sets sugcancancelsug to 0. What way round should the option be? Also should we worry about compatibility with previous versions of endpad.config?



tym said:


> - It would be nice to have rules based on day of week rather than just time of day. We have stations here which are notorious for running late on specific evenings.


I'm having a go at this now. So far I got it to recognise and display "validity Sun" or "validity Sat/18:00-05:00". I still need to think through the best way to make the comparison in getConfig.

Tim.


----------



## cwaring

Hi Guys!

Just insatalled this much-lauded module but it's not working.

Here's what I have done:

the .tcl and .config are in '/var/hack' and my 'rc.sysinit.author' looks like this:



Code:


/var/hack/tivoweb-tcl/tivoweb &
/var/hack/endpad.tcl -s 2 -e 5 -auto >> dev/null &

I have not enabled any options in the .config file. Thought I'd leave everything to default to start with. Have also re-booted Tivo.

If anyone has any idea as to what I might (probably have!) done wrong, it would be very-much appreciated 

Thanks.


----------



## Fozzie

cwaring said:


> Just insatalled this much-lauded module but it's not working.


Not the most helpful of explanations. 



> Code:
> 
> 
> /var/hack/tivoweb-tcl/tivoweb &
> /var/hack/endpad.tcl -s 2 -e 5 -auto >> dev/null &


Change 'dev/null &' to '/dev/null &'


----------



## cwaring

Fozzie said:


> Not the most helpful of explanations.


I'm confused. What else can I tell you. It's not adding any padding at the start or end of a recording, therefore it doesn't work 



> Change 'dev/null &' to '/dev/null &'


Interesting, as I just copied that straight from the readme.txtfile

However, will do. Thanks. Will I need to re-boot or is there another way to re-run that .author file?


----------



## iankb

With regards to the channel and time-based changes, I've run for a week or so and have to report that none of my recordings fitted into the special ranges that were able to take advantage of soft-padding. However, the good thing is that the standard settings still worked fine. So I see no reason not to use the new version, because it appears to be at least as good as the standard version. :up:


----------



## Fozzie

cwaring said:


> I'm confused. What else can I tell you. It's not adding any padding at the start or end of a recording, therefore it doesn't work


So if you have a problem with your car, you'd just drop it off at the garage, say it doesn't work and then walk out the door?! A decription of the problem, symptoms, what you've tried, what's in the log etc. is always helpful, rather than just a "it doesn't work". I would have thought someone with so many posts would have known that?



> Interesting, as I just copied that straight from the readme.txtfile


Halfway up this very page, you should have seen >>this<< post.


----------



## cwaring

Fozzie said:


> So if you have a problem with your car, you'd just drop it off at the garage, say it doesn't work and then walk out the door?! A decription of the problem, symptoms, what you've tried, what's in the log etc. is always helpful, rather than just a "it doesn't work". I would have thought someone with so many posts would have known that?


I'm sorry. I thought I had adequately described what I had done and which files I had put where.

Problem: It doesn't work.
Symptoms: No padding at start or end of programmes
What I have done/tried: See original post. To whit...



> Here's what I have done:
> 
> the .tcl and .config are in '/var/hack' and my 'rc.sysinit.author' looks like this:
> 
> 
> 
> Code:
> 
> 
> /var/hack/tivoweb-tcl/tivoweb &
> /var/hack/endpad.tcl -s 2 -e 5 -auto >> dev/null &
> 
> I have not enabled any options in the .config file. Thought I'd leave everything to default to start with. Have also re-booted Tivo.


Which error log (there are quite a few!) should I be looking in?



> Halfway up this very page, you should have seen >>this<< post.


Well, I did say didn't have the time to read 30-odd pages. Okay, so that was on the last page and I will admit that I missed it. My bad 

Edited to add: Sorry, again. I've just realised what I think you were getting at. I can't try anything to solve the problem as I know nothing at all about Linux so wouldn't have a clue where to start looking for problems


----------



## Fozzie

cwaring said:


> Which error log (there are quite a few!) should I be looking in?


Errr, the endpad.log. (And before you ask, you can view it from Tivoweb by clicking on the 'logs' menu item).

You haven't actually said whether the change I suggested earlier has got it running? Have you done a 'ps ax' from the BASH prompt to see if is running as a process? What does the endpad log say? Have you tried running it from the BASH prompt (this should be normal practise prior to putting it in a startup file, to make sure you get the command syntax correct and don't hang the TiVo)?


----------



## cwaring

Fozzie said:


> Errr, the endpad.log. (And before you ask, you can view it from Tivoweb by clicking on the 'logs' menu item).


Can't see an 'endpag.log' in the logs. I assume that means that maybe it's installed as properly as I thought?



> You haven't actually said whether the change I suggested earlier has got it running?


No I didn't, sorry. However it didn't help.



> Have you done a 'ps ax' from the BASH prompt to see if is running as a process?


"command not found". Something I've not installed?



> Have you tried running it from the BASH prompt (this should be normal practise prior to putting it in a startup file, to make sure you get the command syntax correct and don't hang the TiVo)?


Again, something I never thought of. Suppose I should have!

Anyway, this is the result of running it as you suggest:



Code:


TiVo: {/var/hack} % ./endpad.tcl -s 2 -e 5
EndPad v1.4.2-md4 (c) 2004 Stuart Anderton
Strictly no commercial distribution
See file header for terms of use and distribution
Switching to background...
TiVo: {/var/hack} %

I'm guessing that that is normal so there is a problem with the .author file? Maybe it's not pointing to where it should. I'll check that now and report back.

Thank-you for your assistance.

_A few minutes (and one reboot) later:_

Well, I checked the .author file and there was a couple of extraneous characters in there. Corrected and re-booted but I still don't think it's loaded as the log file only goes up until 15:21 which is when I re-booted.


----------



## Fozzie

cwaring said:


> "command not found". Something I've not installed?


'ls' & 'ps' available from >>here<<

(I'm assuming you've done everything >>here<< - particularly sections 4, 6, 7 & 8)


----------



## cwaring

Darn! Knew there was something I'd forgotten. I've downloaded his SP Backup but meant to go back for the other two


----------



## sanderton

cwaring said:


> "command not found". Something I've not installed?


This doesn't seem to be a problem with EndPad as such; can I suggest that this discussion takes place in Carl's thread, where he can complete the set of re-iterating every hacking thread on the board.


----------



## cwaring

I never for one moment thought the hack was the problem. I'm not Captain Whatever-his-name-was 

Oh, and I'm sorry for taking up _your_ thread with my lack of knowledge


----------



## Fozzie

sanderton said:


> This doesn't seem to be a problem with EndPad as such; can I suggest that this discussion takes place in Carl's thread, where he can complete the set of re-iterating every hacking thread on the board.


Good point! You mean there's other threads that cover all this?


----------



## cwaring

I do so sincerly apologise for messing up _your _ thread with my lack on Linux skills.

Of course, the fact that the more knowledgable on this board can write TCL and know everything about Linux and has a few years more experience of hacking Tivo than me is totally by-the-by


----------



## sanderton

I think we thought you might have picked up a few things having been reading the board every day for however many years it is now!


----------



## cwaring

I have indeed picked up a lot of things. However, as hacking and Linux have both been of no interest until now, I didn't bother reading those threads that relate to hacks.

Also, I knew there'd be problems like this. Hence my past hesitance. I was hoping for some support from my friends on this board, not chastising for asking what may be about simple stuff for those who know what to do when things go wrong; as I do with my PC but know nothing about Linux 

For example, I was going to ask where I should put the afore-mentioned "PS" file so I don't put it somewhere that might break my Tivo but I daren't now for fear of ridicule 

Anyway, I shall leave this thread for posts relating exclusively to errors with Endpad itself


----------



## sanderton

The last part is the important one. We're all very happy to help back in your own thread!


----------



## alpriest

Hi,
I've had a look over this thread and i'm going to install endpad tonight. Could someone confirm that the latest version is endpad-1.4.2-md4.zip as detailed here

Thanks
Al


----------



## Ian_m

I have been running md3 since release no problem. Padding works.

I think md4 added per programme name padding in the config file, which is nice and I will get round to installing one day.


----------



## alpriest

md4 worked perfectly straight out of the box (apart from the /dev/null bit in the readme).

Thanks.


----------



## maxwells_daemon

Here's a new version that I am testing. It has a number of improvements (including a couple that tym sent me):-

a) stop a suggestion's endpad encroaching on a recording's startpad, and cancel a suggestion that overlaps the following recording's startpad. [from tym]

b) remove case sensitivity from channel names comparison (a better way to fix [POST=3283904]this[/POST]). [from tym]

c) allow selection by the day of week, eg. to select an end padding of 20 minutes from Saturday 7:30pm to Sunday 5am, you can specify in endpad.config:



Code:


validity Sat/19:30-05:00 endpad 20

d) We once more have a well-defined order of precedence of selection options. It is (highest to lowest, with higher overruling lower):-

1) channel-specific settings (in config file)
2) programme-specific settings (in config file)
3) weekday-specific settings (in config file)
4) time-dependent settings (in config file)
5) command-line settings (all global)
6) global settings in config file

If there happens to be more than one setting that applies at any one level, the last one specified (in the config file or on the command line) is used.

This might seem a bit arcane, but in most cases it does what you expect, eg.



Code:


programme {Doctor Who} validity Sat/19-20 endpad 30
programme {Doctor Who} endpad 20
validity Sat endpad 10

will use a 20-minute end padding for Doctor Who, even if it's on a Saturday, unless it starts between 7 and 8pm, when a 30 minute endpad is used. Other programmes on Saturday use 10 minutes.

e) Log file rotation happens at midnight local time (according to the -tz setting).

f) I fixed the /dev/null path in the docs 

Tim.


----------



## sanderton

Re: a) - it did that anyway?


----------



## tym

sanderton said:


> Re: a) - it did that anyway?


Not in my experience... on my system startpadding seemed to be missing some of the time (which no adjacent recording) - there appeared to be nothing in the code to handle things differently if the current recording is a suggestion, so the addtional code cancels the suggestion and does the startpadding before the suggestion starts recording.

Tym


----------



## sanderton

Ah yes, thanks for the memory jog - there's a reason for that. If you try to cancel a currently recording show and then extend the start padding of the next show to overlap the current show the results are, ahem, unpredictable. I've seen the TiVo crash, but most often I've seen the user set show fail to record as it gets confused about the overlap. It's possible that there is a way of doing it without these issues, but I didn't find one easily and therefore the EndPad code plays it safe and never cancels a recording which is actually recording already,


----------



## tym

sanderton said:


> EndPad code plays it safe and never cancels a recording which is actually recording already,


The new code preserves this. A not yet recording suggestion is cancelled if it will overlap the startpad of the subsequent real recording. It will then immediately add the startpad to the real recording to avoid another overlapping suggestion being scheduled.

Tim


----------



## sanderton

The just-in-time setup of EndPad means that it only adds start padding a couple of minutes before the show+padding is due to start. Any suggestion before it will therefore be already recording.


----------



## tym

The suggestion that will overlap the startpadding of a real recording is cancelled before the suggestion starts recording. If a suggestion is already recording it will not be cancelled, but this is unlikely as a check is made at each wake up. This changes the just-in-time behaviour slightly to ensure start padding occurs, which is not a big problem in my opinion...


----------



## sanderton

Ok


----------



## sanderton

Hey, TiVo have added negative padding to v. 7.2.1:


----------



## Fozzie

So c'mon Stuart - what's your excuse now?!


----------



## petestrash

Hi,

I have been running endpad.tcl 1.4.2-md3 for about a month now without any problems on a few Series 1 TiVo's.

The last few days on just one TiVo some of the validity rules have been ignored and the global padding settings used instead.

This TiVo has a current up time of 9 days (but this issue only started a couple of days ago). I have not touched the config file since it was setup.

I have attached the relevant parts of the log for one missed event (the only one today).



Code:


Tuesday 00:25:01 : endpad.tcl 1.4.2-md3 log file, log rotated
Tuesday 00:25:01 : Start padding set to 60 seconds
Tuesday 00:25:01 : End padding set to 300 seconds
Tuesday 00:25:01 : Suggestions will not be padded if another suggestion immediately follows them
Tuesday 00:25:01 : Detected TiVo software version 3.0-01-1-000
Tuesday 00:25:01 : Suggestion quality change disabled
Tuesday 00:25:01 : Timezone 00:00
Tuesday 00:25:01 : Configuration options:-
Tuesday 00:25:01 : default: endpad 5 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel 7CEN validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel 7CEN validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel GWN-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel GWN-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel IMP validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel IMP validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel WIN-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
Tuesday 00:25:01 : channel WIN-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
Sleeping, checking every minute for kill signal............................... 
...SNIP...
Tuesday 22:55:00 : Woken up
Tuesday 22:55:00 : Recording {Last Man Standing} on GWN-WA now
Tuesday 22:55:00 : Recording Scheduled End Time: 23:00
Tuesday 22:55:00 : Next recording is Cunnamulla on ABC-WA at 00:30
Tuesday 22:55:00 : Gap to next programme is 5400 seconds
Tuesday 22:55:00 : Added 300 seconds end padding to {Last Man Standing} on GWN-WA 
Tuesday 22:55:00 : Next end padding setting due 01:55
Tuesday 22:55:00 : Not time to add start padding yet
Tuesday 22:55:00 : Next start padding setting due 00:28
Tuesday 22:55:00 : Next wake up will be 23:25

Even though I have channel GWN-WA set for 'validity 22:01-06:00 endpad 20', at 22:55 only the global 5 minutes endpading was added not 20.

As I have said this has been running fine for a month and still fine on another couple of machines. Just thought I'd point it out FYI.

I have stopped and restarted endpad and so far seems ok again.

Peter


----------



## cwaring

Can't help with your problem, but I just have to ask

You really have to set some channels to _20 minutes _ end padding? They over-run _that_ much? Often?


----------



## petestrash

Those channels are every night! Usually about 15 minutes, but I set 20 to be safe.

one of the channels even has a 15 minute filler scheduled each day around 5:00am, needless to say it is rarely actually shown. They just drop the filler each day to fix the time before 6:00am.

It's a game the stations play, they run their primetime shows long hoping that you miss enough of the next show on a different station that you will be forced to stay on the current station. Thank heavens for multiple TiVo's  

Peter.


----------



## cwaring

petestrash said:


> It's a game the stations play, they run their primetime shows long hoping that you miss enough of the next show on a different station that you will be forced to stay on the current station.


They do that over here too, but never by that long! 5 mins max.


----------



## mike0151

cwaring said:


> They do that over here too, but never by that long! 5 mins max.


Apart from when they run 10 minutes late


----------



## cwaring

Of course  What I meant was that the "norm" is to over-run by a relatively small amount. To my knowledge (and barring LIVE events or extended news coverage) no UK channel has ever deliberately over-run by your stated ten minutes just because they felt like it.


----------



## iankb

cwaring said:


> ... no UK channel has ever deliberately over-run by your stated ten minutes just because they felt like it.


ITV certainly went over by almost 10 minutes once with 'Who Wants To Be a Millionaire'. They were trying to stop people switching over to another programme on BBC1.


----------



## cwaring

I just knew someone would give an example  Fair enough, but as I said, it's not a very common occurence


----------



## maxwells_daemon

Hi Peter,



petestrash said:


> The last few days on just one TiVo some of the validity rules have been ignored and the global padding settings used instead.
> 
> 
> Code:
> 
> 
> Tuesday 00:25:01 : channel GWN-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Tuesday 00:25:01 : channel GWN-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> ...SNIP...
> Tuesday 22:55:00 : Added 300 seconds end padding to {Last Man Standing} on GWN-WA
> 
> Even though I have channel GWN-WA set for 'validity 22:01-06:00 endpad 20', at 22:55 only the global 5 minutes endpading was added not 20.


_Last Man Standing_ wasn't scheduled to start at exactly 22:00, was it? It is the start time that is important for the validity selection, since if the start of the programme is delayed, chances are the end is too.  Your time-dependent settings have a gap from 22:00 to 22:01, so if the scheduled start time fell in there, it would pick up the global settings.

To close the gap, you should instead specify



Code:


channel GWN-WA validity 20:00-22:00 endpad 18
channel GWN-WA validity 22:00-06:00 endpad 20

The validity 20:00-22:00 includes 20:00, but excludes 22:00 (ie. goes up to 21:59:59), so there wouldn't be any overlap (not that that would be a problem).

Does this explain your observation?

Tim.


----------



## mike0151

cwaring said:


> I just knew someone would give an example  Fair enough, but as I said, it's not a very common occurence


The Frank Skinner Show usually over-runs by 8 to 10 minutes on ITV1.


----------



## cwaring

tarball'd /var/hack from my Tivo and cpio'd it onto my brother's unit.

Got the following in the.log file. Replacing with default .config file didn't help 



Code:


Friday 13:39:54 : 
Friday 13:39:54 : endpad.tcl 1.4.2-md5 log file, starting up
Friday 13:39:54 : Start padding set to 120 seconds
Friday 13:39:54 : End padding set to 300 seconds
Friday 13:39:54 : Negative start padding set to 0 seconds
Friday 13:39:54 : Force Negative startpadding is 0
Friday 13:39:54 : Suggestions will be padded, even if that means cancelling a subsequent suggestion
Friday 13:39:54 : Detected TiVo software version 2.5.5-01-1-023
Friday 13:39:54 : Suggestion quality change disabled
Friday 13:39:54 : Timezone 00:00
Friday 13:39:54 : Sorted configuration options (last match used):-
Friday 13:39:54 : startpad 2 endpad 5 negpad 0 forceneg 0 maxneg -1 sugeq 1 sugqual -1
Friday 13:39:54 : Woken up
Friday 13:39:55 : Error detected
Friday 13:39:55 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
RetryTransaction ..."
Friday 13:39:55 : Attempting to recover
Friday 13:40:25 : Woken up
Friday 13:40:25 : Error detected
Friday 13:40:25 : can't read "rectype": no such variable
while executing
"if {$rectype == 3} {

# Recording active
set isrec 1

# Get details of currently recording programme
RetryTransaction ..."
Friday 13:40:25 : Attempting to recover
Friday 13:40:25 : Too many errors, stopping

Probably something simple, like a difference between the two Tivos or something. Just got no idea what


----------



## sanderton

Clean TiVo? Endpad won't run unless there are two items in the To Do list.

Mentioned a few times above. These newbies who don't read the thread before posting.


----------



## petestrash

maxwells_daemon said:


> Hi Peter,
> 
> _Last Man Standing_ wasn't scheduled to start at exactly 22:00, was it? It is the start time that is important for the validity selection, since if the start of the programme is delayed, chances are the end is too.  Your time-dependent settings have a gap from 22:00 to 22:01, so if the scheduled start time fell in there, it would pick up the global settings.


I guess I made too many assumptions 

My 1st assumption was a validity of 20:00-22:00 was inclusive and not 20:00-21:59 inclusive.

My 2nd assumption was that when endpad woke up at 22:55 to add the endpadding, it would then check the validity rules that applied at that time and then apply the endpad amount. I did not realise the start time was used for endpadding validity.

Unfortunately I didn't keep the logs showing the other programs that had problems, to see if they all fell into the hole at 22:00, but it's quite possible.



maxwells_daemon said:


> Does this explain your observation?


I believe it explains that one, but I also have another anomaly on a different tivo using the same version of endpad.



> Friday 00:25:01 : endpad.tcl 1.4.2-md3 log file, log rotated
> Friday 00:25:01 : Start padding set to 60 seconds
> Friday 00:25:01 : End padding set to 300 seconds
> Friday 00:25:01 : Suggestions will not be padded if another suggestion immediately follows them
> Friday 00:25:01 : Detected TiVo software version 3.0-01-1-000
> Friday 00:25:01 : Suggestion quality change disabled
> Friday 00:25:01 : Timezone 00:00
> Friday 00:25:01 : Configuration options:-
> Friday 00:25:01 : default: endpad 5 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Nine-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Nine-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Seven-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Seven-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Ten-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Friday 00:25:01 : channel Ten-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Sleeping, checking every minute for kill signal...................
> ...SNIP...
> Friday 23:58:00 : Woken up
> Friday 23:58:00 : No recording in progress
> Friday 23:58:00 : Next recording is Cops on Ten-WA at 00:00
> Friday 23:58:00 : No end padding required:
> Friday 23:58:00 : No recording in progress
> Friday 23:58:00 : Next end padding setting due 00:25
> Friday 23:58:00 : Added 60 seconds start padding to Cops on Ten-WA
> Friday 23:58:00 : Next start padding setting due 00:25
> Friday 23:58:00 : Next wake up will be 00:25
> Sleeping, checking every minute for kill signal............................
> Saturday 00:25:00 : Woken up
> Saturday 00:25:00 : Recording Cops on Ten-WA now
> Saturday 00:25:00 : Recording Scheduled End Time: 00:30
> Saturday 00:25:00 : Next recording is Raid on SBS-WA (Suggestion) at 00:45
> Saturday 00:25:00 : Current recording is on Ten-WA and starts at 00:00 so use endpad 20
> Saturday 00:25:00 : Gap to next programme is 900 seconds
> Saturday 00:25:00 : Added 900 seconds end padding to Cops on Ten-WA
> Saturday 00:25:00 : Next end padding setting due 02:45
> Saturday 00:25:00 : Not time to add start padding yet
> Saturday 00:25:00 : Next start padding setting due 00:43
> Saturday 00:25:00 : Next wake up will be 00:43
> Saturday 00:25:00 : endpad.tcl 1.4.2-md3 log file, log rotated
> Saturday 00:25:00 : Start padding set to 60 seconds
> Saturday 00:25:00 : End padding set to 1200 seconds
> Saturday 00:25:00 : Suggestions will not be padded if another suggestion immediately follows them
> Saturday 00:25:00 : Detected TiVo software version 3.0-01-1-000
> Saturday 00:25:00 : Suggestion quality change disabled
> Saturday 00:25:00 : Timezone 00:00
> Saturday 00:25:00 : Configuration options:-
> Saturday 00:25:00 : default: endpad 5 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Nine-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Nine-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Seven-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Seven-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Ten-WA validity 20:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1
> Saturday 00:25:00 : channel Ten-WA validity 22:01-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1
> Sleeping, checking every minute for kill signal...................
> Saturday 00:43:00 : Woken up
> Saturday 00:43:00 : Recording Cops on Ten-WA now
> Saturday 00:43:00 : Recording Scheduled End Time: 00:45
> Saturday 00:43:00 : Next recording is Raid on SBS-WA (Suggestion) at 00:45
> Saturday 00:43:00 : Current recording is on Ten-WA and starts at 00:00 so use endpad 20
> Saturday 00:43:00 : Gap to next programme is 900 seconds
> Saturday 00:43:00 : Added 900 seconds end padding to Cops on Ten-WA
> Saturday 00:43:00 : Next end padding setting due 02:45
> Saturday 00:43:00 : Gap to previous recording is 0 seconds
> Saturday 00:43:00 : Can't add start padding to Raid
> Saturday 00:43:00 : Next start padding setting due 02:45
> Saturday 00:43:00 : Next wake up will be 01:13
> Sleeping, checking every minute for kill signal...............................
> Saturday 01:13:00 : Woken up
> Saturday 01:13:00 : Recording Raid on SBS-WA (Suggestion) now
> Saturday 01:13:00 : Recording Scheduled End Time: 02:50
> Saturday 01:13:00 : Next recording is {Queens Supreme} on Ten-WA at 04:00
> Saturday 01:13:00 : Not time to add end padding yet
> Saturday 01:13:00 : Next end padding setting due 02:45
> Saturday 01:13:00 : Not time to add start padding yet
> Saturday 01:13:00 : Next start padding setting due 03:58
> Saturday 01:13:00 : Next wake up will be 01:43


On this TiVo the log says "Saturday 00:25:00 : Current recording is on Ten-WA and starts at 00:00 so use endpad 20" which the other TiVo does not show. If it did I wouldn't have posted the previous question 

There is a 15 minute gap between 'Cops' and a suggestion 'Raid'. The endpad validity is set for 20 minutes, but endpad did not cancel the suggestion and only endpaded the 15 minutes gap.

Then 13 minutes into the endpadding time, endpad woke up again and tried to add another 15 minutes endpading. There were no errors in the log, but the extra endpadding was not added and the suggestion was still recorded.

Peter

PS I have since fixed the 22:00 gap on this TiVo also.


----------



## Fozzie

Just noticed this:



Code:


Thursday 20:58:00 : Woken up
Thursday 20:58:01 : Error detected
Thursday 20:58:01 : no such object: {CONFLICT err=errTmActiveLockConflict}
while executing
"dbobj $cstation get CallSign"
("uplevel" body line 11)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set crec [db $db openid $recfsid]
if {$version >= 3} {
set crecbeh [dbobj $crec get RecordingBehavi..."
Thursday 20:58:01 : Attempting to recover
Thursday 20:58:31 : Woken up
Thursday 20:58:32 : Error detected
Thursday 20:58:32 : no such object: {CONFLICT err=errTmActiveLockConflict}
while executing
"dbobj $cstation get CallSign"
("uplevel" body line 11)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set crec [db $db openid $recfsid]
if {$version >= 3} {
set crecbeh [dbobj $crec get RecordingBehavi..."
Thursday 20:58:32 : Attempting to recover
Thursday 20:58:32 : Too many errors, stopping

And ideas Stuart?


----------



## sanderton

Restart the TiVo? - it's having trouble retriving data drom the database.


----------



## Fozzie

Thanks. I've done that just in case. No doubt it's just one of those things that happens from time to time. Still, not bad though since I think that's the first time ever that endpad has keeled; shame I didn't notice yesterday before the end of Casualty was chopped! Makes you realise how vital Endpad is (and Dailymail for telling me it had stopped running).


----------



## Ian_m

Another suggestion for endpad functionality (or a separate CRONable tcl module if anyones interested, Sanderton ???????).

A module/function/endpad functionality to automatically set the ratings for programmes based on the start record time and/or channel. The reason for adding to endpad is it already has CFG init file reading capability and is "active" when a programme is recording. Could also be done as a CRON job once a day to process the ToDo and/or Now Playing list.

This would work in conjunction with the TiVo Parental controls systems to stop kids viewing things they shouldn't ie if they select "Lesbian Lavatory Lust the Series" they would be prompted for a TiVo password (ie 4 numbers). I know Parental controls (possibly) works with films, but not with other recordings.

The cfg file would have a lines like:-

default U
18:00-21:00 12 L
21:00-6:00 18 M
M&M 18 M
CBEEBIES U

Where U=U rating, 12=12 rating etc, M&M = Men and Motors channel, L=strong language, M=violent material. See page 17 of the UK 2.5.5 TiVo user guide for the ratings recognised.

Not to sure if series can have ratings or not. Exploring MFS I can see fields for movies of MpaaRating and Advisory, but nothing equivalent for a series/one off. Wonder if these fields were added to a series/one off the TiVo would honour it in the Parental controls.

Might also need an add-on to TiVoWeb to allow the programme rating to be edited if set wrong. (or the kids to bypass it if they eventually hack TiVoWeb).

Any thoughts anyone ? Looking for an interesting new module Sanderton ?


----------



## Ian_m

Another suggestion for endpad functionality (or a separate CRONable tcl module if anyones interested, Sanderton ???????).

A module/function/endpad functionality to automatically set the ratings for programmes based on the start record time and/or channel. The reason for adding to endpad is it already has CFG init file reading capability and is "active" when a programme is recording. Could also be done as a CRON job once a day to process the ToDo and/or Now Playing list.

This would work in conjunction with the TiVo Parental controls systems to stop kids viewing things they shouldn't ie if they select "Lesbian Lavatory Lust the Series" they would be prompted for a TiVo password (ie 4 numbers). I know Parental controls (possibly) works with films, but not with other recordings.

The cfg file would have a lines like:-

default U
18:00-21:00 12 L
21:00-6:00 18 M
M&M 18 M
CBEEBIES U

Where U=U rating, 12=12 rating etc, M&M = Men and Motors channel, L=strong language, M=violent material. See page 17 of the UK 2.5.5 TiVo user guide for the ratings recognised.

Not to sure if series can have ratings or not. Exploring MFS I can see fields for movies of MpaaRating and Advisory, but nothing equivalent for a series/one off. Wonder if these fields were added to a series/one off the TiVo would honour it in the Parental controls.

Might also need an add-on to TiVoWeb to allow the programme rating to be edited if set wrong. (or the kids to bypass it if they eventually hack TiVoWeb).

Any thoughts anyone ? Looking for an interesting new module Sanderton ?


----------



## sanderton

Easiy enough to code in - if it works! Would need someone to try manually adding those attributes to see. As there is no diffeence in MFS between movies and episodes I think there's agood chance it would.

You can use dbget and dbset to try it out.


----------



## Ian_m

Thinking about it a bit more, a CRON job running once a day would be better as it could have its own CFG input file and own output LOG file, thus not "contaminating" endpads CFG and LOG files.

You could also invoke it manually if needed as well.

I feel the hard bit (if implemented) would be modifying TiVoWeb to allow the attributes to be modded.

I am sure someone a while back said they were looking for ideas for something new to write for their TiVo......


----------



## sanderton

No, that's very easy. You'd just add a line of code to the Edit Recording page.

Trouble with doing it from cron is that recordings would be unproteced for a while.


----------



## Ian_m

sanderton said:


> Trouble with doing it from cron is that recordings would be unproteced for a while.


No it probably wouldn't, as if you put the ratings in the ToDo data and ran the CRON job daily, the programme would have the rating "inserted" maybe upto 2 weeks in advance.

Anyway, for your homework tonight, Mr Sanderton I expect a complete working and debugged programme (CRON script and TiVoWeb mods), to be ready on my desk by the morning, else its no TiVo for you......  (only joking )


----------



## 10203

Having a problem with DS9 on Sky at the moment where it always seems to start a little early. Would it be possible to add the start version of "negpad", so the preceeding programme is ended early rather than not being recorded at all?


----------



## maxwells_daemon

I've been running [POST=3324070]endpad-1.4.2-md5[/POST] for the last six weeks and it seems to work fine. Did anyone else try that version yet?

I noticed one oddity that I hope tym (in particular) can comment on. A few times the logfiles show that the same suggestion is deleted twice "to make room for startpad". The result seems to be OK (the suggestion is gone and the subsequent programme has the padding added), but I don't understand why this should happen. Maybe the suggestion is cancelled too early and so it pops up again.

Come to think of it, why does the suggestion have to be explicitly deleted at all? If the start padding is increased before the previous suggestion starts recoding, won't it give a conflict so the suggestion isn't recorded?

Anyway, this double deletion took place in 3 of the 15 times that my suggestions were deleted to make room for start padding. Here's one example from the logfile:-



Code:


Friday 18:58:00 :  Woken up
Friday 18:58:00 :  Next recording ({Boston Legal} at 20:00 on Fri) starts in 17:00-05:00 so use startpad 1
Friday 18:58:00 :  Deleting suggestion {The Simpsons} on SKYONE to make room for 60 seconds startpad of {Boston Legal} on LIVING
Friday 18:58:00 :  Recording {Veronica Mars} on LIVING  now
Friday 18:58:00 :  Recording Scheduled End Time: 19:02
Friday 18:58:00 :  Next recording is {Boston Legal} on LIVING  at 20:00
Friday 18:58:00 :  Next recording ({Boston Legal} at 20:00 on Fri) starts in 17:00-05:00 so use startpad 1
Friday 18:58:00 :  No end padding required:
Friday 18:58:00 :  End padding of 120 seconds already set
Friday 18:58:00 :  Next end padding setting due 20:55
Friday 18:58:00 :  Gap to previous recording is 3480 seconds
Friday 18:58:00 :  Added 60 seconds start padding to {Boston Legal} on LIVING 
Friday 18:58:00 :  Next start padding setting due 20:55
Friday 18:58:00 :  Next wake up will be 19:28
Sleeping, checking every minute for kill signal............................... 
Friday 19:28:00 :  Woken up
Friday 19:28:00 :  Next recording ({Boston Legal} at 20:00 on Fri) starts in 17:00-05:00 so use startpad 1
Friday 19:28:00 :  Deleting suggestion {The Simpsons} on SKYONE to make room for 60 seconds startpad of {Boston Legal} on LIVING
Friday 19:28:00 :  No recording in progress
Friday 19:28:00 :  Next recording is {Boston Legal} on LIVING  at 20:00
Friday 19:28:00 :  Next recording ({Boston Legal} at 20:00 on Fri) starts in 17:00-05:00 so use startpad 1
Friday 19:28:00 :  No end padding required:
Friday 19:28:00 :  No recording in progress
Friday 19:28:00 :  Next end padding setting due 20:55
Friday 19:28:00 :  Added 60 seconds start padding to {Boston Legal} on LIVING 
Friday 19:28:00 :  Next start padding setting due 20:55
Friday 19:28:00 :  Next wake up will be 19:58

Tim.


----------



## maxwells_daemon

> Originally Posted by *petestrash* [POST=3376829]on 22nd Oct[/POST] concerning endpad.tcl 1.4.2-md3
> 
> On this TiVo the log says "Saturday 00:25:00 : Current recording is on Ten-WA and starts at 00:00 so use endpad 20" which the other TiVo does not show. If it did I wouldn't have posted the previous question


That's odd. Did the two TiVos have the same configuration parameters?



> There is a 15 minute gap between 'Cops' and a suggestion 'Raid'. The endpad validity is set for 20 minutes, but endpad did not cancel the suggestion and only endpaded the 15 minutes gap.
> 
> Then 13 minutes into the endpadding time, endpad woke up again and tried to add another 15 minutes endpading. There were no errors in the log, but the extra endpadding was not added and the suggestion was still recorded.


Sorry, I don't have any ideas (I didn't really look at that part of the code). Can you try the latest version, [POST=3324070]endpad-1.4.2-md5[/POST]? That includes tym's code for deleting suggestions to allow start padding too. If there's a bug, it would be easiest to spot in our latest code.

Thanks,
Tim.


----------



## tym

maxwells_daemon said:


> I noticed one oddity that I hope tym (in particular) can comment on. A few times the logfiles show that the same suggestion is deleted twice "to make room for startpad". The result seems to be OK (the suggestion is gone and the subsequent programme has the padding added), but I don't understand why this should happen. Maybe the suggestion is cancelled too early and so it pops up again.
> 
> Come to think of it, why does the suggestion have to be explicitly deleted at all? If the start padding is increased before the previous suggestion starts recoding, won't it give a conflict so the suggestion isn't recorded?
> 
> Tim.


Tim

I have thought about relying on the TiVo not recording the suggestion automatically and not deleting the suggestion, but your example above seems to indicate that the TiVo is rescheduling the suggestion even though it should be blocked by the startpadding that is added immediately after the deletion the first time. In any case, the current setup seems to work even though it may be a little heavy handed. I've been using 1.4.2-md5 for 8 weeks now without issue.

You could experiment with commenting out the DeleteSuggestion (but leaving in the rest of the related code, in particular the 'set dostartpadnow 1').

Tym


----------



## petestrash

I just noticed it has happened again, a suggestion was recorded in preference to end padding a season pass:



Code:


Tuesday 00:25:00 : endpad.tcl 1.4.2-md3 log file, log rotated
Tuesday 00:25:00 : Start padding set to 90 seconds
Tuesday 00:25:00 : End padding set to 1200 seconds
Tuesday 00:25:00 : Suggestions will not be padded if another suggestion immediately follows them
Tuesday 00:25:00 : Detected TiVo software version 3.0-01-1-000
Tuesday 00:25:00 : Suggestion quality change disabled
Tuesday 00:25:00 : Timezone 00:00
Tuesday 00:25:01 : Configuration options:-
Tuesday 00:25:01 : default: endpad 5 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Nine-WA validity 19:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Nine-WA validity 22:00-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Seven-WA validity 19:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Seven-WA validity 22:00-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Ten-WA validity 19:00-22:00 endpad 18 sugeq 0 sugqual -1 startpad 1.5
Tuesday 00:25:01 : channel Ten-WA validity 22:00-06:00 endpad 20 sugeq 0 sugqual -1 startpad 1.5
Sleeping, checking every minute for kill signal.... 
...Snip...
Tuesday 20:25:00 : Woken up
Tuesday 20:25:00 : Recording Surface on Ten-WA now
Tuesday 20:25:00 : Recording Scheduled End Time: 20:30
Tuesday 20:25:00 : Next recording is {The Ghost Whisperer} on Seven-WA (Suggestion) at 20:30
Tuesday 20:25:00 : Current recording is on Ten-WA and starts at 19:30 so use endpad 18
Tuesday 20:25:00 : Gap to next programme is 0 seconds
Tuesday 20:25:00 : Can't add end padding to Surface
Tuesday 20:25:00 : Next end padding setting due 21:25
Tuesday 20:25:00 : Not time to add start padding yet
Tuesday 20:25:00 : Next start padding setting due 20:27
Tuesday 20:25:00 : Next wake up will be 20:27
Sleeping, checking every minute for kill signal....

I'll load up [POST=3324070]endpad-1.4.2-md5[/POST] as tim suggested and see if the problems continue.

Peter


----------



## snowrides

HI All, 

Newbie here. I'm having trouble getting endpad to start automatcially.
I'm running a UK series 1 tivo software version 2.5.5a
I'm also a little confused as some threads talk about a config file which overrides the rc script.

If I run the following command manually endpad runs OK, but I cant get it to run automatically.
/var/hack/endpad.tcl -s -2 -e 5 -sugqual 75 

My /etc/rc.d/rc.sysinit.author is as follows: 

# Call the Tivo Package Manager Startup Scripts 
/etc/rc.d/rc.sysinit.tpm 
/var/hack/endpad.tcl -s -2 -e 5 -sugqual 75 -auto >> /dev/null & 
/var/hack/tivowebplus/tivoweb console

Any help would be much appreciated

thanks


----------



## sanderton

Are you intending to have minus two as the start padding?

Is TiVoWeb plus running OK - it might be that the call to run /etc/rc.d/rc.sysinit.tpm is not finishing properly and returning control to run the last two lines of this script.


----------



## cwaring

snowrides said:


> /var/hack/endpad.tcl -s -2 -e 5 -sugqual 75


Do I spy an extra (ie not-needed) minus sign there before the 2?


----------



## snowrides

Thanks fior the quick replies.
I've corrected the "-2" typo and still it wont start.
Tivoweb also doesnt start. I have to start it manually , so I guess your right the call for the run script is not finishing.

Any ideas how I can check it?


----------



## tym

petestrash said:


> I just noticed it has happened again, a suggestion was recorded in preference to end padding a season pass:
> 
> 
> 
> Code:
> 
> 
> Tuesday 00:25:00 : Suggestions will not be padded if another suggestion immediately follows them


Taking another look at the code, it would appear this is a bug that occurs if you have sugeq option selected or if the suggestion is on the same channel. Possible fix (line 1254):


Code:


Old: if {$gap < $endpadding && $nselectiontype == 6 && $ncallsign != $ccallsign && $sugcancancelsug == 1} {
New: if {$gap < $endpadding && $nselectiontype == 6 && {{$ncallsign != $ccallsign && $sugcancancelsug == 1} || $cselectiontype != 6}} {

Tym


----------



## Trinitron

I've trawled through the thread but haven't found a mention of this quirk, that's happened two weeks running...

We have 2 Season passes set for Thursdays:
1900-1955 The Avengers BBC4
2000-2030 Bleak House BBC1

Endpad is perfectly ok until it wakes up at 1957 to add start padding (default 1.5 minutes). It has added 298 seconds to the first recording at 1950, making the end time 19:59:58. But at 19:57:30 it adds another 298 seconds to the revised end time and overlaps the start of the next programme. Tivo doesn't lose the second recording, just starts it 4 minutes late.

I'm using Sanderton's 1.4.0 version. I'll try one of the later version and hunt for programmes starting 5 minutes apart, but is there an explanation?

Sleeping, checking every minute for kill signal...............................
Thursday 19:27:31 : Woken up
Thursday 19:27:31 : Recording {The Avengers} on BBC4 now
Thursday 19:27:31 : Recording Scheduled End Time: 19:55
Thursday 19:27:31 : Next recording is {Bleak House} on BBC1NW at 20:00
Thursday 19:27:31 : Not time to add end padding yet
Thursday 19:27:31 : Next end padding setting due 19:50
Thursday 19:27:31 : Not time to add start padding yet
Thursday 19:27:31 : Next start padding setting due 19:57
Thursday 19:27:31 : Next wake up will be 19:50
Sleeping, checking every minute for kill signal........................
Thursday 19:50:00 : Woken up
Thursday 19:50:00 : Recording {The Avengers} on BBC4 now
Thursday 19:50:00 : Recording Scheduled End Time: 19:55
Thursday 19:50:00 : Next recording is {Bleak House} on BBC1NW at 20:00
Thursday 19:50:00 : Gap to next programme is 300 seconds
Thursday 19:50:00 : Added 298 seconds end padding to {The Avengers}
Thursday 19:50:00 : Next end padding setting due 20:25
Thursday 19:50:00 : Not time to add start padding yet
Thursday 19:50:00 : Next start padding setting due 19:57
Thursday 19:50:00 : Next wake up will be 19:57
Sleeping, checking every minute for kill signal.........
Thursday 19:57:30 : Woken up
Thursday 19:57:30 : Recording {The Avengers} on BBC4 now
Thursday 19:57:30 : Recording Scheduled End Time: 19:59
Thursday 19:57:30 : Next recording is {Bleak House} on BBC1NW at 20:00
Thursday 19:57:30 : Gap to next programme is 300 seconds
Thursday 19:57:30 : Added 298 seconds end padding to {The Avengers}
Thursday 19:57:30 : Next end padding setting due 20:25
Thursday 19:57:30 : Gap to previous recording is 2 seconds
Thursday 19:57:30 : Can't add start padding to {Bleak House}
Thursday 19:57:30 : Next start padding setting due 20:25
Thursday 19:57:30 : Next wake up will be 20:25
Sleeping, checking every minute for kill signal.............................
Thursday 20:25:00 : Woken up
Thursday 20:25:01 : Recording {Bleak House} on BBC1NW now
Thursday 20:25:01 : Recording Scheduled End Time: 20:30
Thursday 20:25:01 : Next recording is {Sensitive Skin} on BBC2 at 22:00
Thursday 20:25:01 : Gap to next programme is 5400 seconds
Thursday 20:25:01 : Added 600 seconds end padding to {Bleak House}
Thursday 20:25:01 : Next end padding setting due 22:25
Thursday 20:25:01 : Not time to add start padding yet
Thursday 20:25:01 : Next start padding setting due 21:57
Thursday 20:25:01 : Next wake up will be 20:55


----------



## sanderton

Later versions had some bug fixes; I can't remember if this was one but it rings a bell.


----------



## Trinitron

Ok, I've loaded the latest version and rebooted Tivo for good measure. 

I'll try to record 2 progs 5 minutes apart and see what happens.

0025 BBC1 Strutting Our Stuff is scheduled to 0055
0100 BB4 The Late Edition is scheduled to 0130

Start padding is 1.5 mins, end padding 10 mins.

Off to bed now. See what Tivo says in the morning!


----------



## Trinitron

No good. Same error...

Friday 00:22:30 : Woken up
Friday 00:22:30 : No recording in progress
Friday 00:22:30 : Next recording is {Strutting Our Stuff} on BBC1NW at 00:25
Friday 00:22:30 : No end padding required:
Friday 00:22:30 : No recording in progress
Friday 00:22:30 : Next end padding setting due 00:50
Friday 00:22:30 : Added 90 seconds start padding to {Strutting Our Stuff} on BBC1NW
Friday 00:22:30 : Next start padding setting due 00:50
Friday 00:22:30 : Next wake up will be 00:50
Sleeping, checking every minute for kill signal.............................
Friday 00:50:00 : Woken up
Friday 00:50:00 : Recording {Strutting Our Stuff} on BBC1NW now
Friday 00:50:00 : Recording Scheduled End Time: 00:55
Friday 00:50:00 : Next recording is {The Late Edition} on BBC4 at 01:00
Friday 00:50:00 : Gap to next programme is 300 seconds
Friday 00:50:00 : Added 300 seconds end padding to {Strutting Our Stuff} on BBC1NW
Friday 00:50:00 : Next end padding setting due 01:25
Friday 00:50:00 : Not time to add start padding yet
Friday 00:50:00 : Next start padding setting due 00:57
Friday 00:50:00 : Next wake up will be 00:57
Sleeping, checking every minute for kill signal.........
Friday 00:57:30 : Woken up
Friday 00:57:30 : Recording {Strutting Our Stuff} on BBC1NW now
Friday 00:57:30 : Recording Scheduled End Time: 01:00
Friday 00:57:30 : Next recording is {The Late Edition} on BBC4 at 01:00
Friday 00:57:30 : Gap to next programme is 300 seconds
Friday 00:57:30 : Added 300 seconds end padding to {Strutting Our Stuff} on BBC1NW
Friday 00:57:30 : Next end padding setting due 01:25
Friday 00:57:30 : Gap to previous recording is 0 seconds
Friday 00:57:30 : Can't add start padding to {The Late Edition}
Friday 00:57:30 : Next start padding setting due 01:25
Friday 00:57:30 : Next wake up will be 01:25
Sleeping, checking every minute for kill signal.............................
Friday 01:25:00 : Woken up
Friday 01:25:01 : Recording {The Late Edition} on BBC4 now
Friday 01:25:01 : Recording Scheduled End Time: 01:30
Friday 01:25:01 : Next recording is {The Daily Show with Jon Stewart} on MORE4P1 (Suggestion) at 04:25
Friday 01:25:01 : Gap to next programme is 10500 seconds
Friday 01:25:01 : Added 600 seconds end padding to {The Late Edition} on BBC4
Friday 01:25:01 : Next end padding setting due 04:55
Friday 01:25:01 : Not time to add start padding yet
Friday 01:25:01 : Next start padding setting due 04:22
Friday 01:25:01 : Next wake up will be 01:55
Sleeping, checking every minute for kill signal...............................


----------



## sanderton

Well I guess the log file could be clearer but that seem to be working fine? It hasn't actualy added 2 lots of 5 mins.


----------



## Trinitron

Oops. Lesson here is to actually watch TiVo, not just read the logfile!  

You're right (of course) - First prog has 5 minutes added, the second starts on time.


----------



## petestrash

tym said:


> Taking another look at the code, it would appear this is a bug that occurs if you have sugeq option selected or if the suggestion is on the same channel.


Thanks Tym,

But unfortunately this does not explain either of the two examples I gave, unless by having 'sugeg option selected' you mean sugeg=0, not 1.

I had sugeg =0 and in both cases the suggestions were on different channels to the season passes being recorded.

That said I have not noticed the problem re-occur since moving to md5 .

Thanks,

Peter.


----------



## gregh

WoW! Endpad just let me down after eons of working fine, not sure if this was a one off funny, or a bug???

Sunday 02:50:00 : Woken up
Sunday 02:50:01 : Error detected
Sunday 02:50:01 : no such object: {CONFLICT err=errTmActiveLockConflict}
while executing
"dbobj $nprogram get Title"
("uplevel" body line 16)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set nrec [db $db openid $nextrecfsid]
if {$version >= 3} {
set nrecbeh [dbobj $nrec get RecordingBehavior..."
Sunday 02:50:01 : Attempting to recover
Sunday 02:50:31 : Woken up
Sunday 02:50:31 : Error detected
Sunday 02:50:31 : no such object: {CONFLICT err=errTmActiveLockConflict}
while executing
"dbobj $nprogram get Title"
("uplevel" body line 16)
invoked from within
"uplevel $body"
invoked from within
"transaction {uplevel $body}"
(procedure "RetryTransaction" line 4)
invoked from within
"RetryTransaction {
set nrec [db $db openid $nextrecfsid]
if {$version >= 3} {
set nrecbeh [dbobj $nrec get RecordingBehavior..."
Sunday 02:50:31 : Attempting to recover
Sunday 02:50:31 : Too many errors, stopping
Wednesday 20:08:47 :


----------



## sanderton

Just very bad luck; occasionally when trying to access the database it's busy after several retries and returns ActiveLockConflict. You got two in succession so EndPad quit.


----------



## daxab

Does endpad.tcl care what the time zone is? By default, TZ is unset, but for me, that leads to confusing time (in the log). Would endpad.tcl still work with export TZ=EST5EDT4 (or whatever)?


----------



## maxwells_daemon

If you use the new version, [POST=3324070]endpad-1.4.2-md5[/POST], you can specify the timezone with the -tz option. Unfortunately it still doesn't know to automatically change for summer time.


----------



## daxab

Nice! I've upgraded...

Incidentally, I believe if you modified it to call out to the shell and use 'date' instead of tcl's clock function for formatting then you could have it automatically change in the summer.

E.g., at the bash prompt:

TZ=EST5EDT4 date

does the right thing.


----------



## daxab

I think there is another mention of this error earlier in the thread. I also see the problem. I'm running md5 with vanilla config, startpad 1, endpad 3.



> Sleeping, checking every minute for kill signal........................
> Tuesday 03:55:01 : Woken up
> Tuesday 03:55:02 : Error detected
> Tuesday 03:55:02 : no such object: {CONFLICT err=errTmActiveLockConflict}
> while executing
> "dbobj $cstation get CallSign"
> ("uplevel" body line 11)
> invoked from within
> "uplevel $body"
> invoked from within
> "transaction {uplevel $body}"
> (procedure "RetryTransaction" line 4)
> invoked from within
> "RetryTransaction {
> set crec [db $db openid $recfsid]
> if {$version >= 3} {
> set crecbeh [dbobj $crec get RecordingBehavi..."
> Tuesday 03:55:02 : Attempting to recover
> Tuesday 03:55:32 : Woken up


----------



## b166er

Endpad is one of the main reasons I just recently got networked but looking at this 30 page thread I'm getting a bit scared. Are these issues that caused the 30 page thread all resolved? Are the recent error-log posts caused by people customising endpad incorrectly?

Hmmmm. I really wanna try it...


----------



## kitschcamp

Honestly? You can safely use the current version and not have problems. For the majority of us, it runs with no problem year in year out.


----------



## b166er

kitschcamp said:


> Honestly? You can safely use the current version and not have problems. For the majority of us, it runs with no problem year in year out.


Sweeeeet 

I wondered about the log file size. Is there a maximum log size? Or is it ever-expanding ?

Could use some extra info on the readme.txt (it's not written for dummies, which I still am at this stage)...

Stuart said "Copy to the TiVo using binary mode FTP", but he didn't say where it should be copied to. I assume because it's a tcl file it should be the tivoweb modules folder ... right?

He also said "then chmod 755 endpad.tcl" .... I assume I need to telnet and enter that command while in the same folder as where the file is ... right ?

Starting and stopping is not entirely clear. Do I need to run cron ? If not then do I need to start endpad each time my tivo decides to reboot itself ?

What's rc.sysinit.author ? Is that a way of making it fully automatic ? So we don't need to type the start and stop commands ?

Sorry for the noob questions  but I don't want to get my tivo in a state where it won't work, and doing this wrong I guess could easily cause that.


----------



## sanderton

Log files reset themselves every day.

Copy the file wherever you want. In fact the /modules directory is probably the only place I'd say NOT to put it. I guess most folks just put in /var/hack but it doesn't matter.

Yes, use telnet like that.

No, you don't need to run cron.

Yes, if the command to start endpad is in rc.sysinit.author then EndPad will launch every time the machine starts up.


----------



## b166er

Thanks Stuart  

I got it going, reading the log it seems to be working great


----------



## maxwells_daemon

daxab said:


> Incidentally, I believe if you modified it to call out to the shell and use 'date' instead of tcl's clock function for formatting then you could have it automatically change in the summer.
> 
> E.g., at the bash prompt:
> 
> TZ=EST5EDT4 date
> 
> does the right thing.


That may not work on all different TiVo software versions. TivoWeb has an enormously complicated routine (that I still haven't sussed out completely, although it does use the date command in places) to work out the timezone offset in each version. Apart from pasting in that code (which would make endpad rather larger), I didn't fancy trying to sort this out myself.


----------



## b166er

snowrides said:


> Tivoweb also doesnt start. I have to start it manually , so I guess your right the call for the run script is not finishing. Any ideas how I can check it?


I'm having the same issue. I can start it manually but it doesn't start automatically. Here's my rc.sysinit.author file as per the readme file:

#!/bin/bash
/var/hack/tivoweb-tcl/tivoweb
/var/hack/endpad.tcl -s 2 -e 5 -sugqual 0 -sugeq -auto >> dev/null &
/var/hack/tytools/tserver -s /var/hack/tytools/NowShowing.tcl &


----------



## cashew1970

I have

/var/hack/endpad.tcl -s 2 -e 5 -sugqual 75 -sugeq -auto .. /dev/null &

so 2 dots... not 2 >>

Mine works fine


----------



## b166er

cashew1970 said:


> so 2 dots... not 2 >> Mine works fine


That did the trick it seems. Thanks cashew  The one-minute dots are ticking along nicely


----------



## Fozzie

/var/hack/endpad.tcl -s 2 -e 5 -sugqual 0 -sugeq -auto >> */*dev/null &

is the correct command i.e. the leading '/' is the change to the readme


----------



## b166er

Fozzie said:


> /var/hack/endpad.tcl -s 2 -e 5 -sugqual 0 -sugeq -auto >> */*dev/null &
> 
> is the correct command i.e. the leading '/' is the change to the readme


Thanks Fozzie, I had a feeling that might be right with /dev/null because that's what that snowrides dude further up this thread had but his wasn't working so I wasn't sure.


----------



## zippy7272

Great Routine - Thank You.

1 question though.

Quite often the programs I record run end to end on different channels. EG coronation street on a Monday at 7:30-8:00 then Eastenders from 8:00-8:30 followed by the street again 8:30 to 9:00.

Often the 1st Coronation street runs a bit late, although I can endpad it, I can't because of eastenders starting at 8-00. Now I'm quite happy to have eastenders to start 1 minute late, and corrie to run over by that 1 minute.

Is that possible?

Eastenders to start 1 minute late, corrie to always run over 1 minute?


----------



## b166er

zippy7272 said:


> Is that possible?
> 
> Eastenders to start 1 minute late, corrie to always run over 1 minute?


I think it the following would work, but let someone else (especially stuart) confirm it though:

Endpad set to startpadding=4mins, end padding = whatever you like

set coronation street SP to have +1 min of hard padding in it's SP (that should stop endpad from wanting to give it any padding at all I think).

set eastenders to be a MANUAL SP that runs 8:05 - 8:30. Endpad should add 4 mins to the beginning (giving you your 8:01) and your chosen padding at the end.

Not entirely sure this would work as I've suggested, I'm making assumptions of Endpad based purely on a short amount of experience of it. Plus I don't know if a manual repeat recording is useful for eastenders, I don't know if it's always on the same day.


----------



## sanderton

What you are after is negative padding for Eastenders. It's often been discussed; have a search on "negative padding" in this thread and others and see if anyone has come up with a suitable solution for you.


----------



## zippy7272

b166er said:


> I don't know if a manual repeat recording is useful for eastenders, I don't know if it's always on the same day.


Thanks for the suggestion

Unfortunately (in many ways  ) Eastenders is on multiple nights of the week, and does change times especially around holidays.

Anyone any more suggestions?


----------



## Ian_m

I have an autorecord wishlist for "Eastenders" with 5 mins end padding, a BBC 1 season pass (no padding) and BBC3 season pass (no padding), in that order.

Usually between these three and endpad of start 1 and end 5, I get all episodes each week with 1min start padding and 5 minutes end padding recorded at either 7:30'ish (BBC1 ) or 10:00 (BBC3). Wife happy, me happy as not bumping out recordings made earlier in the evening. The wishlist also gets the weekend omnibus edition as well, which is handy to prevent my death in the week if for some reason an episode is not recorded.


----------



## mike0151

zippy7272 said:


> Anyone any more suggestions?


Either a second TiVo or record the omnibus editions shown at the weekend.


----------



## maxwells_daemon

I have made a new version of EndPad, incorporating [POST=3553169]tym's fix[/POST] (with a minor correction) into [POST=3324070]endpad-1.4.2-md5[/POST], and improving the documentation. Since we've been running this for some time without problems, I decided to bump the version number to EndPad 1.5.0.

sanderton suggested I start a new thread when the new version was ready, so I [THREAD=286631]posted it there[/THREAD]. Please continue EndPad discussions there (Stuart said he'd update the top post and have this thread locked).


----------

