Clock change

A place to discuss general QL issues.
Post Reply
User avatar
dilwyn
Mr QL
Posts: 3048
Joined: Wed Dec 01, 2010 10:39 pm

Clock change

Post by dilwyn »

I wonder who had the most QL clocks to change time today? I'll start with my four which have battery backed clocks:
QL+Gold Card
QL+QIMSI with RTC
Aurora+Super Gold Card (Minis-QL)
Q68

The battery on the Super Gold Card is more or less dead, so occasionally it "forgets" the date.


User avatar
tofro
Font of All Knowledge
Posts: 3033
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Clock change

Post by tofro »

My Q68 takes the time via NTP, so no change necessary. :)

And my Gold and SuperGold Cards have long lost their batteries for danger of leaking, so they enjoy a live without time....


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
Andrew
QL Wafer Drive
Posts: 1029
Joined: Tue Jul 17, 2018 9:10 pm

Re: Clock change

Post by Andrew »

QL+Gold Card
QL+SGC
QL+QIMSI Gold
Q68

Which reminds me that I have to change the batteries in GC and SGC ...


User avatar
dilwyn
Mr QL
Posts: 3048
Joined: Wed Dec 01, 2010 10:39 pm

Re: Clock change

Post by dilwyn »

tofro wrote: Sun Mar 30, 2025 2:02 pm My Q68 takes the time via NTP, so no change necessary. :)

And my Gold and SuperGold Cards have long lost their batteries for danger of leaking, so they enjoy a live without time....
For systems which have battery backed clocks but not the luxury of connecting to such services, here's a little routine I wrote some years ago which can be added to BOOT programs to alert you to summer time changes. It checks if the month is March or October (obviously change the check for Mar and Oct to the language of your system). Then checks if it's a Sunday, and the last Sunday of the month. If so, it shows the current time and offers to add or subtract an hour from the current time by asking you to enter Y or N.

I've only used it from SMSQ/E, I don't know if it works on QDOS. Uses ADATE to advance or deduct one hour from the time.

If it's not the last Sunday of March or October it simple does nothing.

Something for you to tinker with and improve, ready for the next change to summer time in October.

Obviously, on emulators like QPC2, the emulator may take its time from the host computer's time.

And of course no good on systems without battery backed clock.

Code: Select all

100 REMark BST change for BOOT programs
110 REMark adjust day/month language for your system
120 CLS : CLS #0
130 d$ = DATE$ : mth$ = d$(6 TO 8)
140 IF d$(6 TO 8) = 'Mar' OR d$(6 TO 8) = 'Oct' THEN
150   REMark British summer time +1 hour in March, -1 hour in October
160   REMark "Spring forward, Fall back"
170   REMark occurs on last weekend of those months
180   IF DAY$ = 'Sun' THEN
190     IF d$(10 TO 11) > 24 THEN
200       REMark last weekend of March or October
210       INPUT #0,'Date$ = ';(DATE$);'. Adjust clock for BST? ';yn$
220       IF yn$ == 'y' THEN
230         IF d$(6 TO 8) = 'Mar' THEN ADATE 60*60 : ELSE ADATE -60*60
240         PRINT #0,'New time=';DATE$
250       END IF
260     END IF
270   END IF
280 END IF


User avatar
t0nyt
Aurora
Posts: 906
Joined: Wed Nov 22, 2023 6:46 pm
Location: UK

Re: Clock change

Post by t0nyt »

QL+SGC
QL+QIMSI Gold w/RTC - not done yet!

Though I didn't have to manually change the time on the SGC as that QL also reads the date/time over the modem (if plugged in, which it was) so it got set automatically on boot


User avatar
Giorgio Garabello
Gold Card
Posts: 285
Joined: Tue Jun 30, 2015 8:39 am
Location: Turin, Italy
Contact:

Re: Clock change

Post by Giorgio Garabello »

tofro wrote: Sun Mar 30, 2025 2:02 pm My Q68 takes the time via NTP, so no change necessary. :)

And my Gold and SuperGold Cards have long lost their batteries for danger of leaking, so they enjoy a live without time....
I'm really curious, how do you do it?


User avatar
tofro
Font of All Knowledge
Posts: 3033
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Clock change

Post by tofro »

Giorgio Garabello wrote: Mon Mar 31, 2025 4:32 pm
tofro wrote: Sun Mar 30, 2025 2:02 pm My Q68 takes the time via NTP, so no change necessary. :)

And my Gold and SuperGold Cards have long lost their batteries for danger of leaking, so they enjoy a live without time....
I'm really curious, how do you do it?
What? Living without time? That's easy ;)

If NTP was the question: https://github.com/tofro/Q68NTP


ʎɐqǝ ɯoɹɟ ǝq oʇ ƃuᴉoƃ ʇou sᴉ pɹɐoqʎǝʞ ʇxǝu ʎɯ 'ɹɐǝp ɥO
User avatar
RalfR
QL Wafer Drive
Posts: 1166
Joined: Fri Jun 15, 2018 8:58 pm

Re: Clock change

Post by RalfR »

Always good to see the classic mnemonics. :)


7000 4E75
swensont
Forum Moderator
Posts: 316
Joined: Tue Dec 06, 2011 3:30 am
Location: SF Bay Area
Contact:

Re: Clock change

Post by swensont »

Time change? That was 2 weeks ago. You Brits are always behind. :-)


Post Reply