home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 128 16 / q16.d81 / contdirprint (.txt) < prev    next >
Commodore BASIC  |  2022-08-28  |  3KB  |  126 lines

  1. 5 dv=peek(186):ifdv<8thendv=8
  2. 10 poke53281,0:poke53280,0:print"[147]"
  3. 15 gosub1000
  4. 20 sys57812"input a/d cc00",dv,0:poke780,0:poke781,0:poke782,204:sys65493
  5. 22 open15,dv,15,"r0:driver=driver":input#15,er,er$,a,a:close15
  6. 23 ifer<>63then30
  7. 24 open8,dv,8,"driver,p,r"
  8. 26 fori=0to5:input#8,e(i):e=e(i):forj=0toe
  9. 27 input#8,d(i,j)
  10. 28 next:next:close8
  11. 30 dimw$(300),f$(300):w=206*256:f=204*256
  12. 32 sp$="                                            "
  13. 34 h$="0123456789abcdef"
  14. 40 fori=0to3:readm$(i):next
  15. 42 data" [195]reate a printer driver "
  16. 43 data"  [208]rint [195]ontents [211]heet   "
  17. 44 data"    [208]rint  [196]irectory     "
  18. 45 data"    [209]uit the program     "
  19. 50 fori=0to4:readp$(i):next
  20. 52 data"  [211]ubscript [205]ode   "
  21. 53 data"    [197]lite [208]itch    "
  22. 55 data"  [195]ondensed [205]ode   "
  23. 56 data" [204]ine [211]pacing 7/72 "
  24. 58 data"   [210]eset [208]rinter   "
  25. 100 print"[147][129]          [212][200][197] [205][201][199][200][212][217] [204][207][193][196][211][212][193][210]
  26. 102 [153]"     len(NULL)(NULL)(NULL)val(NULL)(NULL)(NULL) atn(NULL)str$ str$right$(NULL)vallen(NULL)(NULL)(NULL)(NULL) (NULL)(NULL)right$(NULL)(NULL)val(NULL)"
  27. 103 [153]"list    (NULL)pecial version for (NULL)(NULL)atnstr$(NULL)(NULL)atn(NULL) 128open"
  28. 105 m[178]0:t[178]8
  29. 110 [129]i[178]0[164]3:[153][163]t)m$(i):[153]:[130]
  30. 120 [151]214,8[170]m[172]2:[153]:[153][163]t)""m$(m)"on"
  31. 130 [161]a$:[139]a$[179][177]"on"[175]a$[179][177]""[175]a$[179][177][199](13)[167]130
  32. 140 [139]a$[178][199](13)[167]180
  33. 145 [153][163]t)"open"m$(m)
  34. 150 [139]a$[178]"on"[167]m[178]m[171]1:[139]m[179]0[167]m[178]3
  35. 160 [139]a$[178]""[167]m[178]m[170]1:[139]m[177]3[167]m[178]0
  36. 170 [137]120
  37. 180 [145]m[170]1[137]200,300,500,400
  38. 200 [153]"loadopen    (NULL)ou will need your printer manual
  39. 202 print" in order to enter the following codes.
  40. 204 [153]" right$f you put a $ before the very first
  41. 206 print" entry, the program will expect the
  42. 208 [153]" numbers in left$val(NULL).
  43. 220 print"[154] [197][216][193][205][208][204][197]
  44. 225 [153]"open"p$(0)": 27 83 49    contor
  45. 227 print"[159]"p$(0)": $1b 53 49
  46. 230 [153]"cont valnter your printer's code for:
  47. 240 k=0:bb=0
  48. 250 poke214,16:print:print"[159]"p$(k)": ";:gosub50000:b$=q9$
  49. 252 ifleft$(b$,1)="$"orbb=1thenbb=1:goto280
  50. 255 j=0:fori=1tolen(b$)
  51. 256 ifmid$(b$,i,1)=" "thend(k,j)=val(c$):c$="":j=j+1:goto258
  52. 257 c$=c$+mid$(b$,i,1)
  53. 258 next:d(k,j)=val(c$):c$="":e(k)=j
  54. 259 k=k+1:ifk<5thenpoke781,17:sys59903:goto250
  55. 260 gosub1000:open8,dv,8,"@0:driver,p,w"
  56. 262 fori=0to5:e=e(i):print#8,e:forj=0toe
  57. 264 print#8,d(i,j)
  58. 266 next:next:close8
  59. 270 goto100
  60. 280 ifleft$(b$,1)="$"thenb$=right$(b$,len(b$)-1)
  61. 282 j=0:fori=1tolen(b$)step3:bb$=mid$(b$,i,1)
  62. 283 forl=1to16:ifbb$=mid$(h$,l,1)thenu=l-1:l=16
  63. 284 next
  64. 286 d(k,j)=16*u:bb$=mid$(b$,i+1,1)
  65. 287 forl=1to16:ifbb$=mid$(h$,l,1)thenu=l-1:l=16
  66. 288 next
  67. 290 d(k,j)=d(k,j)+u:j=j+1
  68. 292 next:goto259
  69. 300 gosub600:sys52736,"t.content*",dv:rem  w$(0)=right$(w$(0),len(w$(0))-2)
  70. 305 h=peek(252)*256+peek(251):g=int(h/2):gg=h-g*2
  71. 310 open4,4,7
  72. 312 fori=0to3:e=e(i):forj=0toe
  73. 314 print#4,chr$(d(i,j));
  74. 316 next:print#4
  75. 318 next
  76. 320 fori=0tog-g*(qq=2)
  77. 322 print#4,w$(i);:ifqq=2thenprint#4:goto330
  78. 324 print#4,left$(sp$,42-len(w$(i)))w$(i+g+1)
  79. 330 next
  80. 335 ifggthenifqq=2thenprint#4,w$(h)
  81. 340 e=e(4):fori=0toe:print#4,chr$(d(4,i));:next:print#4:close4
  82. 350 goto100
  83. 400 print"[147]":end
  84. 500 sys52224,"$:*",dv,0
  85. 505 h=peek(252)*256+peek(251)-1:g=int(h/4)
  86. 510 open4,4,7
  87. 512 fori=0to3:e=e(i):forj=0toe
  88. 514 print#4,chr$(d(i,j));
  89. 516 next:print#4
  90. 518 next
  91. 520 print#4,f$(0):print#4
  92. 522 fori=1tog+1
  93. 524 print#4,f$(i);
  94. 525 print#4,left$(sp$,20-len(f$(i)))f$(i+g+1);
  95. 526 print#4,left$(sp$,20-len(f$(i+g+1)))f$(i+2*g+2);
  96. 527 print#4,left$(sp$,20-len(f$(i+g*2+2)))f$(i+3*g+3)
  97. 530 next
  98. 535 open2,dv,0,"$:qw345":fori=0to33:get#2,a$:next
  99. 537 get#2,lb$:lb=asc(lb$+chr$(0)):get#2,hb$:hb=asc(hb$+chr$(0)):close2
  100. 538 print#4
  101. 539 print#4,hb*256+lb" blocks free"
  102. 540 e=e(4):fori=0toe:print#4,chr$(d(4,i));:next:print#4:close4
  103. 550 goto100
  104. 600 poke214,17:print
  105. 610 print"[159] [201]f you are printing [204][207][193][196][211][212][193][210] 128 #1
  106. 620 [153]" through #8, press 1open.  right$f #10 through
  107. 630 print" #16, press 2[159].
  108. 640 [161]a$:[139]a$[179]"1"[176]a$[177]"2"[167]640
  109. 650 qq[178][197](a$):[142]
  110. 1000 [159]15,dv,15,"i":[132]15,er,er$,a,a:[160]15
  111. 1010 [139]er[178]0[167][142]
  112. 1020 [153]" "er$" - lenheck your drive
  113. 1030 print" and press a key.
  114. 1040 [161]a$:[139]a$[178]""[167]1040
  115. 1050 [137]1000
  116. 10000 [159]15,8,15,"s0:contdirprint":[160]15:[148]"contdirprint",8:[128]
  117. 50000 q9$[178]"":u9[178]53280:[151]198,0
  118. 50010 [161]a$
  119. 50020 [151]646,[187](1)[172]15[170]1:[153]"tocmd";:[139]a$[178]""[167]50010
  120. 50030 [139]a$[178][199](13)[167][153]" ":[142]
  121. 50040 [139](a$[178][199](20)[175][195](q9$))[167]q9$[178][200](q9$,[195](q9$)[171]1):[137]50080
  122. 50050 [139][195](q9$)[177][178]20[167]t9%[178][194](u9):[151]u9,1:[151]u9,t9%:[137]50010
  123. 50060 [139]a$[179]" "[176](a$[177][199](127)[175]a$[179][199](160))[176]a$[178][199](34)[167]50010
  124. 50070 q9$[178]q9$[170]a$
  125. 50080 [153]""a$;:[137]50010
  126.