Listing of file='STODAT.BAS;2D' on disk='vmedia/ncc_4_11-sector.ccvf'
100 REM TERMINAL DATA STORAGE PROGRAM FOR COMPUCOLOR II 120 REM BY MYRON T. STEFFY - SUN CITY, ARIZONA 9/80 400 PLOT 12:CLEAR 100 420 IF PEEK (36865)+ PEEK (36866)= 432THEN 1000 430 PLOT 14,17 440 PRINT TAB( 28)"STODAT":PLOT 15:PRINT 450 PRINT TAB( 12)"INITIALIZED AT 300 BAUD AND FULL DUPLEX " 460 PRINT 470 PLOT 15,19 600 PRINT TAB( 12)"DO YOU HAVE LOWER CASE (Y OR N) ";:INPUT LC$ 620 PRINT 640 IF PEEK (36865)+ PEEK (36866)= 432THEN 760 720 PLOT 27,4 740 PRINT "LOAD STODAT.PRG;2D" 760 IF LC$= "Y"THEN POKE 36963,195:POKE 36964,116:POKE 36965,144 770 IF LC$= "N"THEN POKE 36963,254:POKE 36964,97:POKE 36965,218 800 PLOT 27,6:PLOT 27,9 900 END 1000 REM BEGIN PRINT ROUTINE 1010 PLOT 22,15 1020 PRINT TAB( 8)"TO PRINT TEXT ENTER "TAB( 50)"1":PRINT 1030 PRINT TAB( 8)"TO SAVE TEXT ON DISC "TAB( 50)"3":PRINT 1040 PRINT TAB( 8)"TO RELOAD TEXT FROM DISC "TAB( 50)"4":PRINT 1050 PRINT TAB( 8)"FOR OUTPUT TO LINE PRINTER "TAB( 50)"6":PRINT 1055 PRINT TAB( 8)"TO CHANGE CASE SELECTION "TAB( 50)"C":PRINT 1057 PRINT TAB( 8)"RETURN TO TERMINAL MODE "TAB( 50)"M":PRINT 1060 INPUT A$ 1070 IF A$= "1"THEN 1120 1080 IF A$= "3"THEN GOSUB 1360 1090 IF A$= "4"THEN GOSUB 1460 1100 IF A$= "6"THEN GOSUB 1240 1105 IF A$= "C"THEN GOTO 470 1107 IF A$= "M"THEN PLOT 27,6:PLOT 27,9:END 1110 IF A$= "0"THEN PRINT TAB( 8)"MAKE YOUR SELECTION":GOTO 1000 1120 PRINT :PRINT 1130 B= 38000 1140 Z= PEEK (36862)+ PEEK (36863)* 256 1145 IF B= ZTHEN PRINT TAB( 12)"NO DATA IN MEMORY":PRINT :GOTO 1000 1150 FOR I= BTO (Z- 1) 1160 P= PEEK (B) 1170 PRINT CHR$ (P); 1180 B= B+ 1 1190 NEXT I 1200 PRINT :PRINT 1210 IF A$= "6"THEN GOSUB 1310 1220 GOTO 1000 1230 END 1240 PLOT 19:REM PRINTING SUBROUTINE 1250 PRINT TAB( 8)"SET BAUD RATE (1/7): ";:INPUT BR 1260 PLOT 23,14,27,18,BR,15 1270 POKE 33289,79 1280 OUT 8,4:REM DISABLE INTERUPTS 1290 PLOT 27,13 1300 RETURN 1310 REM BACK TO BASIC SUBROUTINE 1320 POKE 33265,0 1330 OUT 8,255:REM ENABLE INTERUPTS 1340 RETURN 1350 END 1360 REM SUBROUTINE FOR SAVING DATA IN RAM 1365 T= 38000:GOSUB 2100:B$= H$:REM START OF DATA 1370 T= (PEEK (36862)+ PEEK (36863)* 256) 1380 GOSUB 2100:E$= H$:REM END OF DATA 1390 INPUT "WHAT IS THE NAME OF THE DATA TO BE SAVED ? ";N$ 1400 PLOT 27,4:PRINT "SAVE ";N$;".SRC ";B$;"-";E$ 1410 POKE 33265,0 1420 PRINT 1440 GOTO 1000 1450 END 1460 REM SUBROUTINE FOR LOADING DATA FROM DISC 1470 T= 38000:GOSUB 2100 1480 INPUT "WHAT IS THE NAME OF THE DATA TO BE LOADED ? ";N$ 1490 PLOT 27,4:PRINT "LOAD ";N$;".SRC ";H$ 1495 POKE 33265,0 1500 Z= PEEK (33049)+ PEEK (33050)* 256+ 38000- 1:REM END OF DATA 1510 Z1= INT (Z/ 256):Z2= Z- (Z1* 256) 1520 POKE 36862,Z2:POKE 36863,Z1 1525 PRINT 1530 RETURN 1540 END 2090 REM DECIMAL TO HEX CONVERSION 2100 H$= "":X= 4096 2110 IF T< 256THEN X= 16 2120 H= INT (T/ X):T= T- (H* X) 2130 H= H+ 48:IF H> 57THEN H= H+ 7 2140 H$= H$+ CHR$ (H) 2150 X= X/ 16:IF X< 1THEN RETURN 2160 GOTO 2120 2170 END