VGAclocks


Author Message
dddns
Guru

Joined: 20/09/2024
Location: Germany
Posts: 353
Posted: 11:28pm 10 Apr 2025      

I never typed that much in my life :)) My lost cost cherry keyboard is lost..the cursor keys

So here it is, my first real MM Basic program. I couldn't comment it yet but I thought somebody might want to play already. I tired my best, it shows a picture..

VGAclocks_V1.bas.zip
have fun :)

> list
Option explicit
Option console serial
VGAclocks(5,"INIT")
VGAclocks(2,"SET_TIMEZONE",2,,,1)
MODE 3 : Font 1
FRAMEBUFFER create
FRAMEBUFFER write f
CLS RGB(white)
Dim integer count

Do
 For count = 0 To clk_amount
   VGAclocks(count) 'draw the clock
 Next count

 FRAMEBUFFER copy f,n
 FRAMEBUFFER write f
 CLS RGB(white)
Loop

'++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
+

'VGAclocks library starts here

Sub VGAclocks(clk_object,clk_init_action$,clk_draw_scale,clk_source,clk_dest,clk_debug,clk_base_UTC
_time$)

 If clk_debug <> 0 Then
   Print "VGAclocks for PicoMite MMBasic"
   Print "Version 0.1"
   Print "published at https://www.thebackshed.com/forum/ViewTopic.php?FID=16&TID=17822"
   Print "clk_draw_scale = ";clk_draw_scale
   Print "clk_object = ";clk_object
   Print "clk_init_action$ = ";clk_init_action$
   Print "clk_source = ";clk_source
   Print "clk_dest";clk_dest
   Print "clk_debug = ";clk_debug
   Print "clk_base_UTC_time$ = ";clk_base_UTC_time$
   Print :Print
 End If



It's completely encapsulated and need nothing before init, runs with explicit option. I hope that this is how it should be for a library, but I don't know. One of my favorites is to re-invent the wheel, so this is done with zero knowledge.

(technical)comments are very much appreciated!