home *** CD-ROM | disk | FTP | other *** search
/ Loadstar 98 / 098.d81 / contdirprint (.txt) < prev    next >
Commodore BASIC  |  2022-08-26  |  3KB  |  123 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)open"
  27. 105 m[178]0:t[178]8
  28. 110 [129]i[178]0[164]3:[153][163]t)m$(i):[153]:[130]
  29. 120 [151]214,6[170]m[172]2:[153]:[153][163]t)""m$(m)"on"
  30. 130 [161]a$:[139]a$[179][177]"on"[175]a$[179][177]""[175]a$[179][177][199](13)[167]130
  31. 140 [139]a$[178][199](13)[167]180
  32. 145 [153][163]t)"open"m$(m)
  33. 150 [139]a$[178]"on"[167]m[178]m[171]1:[139]m[179]0[167]m[178]3
  34. 160 [139]a$[178]""[167]m[178]m[170]1:[139]m[177]3[167]m[178]0
  35. 170 [137]120
  36. 180 [145]m[170]1[137]200,300,500,400
  37. 200 [153]"loadopen    (NULL)ou will need your printer manual
  38. 202 print" in order to enter the following codes.
  39. 204 [153]" right$f you put a $ before the very first
  40. 206 print" entry, the program will expect the
  41. 208 [153]" numbers in left$val(NULL).
  42. 220 print"[154] [197][216][193][205][208][204][197]
  43. 225 [153]"open"p$(0)": 27 83 49    contor
  44. 227 print"[159]"p$(0)": $1b 53 49
  45. 230 [153]"cont valnter your printer's code for:
  46. 240 k=0:bb=0
  47. 250 poke214,16:print:print"[159]"p$(k)": ";:gosub50000:b$=q9$
  48. 252 ifleft$(b$,1)="$"orbb=1thenbb=1:goto280
  49. 255 j=0:fori=1tolen(b$)
  50. 256 ifmid$(b$,i,1)=" "thend(k,j)=val(c$):c$="":j=j+1:goto258
  51. 257 c$=c$+mid$(b$,i,1)
  52. 258 next:d(k,j)=val(c$):c$="":e(k)=j
  53. 259 k=k+1:ifk<5thenpoke781,17:sys59903:goto250
  54. 260 gosub1000:open8,dv,8,"@0:driver,p,w"
  55. 262 fori=0to5:e=e(i):print#8,e:forj=0toe
  56. 264 print#8,d(i,j)
  57. 266 next:next:close8
  58. 270 goto100
  59. 280 ifleft$(b$,1)="$"thenb$=right$(b$,len(b$)-1)
  60. 282 j=0:fori=1tolen(b$)step3:bb$=mid$(b$,i,1)
  61. 283 forl=1to16:ifbb$=mid$(h$,l,1)thenu=l-1:l=16
  62. 284 next
  63. 286 d(k,j)=16*u:bb$=mid$(b$,i+1,1)
  64. 287 forl=1to16:ifbb$=mid$(h$,l,1)thenu=l-1:l=16
  65. 288 next
  66. 290 d(k,j)=d(k,j)+u:j=j+1
  67. 292 next:goto259
  68. 300 sys52736,"t.content*",dv:w$(0)=right$(w$(0),len(w$(0))-2)
  69. 305 h=peek(252)*256+peek(251):g=int(h/2):gg=h-g*2
  70. 310 open4,4,7
  71. 312 fori=0to3:e=e(i):forj=0toe
  72. 314 print#4,chr$(d(i,j));
  73. 316 next:print#4
  74. 318 next
  75. 320 fori=0tog
  76. 322 print#4,w$(i);
  77. 324 print#4,left$(sp$,42-len(w$(i)))w$(i+g+1)
  78. 330 next
  79. 335 ifggthenprint#4,w$(h)
  80. 340 e=e(4):fori=0toe:print#4,chr$(d(4,i));:next:print#4:close4
  81. 350 goto100
  82. 400 open15,8,15,"r0:hello connect=hello connect":input#15,er:close15
  83. 410 ifer<>63thenprint"[147]":end
  84. 420 print"[147][144]load"chr$(34)"hello connect"chr$(34)",8"
  85. 430 print"run"
  86. 440 poke631,13:poke632,13:poke198,2:end
  87. 500 sys52224,"$:*",dv,0
  88. 505 h=peek(252)*256+peek(251)-1:g=int(h/4)
  89. 510 open4,4,7
  90. 512 fori=0to3:e=e(i):forj=0toe
  91. 514 print#4,chr$(d(i,j));
  92. 516 next:print#4
  93. 518 next
  94. 520 print#4,f$(0):print#4
  95. 522 fori=1tog+1
  96. 524 print#4,f$(i);
  97. 525 print#4,left$(sp$,20-len(f$(i)))f$(i+g+1);
  98. 526 print#4,left$(sp$,20-len(f$(i+g+1)))f$(i+2*g+2);
  99. 527 print#4,left$(sp$,20-len(f$(i+g*2+2)))f$(i+3*g+3)
  100. 530 next
  101. 535 open2,dv,0,"$:qw345":fori=0to33:get#2,a$:next
  102. 537 get#2,lb$:lb=asc(lb$+chr$(0)):get#2,hb$:hb=asc(hb$+chr$(0)):close2
  103. 538 print#4
  104. 539 print#4,hb*256+lb" blocks free"
  105. 540 e=e(4):fori=0toe:print#4,chr$(d(4,i));:next:print#4:close4
  106. 550 goto100
  107. 1000 open15,dv,15,"i":input#15,er,er$,a,a:close15
  108. 1010 ifer=0thenreturn
  109. 1020 print" "er$" - [195]heck your drive
  110. 1030 [153]" and press a key.
  111. 1040 geta$:ifa$=""then1040
  112. 1050 goto1000
  113. 10000 open15,8,15,"s0:contdirprint":close15:save"contdirprint",8:end
  114. 50000 q9$="":u9=53280:poke198,0
  115. 50010 geta$
  116. 50020 poke646,rnd(1)*15+1:print"[164][157]";:ifa$=""then50010
  117. 50030 ifa$=chr$(13)thenprint" ":return
  118. 50040 if(a$=chr$(20)andlen(q9$))thenq9$=left$(q9$,len(q9$)-1):goto50080
  119. 50050 iflen(q9$)>=20thent9%=peek(u9):pokeu9,1:pokeu9,t9%:goto50010
  120. 50060 ifa$<" "or(a$>chr$(127)anda$<chr$(160))ora$=chr$(34)then50010
  121. 50070 q9$=q9$+a$
  122. 50080 print""a$;:goto50010
  123.