PDA

View Full Version : Daylight Savings Changes



zollymonsta
25-07-2007, 09:45 PM
As you're probably all aware, the daylight savings beginning/end dates change from September this year.

"Clocks will go forward an hour a week earlier than usual - on the last Sunday in September- and back an hour on the first Sunday in April, instead of the third Sunday in March."

Just wondering what will need to be done to ensure TiVo has the right time from September? I think it currently uses the Auckland timezone file doesn't it? And wouldn't this need to be updated?

Cheers,
ZollyMonsta

DOlsen
26-07-2007, 12:26 PM
Would the tivo automatically pick up the correct time during a phone call when it sets it's time using ntp?

petestrash
27-07-2007, 12:48 AM
We usually wait till freebsd puts out new zoneinfo files. There will also be further changes to West Australian TZ's this year. We will probably pickup both sets at the same time.

OzTiVo users can update automatically.

NZTiVo users will probably need to FTP the files across.

Peter.

thomson
03-08-2007, 12:08 PM
As you're probably all aware, the daylight savings beginning/end dates change from September this year.

Just wondering what will need to be done to ensure TiVo has the right time from September? I think it currently uses the Auckland timezone file doesn't it? And wouldn't this need to be updated?


The attached file (Auckland) should be placed in /var/hack/zoneinfo/Pacific (replacing the existing file). You may also wish to schedule the following script to run via cron (I normally name the script DST_Adjust.sh and place it in /var/hack/DST/)




# ===========================
# Adjust for Daylight Savings
# ===========================
# Daylight Time commences at 2.00am Standard Time on the last
# Sunday in September each year. It ends at 2.00am Standard
# Time (3.00am Daylight Time) on the first Sunday in April of
# the following year.
#
# ===============
# Crontab Entries
# ===============
# Correct time for Daylight Saving
# 0 2 * 9 0 /var/hack/DST/DST_Adjust.sh >> /var/hack/DST/log 2>&1 &
# 0 3 * 4 0 /var/hack/DST/DST_Adjust.sh >> /var/hack/DST/log 2>&1 &


PATH=/bin:/sbin:/tvbin:/devbin:/var/hack/bin:/var/hack/scripts

StartDST() {
time=`date -d "now +1 hour" "+%Y%m%d%H%M%S"`
settime $time
}

StopDST() {
time=`date -d "now -1 hour" "+%Y%m%d%H%M%S"`
settime $time
}

date "+%w %e %b %k" |\
while read day dom mon hour; do
# Check if it is the last Sunday in September
if [ $dom -ge 22 -a $day -eq 0 -a "$mon" = "Sep" -a $hour -eq 2 ]; then
StartDST
fi

# Check if it is the first Sunday in April
if [ $dom -le 7 -a $day -eq 0 -a "$mon" = "Apr" -a $hour -eq 3 ]; then
StopDST
fi
done

petestrash
04-08-2007, 09:10 PM
Hi Thomson,

I know you don't use the emulator, but your suggestion will not work for those that do.

Time is set daily during the daily call, so the first call will wipe your hack.

Peter.

Edit: disregard the above, I didn't realise the attached file was the timezones files. Should work fine.

zollymonsta
19-08-2007, 07:40 PM
Just re-imaging my tivo now. So this change of the zonefile will need to be made on the NZ Emulator, and the tivo would pick this up with the next daily call, correct?

I'm hoping this re-image will be smooth :) importing data now after first call to the emulator. I must say its a lot easier now than it used to be for NZ users.. thanks guys :)

Cheers,
ZollyMonsta

petestrash
19-08-2007, 11:42 PM
No, the timezone files reside on your TiVo and will need to be manually updated before Daylight savings starts.

Edit: use thomsons file attached above

Peter.

SeanOffShotgun
05-09-2007, 06:17 AM
Hi Thomson,

I know you don't use the emulator, but your suggestion will not work for those that do.

Time is set daily during the daily call, so the first call will wipe your hack.

Peter.

Been wondering about this for a while...

