home *** CD-ROM | disk | FTP | other *** search
Text File | 1994-01-01 | 27.0 KB | 1,741 lines |
- ** TORNADO Z-80 assembler **
-
- ; TORNADO-EDITOR-source ---- 106
-
- ;let op: linbuf en chartable op a * 256 !
- ; symbtop op a * 16
-
-
- filstrt á32768 ;start of textfile
- Vfilmax á65260 ;default end of text
- symbtop á65520 ;top of symboltable
-
- linbuf á32512 ;start of linebuffer
- linlast álinbuf +63 ;end of linebuffer
- xpos álinbuf +68 ;hor. printpos (pixels)
- ypos áXPOS +1 ;vert. printpos (pixels)
- linpoint áXPOS +2 ;pointer in linebuffer
- altflg áXPOS +4 ;zero if no changes in line
- hulp áXPOS +5
- scrtop áXPOS +6 ;addr. of first line on screen
- curslin áXPOS +8 ;addr. of line with cursor
- filend áXPOS +10 ;actual end of text
- filmax áXPOS +12 ;last useable addr. for text
- findadd áXPOS +14 ;addr. of item last found
- asspoint áXPOS +16 ;assemble address
- dumpa áXPOS +18 ;addr. to store ass.code
- dumpf áXPOS +20 ;start of ass.code in mem.
- pass áXPOS +22 ;pass counter
- errcnt áXPOS +23 ;error counter
- sympo áXPOS +24 ;bottom of symboltable
- storevar áxpos +26 ;temp store
- findtable áXPOS +40 ;start of find$, poked by
- ; BASIC
-
-
- ; ORG 26000
- ; DUMP 60000 ;this file might be too long now!
-
-
- begin ┤Ç,(altflg); 0 = warmstart, to menu
- î2 ; 1 = coldstart, default line
- ▒σ,warm ; 2 = coming from 'find', to
- àÇ; text
- è╛,koud
- èprmenu
- wait ┌8
- û#1B;test key pressed
- à223 ;use CAPS
- î"B"
- ▒σ,7406 ;basic
- î"A"
- ▒σ,assemble ;assemble
- î"C"
- ▒σ,movblok ;copy block
- î"D"
- ▒σ,dellblok ;delete block
- î"M"
- ▒σ,movblok ;move block
- î"N"
- ▓╛,w1
- èkoud ;prepare for new text
- ▒warm
-
- w1 î"O"
- ▒σ,warm ;to existing text
- î"P"
- ▓╛,w5 ;cont. if not PRINT TEXT
- ;PRINT TEXTFILE
- ┤Ç,3 ;open #3
- è5633
- ègetblmark ;test for 2 blockmarkers
- ▓σ,w2 ;jp if found
- ┤Ñ,filstrt ;else print complete text
- ┤ö,(filend)
- ▓w3
- w2 íö,Ñ;make DE point to end of
- òö; last line
- ┤Ç,(ö)
- î13
- ▓╛,w2 +1
- èvolger ;make HL point to start of
- ▒σ,begin ; first line
- w3 ʔ
- ┤(curslin),Ñ
- èexpandlin ;expand line into linebuffer
- ┤ö,linbuf ;print 64 characters
- w4 ┤Ç,(ö)
- ʔ
- ┌16
- ɔ
- ⌐¥
- ┤Ç,¥
- à191 ;test 64
- ▓╛,w4
- ┤Ç,13 ;finish with ENTER
- ┌16
- ɔ;retrieve 'last line'
- èVOLGENDE ;next line
- ▒σ,begin ;jp if end of text
- ʥ
- àÇ
- █Ñ,ö;test for end of block
- ɥ
- ▓ë,w3 ;cont. if not
- ┤ç,begin ;set RETaddr.
- ▒mb4 ;delete blockmarkers
- ;TEST MORE KEYS
- w5 î"T"
- ▒σ,SYMT ;print symbols
- î"V"
- ▒σ,SYMV ;view symbols
-
- ┤ç,500 ;save code = 500
- î"R"
- ▓σ,w6
- ┤ç,1000 ;find = 1000
- î"F"
- ▓σ,w6
- ┤ç,2000 ;load = 2000
- î"L"
- ▓σ,w6
- ┤ç,4000 ;save = 4000
- î"S"
- ▓σ,w6
- ┤ç,6000 ;merge = 6000
- î"Q"
- ▒╛,WAIT
- w6 ═;GOTO BC
-
- movblok ┤(storevar +1),Ç;save command temp
- ègetblmark ;find blockmarkers
- ▒╛,BLMERR ;error if not found
- ʥ;store marker positions
- ʔ
- ┤ç,(CURSLIN);test cursorposition
- ΣÇ
- █Ñ,ç;against endmarker
- ▓ë,mb0 ;jp if cursor past block
- íö,Ñ;get startmarker
- òÑ
- òÑ
- █Ñ,ç
- ▒ë,blmerr -2 ;error if inside block
- mb0 üÇ,0 ;save cursorpos. flag
- ┤(storevar),Ç
- ɔ;retrieve markers
- ɥ
- mb1 òÑ;adjust HL
- ┤Ç,(Ñ)
- î13
- ▓╛,MB1
- mb2 ┤Ç,(ö);adjust DE
- ⌐ö
- î13
- ▓╛,MB2
- àÇ
- █Ñ,ö
- ┤å,ú;BC = length of block
- ┤ë,│
- ⌐ç
- ʇ
- ʔ
- èMKROOM ;make room for block
- ɔ
- ɇ
- ▓ë,BLMERR ;error if no room
- íö,Ñ
- ┤Ç,(storevar);retrieve cursorpos. flag
- àÇ
- ▓╛,MB3
- éÑ,ç;add 'room' if necessary
- mb3 ╕;move block
- ┤Ç,(storevar +1);retrieve command
- î"M"
- ▓σ,DELLBLOK ;delete old block
-
- ┤ç,WARM ;RETaddr.
- mb4 ʇ
- ègetblmark ;find blockmarkers
- ═╛;exit if not found
- ʔ;save first marker addr.
- èmb5 ;delete second marker at HL
- ɥ;first marker
- mb5 èVORIGE +3 ;find start of line
- ┤Æ,ú
- ┤¥,│
- èVOLGER ;find end of line
- ;delete line now
- DELLSUB ʥ;save addr. of nextlin
- ┤å,ú;DE = curslin
- ┤ë,│;BC = nextlin
- ┤Ñ,(FILEND)
- àÇ
- █Ñ,ç;calc length of 'tail'
- í(▀),Ñ
- ɇ;HL = addr. of nextlin
- ⌐ç;BC = length
- ╕;move 'tail' from nextlin
- òö;to curslin
- ┤(FILEND),ö;adjust pointer
- ═
-
- dellblok ègetblmark ;find blockmarkers
- ▓╛,BLMERR ;error if not found
- ʥ;store 2nd marker
- íö,Ñ;use 1th marker
- èVORIGE +3 ;find start of block
- íö,Ñ
- ɥ
- èVOLGER ;find end of block
- èDELLSUB ;delete block
- ▒WARM
-
- mkroom ʇ;store length
- èVOLGENDE ;find start of next line
- í(▀),Ñ;HL = length
- ɇ;BC = next line
- ʇ
- èBIGLINE ;make room
- ɥ
- ═
-
- getblmark ┤ö,filstrt
- ┤Ñ,(filend)
- àÇ
- █Ñ,ö
- íö,Ñ
- ┤å,Æ;BC = length of file
- ┤ë,¥
- ┤Ç,126 ; blockmarker = chr$ 126
- É;find
- ═╛;exit if not found
- ʥ;store addr. found
- É;cont. search
- ɔ;DE = first marker
- ═
-
- ɥ;error exit
- ɥ
- BLMERR ┤ç,BERM ;point to block-error-msge
-
- PRINTERR ┤Ñ,POSM ;point to position controllers
- èprintmsge
- ┤ú,å;point to msge in BC
- ┤│,ë
- èprintmsge
- ▒WAIT
-
- prmenu ┤Ç,7 ;cls screen
- ┤(23693),Ç;ATTR-P
- ┤(23624),Ç;BORDERCOL
- ΣÇ
- ┤(23694),Ç;MASK-P
- ┤(23697),Ç;Pflag
- ├(254),Ç
- è3435 ;do cls
- ┤Ç,2 ;open #2
- è5633
- ┤Ñ,menutable ;print menu part 1
- èprintmsge
- ʥ
- ┤Ñ,filstrt ;find end of text
- ┤ç,32512
- ┤Ç,255
- É
- ┤ç,ferm ;point to file-error-msge
- ▒╛,printerr ;jp if no endmarker found
- òÑ
- ┤(filend),Ñ;store end of text
- ┤Ç,ú
- Γ128 ;BC = end-32768 = length
- ┤å,Ç
- ┤ë,│
- ⌐ç
- è11563 ;print length of text
- è11747
- ɥ
- èprintmsge ;print 'file + merge' msge
- ┤ç,(filend);BC = merge addr.
- è11563
- è11747
-
- ┤Ñ,127 ;find$ is default chr$ 127
- ┤(findtable),Ñ; chr$ 0 = endmarker
- ═
-
- ---------------------------------------------------------------
-
- menutable ù" * TORNADO Z-80 assembler *"
- û13,13,13
- ù"O= To editor P= Print text" :û13
- ù"N= New text T= Print symbols" :û13
- ù"A= Assemble V= View symbols" :û13
- û13
- ù"D= Del. block L= Load text" :û13
- ù"M= Move block Q= Merge text" :û13
- ù"C= Copy block S= Save text" :û13
- ù"F= Find text R= SAVE code" :û13
- û13
- ù"B= TO BASIC"
- û13,13,13
- ù" File: 32768,"
- û255,13
- ù" Merge-addr:"
- û255
-
- POSM û22,21,3,20,1,255
- BERM ù"INVALID BLOCK COMMAND"
- û255
- FERM ù"INCORRECT FILE"
- û255
- SERM ù"SYMBOLTABLE: "
- û255
- ù" - 65520"
- û255
- ASSM ù"ASSEMBLY "
- û255
- OKSM ù"O.K., "
- û255
- ASER ù"ABORTED, "
- û255
- ERRM ù" ERRORS"
- û255
- CODM û22,20,3,20,1
- ù"CODE AT: "
- û255
-
- ASSEXIT ┤Ñ,POSM ;print AT
- èprintmsge
- ┤Ñ,ASSM ;"assembly"
- èprintmsge
- ┤Ñ,OKSM ;point to "O.K."
- ┤Ç,(errcnt);test for errors
- àÇ
- ┤å,0
- ┤ë,Ç
- ▓σ,AXI ;jp if no errors
- ┤Ñ,aser ;point to "aborted"msge
- AXI èprintmsge ;print msge
- è11563 ;print number of errors
- è11747
- ┤Ñ,ERRM ;"errors"
- èprintmsge
- ┤Ç,(errcnt)
- àÇ
- ▒╛,WAIT ;exit if errors
- ┤Ñ,CODM ;"code"
- èprintmsge
- ┤ç,(DUMPF);store-address
- è11563
- è11747
- ┤Ç,44 ;comma
- ┌16
- ┤Ñ,(DUMPA);calc. length
- ┤ö,(DUMPF)
- àÇ
- █Ñ,ö
- ┤å,ú;print length
- ┤ë,│
- è11563
- è11747
- ▒WAIT ;to wait-key
-
- KOUD ΣÇ;reset pointers
- ┤(ALTFLG),Ç
- ┤Ñ,SYMBTOP
- ┤(SYMPO),Ñ
- ┤Ñ,VFILMAX
- ┤(FILMAX),Ñ
- ┤Ñ,filstrt ;insert default line
- íö,Ñ
- ┤Ñ,CMESG
- ┤ç,21
- ╕
- òö;DE = end of text
- ┤(FILEND),ö
- ┤Ñ,#0214;repdel=20 , repper=2
- ┤(23561),Ñ
- ═
-
- cmesg û13,127
- ù" * SCUMARI R&D *"
- û13,13,255
-
- VOLGENDE ┤Ñ,(CURSLIN);find addr. of next line
- VOLGER ┤Ç,(Ñ)
- ⌐Ñ
- î13
- ▓╛,VOLGER
- ┤Ç,(Ñ)
- ⌐Ç;test for 255 = end of file
- ═;RET Z if eof
-
- VORIGE ┤Ñ,(CURSLIN);find addr. of previous line
- ┤ö,filstrt
- àÇ
- █Ñ,ö
- íä,â;save flag
- éÑ,ö;restore HL
- íä,â
- ═σ;ret if cursor on first line
- òÑ
- VOR1 █Ñ,ö
- éÑ,ö
- ▓ë,VOR2
- òÑ
- ┤Ç,(Ñ);find end of line
- î14 ;test enter
- ▓║,VOR1
- VOR2 ⌐Ñ;point to first char of line
- ═
-
- WARM èCLS
- ┤Ñ,filstrt ;set pointers to start of file
- ┤(FINDADD),Ñ
- ┤(SCRTOP),Ñ
- WM1 ┤(CURSLIN),Ñ;print file on scr.
- èPRLIN
- èVOLGENDE
- ▓σ,EDITOR ;exit if end of file
- ┤Ç,(YPOS);1 line down
- Γ8
- ┤(YPOS),Ç
- ▓║,WM1 ;until screen full
- ┤Ñ,#B800;top left cursor coords
- ┤(XPOS),Ñ
- ┤Ñ,(SCRTOP)
- ┤(CURSLIN),Ñ;point to topline
- èENTEX ;copy also to linebuffer
-
- EDITOR ΣÇ;point to start of line
- ┤(XPOS),Ç;on screen
- ┤Ñ,linbuf ;and in linebuffer
- ┤(LINPOINT),Ñ
- WAITKEY ₧
- ╠5,(░+1);'no key'
- ΣÇ;'cursor off' flag
- wk0 èCURSOR
- ┤å,6 ;delay
- wk1 ê5,(░+1)
- ▓╛,GET ;jp if key pressed
- ñ;delay
- ¢wk1
- ▓wk0
-
- GET àÇ;cursor flag
- è╛,CURSOR ;unprint cursor if 'on'
- ╠5,(░+1)
- ┤Ç,(23560);get key
- î197 ;'OR'
- ▓╛,G1
- èDELLINE
- ▓G4 -1
- G1 î198 ;'AND'
- ▓╛,G2
- èINSLINE
- èCURSDOWN
- ▓G4 -1
- G2 î199 ;'<='
- ▓╛,G3
- èINSSP ;delete space
- ▓G4 -1
- G3 î200 ;'>='
- ▓╛,G4
- èINSSP ;insert space
- ΣÇ;signal 'click needed'
- G4 î226
- ▓σ,G5
- ê7,Ç
- ▓╛,wk0 -1 ;ignore other extended keys
-
- G5 íä,â;save key
- ┤Ñ,50 ;click
- ┤ö,1
- è949
- íä,â;get key
- àÇ
- è╛,DOKEY ;call if valid key
- ▓WAITKEY ;editor loop
-
- CURSOR íä,â;'print cursor' flag
- èCALC ;calc screenpos
- ┤Ç,ú;bottom pixelrow
- éÇ,7
- ┤ú,Ç
- ┤ö,#F00F;two cursor-patterns
- ┤Ç,(XPOS)
- à4
- ▓σ,C1
- ┤Æ,¥;choose pattern
- C1 ┤Ç,Æ
- Σ(Ñ);move into screen
- ┤(Ñ),Ç
- íä,â
- Σ1 ;toggle cursorflag
- ═
-
- DOKEY î226
- ▓σ,CONTROL
- î32
- ▓║,CHAR ;jp with normal chars
- CONTROL Γ4 ;test shifted numberkeys
- ▒σ,PAGEDOWN
- òÇ
- ▒σ,PAGEUP
- òÇ
- ▓σ,CAPS
- òÇ
- ▒σ,FINDS
- òÇ
- ▒σ,LEFT ;cursor
- òÇ
- ▒σ,RIGHT
- òÇ
- ▒σ,CURSDOWN
- òÇ
- ▒σ,CURSUP
- òÇ
- ▓σ,BKSP ;backspace
- òÇ
- ▓σ,ENTER
- òÇ
- ▒σ,errmark
- òÇ
- ▓σ,blkmark ;graphics, insert blockmarker
-
- ;to menu when 'STOP'
- èstorelin ;store current line if nec.
- ɇ;drop retaddr.
- ┤Ñ,(filend);delete empty lines
- òÑ;if any at end of file
- EX1 òÑ
- ┤Ç,(Ñ)
- î13
- ▓σ,EX1
- ⌐Ñ
- ⌐Ñ
- ┤(Ñ),255;insert endmarker
- ┤(filend),Ñ
- íö,Ñ;cursor in deleted lines?
- ┤Ñ,(curslin)
- ΣÇ
- █Ñ,ö
- ▓ë,ex2
- òö;adjust cursoraddr. if nec.
- ┤(curslin),ö
- EX2 ▒begin ;to menu
-
- CAPS ┤Ñ,23658 ;toggle capsflag
- ┤Ç,8
- Σ(Ñ)
- ┤(Ñ),Ç
- ═
-
- blkmark èINSLINE ;insert new line
- èCURSDOWN ;move cursor
- ┤Ç,126 ;=blokmarker
- CHAR ┤Ñ,ALTFLG
- ▌0,(Ñ);signal 'line changed'
- ┤Ñ,(LINPOINT)
- ┤(Ñ),Ç;insert marker
- èMOVELIN ;copy to screen
- ;move cursor and ret
- RIGHT ┤Ç,(XPOS);adjust curspos.
- éÇ,4
- ͉;ret if at margin
- ┤Ñ,LINPOINT
- ⌐(Ñ)
- ┤(XPOS),Ç
- ═
-
- BKSP ┤Ñ,ALTFLG
- ▌0,(Ñ);line changed
- ┤Ñ,(LINPOINT);cursorpos. in buffer
- ┤ö,LINLAST
- ┤Ç,(Ñ)
- àÇ
- █Ñ,ö
- ▓ë,BK1 ;jp if not last char on line
- î32
- ▓╛,BK1 +3 ;jp if <> space
- BK1 èLEFT ;'delete' char
- ┤Ç,32 ;change into space
- ┤Ñ,(LINPOINT);in buffer
- ┤(Ñ),Ç
- ▒MOVELIN ;copy to screen
-
- ENTER èSTORELIN ;store current line if nec.
- ͉;ret if no room
- èVOLGENDE ;next line in file
- ▓╛,ENT1 ;jp if not end of file
- ┤Ç,(FILMAX +1);new line, test for room
- îú
- ▒ë,IFEX
- ┤(Ñ),13 ;insert new line
- ⌐Ñ
- ┤(Ñ),255
- ┤(FILEND),Ñ
- òÑ
- ENT1 ┤(CURSLIN),Ñ;adjust cursor
- èDOWN ;on screen
- ENTEX èPRLIN ;move line to screen + buffer
- ΣÇ;cursor points to start of
- ┤(XPOS),Ç;line on screen
- ┤(LINPOINT),Ç;also to start of linebuffer
- ═
-
- LEFT ┤Ç,(XPOS);adjust cursorpos.
- Γ4
- ͉;ret if at margin
- ┤Ñ,LINPOINT
- ò(Ñ)
- ┤(XPOS),Ç
- ═
-
- ;insert space
- INSSP ┤Ñ,ALTFLG ;signal: line changed
- ▌0,(Ñ)
- ┤ö,(LINPOINT);pointer in buffer
- ┤Ñ,LINLAST ;end of buffer
- àÇ
- █Ñ,ö
- ═σ;ret if cursor on last pos.
- ┤å,ú
- ┤ë,│
- î199 ;test command <=
- ▓σ,RECSP ;jp if 'delete space'
- ┤ö,LINLAST ;move buffercontents
- ┤ú,Æ
- ┤│,¥
- òÑ
- ╢;make room
- ▓REC1 ;to put a space on cursorpos.
-
- RECSP ┤ú,Æ;reclaim one space
- ┤│,¥
- ⌐Ñ
- ╕
- REC1 ┤Ç,32 ;'delete' last char on line
- ┤(ö),Ç
- ┤Ñ,(XPOS);save curspos. screen
- ʥ
- ΣÇ
- ┤(XPOS),Ç;temp!
- ┤Ñ,(LINPOINT);save curspos buffer
- ʥ
- èMOVELIN ;store line + reprint
- ɥ;restore cursorpositions
- ┤(LINPOINT),Ñ;in linebuffer
- ɥ
- ┤(XPOS),Ñ;in screen
- ═
-
- CURSUP ┤Ç,(XPOS)
- ʄ
- èSTORELIN
- ▒ë,CURSEX ;jp if no room
- èVORIGE
- ▒σ,CURSEX ;jp if on first line
- ┤(CURSLIN),Ñ
- ┤Ç,(YPOS);one line down
- éÇ,8
- ┤(YPOS),Ç
- î185 ;test for top of screen
- ▒ë,UDOLIN ;jp if still on screen
- ┤Ç,184 ;else restore top of screen
- ┤(YPOS),Ç
- ┤(SCRTOP),Ñ;store new top line addr.
- èSCRDW ;scroll down
- ▒UDOLIN ;print new line
-
- SCRDW ΣÇ
- ┤å,Ç
- SCRDW1 ┤ú,Ç;topleft coords = 0,0
- ┤│,å
- ┤ë,Ç
- èCALC +3 ;screenaddr.
- íö,Ñ
- ┤Ç,ë
- éÇ,8
- ┤ú,Ç;HL = 8 pixels down
- ┤│,å
- èCALC +3 ;screenaddr.
- SCRDW2 ┤Ç,ë
- ┤ë,32 ;move 32 bytes (1 line)
- ╕
- ┤ë,224 ;point to next line
- éÑ,ç
- íö,Ñ
- éÑ,ç;point to next line
- íö,Ñ
- ⌐Ç;count for 8 pixelrows
- ┤ë,Ç
- à7
- ▓╛,SCRDW2
- ┤Ç,(YPOS);count for 23 lines this way
- Γ8
- îë
- ═ ë
- ┤Ç,ë
- ▓SCRDW1
-
- INSLINE èVOLGENDE ;find next lineaddr. in HL
- ┤ö,(FILEND)
- íö,Ñ
- ┤Ç,(FILMAX +1);test room
- îú
- ▒ë,IFEX ;jp if no room
- █Ñ,ö
- ┤å,ú;BC = length
- ┤ë,│
- ⌐ç
- ┤ö,(FILEND)
- ┤ú,Æ
- ┤│,¥
- ⌐ö
- ┤(FILEND),ö
- ╢;make room for one chr$ 13
- ┤Ç,13
- ┤(ö),Ç
- ┤Ç,(YPOS);test for bottomline
- î8
- ▓σ,INSL1 ;jp if second lowest line
- ▓║,INSL2 ;jp if not on bottom
- ;insert blank line at bottom
- èSCRUP ;scroll 1 line up
- èCLIN ;cls botlin
- ┤Ç,8 ;adjust cursor
- ┤(YPOS),Ç
- ┤Ñ,(SCRTOP);adjust scrtop line
- èVOLGER
- ┤(SCRTOP),Ñ
- ═
- ;insert on second lowest
- INSL1 ΣÇ;prepare to clean botlin
- ┤å,Ç
- ▓CLIN ;clear 1 line
-
- INSL2 èSCRDW ;make room on screen
- CLIN ┤ú,Ç
- ┤│,å
- èCALC +3 ;calc scraddr. from A and B
- ┤å,8 ;8 pixrows
- CL1 ʥ
- CL2 ┤(Ñ),0 ;fill with zero
- ⌐│
- ┤Ç,│
- à31 ;32 bytes
- ▓╛,CL2
- ɥ
- ⌐ú
- ¢CL1 ;next pixrow
- ═
-
- CURSDOWN ┤Ç,(XPOS)
- ʄ;store xpos
- èSTORELIN
- ▓ë,CURSEX ;jp if no room for line
- èVOLGENDE
- ▓╛,CSD ;jp if there is a next line
- CURSEX Ʉ
- ═;if end of file
-
- CSD ┤(CURSLIN),Ñ
- èDOWN ;move cursor down or screen up
- UDOLIN èPRLIN ;print next line
- Ʉ
- ┤(XPOS),Ç;restore xpos
- ┤ç,#04FF;calc bufferpos. from scr.pos.
- UDO1 ⌐ë
- Γå
- ▓║,UDO1
- ┤å,0
- ┤Ñ,linbuf
- éÑ,ç
- ┤(LINPOINT),Ñ;store current addr. in buff
- ═
-
- DOWN ┤Ç,(YPOS);test for bottom of screen
- Γ8
- ▓ë,D1 ;jp if scroll needed
- ┤(YPOS),Ç
- ═
-
- D1 ┤Ñ,(SCRTOP);adjust scrtop first
- èVOLGER
- ┤(SCRTOP),Ñ
- SCRUP ┤Ç,184 ;point to topline
- ┤å,0
- SCRUP1 ┤ú,Ç
- ┤│,å
- ┤ë,Ç;store pixrow counter
- èCALC +3 ;calc this rowaddr.
- íö,Ñ
- ┤Ç,ë
- Γ8 ;1 line down
- ┤ú,Ç
- ┤│,å
- èCALC +3;calc 1 line down addr.
- SCRUP2 ┤Ç,ë
- ┤ë,32 ;move 32 bytes on each row
- ╕
- ┤ë,224
- éÑ,ç;find next rowaddr
- íö,Ñ
- éÑ,ç
- íö,Ñ
- òÇ
- ┤ë,Ç
- à7 ;counter in lower bits
- ▓╛,SCRUP2 ;8 pixrows to move
- ┤Ç,ë
- àÇ
- ▓╛,SCRUP1 ;until init. A = 0
- ═
-
- ;DELETE A LINE
- delline ┤Ñ,(CURSLIN)
- ┤Æ,ú
- ┤¥,│
- èVOLGER ;result in HL
- ▓╛,DELL1 ;jp if not end of text
- íö,Ñ;on last line simply insert
- ┤(Ñ),13 ;eol +eof
- ⌐Ñ
- ┤(Ñ),255
- ┤(FILEND),Ñ;adjust pointer
- ▒ENTEX ;move line to scr +buf
-
- DELL1 èDELLSUB ;delete the line
- ┤Ç,(YPOS);test for bottom of screen
- àÇ
- ▓╛,DELL2 ;jp if scroll needed
- ┤Ñ,(CURSLIN)
- ▒ENTEX ;move line to scr + buf
-
- DELL2 èSCRUP +2 ;adjust screen
- ┤Ç,(YPOS)
- ┤Ñ,(CURSLIN);find line past bottom of scr.
- DLL Γ8
- ʄ
- èVOLGER
- ▓σ,DELL3 ;exit if last line in file
- Ʉ
- àÇ
- ▓╛,DLL ;cont. until botlin +1 found
-
- ┤ö,YPOS
- ┤Ç,(ö)
- ʄ;save ypos
- ΣÇ;ypos = 0, temporarely
- ┤(ö),Ç
- èexpandlin +3 ;move this line into linbuf
- èMOVELIN ;and to scr.
- Ʉ
- ┤(YPOS),Ç;restore ypos
- ▒ENTEX
-
- DELL3 Ʉ;end of file reached,
- ┤å,Ç;retrieve ypos
- àÇ;test for botlin
- èσ,CLIN ;if so, clear botlin
- ▒ENTEX
-
- PAGEDOWN èSTORELIN
- ͉;RET if no room for line
- ┤å,24 ;calc 24 lines down
- ┤Ñ,(SCRTOP)
- PD èVOLGER
- ═σ;ret if not present
- ¢PD
- ▓F7 ;cls,print scr from addr in HL
-
- PAGEUP èSTORELIN
- ═ ë
- ┤å,24 ;calc 24 lines up
- ┤Ñ,(SCRTOP)
- PU èVORIGE +3
- ▓σ,F7 ;jp if start of file reached
- ¢PU
- ▓F7 ;print scr from addr in HL
-
- FINDS èSTORELIN
- ͉;ret if no room
- ┤Ñ,(FINDADD);point into file
- òÑ
- F1 ┤ö,FINDTABLE ;point to find$
- F2 ⌐Ñ
- ┤Ç,(Ñ)
- ⌐Ç;test end of file (255)
- ▓σ,F4 ;jp if so
- ┤Ç,(ö);compare first char
- èfindcomp
- ▓╛,F2 ;next if no match
- ʥ;save filepointer
- F3 ⌐Ñ
- ⌐ö
- ┤Ç,(Ñ);test end of file
- ⌐Ç;(255)
- ▓σ,F4 +1 ;jp if so
- ┤Ç,(ö);test end of find$
- ┐Ç
- ▓σ,F5 ;exit if end of find$
- èfindcomp ;compare char
- ▓σ,F3 ;loop if matching
- ɥ;no more match
- ▓F1 ;cont searching in file
-
- F4 ʥ;end of file reached
- ┤Ñ,filstrt
- ┤(FINDADD),Ñ;reset filepointer
- ┤Ñ,127 ;reset find$, (c) + chr$0
- ┤(findtable),Ñ
- ɥ;retr. filepntr
- ▓F6
-
- F5 ɥ;retrieve filepointer
- èVOLGER ;get start of next line
- ┤(FINDADD),Ñ;store
- F6 èVORIGE +3 ;retrieve line with match
- ┤Ç,(FINDTABLE)
- î127
- èσ,VORIGE +3 ;prev. line if (c) =error
- F7 ʥ
- èCLS
- ɥ
- ɇ;drop RETaddr.
- ▒WM1 -3 ;print screen (in WARM)
-
- expandlin ┤Ñ,(curslin);use curslin
- ʥ;or use HL on this entrypoint
- ┤Ñ,linbuf +64 ;clear linebuffer
- pl1 ò│
- ┤(Ñ),32
- ▓╛,pl1
- íö,Ñ;DE points to linebuffer
- ɥ
- pl2 ┤Ç,(Ñ)
- î127
- ▓σ,COMM1 ;jp if (c)
- ▓║,TOKEN
- î";"
- ▓σ,COMMENT
- î13
- ═ σ
- î34 ;quote
- ▓╛,noquote ;test more
-
- qo î13 ;inside quotes now
- ═σ;exit if end of line
- èvul
- ⌐Ñ
- ┤Ç,(Ñ)
- î34 ;test for second quote
- ▓╛,qo
-
- noquote èVUL ;move from file into buffer
- PC1 ⌐Ñ;point to next char in file
- ▓PL2
-
- COMMENT ┤Ç,¥;test pos in linebuffer
- àÇ
- ▓σ,COMM1 -2 ;if ';' is first char
- î34 ;no tokenizing inside quotes
- ▓║,COMM1 -2
- ┤Ç,34 ;comment TAB
- ┤¥,Ç;adjust linbuf pointer
- ┤Ç,59 ;insert ';' here
- COMM1 èVUL
- ⌐Ñ;move trailing chars into
- ┤Ç,(Ñ);linebuffer
- î13 ;until end of line
- ▓╛,COMM1
- ═
-
- TOKEN Γ127
- ┤å,Ç;B = tokennr.
- ┤ë,Ç;save token
- ┤Ç,11 ;TAB if token
- î¥
- ▓ë,$+3 ;only if pos. < 11
- ┤¥,Ç;adjust linbufpntr
- ʥ;store filepntr
- ┤Ñ,opcotable ;find opcode
- T1 ê7,(Ñ)
- ⌐Ñ
- ▓σ,T1
- ┤Ç,(Ñ)
- ⌐Ç;test for 255
- ▓σ,T2 -1 ;jp if end of table
- ¢T1 ;exit with HL pointing
- ; to Bth token
- ┤Ç,35 ;inc hl!
- T2 ┤Ç,(Ñ)
- à127 ;move chars into linbuf
- èVUL
- ┤Ç,(Ñ)
- éÇ,Ç;test end of token
- ▓║,T2 -1;more chars if not
- ɥ;retrieve filepntr
- ┤Ç,ë;retrieve token
- î43 ;test 'INCLUDE'
- ▓╛,$+3
- ⌐¥;insert one space after token
- ┤Ç,16 ;next TAB
- î¥;if possible
- ▓ë,PC1
- ┤¥,Ç;adjust linbufpntr
- ▓PC1
-
- VUL ┤(ö),Ç;move char into buffer
- ⌐¥
- ┤Ç,¥
- î64 ;test for linbuf full
- ͉;ret if not
- ɥ;drop retaddr.
- ═;exit directly from here
-
- ;expand + print to scr
- PRLIN ΣÇ;reset 'line changed' flag
- ┤(ALTFLG),Ç
- èexpandlin
-
- MOVELIN ┤Ñ,YPOS ;calc screenposition
- ┤ú,(Ñ)
- ┤│,0 ;start of scr line
- èCALC +3
- ┤Æ,ú
- ┤¥,│
- ó
- ┤ö,linbuf -1
- ó
- LUP ó
- ⌐ö
- ┤Ç,(ö);fetch from linbuf
- ⌐¥
- ó
- ʔ;store scrpos
- ┤│,Ç;calc addr. of pattern
- ΣÇ
- ╨│
- ╤
- ╨│
- ╤
- ╨│
- ╤
- éÇ,chartable /256 -1
- ┤ú,Ç;HL points to pattern 1
- ó
- ┤Ç,(ö);fetch again from linbuf
- ó
- ┤ë,Ç;calc addr of pattern
- ΣÇ
- Љ
- ╤
- Љ
- ╤
- Љ
- ╤
- éÇ,chartable /256 -1
- ┤å,Ç;BC = addr. of pattern
- ┤Ç,(ç);shift second pattern
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ);add first pattern
- ┤(ö),Ç;1 move to screen
- ⌐ë;next pattern2
- ⌐│;next pattern1
- ⌐Æ;next pixrow, 1 down
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;2
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;3
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;4
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;5
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;6
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;7
- ⌐ë
- ⌐│
- ⌐Æ
- ┤Ç,(ç)
- ╓
- ╓
- ╓
- ╓
- éÇ,(Ñ)
- ┤(ö),Ç;8
- ɔ
- ⌐ö
- ┤Ç,¥
- à31 ;test for 64 chars (4 pix)
- ▓╛,LUP
- ═
-
- CALC ┤Ñ,(XPOS);calc scr.addr. from X,Y-pos
- ʔ;do not destroy DE
- ┤Ç,191
- Γú
- ┤¥,Ç
- ╪
- ╪
- ╪
- à24
- ┐64
- ┤ú,Ç
- ┤Ç,¥
- à56
- ހ
- ހ
- ß│
- ß│
- ß│
- ┐│
- ┤│,Ç
- ɔ
- ═
-
- ;compress line inside linebuffer
- COMPLN ┤Ñ,#0D0D;make sure line in linbuffer
- ┤(LINLAST +1),Ñ;ends with ENTER
- ┤Ñ,linbuf
- ┤Æ,ú;HL = insert pointer
- ┤¥,│;DE = linbuf pointer
- ┤Ç,(ö)
- î";"
- ▒σ,ISLN ;jp if comment
- òö;prepare for loop
-
- NXCH ⌐ö;test next char
- ┤Ç,(ö)
- î13 ;if end of line
- ▒σ,ISLN1 ;ready to insert into file
- î33 ;test space e.o.
- ▓ë,NXCH ;skip these
- î127 ;(c)
- ▒σ,ISLN ;execute 'remark' without TAB
- î";"
- ▓σ,ISL ;remark
- ;try for token now
- ʥ;save insertpntr
- ┤Ñ,opcotable
- ┤å,0
- TRY ⌐Ñ
- ⌐å
- ┤Ç,(ö);fetch char from linbuf
- à223 ;CAPs
- ┤ë,Ç
- ┤Ç,(Ñ);fetch char from tokentable
- à127 ;drop bit 7
- îë
- ┤Ç,(ö);retrieve char
- ▓σ,FIRST ;jp if match
- ▓║,NOTOK ;exit if too far in tokentable
- ; = not found
- NXT ê7,(Ñ);test end of token
- ▓╛,TRY ;find next token if so
- ⌐Ñ
- ▓NXT ;find end of token
-
- FIRST ʔ;save linbufpntr
- ê7,(Ñ);test for 1-char token
- ▓╛,VALEND ;jp if so
-
- MORE ⌐ö;next char in linbuf
- ⌐Ñ;next char in tokentable
- ┤Ç,(ö)
- Σ(Ñ)
- à223 ;CAPs
- ▓σ,MORE ;cont. if matching
- à127 ;no more match, test for last
- ▓╛,INVAL ;char of token, jp if not
-
- VALEND ⌐ö;test in linbuf, for end of
- ┤Ç,(ö); opcode
- èTESTA ;alphanum (!)
- ▓ë,VALTOK ;jp if end of opcode
- INVAL ɔ;else retrieve linbufpntr
- ▓NXT ;try next token
-
- VALTOK ɥ;drop old linbufpntr
- òö;adjust linbufpntr
- ┤Ç,127 ;calc tokennr.
- éÇ,å
- NOTOK ɥ;retrieve insertpntr
- î13
- ▓σ,ISLN1 ;exit, inserting line
- ┤(Ñ),Ç;insert char
- ⌐Ñ
- èTESTA ;test last char for alphanum
- ▓║,ISN ;jp if so
- î"%" ;binair
- ▓σ,isn ;insert chars
- î"#" ;hex
- ▓╛,quote
-
- hex ⌐ö;point to char after #
- ┤Ç,(ö)
- î32 ;skip spaces
- ▓σ,hex
- ètesta ;test for alphanumeric
- ▓ë,nxch +1;exit if not
- î"Z" +1 ;convert chars to caps
- ▓ë,hex1
- à223
- hex1 ┤(Ñ),Ç;store
- ⌐Ñ
- ▓hex ;test next char for hex
-
- quote î34
- ▓╛,nxch;compress more if no quote
- QUO ⌐ö;inside quotes now
- ┤Ç,(ö)
- î13
- ▓σ,ISLN1 ;insert line into file
- ┤(Ñ),Ç
- ⌐Ñ
- î34 ;search for second quote
- ▓╛,QUO
- ISN ⌐ö;outside quotes now
- ┤Ç,(ö)
- ▓NOTOK +1 ;treat next char the normal
- ; way
- ISL ┤Ç,│;test for start of linbuf
- àÇ
- ▓╛,ISLN ;jp if not
- ┤(Ñ),32 ;else insert space
- ⌐Ñ
- isln ┤Ç,65 ;calc length of 'tail' of
- Γ¥;line in linbuf
- ┤å,0
- ┤ë,Ç
- ▓σ,IS1 ;jp if no 'tail'
- íö,Ñ
- ╕;shift tail into position
- ▓IS1 +3
- IS1 ┤ö,LINLAST ;remove any trailing spaces
- íö,Ñ
- ┤Ç,32
- IS2 òÑ
- î(Ñ)
- ▓║,IS2
- ⌐Ñ;insert ENTER
- ISLN1 ┤(Ñ),13
- ⌐Ñ
- ʥ;last char +1
- èINSFILE ;make room or reclaim in file
- ɥ;retr. last +1
- àÇ
- ┤ö,linbuf
- █Ñ,ö;calc length of compr. line
- ┤å,ú;incl. ENTER
- ┤ë,│
- ┤Ñ,(CURSLIN);point into file
- íö,Ñ
- ╕;move line into file
- àÇ;NC = no error
- ═
-
- ;adjust file to accommodate new line
- INSFILE ʥ;store 'last +1 in linbuf'
- ┤ö,(CURSLIN);point into file
- èVOLGENDE
- ┤å,ú
- ┤ë,│;BC = next line addr.
- àÇ
- █Ñ,ö;calc length of old line
- í(▀),Ñ;store old length
- ┤ö,linbuf ;HL =last in linbuf
- █Ñ,ö;calc length of new line
- ɔ;=old length
- █Ñ,ö;compare lengths
- ▓ë,MINLIN ;jp if new < old
- ═σ;exit if new = old
- BIGLINE ┤ö,(FILEND);new > old
- éÑ,ö;test for maxfile
- ┤Ç,(FILMAX +1)
- îú
- ▓║,BIG ;cont. if room available
- ɥ;balance stack
- ɥ;drop RETaddr.
- IFEX ┤ö,32 ;rasp
- ┤Ñ,5000
- è949
- ▄;signal ERROR
- ═
-
- BIG íö,Ñ
- àÇ;now DE= new fileend, HL = old
- █Ñ,ç;BC = addr. of next line
- ┤å,ú;BC = nr. of bytes in 'tail'
- ┤ë,│
- ⌐ç;nr of bytes to move
- ┤Ñ,(FILEND);adjust fileend
- ┤(FILEND),ö
- ╢;move tail
- ═
-
- MINLIN éÑ,ö;undo earlier subtraction
- ┤ö,(CURSLIN);HL = old line length now
- éÑ,ö
- íö,Ñ;DE = end of old line
- ┤Ñ,(FILEND);BC =addr. of next line
- █Ñ,ç;calc length of tail
- ʇ
- í(▀),Ñ;HL = addr. of next line
- ɇ;BC = length of tail
- ⌐ç;take endmarker into account
- ╕;move tail
- òö;adjust end of file
- ┤(FILEND),ö
- ═
-
- STORELIN ┤Ç,(ALTFLG);test for 'line has changed'
- ╓
- ═║;ret if no change made
- èCOMPLN ;else compress + store
- ʄ
- èPRLIN ;and reprint
- Ʉ
- ═
-
- AONLY î123 ;on exit: C = invalid
- ï
- ͉
- î95
- ═║;test A - z
- î91
- ï
- ͉
- î63
- ═
-
- TESTA èAONLY ;on exit: C = invalid
- ═║;test alphanum
- TESTN î58
- ï
- ͉;test 0 - 9
- î48
- ═
-
- ---------------------------------------------------------------
- ; FILLERS here, to put CHARTABLE on #7000 , 28672
-
- ÿ2
-
- chartable û0,0,0,0,0,0,0,0 ;space
- û0,32,32,32,32,0,32,0
- û0,80,80,0,0,0,0,0
- û0,0,80,112,80,112,80,0
- û0,32,112,96,112,48,112,32
- û0,64,80,32,64,16,16,0
- û0,16,32,16,32,64,48,0
- û0,32,64,0,0,0,0,0
- û0,32,64,64,64,64,32,0
- û0,64,32,32,32,32,64,0
- û0,0,80,32,112,32,80,0
- û0,0,32,32,112,32,32,0
- û0,0,0,0,0,32,32,64
- û0,0,0,0,112,0,0,0
- û0,0,0,0,0,96,96,0
- û0,0,0,16,32,64,0,0
-
- û0,32,80,112,112,80,32,0 ;0
- û0,32,96,32,32,32,112,0 ;1
- û0,32,80,16,32,64,112,0 ;2
- û0,96,16,32,16,16,96,0 ;3
- û0,16,16,48,80,112,16,0 ;4
- û0,112,64,96,16,80,32,0 ;5
- û0,32,64,96,80,80,32,0 ;6
- û0,112,16,16,32,64,64,0 ;7
- û0,32,80,32,80,80,32,0 ;8
- û0,32,80,80,48,16,32,0 ;9
- û0,0,0,32,0,0,32,0 ;:
- û0,0,0,32,0,0,32,64 ;;
- û0,0,16,32,64,32,16,0 ;<
- û0,0,0,112,0,112,0,0 ;=
- û0,0,64,32,16,32,64,0 ;>
- û0,96,16,32,64,0,64,0 ;?
- û0,32,80,112,112,64,32,0 ;@
-
- û0,32,80,80,112,80,80,0 ;A
- û0,96,80,96,80,80,96,0 ;B
- û0,32,80,64,64,80,32,0 ;C
- û0,96,80,80,80,80,96,0 ;D
- û0,112,64,96,64,64,112,0 ;E
- û0,112,64,96,64,64,64,0 ;F
- û0,32,80,64,112,80,32,0 ;G
- û0,80,80,112,80,80,80,0 ;H
- û0,112,32,32,32,32,112,0 ;I
- û0,16,16,16,80,80,32,0 ;J
- û0,80,96,96,96,80,80,0 ;K
- û0,64,64,64,64,64,112,0 ;L
- û0,80,112,80,80,80,80,0 ;M
- û0,96,80,80,80,80,80,0 ;N
- û0,32,80,80,80,80,32,0 ;O
- û0,96,80,80,96,64,64,0 ;P
- û0,32,80,80,80,112,48,0 ;Q
- û0,96,80,80,96,96,80,0 ;R
- û0,48,64,32,16,16,96,0 ;S
- û0,112,32,32,32,32,32,0 ;T
- û0,80,80,80,80,80,32,0 ;U
- û0,80,80,80,80,32,32,0 ;V
- û0,80,80,80,80,112,32,0 ;W
- û0,80,80,32,32,80,80,0 ;X
- û0,80,80,32,32,32,32,0 ;Y
- û0,112,16,32,64,64,112,0 ;Z
-
- û0,112,64,64,64,64,112,0
- û0,0,0,64,32,16,0,0
- û0,112,16,16,16,16,112,0
- û0,32,112,32,32,32,32,0
- û0,0,0,0,0,0,0,240
- û0,48,64,96,64,64,112,0
-
- û0,0,32,16,48,80,112,0 ;a
- û0,64,96,80,80,80,96,0 ;b
- û0,0,48,64,64,64,48,0 ;c
- û0,16,48,80,80,80,48,0 ;d
- û0,0,32,80,112,64,48,0 ;e
- û0,48,64,96,64,64,64,0 ;f
- û0,0,48,80,80,112,16,96 ;g
- û0,64,96,80,80,80,80,0 ;h
- û0,32,0,96,32,32,112,0 ;i
- û0,16,0,16,16,16,80,32 ;j
- û0,64,80,96,96,80,80,0 ;k
- û0,64,64,64,64,64,48,0 ;l
- û0,0,80,112,80,80,80,0 ;m
- û0,0,96,80,80,80,80,0 ;n
- û0,0,32,80,80,80,32,0
- û0,0,96,80,80,96,64,64 ;p
- û0,0,48,80,80,48,16,16 ;q
- û0,0,48,64,64,64,64,0 ;r
- û0,0,48,64,32,16,96,0 ;s
- û0,32,112,32,32,32,16,0 ;t
- û0,0,80,80,80,80,48,0 ;u
- û0,0,80,80,80,96,32,0 ;v
- û0,0,80,80,80,112,32,0 ;w
- û0,0,80,32,32,32,80,0 ;x
- û0,0,80,80,80,48,16,32 ;y
- û0,0,112,16,32,64,112,0 ;z
- û0,48,32,64,32,32,48,0
- û0,32,32,32,32,32,32,0
- û0,96,32,16,32,32,96,0
- û240,240,240,240
- û240,240,240,240
- û192,96,48,80,80,48,96,192
-
- opcotable û128 ;startmark
- û"A" +128 ; 128
- ù"AD" :û"C" +128
- ù"AD" :û"D" +128
- û"A" :û"F" :û39 +128 ;rara?
- û"A" :û"F" +128
- ù"AN" :û"D" +128
- û"B" +128
- ù"B" :û"C" +128
- ù"BI":û"T" +128
- û"C" +128
- ù"CAL":û"L" +128
- ù"CC":û"F" +128
- ù"C":û"P" +128 ; 140
- ù"CP":û"D" +128
- ù"CPD":û"R" +128
- ù"CP":û"I" +128
- ù"CPI":û"R" +128
- ù"CP":û"L" +128
- û"D" +128
- ù"DA":û"A" +128
- ù"D":û"E" +128
- ù"DE":û"C" +128
- ù"DEF":û"B" +128 ; 150
- ù"DEF":û"M" +128
- ù"DEF":û"S" +128
- ù"DEF":û"W" +128
- ù"D":û"I" +128
- ù"DJN":û"Z" +128
- ù"DUM":û"P" +128
- û"E" +128
- ù"E":û"I" +128
- ù"EN":û"D" +128
- ù"EQ" :û"U" +128 ; 160
- ù"E":û"X" +128
- ù"EX":û"X" +128
- û"H" +128
- ù"HAL":û"T" +128
- ù"H":û"L" +128
- û"I" +128
- ù"I":û"M" +128
- ù"I":û"N" +128
- ù"IN":û"C" +128
- ù"INCLUD" :û197 ; 170
- ù"IN":û"D" +128
- ù"IND":û"R" +128
- ù"IN":û"I" +128
- ù"INI":û"R" +128
- ù"I":û"X" +128
- ù"I":û"Y" +128
- ù"J":û"P" +128
- ù"J":û"R" +128
- û"L" +128
- ù"L" :û"D" +128 ; 180
- ù"LD" :û"D" +128
- ù"LDD":û"R" +128
- ù"LD":û"I" +128
- ù"LDI" :û"R" +128
- û"M" +128
- ù"N" :û"C" +128
- ù"NE" :û"G" +128
- ù"NO" :û"P" +128
- ù"N" :û"V" +128
- ù"N" :û"Z" +128 ; 190
- ù"O" :û"R" +128
- ù"OR" :û"G" +128
- ù"OTD" :û"R" +128
- ù"OTI" :û"R" +128
- ù"OU" :û"T" +128
- ù"OUT" :û"D" +128
- ù"OUT" :û"I" +128
- û"P" +128
- ù"P" :û"E" +128
- ù"P" :û"O" +128 ; 200
- ù"PO" :û"P" +128
- ù"PUS" :û"H" +128
- û"R" +128
- ù"RE" :û"S" +128
- ù"RE" :û"T" +128
- ù"RET" :û"I" +128
- ù"RET" :û"N" +128
- ù"R" :û"L" +128
- ù"RL" :û"A" +128
- ù"RL" :û"C" +128 ; 210
- ù"RLC" :û"A" +128
- ù"RL" :û"D" +128
- ù"R":û"R" +128
- ù"RR" :û"A" +128
- ù"RR" :û"C" +128
- ù"RRC" :û"A" +128
- ù"RR" :û"D" +128
- ù"RS" :û"T" +128
- ù"SB" :û"C" +128
- ù"SC" :û"F" +128 ; 220
- ù"SE" :û"T" +128
- ù"SL" :û"A" +128
- ù"S" :û"P" +128
- ù"SR" :û"A" +128
- ù"SR" :û"L" +128
- ù"SU" :û"B" +128
- û"V" +128
- ù"XO" :û"R" +128
- û"Z" +128 ; 229
- û255 ;endmarker
- ù"ERRO" :û128 +82
-
- CLS ┤Ñ,16384
- ┤ö,16385
- ┤ç,6144
- ┤(Ñ),0
- ╕
- ┤Ñ,22528 ;ATTR
- ┤ç,768
- ┤Ç,71 ;paper 0, ink 7, bright 1
- ┤(Ñ),Ç
- ╕
- ┤(23624),Ç;border
- ┤Ç,0
- ├(254),Ç
- ┤Ñ,#B800;point to topleft pixelpos
- ┤(XPOS),Ñ
- ═
-
- findcomp èaonly ;test for alpha char
- ▓║,fc1 ;jp if so
- î(Ñ);test other char
- ═
- fc1 Σ(Ñ);cp alpha char
- à223 ;take CAPS into account
- ═
-
- SYMT ┤Ç,3 ;use printer
- ▓SMT
- SYMV è3435 ;cls
- ┤Ç,2 ;use screen
- SMT ┤(storevar+1),Ç
- è5633 ;open #
- ┤Ñ,SERM ;point to 'SYMBOLTABLE'
- èprintmsge
- ʥ;store msge pointer
- ┤ç,(SYMPO);print bottomaddr. of S-table
- è11563
- è11747
- ɥ;point to '-65520'
- èprintmsge
- ┤Ç,13 ;newline
- ┌16
- ┤ö,SYMBTOP -16 ;get top of table
- LS1 ┤Ñ,(SYMPO);test for ready
- òÑ
- àÇ
- █Ñ,ö
- ▓║,LSEND ;jp if ready
- ʔ;store pointer
- ┤å,14 ;print 14 chars
- ┤Ç,(ö)
- ┤ë,Ç
- LS2 ┤Ç,(ö)
- à127 ;drop bit 7
- ⌐ö
- ┌16
- ¢LS2 ;loop
- ê7,ë;test 'undefined'
- ▓╛,LS3 ;jp if not
- ┤Ñ,UNDEF
- èprintmsge
- ⌐ö
- ▓LS4 ;do not print an adress
- LS3 ┤Ç,(ö);collect adress in BC
- ┤ë,Ç
- ⌐ö
- ┤Ç,(ö)
- ┤å,Ç
- ┤Ç,32 ;space
- ┌16
- ┤Ç,35 ; #
- ┌16
- ┤Ç,å
- èPRHX ;print hex
- ┤Ç,ë
- èPRHX ;print hex
- ┤Ç,32 ;spaces
- ┌16
- ┤Ç,32
- ┌16
- ┤Ç,32
- ┌16
- è11563 ;print decimal in BC
- è11747
- LS4 ɔ;retrieve table pointer
- ┤Ç,¥
- Γ16 ;next label
- ┤¥,Ç
- ▓║,LS5
- òÆ;adjust high byte when needed
- LS5 ┤Ç,13 ;newline
- ┌16
- ▓LS1 ;loop
-
- PRHX ʄ;print number in hex
- ╓
- ╓
- ╓
- ╓
- èHXZ
- Ʉ
- HXZ à15
- éÇ,48
- î58
- ▓ë,HXZ1
- éÇ,7
- HXZ1 ┌16
- ═
-
- LSEND ┤Ç,(storevar+1);retrieve command
- î3 ;was it printer
- ▒σ,begin ;ready if so
- ┤Ñ,PRESS
- èprintmsge
- ╠5,(░+1);wait for keypress
- LS6 ê5,(░ +1)
- ▓σ,LS6
- ▒begin ;to menu
-
- printmsge ┤Ç,(Ñ);print msge until 255 is found
- ⌐Ñ
- î255
- ═σ;exit here
- ʥ
- ┌16
- ɥ
- ▓printmsge
-
- PRESS û13,20,1
- ù"Press..."
- û255
-
- UNDEF ù"Undef"
- û255
-
- ASSEMBLE á$
- LENGTE áassemble -begin
-