home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Commodore Disk User Volume 4 #6
/
Commodore_Disk_User_Vol.4_6_1991_-.d64
/
lgconvert
(
.txt
)
< prev
next >
Wrap
Commodore BASIC
|
2022-10-26
|
2KB
|
66 lines
1000 rem"@:lgconvert.bas"
1001 rem
1002 rem ******************************
1003 rem * *
1004 rem * this program remains *
1005 rem * *
1006 rem * (c) copyright 1988 *
1007 rem * *
1008 rem * by *
1009 rem * *
1010 rem * dave weaver *
1011 rem * *
1012 rem * *
1013 rem * but feel free to give *
1014 rem * copies away to friends! *
1015 rem * *
1017 rem * *
1018 rem ******************************
1019 rem
1029 deffnhi(x)=int(x/256)
1030 deffnlo(x)=x-(fnhi(x)*256)
1040 d=8:ln=1000:lk=2049
1050 print"[147]laser genius to 6510+ source converter"
1060 print"(c) 1988 dave weaver"
1061 print"nb: l.g. files must have been saved with the 'fsave' command!"
1062 print"you must also have 6510+ v1.21 or more!"
1070 input"l.g. file name ";fi$
1080 iffi$=""then1070
1090 input"new file name ";fo$
1100 iffo$=""thenend
1110 open15,d,15,"i0:"
1120 gosub1360
1130 open1,d,0,fi$+",s,r"
1140 gosub1360
1150 open2,d,1,fo$+",p,w"
1151 gosub1360
1152 print#2,chr$(1)chr$(8);
1160 gosub1360
1171 input#1,s$
1180 println""s$
1185 s=st
1190 rem * output s$ as a basic line
1200 rem * lk = link address
1210 rem * ln = line number
1220 lk=lk+len(s$)+5
1230 print#2,chr$(fnlo(lk));
1240 print#2,chr$(fnhi(lk));
1250 print#2,chr$(fnlo(ln));
1260 print#2,chr$(fnhi(ln));
1280 ln=ln+10
1290 print#2,s$+chr$(0);
1299 s$=""
1300 ifs=0then1160
1310 print#2,chr$(0)chr$(0);
1320 close2
1330 close1
1340 close15
1350 end
1360 input#15,a,b$,x,y
1370 ifa=0thenreturn
1380 print:print""a"[157],"b$","x"[157],"y
1390 close2
1400 close1
1410 close15
1420 end