home *** CD-ROM | disk | FTP | other *** search
/ Compute! Gazette 1987 April / 1987-04.d64 / printshop-geos (.txt) < prev    next >
Commodore BASIC  |  2022-09-20  |  3KB  |  103 lines

  1. 10 ad=22528:poke53281,0:poke53280,0:print"[147]"
  2. 20 print"     [158][176][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][174]"
  3. 30 print"     [194]print shop to geos converter[194]"
  4. 40 print"     [173][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][195][189]"
  5. 50 forn=1to11:print:next:goto190
  6. 60 ff=0:print#15,"u1:2 0"+str$(t)+str$(s)
  7. 70 get#2,a$:tn=asc(a$+chr$(0)):get#2,a$:sn=asc(a$+chr$(0))
  8. 80 forn=0to7:print#15,"b-p:2,"+str$(32*n+2)
  9. 90 get#2,a$:ifa$<>chr$(131)then160
  10. 100 get#2,a$:tp=asc(a$+chr$(0)):get#2,a$:sp=asc(a$+chr$(0)):h$=""
  11. 110 get#2,a$:ifa$<>chr$(160)thenh$=h$+a$:goto110
  12. 120 ifh$<>di$then160
  13. 130 ff=1:kp=n:n=7
  14. 140 print#15,"b-p:2,"+str$(32*kp+30)
  15. 150 get#2,a$:sl=asc(a$+chr$(0)):get#2,a$:sh=asc(a$+chr$(0))
  16. 160 next:iftn=0thenreturn
  17. 170 ifff=1thenreturn
  18. 180 t=tn:s=sn:goto60
  19. 190 print"[145][145][145][145][145][145][145][145][145]  place print shop data disk in drive"
  20. 200 print"       press return[146] when ready..."
  21. 210 geta$:ifa$<>chr$(13)thengosub970:goto210
  22. 220 poke53280,0
  23. 230 print"[147]  are these graphics for a c[146]ommodore"
  24. 240 print"           or o[146]ther printer?";
  25. 250 geta$:ifa$="c"thensf=2:w=6:h=45:goto280
  26. 260 ifa$="o"thensf=3:w=11:h=52:goto280
  27. 270 goto250
  28. 280 nl=int(h/8+1)*8:print"[147]"
  29. 290 print"type file name or press return[146] for list":inputn$
  30. 300 ifn$=""thengosub680
  31. 310 open15,8,15:open8,8,0,n$:input#15,en,eb$,et,es
  32. 320 ifen<>0thenclose8:close15:print"[147]";spc(20-len(eb$)/2)eb$:n$="":goto290
  33. 330 print"[147]"spc(16-len(n$)/2)"loading "+n$
  34. 340 poke185,0:poke780,0:poke781,0:poke782,88:sys65493:close8:close15
  35. 350 print"[147]        place geos disk in drive"
  36. 360 print"       press return[146] when ready..."
  37. 370 geta$:ifa$<>chr$(13)thengosub970:goto370
  38. 380 poke53280,0:print"         saving photoscrap file"
  39. 390 open15,8,15,"i0":input#15,en,eb$,et,es:ifen<>0then1000
  40. 400 open2,8,2,"s,u,w":input#15,en,eb$,et,es:ifen<>0then1000
  41. 410 print#2,chr$(w)chr$(nl)chr$(0)chr$(2*w)chr$(0);
  42. 420 forn=0toh-1:print#2,chr$(128+w);:form=0tow-1
  43. 430 print#2,chr$(peek(ad+w*n+m));:next:next
  44. 440 print#2,chr$((nl-h-2)*w)chr$(0)chr$(w*nl/8)chr$(191)chr$(0);:close2
  45. 450 data80,104,111,116,111,32,83,99,114,97,112
  46. 460 p$="":forn=0to10:readx:p$=p$+chr$(x):next
  47. 470 open2,8,2,"#":t=18:s=1:di$=p$:gosub60
  48. 480 ifff=0thenprint"no photo scrap file":goto640
  49. 490 t1=t:s1=s:fs=256*sh+sl-1:t2=tp:s2=sp:k1=kp
  50. 500 t=18:s=1:di$="s":gosub60
  51. 510 print#15,"b-p:2,"+str$(32*kp+3)
  52. 520 print#2,chr$(t2)chr$(s2);
  53. 530 print#15,"b-p:2,"+str$(32*kp+30)
  54. 540 fh=int(fs/256):fl=fs-256*fh
  55. 550 print#2,chr$(fl)chr$(fh);
  56. 560 print#15,"u2:2 0"+str$(t)+str$(s)
  57. 570 print#15,"u1:2 0"+str$(t1)+str$(s1)
  58. 580 print#15,"b-p:2,"+str$(32*k1+3)
  59. 590 print#2,chr$(tp)chr$(sp);
  60. 600 print#15,"b-p:2,"+str$(32*k1+30)
  61. 610 print#2,chr$(sf+1)chr$(0);
  62. 620 print#15,"u2:2 0"+str$(t1)+str$(s1)
  63. 630 print#15,"s0:s"
  64. 640 close2:close15
  65. 650 print"[147]done"
  66. 660 print"    place geos[146] master disk in drive"
  67. 670 print"       hit restore[146] to reboot geos":end
  68. 680 open15,8,15,"i0":open2,8,2,"#":x=0:m=0:t=18:s=1:n=0
  69. 690 print"[147]  the graphic files on this disk are:"
  70. 700 print#15,"u1:2 0"+str$(t)+str$(s)
  71. 710 get#2,a$:tn=asc(a$+chr$(0)):get#2,a$:sn=asc(a$+chr$(0))
  72. 720 print#15,"b-p:2,"+str$(n*32+2)
  73. 730 get#2,a$:ft=asc(a$+chr$(0)):if(191andft)<>130thenn=n+1:goto810
  74. 740 print#15,"b-p:2,"+str$(n*32+30)
  75. 750 get#2,a$:fs=asc(a$+chr$(0)):get#2,a$:fs=fs+256*asc(a$+chr$(0))
  76. 760 iffs<>sfthenn=n+1:goto810
  77. 770 print#15,"b-p:2,"+str$(n*32+5):d$=""
  78. 780 get#2,a$:ifa$<>chr$(160)thend$=d$+a$:goto780
  79. 790 x=x+1:m=m+1:ifm=16thenm=0:goto840
  80. 800 print"   "+chr$(34)+d$+chr$(34):n=n+1
  81. 810 ifn<8then720
  82. 820 n=0:t=tn:s=sn:ift<>0then700
  83. 830 ift=0then860
  84. 840 print"        press return[146] to see more"
  85. 850 print"    type _ and press return[146] to abort"
  86. 860 ifx=0thenprint"        none":goto930
  87. 870 print"      place cursor next to name or"
  88. 880 print"   type name and press return[146] to load":inputn$
  89. 890 ifn$="_"thenn$="":goto920
  90. 900 ifn$<>""thenclose2:close15:return
  91. 910 ift<>0then690
  92. 920 print"[147]";
  93. 930 close2:close15:print"    place another data disk in drive"
  94. 940 print"       press return[146] when ready..."
  95. 950 geta$:ifa$<>chr$(13)thengosub970:goto950
  96. 960 poke53280,0:goto680
  97. 970 a=a+1:ifa>10thenpoke53280,2
  98. 980 ifa>20thenpoke53280,0:a=0
  99. 990 return
  100. 1000 print"[147]";spc(20-len(eb$)/2)""+eb$
  101. 1010 print"           resetting drive..."
  102. 1020 print#15,"uj":forn=1to1500:next:close15:close2:goto380
  103.