10 REM" [0x16] [0x07] [0x0E] 20 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] Convert files to ASCII V.3 30 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒConvert files to ASCII V.3 40 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] By C.J.Richardson. 50 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒBy C.J.Richardson. 60 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚This program will convert most 70 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚files containing control codes 80 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚Remove line320‚to run from a 90 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚menu. Place filename in $&A00. 100 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚Run with Z%=1‚for a printout. 110 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚Remove the REM‚ from lines 120 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] 370‚and390‚to save converted 130 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚file. Change the value of 140 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] PTR#F%‚in line340‚to miss out 150 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚header files etc. 0 if none. 160 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚To convert from a chosen point 170 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚in a file, enter the phrase to 180 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚start from after entering"Y" 190 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ‚To MARKED PRINTOUT? ‚Press 200 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ESCAPE‚ to stop printout. 210 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] †------------------------------ 220 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒThis program is Public domain. 230 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒPlease do not alter it in any 240 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒway. If you use any of the 250 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒroutines, please mention me 260 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] ƒin the titles. Thanks,CJR. 270 REM" [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] [0x08] †------------------------------ 285 CLOSE#0:REM TEMP VERSION 290 ONERROR:CLOSE#0:OSCLI"SPOOL":VDU3:Z%=0:OSCLI"*EX. !BOOT":END 300 MODE3:VDU21:PROCass 310 VDU6,23;8202;0;0;0;19,1,3;0; 320 REM:REPEAT:PRINT"DRIVE TO READ FROM?":D$=GET$:UNTILVALD$<4:OSCLI"DR."+D$:OSCLI".":INPUT"FILE TO PRINTOUT?"$&A00:REM REMOVE IF FROM MENU 330 F%=OPENIN $&A00:?&A50=13:?&71=F%:!&72=0:!&76=0 340 PRINT"MARKED PRINTOUT? Y/N":IF GET$="Y":PROCmark ELSE PTR#F%=&E7 350 PRINTTAB(18)"Print out a teletext file by C.J.Richardson."'TAB(29)"Press SHIFT to scroll."'' 360 IFZ%=1PRINTTAB(21)"Prepare your printer and press a key.":REPEATUNTILGET:VDU2 ELSE VDU14 370 REM"*SPOOL newfile 380 REPEAT:CALLa%:PRINTTAB(40-LEN$&A00/2)$&A00:UNTILEOF#F%:CLOSE#F%:Z%=0:VDU3,15:*FX21 390 REM"*SPOOL 400 PRINT''TAB(23)"Press a key to return to main menu.":REPEATUNTILGET:OSCLI"EX. !BOOT":END 410 DEFPROCass:FORL%=0TO2STEP2:P%=&900 420 [:OPTL%:.a%:JSRl12:LDA&74:BEQl10:JSR&FFE7:LDA#0:STA&74:.l10:LDY&73:.l11:STY&73 430 JSRget:.l:LDA&70:LDY&73 440 STA&A00,Y:CMP#13:BNEl9:RTS:.l9:INY:CPY#80:BCCl11:LDY#80 450 .l3:DEY:TYA:BEQl20:LDA&A00,Y:CMP#32:BNEl3:.l21:STY&75:LDA#13:STA&A00,Y:.l20:RTS 460 .l12:LDA&75:BNEl4:LDA#0:STA&73:RTS 470 .l4:LDX#0:LDY&75:INY 480 .l5:LDA&A00,Y:STA&A00,X:INX:INY:CPY#80:BNEl5:LDA#0:STA&75:LDA#32:STA&A00,X:STX&73:RTS 490 .get:LDY&71:JSR&FFD7:BCSdone:STA&70:JSRl14:LDA&70:CMP#0:BEQget:CMP#128:BCClow:LDA#32 500 .low:CMP#32:BCSok:LDA#32 510 .ok:STA&70:CMP#32:BNErts:INC&72:LDA&72:CMP#1:BEQrt:CMP#42:BNEl2:DEC&72:.l2 520 CMP#40:BNEget:INC&74 530 .done:LDA#13:STA&70:JMPl 540 .rts:LDA#0 550 .rt:STA&72:RTS 560 .l14:LDA&70:CMP#96:BNEk:LDA#95:BNEk3:.k:CMP#95:BNEk1:LDA#35:BNEk3:.k1:CMP#35:BNEk3:LDA#96:.k3:STA&70:INC&78:LDA&78:CMP#40:BNEl13:LDA#0:STA&78 570 LDA&77:BNEl16 580 .l13:LDA&70:CMP#141:BEQl15:RTS 590 .l15:INC&77:RTS 600 .l16:LDA#0:STA&77:LDX#40 610 .l17:LDY&71:JSR&FFD7:BCSdone:DEX:TXA:BNEl17:RTS 620 ]:NEXT:ENDPROC 630 DEFPROCmark:A%=0 640 INPUT"Start string ";D$ 650 REPEAT 660 IFBGET#F%=ASC(LEFT$(D$,1)):T%=PTR#F%:PROCsrchstring 670 UNTILA%=1 OR EOF#F% 680 IF EOF#F%:PRINTD$;" Not found. (Q)uit or (C)ontinue":IF GET$="Q" GROO ELSE IF EOF#F% RUN 690 PTR#F%=T%-1 700 ENDPROC 710 DEFPROCsrchstring 720 L%=1:REPEAT: 730 A%=BGET#F%:L%=L%+1 740 UNTILL%>LEN D$ OR A%<>ASC(MID$(D$,L%,1)) OR EOF#F% 750 IF L%>LEN D$ A%=1 ELSE A%=0 760 ENDPROC