@L}5 _$% l0$)$$Hȱ$ UhL" `e$$%`$%`  R@P!( L(1   Y I`  d  Ld M * @  $ % CC$$)%1 Udߥ$9%: !0 S$% DD˙`  }J)Lr d M * @  $ % CC$$)%1 Udߥ$9%: !0 S$%} DD˙`  }J)Lr J  ((  p L ()   J}L= ( L 0q A    IB JC;? D W } LL  ` W )LA!  ߰")-݆ p" } $G@LL 08`Q")<2Q0 -G$Ș݆ UL# ; p8(()(0ʥ)NQ` }$GȘ݆LU )L ݆ L GȘ ݆LL )W>Z   HH)H }p h  hyhy D L> L JJ    ! LA*` BF }7'8  M HN H` 8 Z  \LdJJ!"! GFE@F (!L }EE !E^ ^ E E7EȩEdE/EȩE  D } .L }  ;F d  ;?F7F? ( .   Z D LL d } . D  L    p  E` , d)  D L) 0BM݊L݉} ML  N݆ L NLML [ TEqEHȱEqEh 0Gȹ G} HLL GɛL  LFREE SECTORS G) *Gȩ GȽG GȌ*jj >G} C8jJ3j2CD( C202C ԠBX` N 1? l LlD:RAMDISK}.COMLu L1 L ;LHL  T`  `1  ɐ     `TU  } L ? .  t`GBJ ~DEHI B V0dV!}QDEHI VF9 ,0 ,0 s0hhL  L` H hDHEh"}DEL8HI4 0 HI,0 0  9 .G VLO#},0 L4*IJ`llD1:AUTORUN.SYSNEED MEM.SAV TO LOAD THIS FILE.D1:MEM.SAV J y08 B|DEHI$} V0 0`B;DEL`?<0LV`@ʆ v s? F0Ξ05: [ BDEHI%} VY8 B V  @  /DE `E:D1:DUP.SYSERROR-SAVING USER MEMORY ON DISKTYPE Y TO &}STILL RUN DOS B;DE J  (` 9 V⪍ ઍ  -'}LLu ÝDEHILV 9 .l 9 .l  `` s$B BH(}I|DE V BLV nB,DE JLV B V BLVDEIʩ BꭝLu  } 3E:}DISK OPERATING SYSTEM II VERSION COPYRIGHT 1984 ATARI CORP.A. DISK DIRECTORY I. FORMAT DISKB. RUN CARTRIDG*}E J. DUPLICATE DISKC. COPY FILE K. BINARY SAVED. DELETE FILE(S) L. BINARY LOADE. RENAME FILE M. RUN AT ADDRES+}SF. LOCK FILE N. CREATE MEM.SAVG. UNLOCK FILE O. DUPLICATE FILEH. WRITE DOS FILES P. FORMAT SINGLEL !N',}#"&))9(&*)/h)''-&؆莟R'S  vL/ˢ L }Insert DOS 2.0s, type Y Λx -}DEfHI 1莏#q! @ y0ɛ8A0,' ȅ 1 1ild! 1L!NO SUCH ITEMSELECT.} ITEM OR FOR MENU! 0 .z:*{}.|{ 1 0 0JB 18L%|DL/}%DIRECTORY--SEARCH SPEC,LIST FILE?[# 0 0 &|D3" 1L!NOT A DISK FILEN !B 1L!E# 1 !BD0}ED:}:1BJ|DE 1DEBHI 1 h0ߢ 0.1}  0?詛 1 y0YЛ 1 ;#L" ;#L! BL1TYPE "Y" TO DELETE...DELETE FILE SPEC2}COPY--FROM, TO?OPTION NOT ALLOWED736 FREE SECTORS COPYING---D1:DIRECK.COMl# 0|D .L/%#3}##JB|DE 1BHID#E 1#0: B 1L!#͑### B 1#c$0SY4}S1}:## # # .#Ƚ# # 𩛙## 1,#PD#ELJ- <.BJD#E 5}1 1HH 0hh|DL%1}:̳# L% #D#EL% 1 0 . .0O% 1L!WILD CARDS NOT A6}LLOWED IN DESTINATION 0 <.|K}N 2 FORMAT. t* 5) 1L!`) 0NΞ 0 L1) 1 L!BAD LOAD FILELOAD FROM WHAT FILE?) 0 ?}0#B 1L!WHAT FILE TO LOCK?) 0 0$B 1L!WHAT FILE TO UNLOCK?DUP DISK-SOURCE,DEST DRIVES?TYPE "Y" IF OK TO US@}E PROGRAM AREACAUTION: A "Y" INVALIDATES MEM.SAV.FE! +L1   `*  70 2 2A} 0.* 1 y0 0)INSERT BOTH DISKS, TYPE RETURN^, 1 y038逍 N, 1L! ,B}C, t*  Lx+, 0 ^, 1 y0 , ,0,0 ,L+ ,I0 ,Vǭ0C}Ξ, 0 }, 1 y0C,ШC, 0K'!" H H 'h h Lx+!EF 5L1L!D,I,HhD}` NOT ENOUGH ROOMINSERT SOURCE DISK,TYPE RETURNINSERT DESTINATION DISK,TYPE RETURNE}`  `8 rL1`-* 1P* 1 y0Y`hhL!NAME OF FILE TO MOVE?- 0 0|DL% <.F},^ 1 70 0 .@L# .BJ 1  DEHIB V L1 ,} 1 70,L.  G}JB|,#P#DE 1 HI BDEHHII 1 B 1 ,^ 1 70,0La- B V,#PH},^ 1 70 0L#L!-* 1P* 1 y0Yj383}mm ݭI}}`8}``|* ? ɛ,`|:-)| / 1L!`DESTINATION CANT BE DOJ}S.SYS0 0H{ 24Δ 28/L!/) 2 Π 2 0 ξK}hAΞB,0 J 1 BDEHI,HÝDE 1HIHIDELSAVE-GIVE L}FILE,START,END(,INIT,RUN)O S0 1`BDEPHI V` S0H 1 L!M}0 0 1L~0`PLEASE TYPE 1 LETTER,0`hhL! 70 1L0L<1 ,;ɛ7,"ɛ:ݦ1ݥN}A"D|ݤD|ȩ:|ȩ|ɛ,,(/+.ީ1 1,ɛ`轤{NAMEO} TOO LONG B VL!` L1I H1EΝDL1|mDiE` V0`8d/8 i:222 1 LP}!ERROR- 138ɛ+,' 20*.. өr2 1``2TOO MANY DIGITSINVALID HEXAQ}DECIMAL PARAMETER800 0 8 00`,0'D800 H,ɛh`2L1NEED D1 THRU D8uR} ECIMAL PARAMETER800 0 8 00`,0'D800 H,ɛh`2L1NEED D1 THRU D8u\](DDDDDDDDDDD1D1D1D1D2MDCOLSMLOSSCRRCRCCRSPODLLDTT} @@U} !V}"#$%&'()*+,33*** ĠӠҠW}Ӯ *** 6-6-@'6-@36-@?6-@K6-@W6-@c6-@o6-@X}{6-@ 6-@6-@6-@6-@6-@ 9@)<@,;@,9@,"Y}AR(>:A%,"-: A A! A+ A :68,-AB( AAdAU2F:Z}B2y,"A<F:B2y,"AFF:B2y,"@@PF:B2y,"+ZF:B2y,"A [}d 6-R:,  @AnT:,"Ax F:Ad,"AU@P6-F:Ad,$AdAU\}6-+$+"@,,%+$+"@X,,%+$+",,%+$+"@b,,%+$+"@,,%+$+"@5,,"AҠ]}՛77AAA A0A@AP٠ěN B-@)J6-?:C:,<8<,<8<,<^}8<,<8<,<8<,,N 5 22!2+25 @P+Šқ, -%(>:,6S+6-%++_}",$+ @),,&++",$+!,,7"@E6-&$+!,S"A`@1"@#6-%$+ @",1"ApJ3`}"@)6-&@$+!@,3 ATE"@)6-%@$+ AU,;6-$+ @!,E A^ Aa}h26-%$+ @,(6-F:A6%,2 Ar"6-&$+!,"6-F:A6%,|%"@!6-A!% Ab}"@!6-AUK -%-6-F:@,%F:@,$AV<6-F:@,K6-F:@,N6-%+$@@,%+c},"6-F:,>6-&+@d$+"@,,D(N @PΠěL68<,-$68<,-068<,-$%$+!,;6d}8<,-L68<,-$+!,W-@"-%(|# +-%1(96-%E"@0K6-W6-@"K -%-e}6-F:@,%F:@,$AV<6-F:@,K6-F:@,N6-%+$@@,%+,"6-F:,>6-&+@d$+"@,,f}D(N @PWŠӛX1 6-%6-$+ ,#-@'(1 @PbJ 6-%6-$+ @,)-@g}0( <-@@(J @PlD 6-%6-$+ ,#-@*( 6-@:(D @PvJ 6-%6-$+ h}@a,)-@20( <-@2@(J @PY 6-+$,6-%+",+6-$+ A),7-@2?( K-@2i}O(Y @P; 6-%6-$+",6-#6-/6-@";6-A$5 "-(SND#-@6+(5 Aj}% -(-@6%(NTS;-@"-%(|# +-%1(; @PŠ՛. -k}.( - Play ̫ - Print ++(# - New ԫ - End>,($ ԫ- Save (Any Key) l} >AdAU F:Ad,"AUA0ZAdAU-6( oice:  B-@"Z( um}stain:  E"( istortion:  .-@"E( ontrol:  B"( oudness:  .-@n}"B(otes/Sound  @PŠϠ˛ B @P) D:SOUND.SUB56-A B6. DATA o}*91( DIM ML$(54):RESTORE 2030>:AU,96-%4W5( ML$=>:@4,>:@4,>:AU,=6-%W(p} FOR L=0 TO 29:>``(JREAD V:READ P:READ Q:READ C:READ S:U=USR(ADR(ML$),V,P,Q,C,S):NEXT L:RETURN>:AU,H5 6-q}6--! A`)6-%16-%5 R @P\ 6-%(@fT -D(8<,,8<,,r}8<,,8<,,8<,J T(,p (>:AU,$ԠĠ6 @P33!*** SOUND EFFs}ECTS EDITOR DATA ***63A3 1. Voice x 2!32. PitchA33. Distortion x 16 + VolumeB&34. POKE 53768 (AUDCTL - $D208t})?35. Sustain (Jiffies)B3-@)@@3DATA 8<,,8<,,8<,,8<,,8<, u} @PԠΛU 6-6-6-6-!6-'6--6-36-?6-A$KAU A!W -.( ov}ice:  ustain: 2 W( istortion:  ontrol: 0 ''( oudness: 6 otes/SoundD-@"w}6--@(||||||||||||||||||||||||||||||D % -(-@6%(NTS$O 6-6-@"-%#(x}1-@)9-D68<,-H L O$ŠΛ3 +@00%0-03-?;@0y},56.SOUND effects ?#APP-@)"""!"%";6-?:C:,<<<<<,L(7%<%z},P *( ((*( , 22%-A) ,$GG0,34,143,1,5,0,17,143,2,20,{}0,17,138,2,5,0,17,135,2,5,0,17,132,2,5NN0,17,130,2,30,0,85,97,64,20,0,119,98,64,20,0,85,99,64,20,0,119,100,64,20RR0,8|}5,101,64,20,0,119,102,64,20,0,85,103,64,20,0,119,104,64,20,0,85,105,64,20SS0,119,106,64,20,0,85,105,64,20,0,119,104,64,20}},0,85,103,64,20,0,119,102,64,20 OO0,85,101,64,20,0,119,100,64,20,0,85,99,64,20,0,119,98,64,20,0,85,97,64,20NN0,119,97,~}64,20,0,85,97,64,20,0,119,97,64,20,0,85,97,64,20,0,119,97,64,20wԠśx4 #A-@"-A6%1} 4$660,121,108,96,91,81,72,64,60,53,47,45,40,35,31,29 Ԡ̤? #A;@T,(-@T,"867,.>}:,< ?$UU104,104,104,170,104,104,133,203,104,104,133,204,104,104,133,205,104,104,168,169JJ0,157,0,210,157,1,210,14}1,8,210,133,20,165,203,157,0,210,165,204,157551,210,165,205,141,8,210,196,20,144,2,176,250,96ԠРٛ# +}AR##A pI-A$Ah"!% 7AIA@M%6-F:A`,%F:Aa},$AV=-%@%@&IA0M 9A'A@9BBA2 -2($}Ӯ96-AU-@"#-'(56-&@9  P #A"-@!#"}/-@63(7 I-@6@"M(P$dd72,138,72,166,208,189,27,4,141,10,212,141,24,208,232,224,16,208,2,162,0,1}34,208,104,170,104,64 ::18,20,18,22,18,20,18,22,18,20,18,22,18,20,18,20,18,04E8,"AB#A!*-@."}768,-; E A">5518,20,18,22,18,20,18,22,18,20,18,22,18,20,18,22H#-@68,-8,%# LA}8,&&A4-@EAQ%8,I L$D:SOUNDEDT.BAS@68,-8,%# LAUVcwVOVOICPITCDISCNTSUSTAI..*** ĠӠ }ҠҠ ***? #A 06-@?Change to volume value if differentI-@@0",6-P:'@ },0"4"I6-P:+&,'@,!" "2!B7h@ F:@ , A   } D:SOUND2.BAS-P:+&,'@,!" "2!B7h@ F:@ , A    dX;------------------------nX;SYSTEM EQUATES FILE FORxX;ATARI HOME COMPUTERSX;------------------------X; X;}DISK I/OX;DSKINVS SIOVYDDEVICDUNIT;;D: UNITDCOMND;;D: commandDSTATSDBUFLO};;sector bufferDBUFHIDTIMLODBYTLODBYTHI DSECLO ;;sector #"DSECHI ,X;6X;CI}O ROUTINES@X;JCIOVV;;CIO vectorTICCOMB;;command^ICBALD;;buffer addressh ICBAHErICBLLH;;buffer }len| ICBLHI AUX1J AUX2K RUNADINITADX;X;SCREEN HANDLER/INTERRUPTSX;VDSLST;;DL}I vectorVBREAK;;BRK vectorVKEYBD;;keyboard vecSRTIMR+;;key repeatSDMCTL/;;DMA controlSDLSTL}0;;display listPCOLR0PCOLR1PCOLR2&PCOLR30COLOR0:COLOR1DCOLOR2NCOLOR}3XCOLOR4bCHBAS;;char setlSETVBV\vSYSVBV_XITVBVb NMIENԔVCOUNT ԞCHBASE } WSYNC Բ CHACTCHACTLCRSINHCHRSET;;ROM charactersX; X;MISC.X;CONSOL;;conso}le keys RTCLOK  CH MEMLO SHFLOK*WARMSVt4COLDSVw> LBUFFH EOLRX;\X;Device }VectorsfX;pHATABSzEDITRVSCRENVKEYBDV PRINTV0CASETV@X;X;PAGE ZERO LOCATIONS}X; CASINI TRAMSZ WARMST BOOT?  DOSVEC  DOSINI  POKMSK BRKKEY SOUNDRA$ }CRITICB. ATRACTM8 KEYDEFyB LMARGNRL RMARGNSV ROWCRST` COLCRSUj SAVMSCXt RAMTOPj~X;X;FL}OATING POINTX; FR0Ԧ FREڰ FR1 FR2 FRX EEXP NSIGN ESIGNFCHRFLG DIGRT} CIX  INBUFF RADFLG AFP( FASC2 IFP< FPIF ZFR0DP ZF1FZ FSUB`d FA}DDfn FMULx FDIV(ۂPLYEVL@݌ FMOVEݖ EXPݠ EXP10ݪ LOG޴ LOG10޾X;X;STICK, PAD}DLES, TRIGGERSX;PADDL0pPADDL1qPADDL2rPADDL3sSTICK0xSTICK1yPTRIG0|"PTRI}G1},PTRIG2~6PTRIG3@STRIG0JSTRIG1TX;^X;AUDIO CONTROLhX;r AUDF1| AUDC1҆ AUDF2}Ґ AUDC2Қ AUDF3Ҥ AUDC3Ү AUDF4Ҹ AUDC4AUDCTL SKCTLX;X;P/M GRAPHICSX;}PMBASEGPRIORoHPOSP0HPOSP1HPOSP2&HPOSP30 M0PF: M1PFD M2PFN M3P}FXHPOSM0bHPOSM1lHPOSM2vHPOSM3Ѐ P0PFЊ P1PFД P2PFО P3PFШSIZEP0в}SIZEP1 мSIZEP2 SIZEP3  M0PL M1PL  M2PL  M3PL SIZEM ;;missile sizeP0PL} ;;player/pf  P1PL  P2PL  P3PL*COLPM04COLPM1>COLPM2HCOLPM3RCOLPF0\CO}LPF1fCOLPF2pCOLPF3z COLBKЄGRACTLЎHITCLR>COLPM2HCOLPM3RCOLPF0\COMLgfffffff>`<|fl0fF68of;p88pf< 80 0 ~~`}0 0```nf>ff~fff~~f<flxxlf`````~cwkc}cfv~~nfgggogsss>ggggggfl7g<~}~<0~0 ~ ρ<>f>``|ff|<```<>ff>>ff>|``|fff8<<``lxlf8}<fkc|ffffff>|f```>`<|~ffff>fff<ck>6f< x~ 0~}`p||p`pppB#A#/,2/7&2%%}~}@ ` @`LOAD FILE:SAVE FILE:PRINT DEV:FIN}D WHAT?REP. WITH:DIRECTORY FOR DRIVE [1-2-3-4-8]?DIRECTORY PAUSED - PRESS A KEYDIRECTORY FINISHED - PRESS A KEYDIRECTORY} ERRORREPLACE STRING - Y/N?QUIT EDITORERASE MEMORYPRINT TEXTSAVE I/O ERRORLOAD I/O ERRORPRINTER ERRORPage # !2%9}/5352% 9.WORD COUNT: 00000E:P:12348D1:D1:*.*TEDIT a0rogram4ext%ditor7ritten"y "ryan03chappelc }ANALOG#omputing 0ressa+ey `{} ~   ڨ­6Z>t1&1*dwǪ=CԪ}ܭ4үw`@`OK`''s` ɛ GM`~HЭ }hyɀɁ IL*ɂ I@L*Ƀ@ЬɄ `Ʌ🥒@a { LKœE`Ȅ 嶭,}- 嶭67LbHHB ԍhh@Ј报 I?XL_䥍   a}`Ȅ ܦȄ L Υu *)[8 Y 8` `s  aLhhb \_ \@Ԣ B VB} JKDE Vl LM`   0*DE8吝H呝I 0 ƪL   *ƪL}`ˠ   0%  a   ƪL*`ĥ K0ߥą 嶭i ʥi ˥i ̥å}ɛ S0 K0 0𭥝 KLީƪL   0Q HI 0;H8HII}H}I} ƪ LM  ƪL*ʆ8傅``` 挥ŇeiLᵥLᵩ}8ő ML dL`I`Hȱh`8呅Ɖ扑`} eLᵩ RL e`eeɟhh`ee8岅峅 ee``e}ϫΫeҫѫ褶 ϫҫ`ĸ⥶`Lᵥƌ}ƋL  G & b` G &Lb8吅hh``8IeIe8崅嵅 ⫥8弅彅`}8剪Hhɛ`"} GLh` } P`I` Ԫyi饇Ō  ŋ}L ML d}iHHmi MhhŀL dʥ8Lf ŀ}L Ԫ 򳄂`8傅` 来L  Ǫ8内88内 `8必} wLᵥŇ ee8崅嵅8崅嵅 8弅彅`}֠  .`, ]  o ᠤ  .` ꮥ [ Lخ Gш 扥ŇDe}ił僐)8¥ ᵠI MI``8…aee8崅嵅淥ū} 8 e GīeiLᵠ)?! ;I@L w`Fű ȱŘ8e}i PH) ihHhݩ S08内ũ`ᠥ  ɛ G_L*} Y0Р)` ܰ` Ұ) `e扥8内`` 檢B*DEJ}KLV BLV*© w *Ƭ8`)x~ ƫ ԤXYɜ𿤫ɛ GX} L7ɛX`XY` .hhL::* *ɛ*ESD*`B}DELVɛ{a8 i@` BDEPHILV w -0来> - - -ĩ`젤  *}`*  M  ƪL* ܦiiƅ /0Mɛ Gƥ 来ii}L˲  *젤 L,  * ƪLܦBDEHILVii8吅})`&戱)%ȄĂei&@Lʳi(L{`Ő ő}`8ő`&%eiŌإŋ` Y` Y`H****)h)`ة"}/ \ \ԩ01 Gyzyz ,ƹ)&&&iE j} M 1Ь$)a{8 A [8@EL)|0 gh M}L´捥ɛ)x0L´ ɛ`H` *h G M8内 ii L´ /8嘥噰8}吅 M8勅包mi ML`88吅 `8内}``T `&u` ضi`H)hJJJJ`}Ȑ 8L d8d 8 iii`ꝿ( 讀i(i}L*8内凅 A` iii`ꝿ( 讀i(i%=/dEInX;------------------------xX;X;A Simple Text EditorX;X;By: Bryan SchappelX;X;Written for: DEEP }BLUE CX;X;------------------------EOLCHAR`;;return charTCOMS;;# of commands-1 ILEGSTXTEND}X;PASSPASS PASS>D:SYSEQU.M65",X;6X;PRINT macro@X;J PRINT T Q>4 ^ %>5 h LNPRIN}Tr|X;X;BUMP macroX; BUMP #  H@BMP # @BMPX;X;---------------X;Zero Page Usage}X;---------------X;CURX;;cursor XposCURY;;cursor Ypos& TEMP0 BOTSCR: MEMPNTD TEXTP}N CLOCKXCURMEM;;cur pos in membFILE?;;file flagl MEMMAXvMEMST;;memory startOLDC;;keycode}OLDAC;;ascii convertINVS;;inverse flagCAPS;;caps flagSAVXI;;X saveDLIDX;;DLI indexTOPLN};;upper lft scrSCR;;screen adrWLEN;;word lengthLINES;;# linesLO;;Work VariablesHI;;for }INTEGER toWORKL;;BCD conversion WORKH  BCD LO1  HI1*HNUM;;hex buffer4PAUSE?;;VB paus}e>CEND;;input lengthHIPUT;;input flagRIODIR;;i/o direction\CHARUNDR;;char savefINSMODEp INSLE}Nz FROM DESTMOVELEN ENDPOS INFLG CBAS GOBLENCONFLAG SAVCURSLEN};;srch length FPOSPAGENUM LPLEN COLSI ENDZPG EI$X;----------------.X;Start of Prog}ram8X;----------------BX;L SCMEMVX;`;;start of codejPSTART ;;save addr.tX;~ !INIT>D:TEXT2.M65}X;------------X;Display ListX;------------X;DLIST p=p=p=B SCMEM ==== ====} ==== ====  MYMEM  ===A DLISTX;----------------(X;My Screen Memory2X;----}------------<X;F5MYMEM A COL: 02 ROW: 00 FREE: 00000 AP3LN1 A AZ3}LN2 A AdCOMLNLN1 nX;xX;Special Key CodesX;KEYS ==== }====~ }==== X;X;Convert TablesX;A2I @== =`I2A  =@==`X;X;DLI Colors}X;DLICL =X;X;Text and Misc. Data"X;,LOADM ALOAD FILE:A=EOL6SAVEM ASAVE FILE:A=EOL@PRNTM APRINT} DEV:A=EOLJFINDM AFIND WHAT?A=EOLTREPLW AREP. WITH:A=EOL^2DIRMS ADIRECTORY FOR DRIVE [1-2-3-4-8]?A=EOLh0DIRP}S ADIRECTORY PAUSED - PRESS A KEYA=EOLr2DIRFN ADIRECTORY FINISHED - PRESS A KEYA=EOL|!DIRER ADIRECTORY ERRORA=EOL}'REPLM AREPLACE STRING - Y/N?A=EOLQTEXT AQUIT EDITORA=EOLERASE AERASE MEMORYA=EOLPTEXT APRINT TEXTA=EOL} SAVER ASAVE I/O ERRORA=EOL LOADR ALOAD I/O ERRORA=EOLPRTER APRINTER ERRORA=EOLPAGEN APage # A=EOL }SURE? AARE YOU SURE - Y/N?A%WORDTXT AWORD COUNT: 00000A=EOLEADR AE:A=EOLPDEV AP:A=EOLDIRNUMS A12348A}D1TXT AD1:ADIRTXT AD1:*.*A=EOLX;&X;Intro Text0X;:ITXT =ATA==AEDITAD A - a Program TextAN A Ed}itorAX ==b AWritten By:Al == v ABryan P. SchappelA == A(c) 1986 A AANALOGA A Comput}ingA ==  A- Press a Key -A ;;end of textX;X;Illegal charsX;ILLEG =`={=}X;X;Command T}extX; CMDTXT  ===== ==  ~====* =====4 ==== => == ==}= HX;RX;Command Addresses\X;fCOMADR LOAD;;^Lp SAVE;;^Sz TOP;;^T BOTTOM;;^B UPSC;;^U DNSC;;^D} CLEAR;;^C PRINT;;^P QUIT;;^Q CHRDEL;;DEL-BS UPLN;;^- DNLN;;^= GOLEFT;;^* GORIGHT;;^+ CTRLDE}L;;^DEL-BS INSCHAR;;^INS  BLINE;;^A  UPWORD;;^W  ENDLN;;^Z$  REVERSE;;^R.  ADD255;;SH-INS8  ADDTAB;;TABB } PARSE;;^OL HOME;;^HV  IMODE;;^I`  DEL2CR;;SH-DELj  KSPACE;;^Et FIND;;^F~  CONVERT;;^K or ^CAPS  DODIR;;^X}  CNTWORD;;^N  MANUAL;;^M X; X;-------------------- X;Start of Subroutines X;-------------------- X; X;Clear} Main Text Screen X; CLRSCR%> C CLR1PSCMEM8 PSCMEM8 PSCMEM8 3( HCLR12 %>< CLR2PSCMEM}8F 1P ICLR2Z :d X;n X;Clear Entry Windowx X; CLRWIN%>O CLWQ> CLRWPLN18 1 ICLRW : X; X;Clear Ot}her Line X; CLRW1%>' HCLW X; X;Clear Qline X; CLRW2%>' Q>" CL2PLN28, 16 ICL2@ :J X;T X;Print }line routine^ X;h LNPRINTPLNLr 'LNL| CLRW1 %> LNLQ8 R>EOL FLNLV ASC2IC PLN18 3 H}LNL LNLV: X; X;Get Key Routine X; GETKEYQCH R> FGETKEY GETKEY1$>& &CH0 POLDC: $>~D 5N CLKI}T&CONSOLX QVCOUNTb CLKWTRVCOUNTl FCLKWTv 0 0 ICLKIT 7 K0? )> DK1 %> K1Q@KEYDEF7 POLDAC }R> FGETKEY R> HK2 QINVS N> PINVS !GETKEY* K2R>4 HK3> QCAPSH N>@R PCAPS\ !GETKEYf K3}R>p HK4z Q>@ PCAPS HGETKEY K4R> HK5 Q> POLDAC : K5R> FGETKEY QOLDC R>@ EK6 Q}OLDACR>aDK6R>{$EK6. QCAPS8FK6B LOLDCL!K0V K6$>` K7QKEYS9j ROLDACtFK8~0IK7 K8FK}9 QOLDAC NINVS K9POLDAC:X;"X;Vertical Blank Cursor HandlerX;Deferred ModeX;VBLANK1%CURX3'}LO  CALCNM QNBUF PMYMEM ( QNBUF2 PMYMEM < QCURYFPLOP CALCNMZ QNBUFd PMYMEMn QNBUFx P}MYMEMVB1.X!XITVBVX;X;Display List InterruptX;DLI5A5 $DLIDX HGDLIC QINSMODE FGDLICQ}>B HDLIADGDLICQDLICL9DLIADPWSYNC PCOLPF2" #DLIDX,76>@7J9TX;^X;Immediate Mode VBLANKhX;rVB}LANK2Q>| PDLIDX%>VBL2.1QCOLOR08 PCOLPF081 IVBL2.1 QPAUSE? HVBL2.X #CLOCK QCLOCKR> H}VBI2.2QCURCHRN>PCURCHRQ> PCLOCK&VBI2.2QIPUT0 FVBL2.X: %CENDDQ>?N PCOMLN8XVBL2.X!}SYSVBVbX;lX;Erase FilevX;CLEARQFILE?FCLLPRINT ERASE YESNO DCLEAR2CLL:CLEAR2%> 'FILE?} 'MEMST3 'CURY 'CURX CLRSCRX;  %MEMLO3  'MEMST*X;4 ERASEMEM>X;H !CLRWINRX;\ X;YES}/NOfX;pYESNO CLRW2z%>YN1QSURE?8 PLN281IYN1YN2 GETKEYM>R> [DUPC;S>  UPC }R> Y FGOTY CLRWIN;:GOTY CLRWIN$,.:8X;BX;Quit EditorLX;VQUITPRINT QTEXT` YESNOj DDOQUIT }t !CLRWIN~ DOQUIT77Q> %>4XITVBV $>5XITVBV SETVBVQ> %>4SYSVBV $>5SYSVBV SETVBVQ>@ P }NMIEN$>Q>  PICCOM CIOV$>(Q>2 PICCOM<Q> F PAUX1P &AUX2Z Q>4EADRd PICBALn Q>5EADRx P }ICBAH CIOV !@DOSVEC:X;X;Go To TOP of textX;TOPQMEMST PCURMEM PTOPLN QMEMSTPCURMEM P }TOPLN !SCRDRAWX;#X;******************************X;INCLUDE SubroutinesX;">D:TEXT3.M65,>D:TEXT4.M656}X;@X;JX;Convert ATASCII to ICODETX;^ASC2IC BITERh LA2I9r $SAVXI|:X;X;Convert ICODE to ATASCIIX;}IC2ASC BITER LI2A9 $SAVXI:X;X;Ready CharacterX; BITER5U?U?U?U?M>& &SAVXI0>:7D}M>N:XX;b"X;#############################l"X;Program Execution Starts Herev"X;#############################X; I}NIT-Q> PCLOCK PINSMODE PINVS PPAUSE? PIPUT PCAPSQ>" PSDMCTLQ>%>4VBLANK1$>5VBLANK1 } SETVBVQ> %>4VBLANK2*$>5VBLANK24 SETVBV> Q>4DLIH PVDSLSTR Q>5DLI\PVDSLSTfQ>p PNMIENzQ>} PCOLOR2 Q>4DLIST PSDLSTL Q>5DLISTPSDLSTL CLEAR2 QKEYDEFLKEYDEF HINSETQ> PKEYDEF}PKEYDEFX;INSETQ>5MYSET PCHBASGOINT INTRO;;call intro$X;. MAIN%>8 'INFLGB Q@CURMEM7L PCHARUN}DRVIBLN` "INFLGj BLNM>t PCBAS~ 'CBAS TCBAS UCBAS TCBAS UCBAS TCBAS UCBAS QCBAS}, O>5MYSET PCBAS%>CCHRMQ@CBAS7 NINFLG  PCURCHR81 ICCHRM(MAIN2 SHOFREE2%><Q>F }P@CURMEM7P SCRDRAWZ WAITMQCHdR>n FMAIN2xX;HAVKEY GETKEY1>;;SAVE KEY%> 'INFLG QCHARUNDR P@}CURMEM7A;;RESTORE KEY%> 'CONSOL %CONSOL)> HHAVK1A ICTRAND%> 'INFLG"CTRANDM>,R> a6} DCHKRN@ R> zJ ECHKRNT;^S> h CHKRNR> Ar DHAVK1| R> Z EHAVK1;S>@ NINFLG !NOTEOLHAVK1%}>TCOMS;;# COMMANDSAM>R> DCMDCKACMDCKRCMDTXT8 FGOTCOM1 ICMDCK GJUSTCHR& GOTCOMC0T?:}?D QCOMADR8NPCMDJSRXQCOMADR8bPCMDJSRlCMDJSR vQ> PIPUT CLRWIN SCRDRAW !MAINX;}JUSTCHRQFILE? HJCHAR #FILE?JCHARQOLDAC R>EOL FJCH2M> %>ILEGSJCHTRILLEG8  FJCHI1  IJCH}T* GJCHTST4JCHI!MAIN>JCHTSTR> H DJCHIRJCH2QOLDAC\ R>EOLf HNOTEOLp Q>EOLCHARz NOTEOL5%> Q@CURM}EM7 R>EOLCHAR FDOINS QINSMODE FNOTINSDOINS INSCHAR NOTINS7 ASC2IC%> P@CURMEM7 SCRDRAW;} QCURMEM SMEMPNT PTEMP$QCURMEM.SMEMPNT8 LTEMPB DINCCURL QCURMEMVO>` PMEMPNTjQCURMEMt }O>~PMEMPNTX;INCCURBUMP CURMEM CHECKMEM !MAINX;X;Check Memory RoutineX;CHECKMEM CHECKM2!}; QCURMEM STOPLNQCURMEM STOPLN EOK1; QTOPLN( SMEMST2 PTEMP< SMEMSTF LTEMPPFOK1Z"} QCURMEMd PTOPLNnQCURMEMx PTOPLN SCRDRAWOK1; QBOTSCR SCURMEM PTEXTPQBOTSCRSCURMEM#} PTEXTP LTEXTPFEQAEOK2EQA, QTOPLN OLENTABLE PTOPLN QTOPLN"O>, PTOPLN6REF SC$}RDRAW@!OK1JOK2:T CHECKM2;^ QMEMPNTh S>4TXTENDr PTEMP|QMEMPNT S>5TXTEND LTEMPDCK3 Q>4TXTEND%} PMEMPNT Q>5TXTENDPMEMPNTCK3; QCURMEM SMEMST PTEMPQCURMEM SMEMST LTEMP EINRANGE &}QMEMST& PCURMEM0 QMEMST: PCURMEMD :N INRANGE;X QCURMEMb SMEMPNTl PTEMPv QCURMEM SMEMPNT L'}TEMP EOUTRANGE : OUTRANGEQMEMPNT PCURMEM QMEMPNT PCURMEM : X; X;Erase Buffer X; ERMYBF%>T(}!Q> !ERMBPMYBUF8!1 ! IERMB*!:4!X;>!X;2 BYTE BINARY INTEGER TO AH! X;4 BYTE BINARY CODED DECIMALR! X;NUMBER.\!X;)}f!INT2FPQLO1p! PWORKLz!QHI1! PWORKH!Q>!PBCD! PBCD! PBCD! PBCD!!IFP1TWORKL! UWOR*}KH!$>!IFP2QBCD9! OBCD9" PBCD9"0" HIFP2$"1." HIFP18"-B":L"X;V"!X;Convert BCD to Internal Code`"X;j"CON+}BCD INT2FPt"%>~"$>"CONBQBCD8" BIN2HEX" QHNUM" PABUF9" QHNUM" PABUF9"2"2"3")>" HCON,}B"%>#CONB3QABUF8 #,#O># PABUF8(#12# ICONB3<#:F#X;P#!X;Convert BCD to 2 byte numberZ#X;d# BIN2HEX5n#M>-}x# PHNUM#7#V?#V?#V?#V?# PHNUM#:#X;#!X;Convert 1 byte binary number#X;to internal code#X;#CALCNMQ.}LO#%>$'HI$ 'NBUF$R>"$ DTRY100,$%>6$ PNBUF@$;J$S>T$ !CLC1^$TRY100R>dh$ DCLC1r$%>|$ 'NBUF/}$;$S>d$ CLC1R> $ DCLCDN$;$S> $#HI$ HCLC1$ CLCDN,$O>$ PNBUF$QHI$,%O>% PNBUF% QNB0}UF&%,0%O>:% PNBUFD%:N%X;X%X;Introductionb%X;l% INTRO$>v%Q>;;a NOP%INTRO1PGOINT9%0% IINTRO1%Q>41}SCMEM( %PSCR%Q>5SCMEM( % PSCR% PTITL2% QITXT9%?%R>% FIADD40%P22& QITXT9 &R>& FIADD40 2}&R>*& FIPDN4& P@SCR7>&3H&HP2R&IADD40QSCR\&,f&O>(p&PSCRz& QSCR&O>& PSCR& HPTITL&IPDN!GETKEY3}&X;&"X;This routine shows the number&X;of free bytes left in text&#X;memory, it puts the # of bytes&X;on the MYMEM+304} line.&X;&SHOFREEQ>4TXTEND&;& SMEMPNT'PLO1' Q>5TXTEND'SMEMPNT$'PHI1.' CONBCD8'%>B'SHOFREE1QABU5}F8L'PMYMEM8V'1`' ISHOFREE1j':t'X;~'X;Work Buffers'X;'I'LENTABLE' MYBUFU' ABUF' NBUF' 6}SBUF-' FILNAM'ENDMYPG 'EI'X;'X;Set Run Address(X; ( RUNAD( PSTART(U' ABUF' NBUF' a dMYSET ===n ===x === === =f=f=f === =f==f f==8}f= =>=`=< =|== =f=l= 0=f=F= =6==8 o=f=;= === ===9} === === =p=8=" =8=p=, =f=<=6 <=f==@ ===~J ===T :}===^ ===0h ===~r ===| === === == = 0=`=@= =<=;}f=n v=f=<= ==8= ==~= =<=f=  =0=~= =~= =  =f=<= = ==<<} l=~= = =~=`=| =f=<= =<=`=|& f=f=<=0 =~== : =0=0=D =<=f=b = =8=l ===v === === ===0 = ==0 = =>}= ==~= =~== `=0==  =0=`= =<=f=  === =<=f=n n=`=>=?} ==<=f f=~=f=  =|=f=| f=f=|=  =<=f=`* `=f=<=4 =x=l=f> f=l=x=H @}=~=`=|R `=`=~=\ =~=`=|f `=`=`=p =>=`=`z n=f=>= =f=f=~ f=f=f= =~=A}= ==~= === =f=<= =f=l=x x=l=f= =`=`=` `=`=~= =c=w=B} k=c=c= =f=v=~ ~=n=f= =<=f=f f=f=<=$ =|=f=f. |=`=`=8 =<=f=fB C}f=l=6=L =|=f=fV |=l=f=` =<=`===0 L}g=g=g=o: ==g=D s=s=s=>N g=g=g=X g=g=g=b ===l =f=l=v 7=g== ==M}= === ==<=~ === === ~=<== ==0=~ 0=== == =~N}  === === === ==<= >=f=>=  =`=`=| f=f=|=  ==<=`* O}`=`=<=4 ===>> f=f=>=H ==<=fR ~=`=<=\ ===>f ===p ==>=fz f=>=P}=| =`=`=| f=f=f= ===8 ==<= === ===< =`=`=l x=l=f=Q} =8== ==<= ==f= =k=c= ==|=f  f=f=f=  ==<=f  f=f=<=$  R}==|=f.  f=|=`=`8  ==>=fB  f=>==L  ==|=fV  `=`=`=`  ==>=`j  <==|=t  ==S}~=~  ===  ==f=f  f=f=>=  ==f=f  f=<==  ==c=k  =>=6=  ==f=<T}  =<=f=  ==f=f  f=>= =x  ==~=  =0=~=  ===  ===  ===  U}===(  =`=p=|2  |=p=`=<  ===F  ===P CURCHR ===Z  === ===  kJdX;-----------------------nX;xX;Text Editor SubroutinesX;X;By: Bryan SchappelX;X;FILE: TXTSUBX;X;!W}-----------------------X;X;SAVE a fileX;"X;This routine will SAVE a file#X;to disk, if there is a file in"X;me!X}mory at this time, if thereX;is no file in memory, the$X;command is aborted. The routine#X;will over-write the disk fi!Y}le.#X;it will not ask to replace it."X;,SAVEQFILE?6HDSV@:JDSVPRINT SAVEMT COPFIL^ CONASChQ>r P!Z}IODIR| OPENFIL;;open fileSV1GSVERR$> QMEMST PICBAL9 QMEMST PICBAH9; QMEMPNT SMEMST PI![}CBLL9QMEMPNT SMEMST PICBLH9Q>  PERFIO GSVERR& CLOSE10 "PAUSE?: !CONINTDX;NSVERRPRINT!\} SAVERXSCL CLOSE1b GETKEYl "PAUSE?v !CONINTX;"X;This is the PRINT TO DISK, or X;MANUAL routine. This just!]}s#X;asks for a disk filename, then!X;branches to the proper place$X;in the print routine to produceX;the output.X!^};MANUALQFILE? HDMAN:DMANPRINT PRNTM COPFILQ>  PIODIR OPENFIL  GPERR*IPV24X;>X;PRINT!_} a fileHX;R$X;This routine will generate page\!X;formatted output to any linef#X;printer. The text is formattedp"X;for !`}80 columns by the routinez"X;LPLINE. The LINES location is$X;used to keep track of where the$X;page is being printed, if!a} LINES#X;=0 then we are at TOP of form, X;else some where else on the"X;page. The program will number!X;all pages (up!b} to 255, if the"X;page number exceeds 255, then!X;the page number is set to 0) X;The message 'Page # xxx' is"X;used a!c}t the top of each page.X;PRINTQFILE?FPV0PRINT PTEXT YESNOEPV0$ OPENP.IPV28PERR CLOSE1B!d}PRINT PRTERL "PAUSE?V !GETKEY`PV0:j PV2Q>t PPAGENUM~ QMEMST PTEXTP QMEMST PTEXTPPRINTLP !e}LPCR GPERR QPAGENUMPLO CALCNM QNBUF,O>  PPAGEN QNBUF ,O>  PPAGEN( QNBUF2!f},<O> F PPAGEN P%>Z 'LINESdPGNLPQPAGEN8n PMYBUF8x R>EOL FPGNLP03 HPGNLPPGNLP0 LPRINT;;lin!g}e #1 GPERR LPCR;;line #2 GPERRLPTEXT LPLINE GPERR QLPLENR> FLPDONE QLINES HLPTEXT FPRIN!q}?B%DOS SYSB*)DUP SYSB6SSOUND1 BASBSOUND2 BASBSYSEQU M65B1TEDIT OBJBaTEXT1 M65B7TEXT2 M65BVTEXT3 M65B;TEXT4 M65BE4ZEROFREEACTBAyZEROFREEOBJTLPLPDONEQLINES" FLPDONE1, LPCR6 !LPDONE@LPDONE1"PAUSE?J !CLOSE1TX;^X;LOAD a filehX;rX;Here we LOAD!r} a file into| X;memory. If the LOAD is good!X;we convert the file to ICODE X;by calling - CONINT. If the#X;LOAD is bad!s} we print the errorX;message, and exit.X;LOADPRINT LOADM COPFILQ> PIODIR OPENFIL GLOERR E!t}RASEMEM$> QMEMMAX PICBLL9QMEMMAX& PICBLH90Q>: PERFIOD GLOERRN LOAG$>X QICBLL9b;lS>v!u} PICBLL9 QICBLH9S> PICBLH9 QMEMST OICBLL9 PMEMPNT PTEXTP QMEMST OICBLH9PMEMPNT PTE!v}XTP CLOSE1 #FILE? "PAUSE? %>Q> LOALP@TEXTP7*34 HLOAL> CONINTH !SCRDRAWRX;\LOERR)>;;!w}EOF?f FLOAGp CLOSE1zPRINT LOADR "PAUSE? !GETKEYX;X;Jump to Beginning of LineX; X;We jump to the st!x}art of the#X;line by taking the Xpos of the"X;cursor, subtract 1 (since the"X;actual Xpos is kept as 1 less"X;than th!y}e number that is shownX;on the cursor line), thenX;subtract this number from X;CURMEM. X; BLINE$CURX 0$ &TE!z}MP. QCURMEM8 ;B STEMPL PCURMEMV QCURMEM` S>j PCURMEMt BLOUT:~ X; X;Advance ONE word X; #X;Here we!{} scan ahead for a SPACE #X;or a RETURN to determine if we !X;have found the end of a word X;then scan ahead for a non- !|}X;space character. X; UPWORD%> RLOOPQ@CURMEM7 FUPWRD1 R>EOLCHAR FUPWRD1 3 HRLOOP :( UPWRD132 H!}}UPWRD< #CURMEMF QCURMEMP RMEMPNTZ DUPWRDd HENDTEXTn UPWRDQ@CURMEM7x FUPWRD1 X; X;This routine add!~}s the Y-reg X;to CURMEM, and then calls !X;CHECKMEM to make sure we did X;not leave the screen. X; ADDY2CP, C O!}CURMEM PCURMEM QCURMEM O> PCURMEM WRTN!CHECKMEM ENDTEXTQMEMPNT PCURMEM" QMEMPNT, PCURME!}M6 !CHECKMEM@ X;J X;Goto bottom of textT X;^ !X;This routine is a little bith "X;tricky. If the end of text isr X;on!} the screen, we just call| X;ENDTEXT, else we subtract X;1K from the EOT pointer and #X;call CHECKMEM to scroll to the !}X;end of text. X; BOTTOMQ> PTOPLN QMEMPNT ; S> RMEMST EBOTSAFE QMEMST BOTSAFEPTOPLN!} SCRDRAW !ENDTEXT X;& X;Goto end of line0 X;: #X;To goto the EOL we move to theD X;Begin of line, and then addN!} X;line length-1 to the CURMEMX X;pointer.b X;l ENDLN BLINEv $CURY QLENTABLE9 ? 1 !ADDY2CP X; X;Home!} Cursor X; "X;All we do here is move to ADR X;of TOPLN to the CURMEM X;pointer. X; HOMEQTOPLN PCURMEM QTOP!}LN PCURMEM : X;* X;Flip Insert mode4 X;> X;All we do here is flip theH "X;INSMODE mode between 0 and 1.R !X;T!}hen the DLI will change the\ !X;CURSOR line color to reflectf X;the mode change.p X;z IMODEQINSMODE N> PINSMODE !}: X; X;Reverse Characters X; !X;This command was one I heard X;PAPERCLIP had so I had to X;include it here. As yo!}u can !X;see it is not hard to do. If !X;you move to the EOT and do a #X;swap, the character is flipped X;with a blank s!}pace.X;REVERSE%> Q@CURMEM7$5.38 Q@CURMEM7B1L P@CURMEM7V3`7j P@CURMEM7t:~X;X;Erase all of M!}emoryX;!X;This is called only to ERASE!X;the entire TEXTPT buffer. ItX;also resets some of my#X;pointers. It fill!}s memory with X;zeroes.X;ERASEMEMQMEMST PTEXTP PTOPLN PCURMEM PMEMPNT  QMEMST PTEXTP PTOP!}LN(PCURMEM2PMEMPNT<;F Q>5TXTENDP SMEMSTZPMEMMAXd>nQ>x PMEMMAXERMEMLP%> "TEXTP!} P@TEXTP73 #TEXTPERMLP2P@TEXTP73 HERMLP2 #TEXTP0 HERMLP2 P@TEXTP7:X;X;Insert!} One SpaceX;""X;This sets the INSLEN location,X;to 1 and calls the block6!X;insert routine. Then it puts@X;a space u!}nder the cursor.JX;TINSCHARQ>^ PINSLENhQ>rPINSLEN| INSBLOCKQ>? P@CURMEM7 !CHECKMEMX;!} X;These are the block insertsX;X;This is the 255 char block"X;insert routine. It works much"X;the the 1 char inser!}t routine X;it only sets INSLEN to 255.X;ADD255Q> PINSLEN HTAB2X;&"X;This routine inserts 5 spaces0X;i!}nto the text.:X;DADDTABQ>N PINSLENX TAB2b Q@CURMEM7l HNOINCYv3NOINCY!ADDY2CP TAB2Q>PINSLEN!} INSBLOCKQ>? $INSLENFILLSPP@CURMEM730 HFILLSP:X;X;Insert a block of text X;#X;This !}is the actual INSERT code !X;it sets up the pointers DEST*X;and FROM, then moves the4"X;memory. There are checks made>#X!};to make certain that you don'tHX;go past the EOT memory.RX;\ INSBLOCK,f QMEMPNTp OINSLENzQMEMPNTOINSLEN!} R>5TXTEND DOKINS77: OKINS, QCURMEM PFROM OINSLEN PDESTQCURMEM PFROMOINSLEN!} PDEST;$ QMEMPNT. SFROM8 PMOVELENBQMEMPNTL SFROMVPMOVELEN` DMOVEj,t QMEMPNT~ OINSL!}EN PMEMPNTQMEMPNTOINSLENPMEMPNT:X;X;Move Memory RoutinesX;"X;The next two routines are !}theX;memory move routines."X;They self-modify for a littleX;extra speed.X; DMOVEQMOVELEN> LMOVELEN( !}HNOTNULL2:< NOTNULL,FAP OFROMZ PDMVLPd QFROMn PDMVLPx,A ODEST PDMVLP QDEST PDM!}VLP2 %MOVELEN HDMVLP FSKIPDMV DMV1%>DMVLPQ8P81)> HDMVLPSKIPDMV"DMVLP" "!}DMVLP,06 HDMV1@:JX;TX;Move memory up^X;hUMOVEQFROMr PUMVLP| QFROM PUMVLP QDEST PUMVL!}P QDEST PUMVLP$MOVELEN FSKIPUMV UMV1Q>UMV2PENDPOS%>UMVLPQ8P83 )END!}POS HUMVLP #UMVLP& #UMVLP0(>: FUMVOUTD0N HUMV1XSKIPUMVQMOVELENb HUMV2l UMVOUT:vX;X;Move !}cursor RightX; X;This simply adds one to the!X;CURMEM pointer and calls the"X;CHECKMEM routine to make sure"X;we d!}id not leave text memory.X;GORIGHTBUMP CURMEM !CHECKMEMX;X;Move Cursor LeftX;!X;This just subtracts o!}ne from"X;CURMEM and calls CHECKMEM. If $X;you go left from the HOME posit"X;the screen will only move one "X;character!} up in the document.*X;This can cause some minor4#X;cosmetic problems for the word>X;wrap later on.HX;RGOLEFTQCURM!}EM\ HNODECf"CURMEMpNODEC"CURMEMz !CHECKMEMX;X;CONTROL-DEL a charX;#X;This moves the cursor forward,!}"X;then saves its position, then"X;moves it back again and calls#X;the DELETE2 code to delete the X;text.X;CTRL!}DEL GORIGHT DELETE1 GOLEFT DELETE2:X;X;Delete a char (BACK S)$X;."X;This save the CURMEM position8 !}X;then moves left and deletesBX;the text.LX;VCHRDEL DELETE1` GOLEFTj !DELETE2tX;~X;Actual delete codeX;!}#X;Here are the work-horse delete X;routines, that perform most"X;of the text delete functions.X; DELETE1; QCURM!}EM SMEMST PTEMPQCURMEM SMEMST LTEMPHDELETE1.1 77:(DELETE1.1QCURMEM2 PFROM<QCURMEM!}F PFROMP:Z DELETE2;d QCURMEMn PDESTxN> OFROM PGOBLENQCURMEM PDESTN> OFROM!}PGOBLEN DELMEM; QMEMPNT SDEST PMOVELENQMEMPNT SDESTPMOVELENBUMP MOVELEN UMOVE"!} QMEMPNT,;6 SGOBLEN@ PMEMPNTJQMEMPNTTSGOBLEN^PMEMPNTh:rX;|X;These are the routinesX;that co!}nvert the text into"X;the internal form the program X;uses.X;CONASCQ> PCONFLAG FDOCONCONINTQ> PCO!}NFLAGDOCONQMEMST PTEXTP QMEMST PTEXTP;QMEMPNT STEXTP&>02:%>DCVLOOPQ@TEXTP7N!}5X QCONFLAGb FCOTHERl7v R>EOL HNOTRTN Q>EOLCHARHOVEROTHERNOTRTNR> HGOASCQQ>}HOVEROTHER!}GOASCQ ASC2IC!OVEROTHER COTHER7 R>EOLCHAR HNOTRC Q>EOLHOVEROTHER  NOTRCR>} HGOASCX Q>*HOVER!}OTHER4GOASCX IC2ASC>OVEROTHERP@TEXTP7H3R HCVLOOP\ #TEXTPf0p HCVLOOPz:X;X;Show false spacesX;!}!X;This simply flips the middle"X;bit of the middle byte on one!X;of the characters in my set.!X;This produces a small!} dot on!X;the screen where a word-wrap X;occured.X;PARSEQMYSETN>PMYSET:X;X;Move Down On!}e Screen$X;."X;This will HOME the cursor and8!X;then move the screen down 19BX;lines by simply adding theL"X;length of!} the line, stored inV X;the table - LENTABLE. If we`!X;try to go past the EOT, thenj X;we call the BOTTOM routine.tX;~!}DNSC HOME%>DNLOOPQTOPLN,OLENTABLE8 PTOPLN PCURMEM QTOPLNO> PTOPLNPCURMEM3!})> HDNLOOP QMEMPNTRCURMEM DDNBT( FDNCL2 EDNSCO<DNCLQMEMPNTF RCURMEMP DDNSCOZDNBT!BOTT!}OMdDNSCO SCRDRAWn !CHECKMEMxX;X;Move Cursor Down a lineX;!X;This simply moves the cursor#X;to the start of !}the line, then#X;adds the length of the line to X;CURMEM. If the cursor is on!X;the last line, we must first"X;scroll!} the screen (to get the"X;length of the next text line)X;and add this new length.X;DNLN BLINE $CURY QCURME!}M,OLENTABLE9" PCURMEM,QCURMEM6O>@PCURMEMJ(>T HDOVER^Ah5r QCURX|5 QTOPLN, O!}LENTABLE PTOPLN QTOPLNO> PTOPLN SCRDRAW7 PCURX7 PCURY$> DOVERQLENTABLE9 RCURX!} DADDONY& QCURX0 ADDONY?: 1D !ADDY2CPN X;X X;Move cursor Up a lineb X;l X;This was the most difficultv !X;routi!}ne to write for T:EDIT. !X;If the cursor is on any line X;but one, we simply goto the X;start of the line, subtract "X;!}the length of the line before X;it and then check to see if "X;the cursor Xpos is on the new X;line. If not we move to t!}he X;end of the new line. If the #X;cursor was on the TOP line, we X;run into the problem - How "X;long is the line jus!}t off the #X;top of the screen? - To figure X;this out I wrote a routine!#X;much like the BOTTOM routine + !"X;the SCRDRA!}W routine. It steps!#X;back 1K and 'draws the screen' !#X;until we find the cursor. When*!#X;we are done with this, we know4!}! X;the length of the line just>!X;off the screen. Yeah! ThisH!X;little gem of an idea tookR!"X;weeks to form and a matter !}of\!!X;hours to get to work. Enjoy.f!X;p!UPLN BLINEz! $CURY!(>! FSCRLUP!0!0! QCURMEM!;!SLENTABLE9! PC!}URMEM!QCURMEM!S>!PCURMEM! !DOVER!SCRLUP MOVEUP" $CURMEM" &TOPLN"$CURMEM$" &TOPLN." RCURX!}8" DSCRLUYB" QCURXL" SCRLUY?V"1`" !ADDY2CPj"X;t"X;Move CURMEM up one line~"X;"#X;This routine HOME's the cursor" X;!}then calls CUROFF, to calc."#X;the length of the unseen line,""X;If Y-reg = $FF, we are at the"X;top of text and abort."!}X;"MOVEUP HOME" CUROFF" 'TEMP")>"HMVU":#MVUQCURMEM #;# STEMP# PCURMEM(#QCURMEM2#S><#PCU!}RMEMF#CP#:Z#X;d#"X;Move the cursor up one screenn#X;x# X;This simply calls MOVEUP 19# X;times, and when we are done#!}!X;we call CHECKMEM to move the#X;screen up.#X;# UPSCQ># PLINES#UPSCL MOVEUP# QCURMEM# PTOPLN#QCURMEM!}# PTOPLN# #LINES# QLINES$R>$ HUPSCL$ !CHECKMEM"$X;,$X;Delete to end of line6$X;@$#X;This saves the CURMEM!} positionJ$"X;moves to the EOL then deletesT$X;the text, very simple.^$X;h$DEL2CR ERAS1r$ ENDLN|$ QSAVCUR$;$ SMEM!}PNT$ PTEMP$QSAVCUR$SMEMPNT$ LTEMP$ EDEL2CRLV$ QCURMEM$;$ SMEMPNT$ PTEMP$QCURMEM$SMEMPNT!}% LTEMP% FERAS3% HERAS2&%X;0%#X;The following routines are the:%$X;ones used to delete to the EOL.D%X;N%ERAS1QCURM!}EMX% PDESTb% PSAVCURl%QCURMEMv% PDEST%PSAVCUR%:%X;%ERAS2BUMP CURMEM% ERAS3;% QCURMEM% PFROM!}% SSAVCUR% PGOBLEN%QCURMEM% PFROM%SSAVCUR%PGOBLEN& DELMEM &DEL2CRLVQSAVCUR& PCURMEM &QSAV!}CUR*&PCURMEM4& !CHECKMEM>&X;H&"X;Delete all spaces from CURMEMR&!X;to next non-space character.\&X;f&!X;This simpl!}y moves the CURMEMp&X;to the next non-space charz&"X;and deletes all chars between&"X;the original position and the&X;new!} position.&X;&KSPACEQCURMEM& PTEXTP& PDEST&QCURMEM& PTEXTP& PDEST&%>&SPCFNDQ@TEXTP7& HOUT!}SPC&3' HSPCFND' QTEXTP'RMEMPNT$' DGOINC.' QMEMPNT8' PTEXTPB'QMEMPNTL' PTEXTPV'%>`' FOUTSPCj'!}GOINC#TEXTPt' HSPCFND~' OUTSPC,'C' OTEXTP' PFROM'Q>' OTEXTP' PFROM';' QMEMPNT' SDEST' PMOVE!}LEN'QMEMPNT' SDEST(PMOVELEN (;( QFROM( SDEST(( PGOBLEN2( QFROM<( SDESTF(PGOBLENP(BUMP !}MOVELENZ( UMOVEd(;n( QMEMPNTx( SGOBLEN( PMEMPNT(QMEMPNT(SGOBLEN(PMEMPNT(:(X;(X;Find a string !}in memory(X;("X;These are the GLOBAL Search &(X;REPLACE routines. If the(X;Search string is equal in(!X;length to the!} Replace string(!X;the S&R goes very fast, else)"X;you might wait a little while)X;)FINDPRINT FINDM") INPUT,) DF!}INDOK6):@)FINDOKQCENDJ) PSLENT)%>,^)FNDMBQMYBUF8h) PSBUF8r)1|) IFNDMB)GLOBL CSRCH)R>) FNFND)PRINT !}REPLM) YN2) ENFND)GETREPPRINT REPLW) INPUT) DGLBREP) NFND:)GLBREP CSRCH) QFPOS)R>* FNFND* !} REPL* CHECKMEM&* !GLBREP0*CSRCHQCURMEM:* PTEXTPD*QCURMEMN* PTEXTPX*%>b* SRCH0$>l*SRCH1QSBUF9v* !}ASC2IC* R@TEXTP7*FCY*(>* HSRCH0*0*CY3* HNOVFL* #TEXTP* QTEXTP*RMEMPNT* FNOVFL* ENOTFOUN!}D* NOVFL2+ (SLEN + HSRCH1+, +C*+ OTEXTP4+ PTEMP>+ QTEXTPH+O>R+ PTEMP\+ QMEMPNTf+ RTEMPp+QMEMPNTz+!} STEMP+ DNOTFOUND+;+ QTEMP+ SSLEN+ PCURMEM+ PFPOS+ QTEMP+S>+PCURMEM+ PFPOS+ CHECKMEM+!}%>+ Q@CURMEM7,N>, P@CURMEM7, SCRDRAW$,%>., Q@CURMEM78,N>B, P@CURMEM7L,CV,:`,NOTFOUNDQ>j, PFPOS!}t,:~,X;, X;This is the replace routine,X;, REPL;, QCURMEM, PDEST, SFPOS, PTEMP,QCURMEM, PDEST, S!}FPOS, LTEMP, HNOREPL-Q> - PFPOS-,- QSLEN(- OCURMEM2- PFROM<-Q>F-OCURMEMP- PFROMZ-;d- QMEMP!}NTn- SDESTx- PMOVELEN-QMEMPNT- SDEST-PMOVELEN-BUMP MOVELEN- QSLEN- RCEND- FDOREPC- UMOVE-;!}- QMEMPNT- SSLEN- PMEMPNT-QMEMPNT.S>.PMEMPNT. QCEND". PINSLEN,.Q>6.PINSLEN@. INSBLOCKJ.D!}OREPC%>T.REPLOOPQMYBUF8^. ASC2ICh. P@CURMEM7r.3|. )CEND. HREPLOOP.,. QCURMEM. OCEND. PCURMEM.QCURMEM!}.O>.PCURMEM.NOREPL!CHECKMEM.X;.!X;Convert char under cursor to. X;UPPER if LOWER and LOWER if. X;UPPER./!}X;/CONVERT%>/ Q@CURMEM7&/M>?0/R>!:/ DNOTALPD/R>;N/ ENOTALPX/ Q@CURMEM7b/N>@l/ P@CURMEM7v/NOTALP!GORIGH!}T/X;/!X;This routine forms a line of/"X;text for the printer routine./"X;If the end of text is reached/X;it returns a !}$FF in LPLEN./X;else, it returns the CIO/X;error code./X;/LPLINE ERMYBF/%>/PLOOP1Q@TEXTP7/ R>EOLCHAR/F!}FOUNDSPACE0NOTRETPMYBUF8;;LMARG=5 030)>F;;70 chars? 0 DPLOOP1*0 'LPLEN40FINDSPACEQ@TEXTP7>0FFOUNDSPACEH01R!}0HFINDSPACE\0 %LPLENf0 FSPACE3p0 Q@TEXTP7z0FFOUNDSPACE010FOUNDSPACE'LPLEN0 OVERSTORC0;0 OTEXTP0 PTEXTP0!} QTEXTP0O>0 PTEXTP0%>0MAKEASCQMYBUF80 IC2ASC051M>1R> 1 ECHR2BUF$1,.1O>81>B17L1AV!}1R>`1 HCHR2BUF1j1 Q>EOLt1 CHR2BUF15~1 CHR2BUF71PMYBUF8131 )LPLEN1 HMAKEASC1 Q>EOL1PMYBUF81 LPRI!}NT1 GLEAVELPL1;1 QTEXTP1 SMEMPNT1 PTEMP2 QTEXTP 2SMEMPNT2 LTEMP2 DLEAVELP(2Q>22 PLPLEN<2LEAVELP!}Q>F2 LEAVELPL:P2X;Z2X;This routine counts thed2 X;number of words in the textn2X;in memory. This is a truex2!X;count, n!}ot faked by counting2 X;spaces and dividing by two.2X;The count begins from the2X;top of memory.2X;2CNTWORDQMEMST!}2 PTEXTP2 QMEMST2 PTEXTP2Q>2PLO12PHI12PRINT WORDTXT2CNTWLP GETWORD3 DCNTOK3%>3CNTDNQD!}IRPS8"3 R>EOL,3 FCNTKEY63 ASC2IC@3 PLN18J33T3 HCNTDN^3CNTKEY!GETKEYh3CNTOKBUMP LO1r3 CONBCD|3%>3!}CNTCPYQABUF83 PLN18313 ICNTCPY3 GCNTWLP3X;3!X;This routine finds a word in3"X;memory, it skips spaces unti!}l3X;it hits a non-space, then3X;looks for another space.3!X;Then we check if we are past3X;the end of the text.3X;4!}GETWORD%>4GETW1Q@TEXTP74M>&4 FGETUPL04 R>EOLCHAR:4 HGOTWORDD4 GETUPL3N4 HGETW1X4 #TEXTPb4 WRDRTSl4 DG!}ETW1v4:4GOTWORD ENDWORD4%>4GETWSPCQ@TEXTP74M>4 FENDWORD4 R>EOLCHAR4 FENDWORD434 HGETWSPC4 #TEXTP!}4 HGETWSPC4 ENDWORDC4,5 OTEXTP 5 PTEXTP5 DWRDRTS 5 #TEXTP*5WRDRTSQTEXTP45;>5 SMEMPNTH5 PTEMPR5 QTEXT!}P\5SMEMPNTf5 LTEMPp5 DWRDRTS2z5 FWRDSET5 WRDRTS2:5 WRDSET,5:WRDRTSQTEXTP45;>5 SMEMPNTH5 PTEMPR5 QTEXT MwdX;-------------------nX;xX;I/O SubroutinesX;X;For the TEXT EDITORX;X;FILE: IOSUBX;X;------------%}-------X;X;OPEN a file/deviceX;$X;This routine will open whateverX;file or device is named in X;the string - %}FILNAM. It I/O$X;mode is transfered in IODIR. ItX;will also pause the VBI's.X;OPENFIL CLOSE1" #PAUSE?,$>6%}Q>@ PICCOM9J Q>4FILNAMT PICBAL9^ Q>5FILNAMh PICBAH9r QIODIR| PAUX19Q> PAUX29 !CIOVX;X;Close%} IOCB #1X;CLOSE1$>Q>  PICCOM9 !CIOVX;X;Open PrinterX; OPENP%>OPENP1QPDEV8 PFILNAM8&%}10 IOPENP1:Q>D PIODIRN HOPENFILXX;bX;Custom Input RoutinelX;v$X;This is my famous INPUT routineX;that I %}used in DEBUG+ and X;about 10 other programs. ItX;will fetch a 24 character!X;string from the keyboard and#X;return &}it in MYBUF, terminatedX;by a EOL ($9B).X;INPUTQ>;;length = 0 PCEND#IPUT;;signal input ERMYBF;;and buf&}ferGETC GETKEY;;get a keyR>;;ESCape?HGOTCHR;;nope.  "IPUT;;;signal error :;;and leave*GOTCHR%>ILEGS4&}M>>CHKLEGRILLEG8H FGETCR1\ ICHKLEGf QOLDACpINPDELR>~;;Delete?zHNOTDEL;;no."CEND;;lower lengthI&}TS2;;<0? no.Q>;;make zero. PCENDTS2 TST1;;test lengthQCEND;;get lengthFGETC;;if not 0 go!%CEND;;put &}in a spc)> HDODEL1 DODELQ>PCOMLN8;;erase charPCOMLN8;;erase cursorFGETC;;get next.NOTDELR>&};;Delete Line?$FGETC;;yes.. %CEND8 PMYBUF8BR>EOL;;EOL?LFATEND;;done!V ASC2IC;;make icode`)>j HSHCHt&}1~SHCHPCOMLN8;;to screen3)> DTST91TST9'CEND TST1;;length?!GETC;;do again.ATENDQMYBUF R>&}EOL FINPUTQ>PCOMLN8;;erase cursor PIPUT ,;;show good input :;;bye.X;(X;Test INPUT length2X;<TST&}1QCENDFHTL1P PCOMLNZ PCOMLNdTL1:nX;xX;Get and copy FilenameX; X;This calls INPUT to fetch a X;filena& }me, if ESC is pressed"X;it returns to MAIN. Otherwise X;it converts the filename to#X;upper-case and moves it to the& }X;FILNAMe buffer.!X;If the user tried to use the"X;E: or S: devices for file I/OX;the routine defaults to D:X;C& }OPFIL INPUT DCOP077 !CLRWIN"X;, COP0$>6QMYBUF;;second char@R> :J FYZEROTQMYBUF;;third char& }^R> :h FYZEROr%>|COP1QD1TXT8 PFILNAM81 ICOP1%> HCOPMYBF YZERO%>COPMYBFQMYBUF9 CONL& }2U PFILNAM8 R>EOL FCOPFILD32(> HCOPMYBFCOPFILDQFILNAM&R> E0 FINSDD:R> SD HCOPFILD2N INS&}DDQ> DX PFILNAMb COPFILD2:lX;vX;Perform I/O OperationX;PERFIO$> PICCOM9 QMEMST PICBAL9 QMEMST&} PICBAH9 !CIOVX;X;Convert lower to UPPERX; X;This simply check to see of X;the char is lower-case or a X&};CONTROL character, if so it X;converts it to upper-case.X; CONL2UR>EOL* FCNNCR4R>{> ECNNCRHR>aR DCNL2\&};fS> p CNL2R> z ECNNCR,O>@ CNNCR:X;X;LPRINT MYBUF to printerX;!X;This is similar to the BASIC&}X;LPRINT statement. It sends"X;MYBUF to the printer, settingX;a max output of 80 chars,X;terminated with an EOL.X&};LPRINTR$> Q>  PICCOM9 Q>4MYBUF$ PICBAL9. Q>5MYBUF8 PICBAH9B Q>PL PICBLL9V Q>` PICBLH9j !CIOV&}t X;~ X;Print a CR to printer X; "X;This simply sends out a blank !X;line to the printer by first !X;erasing MYBUF (a &}precaution) X;then putting an EOL in the "X;first position in MYBUF, then X;it falls through to LPRINT. X; LPCR ER&}MYBF Q>EOL PMYBUF X; X;Print a line and check for X;page break. X; "X;This first sends out the line( X;in MYB&}UF, then bumps the2 X;number of lines printed,< "X;checks to see if we should doF !X;a FORM FEED, if so we do andP "X;then w&}e increase the PAGENUM.Z #X;If an error happens during thed !X;print LPRINT returns the CIOn X;error code in the Y-reg.x X;&} LPRINT LPRINTR GLPERR #LINES QLINES R>> DLPOUT Q>EOL PMYBUF LPRINTR LPRINTR LPRINTR #&}PAGENUM Q> PLINES LPOUTQ> LPERR:" X;, #X;This is the directory routine.6 X;It first asks what drive to@ #X;&}get the directory from (12348)J X;and then will get and printT #X;the directory, putting 2 file-^ #X;names per line. If the&} end ofh !X;the screen is reached beforer #X;the directory is done, we will| #X;wait for a key, then clear the X;screen and&} start at the top X;again. X; DODIRPRINT DIRMS GETKEY %> DIRLP1RDIRNUMS8 FGOTDIRN 1 IDIRLP1 :&} X; GOTDIRNPDIRTXT %> DIRLP2QDIRTXT8 PFILNAM8& 10 IDIRLP2: Q>D PIODIRN CLOSE1X  OPENFIL;;ope&}n diskb IDIRGOODl PRINT DIRERv CLOSE1 "PAUSE? !GETKEY DIRGOOD CLRSCR Q> , O>4SCMEM PSCR Q>5& }SCMEM O> PSCR Q> PCOLS PLINES DIRLP3 READIR GDIRDONE %> DIRLP4QMYBUF8* R>EOL4 FENTRYFI&!}N> ASC2ICH P@SCR7R 3\ HDIRLP4f ENTRYFIN#COLSp QCOLSz R> DADD20 Q> PCOLS #LINES QLINES R>&"} FPAUSEDIR ADD20QSCR , O> PSCR QSCR O> PSCR !DIRLP3X;$PAUSEDIRPRINT DIRPS. GETK&#}EY8R>B FDIRLEAVELPRINT DIRMSV !DIRGOOD`X;jDIRDONEPRINT DIRFNt GETKEY~DIRLEAVE CLOSE1 "PAUSE?&$} !CLRSCRX;X;This routine will get one"X;directory entry from the diskX;and put it in MYBUF.X;READIR$>&%}Q> PICCOM9 Q>4MYBUF PICBAL9 Q>5MYBUF  PICBAH9Q> PICBLL9(Q>2 PICBLH9< !CIOVFX;PX;This rout&&}ine relies on theZ!X;fact that all text is storedd!X;in ICODE in memory, else alln X;is lost.xX;SCRDRAWQ>, O>&'}4SCMEMPSCR Q>5SCMEMO> PSCR QTOPLN; SMEMST PTEMP QTOPLN SMEMST LTEMP EADROK&(} QMEMST" PTOPLN, QMEMST6 PTOPLN@ADROKQTOPLNJ PTEXTPT QTOPLN^ PTEXTPh$>r PPAGE%>|PLINE&)}Q@TEXTP7 PLBUFF83R> HRCRET &CURY 'CURX QCHARUNDR RCRETM> R>EOLCHAR FBREAK)>& HPLINE&*}1SLOOPQ@TEXTP7M>R>& HNXCUR0 QCHARUNDR: NXCURR>DFSBRK;;IF = 0N1X HSLOOPb%>%;;LINELEN-1l &+}SBRK3vBREAK'TEMP%>COPYQLBUFF8 P@SCR73 )TEMP HCOPY,C OTEXTP PTEXTP QTEXTPO>&,} PTEXTPC PLENTABLE9 CLRLN)>&  FCLEARED*Q>@;;SOME CHAR4 P@SCR7>3H !CLRLNR CLEARED,\QSCRfO>&-}(pPSCRz DINCNOT #SCR INCNOT2(>;;LINE COUNTER FPDONE !PPAGEPDONEQTEXTP PBOTSCR QTEXTP&.}PBOTSCR:X;X;This routine will find the X;length of the line just off!X;the top of the screen. Thus X;all&/}owing the user to cursorX;off the top of the screen$X;.CUROFFQCURMEM8 RMEMSTB HNPASTLQCURMEMV RMEMST`&0} HNPASTj%>t:;;finished.~ NPASTQ> PTEXTPQCURMEM;S> PTEXTP RMEMSTENP1 QMEMST&1} PTEXTP QMEMST PTEXTP NP1%>PLN1Q@TEXTP7 3 R>EOLCHAR FBRKL()>&2 HPLN1<1FSLP1Q@TEXTP7&2}P FSPBRKZ1d HSLP1n%>%x SPBRK3 BRKL,C OTEXTP PTEXTP QTEXTPO> PTEXTPRCURMEMD&3}NP1 QTEXTP RCURMEMDNP1 ALLD: BRKL,C OTEXTP PTEXTP QTEXTPO> PTEXTPRCURMEMD$); CHECKSUM DATA;[9F CA 03 3A 1A 80 5A 02 ; 43 F0 3F 9D 21 E0 1F F6 ; 95 99 75 78 70 06 4C 37 ; 46 73 A7 3D 60 39 F1*5} BC ; 99 AF 06 8C 79 5B B9 7D ; D1 68 EC 7E EC E7 4C 9F ]BYTE btemp,spaces,len,checkflag, maxfiles,devc,num,quit, *6} lmargin=82,shflok=702,ch=764, atract=77,crsinh=752,errno=73, brkkey=17CARD idx,which,ctemp,sum,max,spare, *7} free,a,b,loss,leastloss,waste, addlen,TmpErr,dl=560,sc=88INT iiBYTE ARRAY names(6000),name(20), extender(5),*8}hold(324), string1(14),string2(14)CARD ARRAY length(500),hlen(27), programs(500),pr(500)CARD FUNC Min(CARD aa*9},bb) IF aa15*;}9 THEN Print("Disk Error #") PrintBE(errno) PutE() Print("Check the drive and ") PrintE("press a key.") *<} ii=GetD(2) ELSE PrintE("Unexpected error.") Print("Check things and press ") PrintE("a key.") ii=GetD(2)*=} FIRETURNPROC Title() lmargin=0 Graphics(0) FOR btemp=1 to 10 DO Put(127) Put(158) OD Print(" *>} ") Put(159) Put(125) Poke(dl+9,7) Poke(dl+10,6) Poke(710,194) Poke(708,198) Poke(712,192) crsinh=1 Pri*?}nt("") Print("") Print("| Written in ACTION! by ") Print("Mike Stortz |") *@}Print("| G.R.A.S.P. of ") Print("Richmond, Va. |") Print("") Print("")*A} lmargin=2 Print(" ") PrintE("NO EMPTY SECTORS ") Print(" This program reads in ") PrintE("t*B}he contents") Print("of your binary file disks, ") PrintE("remembers") Print("their lengths, and sorts ") PrintE("the*C}m to") Print("occupy the least number ") PrintE("of diskettes.") Print("ZEROFREE will hold about ") PrintE("500 ") *D}PrintE("programs & their lengths.") PutE() Print(" A disk has 707 free ") PrintE("sectors if you") Print("use a boot*E} menu like ") PrintE("QuikLoad, or 668") Print("sectors minus the length ") PrintE("of your menu") PrintE("if using D*F}OS.") PutE() Print(" A '#' will appear ") PrintE("before a filename") Print("if it is a duplicate, ") PrintE("or a*G} '=' will") Print("appear if it is of ") PrintE("equal length.") PutE() Print(" ") PrintE("*H}") ii=GetD(2) crsinh=0 free=0 DO ClearOut() Print("How many free sectors ") Print("available? *I}") free=InputC() UNTIL free>0 OD maxfiles=0 DO ClearOut() Print("Maximum files per disk? ") maxfiles=I*J}nputB() UNTIL maxfiles>0 OD devc=0 DO ClearOut() PrintE("Output to D:PRINTOUT,") PrintE(" screen,") *K}PrintE("or printer") Print(" (//)? ") devc=GetD(2) UNTIL devc='D OR devc='P OR devc='S OD Gr*L}aphics(0) Poke(710,194) crsinh=1RETURNPROC GetDir() Put(125) ClearOut() Print(" Now up to ") PrintC(max)*M} PrintE(" programs.") num=0 Close(1) Open(1,"D:*.*",6,0) DO InputMD(1,name,18) MoveBlock(extender+1,name+1*N}1,3) extender(0)=3 ii=SCompare(extender,"SYS") IF name(0)>16 AND ii#0 THEN num==+1 MoveBlock(hold+num*O}*12+1,name+3, 11) hold(num*12)=11 hlen(num)=ValC(name+14) IF num=26 THEN EXIT FI FI U*P}NTIL EOF(1) OD Close(1)RETURNPROC PrintDir() BYTE dup Put(125) IF num>0 THEN Print(" ") FOR btemp=1 TO*Q} num DO IF max>0 THEN FOR ctemp=1 TO max DO MoveBlock(string1+1, hold+12*btemp+1,1*R}1) string1(0)=11 MoveBlock(string2+1, names+12*ctemp+1,11) string2(0)=11 *S} ii=SCompare(string1,string2) IF ii=0 AND hlen(btemp)=length(ctemp) THEN *T} ii=10 FI IF ii=0 OR ii=10 THEN EXIT FI OD FI IF ii=0*U} THEN dup='# ELSEIF ii=10 THEN dup='= ELSE dup=32 FI PrintF("%C -%C%S%C ",192*V}+btemp, dup,hold+12*btemp,127) OD FI PutE()RETURNPROC CopyDir() MoveBlock(names+12+max*12,hold+1*W}2, num*12) MoveBlock(length+2+max*2,hlen+2, num*2) max==+numRETURNPROC Add() ClearOut() *X} SetBlock(string1,14,32) PrintE("Enter filename to add") PrintE("(No '.', please)") InputMD(0,string1,11) IF string1(*Y}0)=0 THEN RETURN FI string1(string1(0)+1)=32 string1(0)=11 ClearOut() Print("Enter length of ") PrintE(string1) a*Z}ddlen=InputC() IF addlen=0 OR addlen>400 THEN RETURN FI num==+1 MoveBlock(hold+num*12,string1,12) hlen(num)=a*[}ddlen RETURNPROC Delete() btemp==-64 IF btemp#num THEN MoveBlock(hold+btemp*12, hold+(btemp+1)*12*\}, (num-btemp)*12) MoveBlock(hlen+btemp*2, hlen+(btemp+1)*2, (num-btemp)*2) FI*]} IF num>0 THEN num==-1 FIRETURNPROC GetLibrary() DO IF idx>480 THEN EXIT FI PrintDir() ClearOut(*^}) Print("Insert next disk to ") PrintE("be cataloged") PrintE("and press ,") PrintE(" LETTER to delete,*_}") PrintE(" + to add, or") PrintE("  to quit & print") btemp=GetD(2) IF btemp=32 THEN CopyDir*`}() GetDir() ELSEIF btemp>64 and btemp<65+num THEN Delete() ELSEIF btemp='+ THEN Add() EL*a}SEIF btemp=' THEN CopyDir() RETURN FI ODRETURNPROC PrintName() PrintD(1,names+which*12) PrintD(1,*b}" ") spaces==+1 IF spaces=4 OR (spaces=3 AND devc='S) THEN spaces=0 PutDE(1) FIRETURNPROC KeyCheck()*c} IF ch<255 THEN ch=255 PutE() FOR idx=1 TO max DO PrintD(1,names+programs(idx)*12) PrintD(1," ") *d} PrintCDE(1, length(programs(idx))) OD PrintE("Press .") ii=GetD(1) quit=1 FIRET*e}URNPROC PrintMess() Put(125) PutE() PrintF("%S%U%E", "Programs left - ",max) PrintF("%S%U%E", *f} "Sectors wasted - ",spare) PrintF("%S%U%E", "Allowable waste - ",waste) PutE() PrintE("Press any key to abor*g}t") PutE() Print("Thinking about ") PrintE("combinations...") PrintE("This many free sectors :")RETURNPROC Switch*h}() idx=Rand(max)+1 which=Rand(max)+1 ctemp=programs(idx) programs(idx)=programs(which) programs(which)=ctempRETU*i}RNPROC PrintOut() spaces=0 FOR idx=1 TO len DO which=programs(idx) PrintName() OD IF spaces#0 THEN P*j}utDE(1) FI PrintCD(1,free-sum) PrintDE(1," FREE") spare==+free-sum IF devc='S THEN PutE() Print("Press an*k}y key ") PrintE("to continue") btemp=GetD(2) FIRETURNPROC Remove() FOR idx=len+1 TO max DO programs(idx*l}-len)=programs(idx) OD max==-len IF max=0 THEN Close(1) Close(2) ClearOut() PrintE("All done...") B*m}reak() FIRETURNPROC Check() sum=0 b=Min(max,maxfiles) FOR idx=1 TO b DO len=idx ctemp=sum which=pr*n}ograms(idx) sum==+length(which) IF sum>free THEN sum=ctemp len==-1 EXIT FI loss=free-sum *o} ODRETURNPROC PrintLibrary() FOR idx=1 to max DO programs(idx)=idx OD PrintMess() DO atract=0 le*p}astloss=1000 FOR a=1 to 10000 DO IF quit=1 THEN EXIT FI Keycheck() Switch() Check() IF loss*q} . &L1/NO EMPTY SECTORS / </ This program reads in /; &Lk/ the contents/^ &L/of y.}our binary file disks, /u &L/ remembers/ &L/their lengths, and sorts / &L/them to/ &L/occupy the least .}number / &L0 of diskettes.0 &L:0ZEROFREE will hold about 0 &LI0500 0D &Lm0programs & their lengths.0S &.} &L0 A disk has 707 free 0z &L0sectors if you0 &L0use a boot menu like 0 &L0QuikLoad, or 6680 &L 1s.}ectors minus the length 0 &L 1 of your menu1 &L81 if using DOS.1* & &LZ1 A '#' will appear 1E &Lv1before a .}filename1d &L1if it is a duplicate, 1 &L1 or a '=' will1 &L1appear if it is of 1 &L1 equal length.1 .}& &L 2 1 &L2 2 & &++++ 5,L\2How many free sectors 2E &Lr2 a.}vailable? 2f & '++͟++L?2+ 5,L2Maximum files per disk? 2 & '+͏+L2+ 5,L2Output .}to D:PRINTOUT,2 &L3 screen,2 &L3 or printer3 &L33 (//)? 3' & &++ID+IP +ISL2 M).}¢ v*`Ls3} & 5,L3 Now up to 3~ &++ .'L3 programs.3 &+ &L3D:*.*3 V&+.} &++ *+L4SYS4+ *++͵+L4+ +L4+ + g%+e+ei.}i+ * + g%+e+e + m+*(m+HH+ 'hh+I.}L4L4L3 &`L4} &͑+L 7L5 5 &++%5%5͋+L 7͛++Lz6+Ȍ++[5+\5[5͗+\5+.}Lz6+ g%+e+eii + * +++ g%+e+eii.} + * +++ *+++ +LS6+ m+*(m++ m++*(m+QQLS6+ .}++ ++I  +ILo6Lz6++LJ5+ +L6#4L6+I  +IL6=4L6 4L6 %C -%C%S%C m+4.}+ g%+e+e6 (+L5 &`L7+i +i ++ g%ee+i .}+i + g% *+i+i++ g%ee+i+i+ g%.} *+m+++i+`L7 5, + *L8Enter filename to add7 &L/8(No '.', please)8 & +ҩ &.}+LL8`+i + + 5,Lw8Enter length of 8f &+ & '+++ +ͫ++L8`+ + g%.}+e+e+ Ҧ *+ m+*(m+++`L 98+@++M+L : + g%+e.}+e+i g%+e+e8++ g% *+ g%+e+e.}+i g%+e+e8++ g% *͑+L:8++`L :͓++L2:LC; 4 5,.}LP:Insert next disk to :; &Lg: be cataloged:Z &L:and press ,:q &L: LETTER to delete,: &L: + to a.}dd, or: &L:  to quit & print: & &++I L; 7 p3L@;@͋+L";Am++ŮL"; 9L@;+I+L2; 7L@;.}+IL@; 7`L :`LG; ++ g%+e+e &L{; ;y &++I+IL;+ISL;+ '`L.};L< &+Ȍ++;+;;͓+;+L<+ m++*(m+  g%+e+e.} &L4< <2 &+ m++*(m+ m+ȱ*(m+ X'++L;L< Press .< & &+.}++`L<} & &L<%S%U%EL<Programs left - <++ʢ< (L<%S%U%EL=Sectors wasted - =++<.} (L5=%S%U%ELK=Allowable waste - =++8=. ( &L=Press any key to abort=h & &L=Thinking about = &.}L=combinations...= &L=This many free sectors := &`L=+ )i+++ )i+++ m++*(m+.}+++ m++*(m++ m++*(m+ȱ+ m++*(m++ȑ+`L>++Ȍ++>>͓+.}+L>+ m++*(m+++ D;++L>+L> '8++++ G'L? FREE? &+m+.}+m+8+++++ISLy? &LR?Press any key ?C &Lh? to continue?\ & &+`L}?+i+++?+?.}?͓+?+L?8+++ m+*(m++ m++*(m++Х+L?8++++++ +L;.}@ & & 5,L1@ All done...@% & $`L?@+++++ ,+++Ȍ++@+@@͓+@+L+A++.}+++++ m++*(m++++ m++*(m++q++q++͙+++L A++++8++L+A8.}++++++++Lv@`L/A+Ȍ++UA+VAUA͓+VA+LA+ m++*(m+++++LDA <M.}+荧++Ȍ+͡+'+L B+ILAL B ; = <@+ͧ+++LA++++++ ?'+Ȍ++ +LAL B+Й+L.}A+++++Ȍ+͡+'+LqB+IL:BLqB ; = <@+ͥ+++LfB+Ȍ+ > z? <+г+LB+IL~BLBLALB.} &LBK:B V&$+$+u,$t,$++++++++++@++ * a- : &+IDLC .}5,LCInsert disk to C &L1Chold D:PRINTOUTC! &LOC and press any keyC; & &+LnC D:PRINTOUTCc V&.}LC+ISLCLCE: C V&¢ v*Ƣ v*LCLCP:C V& ,A & &+$+$``Bc V&,v