Very Basic BASIC: making a digital clock program using CBM characters and sprites (C64)

One of my readers (Crispin) has kindly requested a simple digital clock program for the Commodore 64 (in BASIC V2). He showed me a C64 BASIC example from Rosetta code and asked if I could make a similar program that would be either fast (at least to be usable) and flicker-free. And possibly, with simple code.

On the program “sprite clock v2” instead, TI$is only printed in memory, not on screen (so, no hidden characters on screen). As this requires to change the content of location 648 decimal, the same fix as the one in the program “basic char clock” has been added, so that proper program exiting by using the RUN/STOP + RESTORE key combination is possible. 2 thoughts on “Very Basic BASIC: making a digital clock program using CBM characters and sprites (C64)” 1. Crispin on said: Excellent! I hoped you’ll make something like this. You were so fast that I did not realize you already published it until right now. Avoiding TI$ – string operations, well, that’s something I thought about. Just change is important (and we know it is 1 second).
I thought about double buffering as a “proper” solution, just my practical knowledge is too low to implement it.

Thank you for sprite solution(s). Obviously, it is easier to achieve it with sprites. Just, for real purposes, sprites will be used for more useful stuff, more often then to be spared for time / timer. But you made a showcase how it could be (and should be) used, if needed.

Now I want to forget about my real life and start studying C64 BASIC and machine code for the rest of my life … 🙂
Thanks a lot, I hope that this will worth to anybody reading it.
You really have to make e-book.

Best regards,
Crispin