Pause Function - useful for a Clock?

Anything Sinclair ZX Basic related; history, development, tips - differences between BASIC on the ZX80 and ZX81
User avatar
1024MAK
Posts: 2524
Joined: Mon Sep 26, 2011 10:56 am
Location: Looking forward to summer in Somerset, UK...

Re: Pause Function - useful for a Clock?

Post by 1024MAK » Wed Aug 10, 2016 11:25 am

Some years ago, I needed to keep real time on a BASIC Stamp microcontroller. I used a circuit based on a 32.768kHz watch crystal and a 4060 CMOS logic 14 stage counter chip. The microcontroller polled the output of the counter using an I/O pin. It used this as the time reference and then the program kept track of seconds, minutes, hours and days. It ran for weeks and the time was fairly stable with not much drift.

If you wanted, this could also be done on a ZX81 / TS1000. You would of course need some extra circuitry so that the Z80 CPU could read the counter (address decoding and control).

The schematic and other details (for the BASIC Stamp) are in this PDF.

Mark

User avatar
siggi
Posts: 883
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Pause Function - useful for a Clock?

Post by siggi » Fri Aug 12, 2016 10:10 am

mrtinb wrote:You need some external hardware for a clock.

Maybe you could use ZeddyNet to sync the clock with an Internet server.
Erik already wrote such a program .....

Siggi
My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

User avatar
siggi
Posts: 883
Joined: Thu May 08, 2008 9:30 am
Location: Dauernheim, Germany
Contact:

Re: Pause Function - useful for a Clock?

Post by siggi » Fri Aug 12, 2016 2:29 pm

My ZX81 web-server: online since 2007
http://zx81-siggi.endoftheinternet.org/index.html

Post Reply