Clock

Date: 198x
Type: Program
Platform(s): TS 1000

Appears on

Assembled by Tim Ward from many sources. Contains programs 10294-10335.

Gallery

Clock

Source Code

  12 PRINT "  INPUT TIME"
  14 INPUT T
  16 LET H=2*INT (T/100)
  18 LET T=T-100*INT (T/100)
  20 IF T>15 THEN LET H=H+1
  22 IF T>45 THEN LET H=H+1
  24 CLS 
  26 FAST 
  30 FOR D=1 TO 12
  40 PRINT AT 10-10*COS (D/6*PI),13+10*SIN (D/6*PI);D
  50 NEXT D
  60 SLOW 
  65 POKE 16437,250
  70 GOTO 150
  80 LET P=0
  90 LET C=X
 100 LET D=Y
 110 GOSUB 1000
 120 LET T=T+1
 130 IF T=60 THEN LET T=0
 140 IF T=16 OR T=46 THEN GOTO 250
 150 LET P=1
 160 LET L=T/30*PI
 170 LET X=27+18*SIN L
 180 LET Y=22+18*COS L
 190 LET C=X
 200 LET D=Y
 210 GOSUB 1000
 220 GOSUB 310
 230 IF PEEK 16437>241 THEN GOTO 230
 235 PAUSE 219
 240 GOTO 80
 250 LET H=H+1
 260 GOTO 24
 310 LET P=1
 320 LET A=27
 330 LET B=22
 340 LET G=H/12*PI
 350 LET C=27+12*SIN G
 360 LET D=22+12*COS G
 370 GOSUB 1000
 380 RETURN 
 490 CLEAR 
 500 SAVE "1031%8"
 510 RUN 
1000 LET A=27
1002 LET B=22
1008 LET U=C-A
1010 LET V=D-B
1020 LET O=SGN U
1030 LET L=SGN V
1040 LET Z=SGN U
1050 LET Q=0
1060 LET M=ABS U
1070 LET N=ABS V
1080 IF M>N THEN GOTO 1130
1090 LET Z=0
1100 LET Q=SGN V
1110 LET M=ABS V
1120 LET N=ABS U
1140 LET S=INT (M/2)
1150 FOR I=0 TO M
1160 IF P=1 THEN PLOT A,B
1165 IF P=0 THEN UNPLOT A,B
1170 LET S=S+N
1180 IF S<M THEN GOTO 1230
1190 LET S=S-M
1200 LET A=A+O
1210 LET B=B+L
1220 GOTO 1250
1230 LET A=A+Z
1240 LET B=B+Q
1250 NEXT I
1260 RETURN 

People

No people associated with this content.

Scroll to Top