home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Commodore Disc 53
/
Commodore_Disc_53_19xx_-_de.d64
/
time
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
693b
|
30 lines
100 deffnur(n)=val(mid$(ur$,3*n+1,2))
110 deffnbc(ur)=ur+6*int(ur/10)
115 deffndz(ur)=ur-6*int(ur/16)
120 uh=56331:goto360
130 :
140 rem ===== uhr stellen =========
150 printchr$(147)"uhrzeit 00-00-00[157][157][157][157][157][157][157][157][157][157]";
160 inputur$
170 pokeuh+3,peek(uh+3)or128:rem 50hz
180 pokeuh+4,peek(uh+4)and127:rem uhr
190 ur=fnur(0):ifur>=12thenur=ur+68
200 fori=0to2:pokeuh-i,fnbc(ur)
210 ur=fnur(i+1):next
220 print:print"start auf tastendruck"
230 geta$:ifa$=""then230
240 pokeuh-3,0:return
250 :
260 rem ===== uhr lesen ==========
270 ur=fndz(peek(uh)):ifur=12thenur=0
280 ifur>12thenur=ur-68
290 ifur=24thenur=12
300 ur$="":fori=1to3
310 ur$=ur$+chr$(48+int(ur/10))+chr$(48+ur-10*int(ur/10))+":"
320 ur=fndz(peek(uh-i)):next
330 ur$=left$(ur$,8):return
340 :
350 rem ====== hauptprogramm =======
360 gosub150:printchr$(147);
370 gosub270:printchr$(19)ur$;:goto370