If ThomPPPson's hack gets wiped isn't the correct time from the start of daylight savings via his hack just getting replaced with the correct time from the daily call?

Since the daily call happens some unknown time after daylight savings starts if you just rely on the daily call and not ThomPPPson's hack (in combination) don't you then run the risk of missing recording programmes?

SeanOffShotgun
05-09-2007, 06:30 AM
No, the timezone files reside on your TiVo and will need to be manually updated before Daylight savings starts.

Not an issue till then though.

Peter.

For NZ'ers that's DST starts on 30th September - not too far away.

What to do... ? :)

petestrash
05-09-2007, 11:45 AM
Been wondering about this for a while...

If ThomPPPson's hack gets wiped isn't the correct time from the start of daylight savings via his hack just getting replaced with the correct time from the daily call?

Yes, as conforms to the existing timezone rules loaded into your TiVo.

Edit: didn't realise thomson attached the auckland tz file. using both the script and tz file together should be fine


Since the daily call happens some unknown time after daylight savings starts if you just rely on the daily call and not ThomPPPson's hack (in combination) don't you then run the risk of missing recording programmes?

Yes, we get around this with the following crontab entry on all OzTiVo's:
5 2 * * 0 /hack/bin/fixtivotime
5 3 * * 0 /hack/bin/fixtivotime

Peter.

petestrash
05-09-2007, 11:47 AM
For NZ'ers that's DST starts on 30th September - not too far away.

What to do... ? :)

We rely on the freebsd guys to make the new files and then convert for TiVo.

Should happen soon.

Peter.

SeanOffShotgun
06-09-2007, 06:36 AM
Thanks for your replies Peter - all clarified nicely.

PS

I've just noticed ThomPPPson's Auckland file in this thread.

DOlsen
06-09-2007, 11:04 AM
I've just noticed ThomPPPson's Auckland file in this thread.

You did better than me...
I've been waiting for the updated file to put onto another tivo I set up for a mate, but gave it to him in the meantime. Seems that it was there since before I gave it to him....
Oh well, at least I'll get a dinner when I go round to update the file :-)

Just to check - this has been recompiled from the updated zoneinfo file?

petestrash
06-09-2007, 11:07 PM
Please read the threads following Thompsons Post. The File he posted will not work for those of you connecting to Orac.

Peter.

Edit: my bad I didn't realise thomson posted the tz file, I assumed it was just his script.

catdog
07-09-2007, 05:33 AM
the timezone files reside on your TiVo and will need to be manually updated before Daylight savings starts.
Unless I am missing something here, the "timezone file" is the one Thomson attached to the bottom of his post (i.e. /var/hack/zoneinfo/Pacific/Auckland) and is completely seperate from the script in the middle of the post. My understanding is that the timezone file will work with the daily call, while the script will adjust the time when DST changes (instead of waiting for the next daily call to occur).


Please read the threads following Thompsons Post. The File he posted will not work for those of you connecting to Orac.
Can you clarify why this new timezone file will not work (assuming it was correctly compiled with the new day light saving dates)?

petestrash
07-09-2007, 02:42 PM
My bad I didn't realise thomson posted the tz file, I assumed it was just his script. And without a new TZ file the script wouldn't work.


So everyone give Thomsons file a go.

Peter.

thomson
07-09-2007, 02:51 PM
Just to check - this has been recompiled from the updated zoneinfo file?

Yes the (binary) "Auckland" file attached to post 4 (http://forums.oztivo.net/showpost.php?p=10969&postcount=4) has the correct Daylight Savings Changes compiled within it. This file should be placed on your TiVo replacing the existing one so that when you next synchronise your clock via a Daily Call, Fixtivotime or one of the modified NTP binaries (ie rdate (http://www.forums.oztivo.net/showthread.php?p=2295&#post2295)) it will set the clock correctly.

The script that is include in the same post (http://forums.oztivo.net/showpost.php?p=10969&postcount=4) is just a backup in case your system is unable to connect to the Internet during the daylight savings changeover. If you do not have your TiVo connected to the Internet, or if your connection is unreliable then I would suggest also implementing the script to avoid missed recordings.