8-Bit Software Online Conversion

Printer driver - Listing

10DEFFNS="PDrv" 20MODE0 30PROCa 40PRINT"EPSON Compatible Printer Driv er by C.J.Richardson." 50PRINT'"The function keys are now pr ogrammed to turn print styles on and off ." 60PRINT"Function key turns style on. Function key + SHIFT turns style off." 70PRINT'" Shows as o n off" 80PRINT'"f0=Double height 90PRINT"f1=Superscript 100PRINT"f2=Italics " 110PRINT"f3=Undeline " 120PRINT"f4=Expanded " 130PRINT"f5=Compressed " 140PRINT"f6=Emphasised " 150PRINT"f7=Correspondence Quality 160PRINT"f8=Reversed " 170PRINT'"You can mix these styles" 180PRINT"Place the codes in print stat ements." 190PRINT"The codes show on the screen but are not printed out." 200PRINT"Try it now. Type something li ke:" 210PRINT''"VDU2:PRINT"" THIS IS DOUBLE HEIGHT. Notice the £. N    lics."":VDU3" 220PRINT''"You can incorporate PROCa f rom this program into your own programs. " 230PRINT"Then just put the codes into the PRINT statements as in the example a bove." 240PRINT'"The program PdrSTR will prin t out a function key strip for you." 250END 260DEFPROCa:IF ?&22B<&80 ENDPROC 270IF PAGE<>&1C00:PAGE=&1C00:CHAIN"PDr v" 280OSCLI"FX20,1" 290X%=&90:Y%=0:A%=10:FORl%=140TO149:?& 90=l%-92:CALL&FFF1:VDU23,l%,255-?&91,255 -?&92,255-?&93,255-?&94,255-?&95,255-?&9 6,255-?&97,255-?&98,23,l%+10,?&91,?&92,? &93,?&94,?&95,?&96,?&97,255:NEXT:REM SET CODES TO RECOGNISABLE 300OSCLI"FX225 140":OSCLI"*FX226 150": OSCLI"*FX227 160":REM SET F KEYS 310FORL=0TO2STEP2:P%=PAGE-&100 320[OPTL:SEI:LDA&22A:STA u+1:LDA&22B:S TA u+2:LDA#t MOD256:STA&22A:LDA#t DIV256 :STA&22B:CLI:RTS 330.t:CPX#3:BEQ v 340.u:JMP&0000 350.y:LDA#27:JSRs:LDA#82:JSRs:LDA#3:JS Rs:LDA#35:JMPs 360.z:LDA#27:JSRs:LDA#82:JSRs:LDA#0:JS Rs:LDA#35:JMPs 370.v:CMP#96:BEQy:CMP#35:BEQz:CMP#140: BCSw:JMPs:.w:CMP#160:BCC x:JMPs:.x:PHA:L DA#27:JSRs:PLA 380CMP#140:BNEa:LDA#104 390.a:CMP#150:BNEb:LDA#117 400.b:CMP#141:BNEc:LDA#83:JSRs:LDA#0 410.c:CMP#151:BNEe:LDA#84 420.e:CMP#142:BNEf:LDA#52 430.f:CMP#152:BNEg:LDA#53 440.g:CMP#143:BNEh:LDA#45:JSRs:LDA#1 450.h:CMP#153:BNEi:LDA#45:JSRs:LDA#0 460.i:CMP#144:BNEj:LDA#14 470.j:CMP#154:BNEk:LDA#20 480.k:CMP#145:BNEl:LDA#15 490.l:CMP#155:BNEm:LDA#18 500.m:CMP#146:BNEn:LDA#69 510.n:CMP#156:BNEo:LDA#70 520.o:CMP#147:BNEp:LDA#120:JSRs:LDA#1 530.p:CMP#157:BNEq:LDA#120:JSRs:LDA#0 540.q:CMP#148:BNEr:LDA#72:JSRs:LDA#27: JSRs:LDA#114 550.r:CMP#158:BNEs:LDA#116 560.s:JSRu:PHP:CLI:NOP:NOP:PLP:BCSs:RT S 570]:NEXT:CALL PAGE-&100:ENDPROC