      
.po10
      ; HC-ASSEMBLER;***************************************************************; BEARBEITER:	WOLFGANG DAUSCHA; STAND:	12.05.86;***************************************************************A5130	EQU	0HC900	EQU	1-A5130;***************************************************************	GLOBAL	ACOMM,ASSEND,TYPEA,CAPIT;---------------	IF	HC900;	EXTERNAL	NAMIN,CLRPU,UOT1,TASTE	EXTERNAL	ASSFLG,OFFSET,TEMP,TEMP2,MCODE	EXTERNAL	LABEND,LABSTK,IXREG,ERROR,LAENG,PRBUFF	EXTERNAL	ELEM1,IXIY,BFLAG,FLDFND,NEGFLG	EXTERNAL	REG,REGCOD;STOP	EQU	13H		;STOP-TASTE;CASPU	EQU	0B700H		;KASSETTENPUFFERCURSO	EQU	0B7A0H		;CURSOR-POSITIONCAOS	EQU	0F003H		;PROGRAMMVERTEILER;MBOT	EQU	01HISRO	EQU	08HCSRO	EQU	09HKBDS	EQU	0CHHLHX	EQU	1AHHLDE	EQU	1BHAHEX	EQU	1CHSOUT	EQU	1EHNOUT	EQU	20HOSTR	EQU	23HOCHR	EQU	24HBRKT	EQU	2AHCRLF	EQU	2CH;	ENIF;---------------SPACE	EQU	020H		;LEERZEICHENTAB	EQU	009H		;TABULATORCR	EQU	00DH		;CARRIAGE RETURNLF	EQU	00AH		;LINE FEEDEOF	EQU	003H		;FILE MARKELBCH1	EQU	'.'		;1. LABELZEICHENLBCH2	EQU	05FH		;2. LABELZEICHEN (UNTERSTRICH)ZEIL1	EQU	39		;LAENGE EINER DRUCKZEILE (SCHMAL)ZEIL2	EQU	64		;56 !,  LAENGE EINER DRUCKZEILE (BREIT)MAXLA	EQU	100H		;MAXIMALE QUELLZEILENLAENGE;***************************************************************FEHL1	EQU	'1'		;KOMMENTAR OHNE SEMIKOLONFEHL2	EQU	'2'		;MARKE MEHRFACH DEFINIERTFEHL3	EQU	'3'		;MARKE NICHT DEFINIERTFEHL4	EQU	'4'		;FALSCHER OPERATIONSCODEFEHL5	EQU	'5'		;FALSCHES ZAHLENFORMATFEHL6	EQU	'6'		;OPERANDENFEHLER BEI JR, IX, IYFEHL7	EQU	'7'		;KEINE MARKE FUER EQUFEHL8	EQU	'8'		;HOCHKOMMA FEHLTFEHL9	EQU	'9'		;OPERANDENFEHLER BEI EXFEHLA	EQU	'A'		;FALSCHE FLAG-BEDINGUNGFEHLB	EQU	'B'		;PLUS ODER KOMMA IN OPERANDEN FEHLT;---------------	IF	A5130	ORG	100HBDOS	EQU	5	ENIF;***************************************************************ACOMM	PUSH	HL		;+	LD	HL,ASSFLG;---------------	IF	A5130	EX	(SP),HL	LD	HL,(ASTXT)	EX	(SP),HL	LD	(HL),1	ENIF;---------------	BIT	2,(HL)	JR	NZ,AXX	LD	HL,(LABSTK)	LD	(LABEND),HL	;MAKENTABELLE LOESCHENAXX	JP	ASSMBL;-----------------------------------IGNBLK	LD	A,(HL)	;LEERZEICHEN UND TAB UEBERSPRINGEN	CP	SPACE	JR	Z,CONLIN	CP	TAB	RET	NZCONLIN	INC	HL	JR	IGNBLK;-----------------------------------CMPSTR	LD	A,(HL)	CP	20H	JR	NC,MSMRE	INC	HLCSTR0	PUSH	HL	PUSH	DE	PUSH	BCCSTR1	INC	HL	INC	DE	LD	A,(DE)	CALL	LBTES	JR	C,CMSM1	LD	B,A	LD	A,(HL)	CALL	LBTES	CP	B	JR	NZ,MSMTCH	JR	CSTR1CMSM1	LD	A,(HL)	CALL	LBTES	JR	NC,MSMTCH	POP	BC	POP	HL	POP	HL	OR	A	RET		;CY=0, GEFUNDEN	;-----------------------------------MSMTCH	POP	BC	POP	DE	POP	HL	DEC	HLMSMRE	SCF	RET		;CY=1, NICHT GEFUNDEN	;-----------------------------------LBTES	CALL	CAPIT	RET	NC	CP	'0'	JR	C,LBTE1	CP	'9'+1	CCF	RET	NCLBTE1	CP	LBCH1	RET	Z	CP	LBCH2	RET	Z	SCF	RET		;CY=0 FUER LABELZEICHEN, =1 SONST;-----------------------------------WSTRNG	LD	A,(PRBUFF)	CP	SPACE	JR	Z,WSTR2	LD	A,'*'	LD	(PRBUFF+1),A	LD	HL,(ERROR)	;FEHLER DEZ. ZAEHLEN	LD	A,L	INC	A	DAA	LD	L,A	JR	NC,WSTR1	XOR	A		;CY=0	LD	A,H	INC	A	DAA	LD	H,AWSTR1	LD	(ERROR),HLWSTR2	LD	HL,PRBUFF	LD	DE,ZEIL2	;D - POSITION, E - MAX. ZEICHENZAHL	LD	A,(ASSFLG)	AND	20H	JR	Z,WSTR3	LD	E,ZEIL1WSTR3	LD	A,(HL)	INC	HL	CP	CR	JR	Z,WSTR4	CALL	TYPEA		;REG. A AUF DISPLAY	LD	A,E	OR	A	JR	NZ,WSTR3WSTR4	LD	A,CR	CALL	TYPEA	LD	A,LF	CALL	TYPEA;-----------------------------------PRCLR	LD	HL,PRBUFF	;DRUCKPUFFER LOESCHEN	LD	D,H	LD	E,L	INC	DE	LD	BC,ZEIL2	LD	(HL),SPACE	LDIR	LD	(HL),CR	RET;-----------------------------------PUTDEF	LD	HL,PRBUFF+2	;ADRESSE IN PUFFERPUTDE	LD	A,D		;HEX ADR SCHREIBEN AB HL	CALL	WRITA	LD	A,E;-----------------------------------WRITA	PUSH	AF		;HEX BYTE SCHEIBEN AUF HL	RRA	RRA	RRA	RRA	CALL	DIGCON	POP	AF;-----------------------------------DIGCON	AND	0FH		;HEX-UMWANDLUNG	ADD	'0'	CP	3AH	JR	C,DIGC1	ADD	7DIGC1	LD	(HL),A	INC	HL	RET	;-----------------------------------CALLAS	CALL	NXTSTPPARSE	LD	A,(ASSFLG)	RLA	JR	NC,NOLIST	;SPRUNG IM 1.PASS (BIT 7)	PUSH	HL		;++	PUSH	AF		;+++	RRA	RRA	CALL	C,WSTRNG	;ASS.-LISTE (1)	POP	AF		;+++	BIT	5,A		;ORG. BIT 4, KASS. AKTIV	PUSH	AF		;+++	JR	NZ,NOERR	LD	A,(PRBUFF)	CP	SPACE	CALL	NZ,WSTRNG	;FEHLERAUSSCHRIFTNOERR	CALL	PRCLR;---------------	IF	HC900	CALL	CAOS	DEFB	BRKT		;BREAKTEST NUR IM 2. PASS	JR	NC,NOBRK	POP	AF		;+++	POP	HL		;++	JR	NZ,CLOCA	POP	HL		;+	RET	ENIF;---------------NOBRK	POP	AF		;+++	LD	DE,(IXREG)	;DE = PC	CALL	PUTDEF		;PC DRUCKEN	INC	HL		;1 LEERZEICHEN	LD	(TEMP),HL	POP	HL		;++	PUSH	HL		;++	LD	DE,PRBUFF+16	LD	BC,ZEIL2-16	LDIR	EX	DE,HL	LD	(HL),CR	POP	HL		;++NOLIST	LD	A,(HL)	CP	EOF	JR	NZ,CALLAS	;SPRUNG WENN FILE NOCH WEITER	CALL	PRCLR	LD	HL,ASSFLG	LD	A,(HL)	RLA	JR	NC,ASEX1	;SPRUNG IM 1. PASS	AND	20H	JR	NZ,CLOCA	;MC-AUSGABE SCHLIESSEN;---------------	IF	HC900	CALL	CAOS	DEFB	OSTR	ENIF;---------------	IF	A5130	CALL	TYPET	ENIF;---------------	DEFB	LF	DEFM	'ERRORS: '	DEFB	0;---------------	IF	HC900	LD	HL,(ERROR)	CALL	CAOS	DEFB	HLHX	CALL	CAOS	DEFB	OSTR	ENIF;---------------	IF	A5130	LD	DE,(ERROR)	CALL	PUTDEF	LD	HL,PRBUFF+2	LD	B,4ERRNM	LD	A,(HL)	CALL	TYPEA	INC	HL	DJNZ	ERRNM	CALL	TYPET	ENIF;---------------	DEFB	CR	DEFB	LF	DEFB	LF	DEFB	0	LD	HL,ASSFLG	BIT	3,(HL)	JR	Z,ASEXIT	;KEINE KASS. AUSGABE	LD	(HL),98H	;2.PASS, OFFEN, KASS.;---------------	IF	HC900	CALL	OPCA		;NAMEN EINTRAGEN	ENIF;---------------	JR	ASSCACLOCA	EQU	#;---------------	IF	HC900	LD	BC,0A0H	CALL	CAOS	DEFB	CSRO	CALL	CAOS	DEFB	CRLF	ENIF;---------------ASEXIT	POP	HL		;+;---------------	IF	HC900	RET			;ENDE DES ASSEMBLERS	ENIF;---------------	IF	A5130	LD	C,0	CALL	BDOS	ENIF;---------------ASEX1	SET	7,(HL)		;2. PASS;---------------	IF	HC900	CALL	CAOS	DEFB	OSTR	ENIF;---------------	IF	A5130	CALL	TYPET	ENIF;---------------	DEFM	'END PASS 1'	DEFB	CR	DEFB	LF	DEFB	LF	DEFB	0ASSCA	POP	HL		;+ PROGRAMMANFANG HOLEN	PUSH	HL		;+ASSMBL	LD	HL,0	LD	(ERROR),HL	LD	(LAENG),HL	LD	A,(ASSFLG)	AND	82H	CP	82H		;2. PASS UND DRUCKER ?	JR	NZ,NOPRT;---------------	IF	HC900	LD	HL,UOT1	CALL	CAOS	DEFB	SOUT	ENIF;---------------NOPRT	POP	HL		;+	PUSH	HL		;+	LD	IY,(MCODE)	LD	(IXREG),IY	JP	PARSE;-----------------------------------NXTSTP	LD	C,0FFH		;LABELFLAG = FF	CALL	CAPIT	JR	NC,DCLP1	;MARKE !DCLP0	CALL	IGNBLK	CP	CR	JR	Z,CLNJP		;LEERZEILE	CP	';'	JR	Z,CLNJP		;KOMMENTARZEILE	CALL	CAPIT	JR	NC,HASH		;OP-CODE	LD	A,FEHL1		;KOMMENTAR OHNE SEMIKOLON,1.ZEICHEN KEIN BUCHST.	LD	(PRBUFF),ACLNJP	JP	CLNUP		;REST UEBERSPRINGEN;---------------DCLP1	INC	C		;LABELFLAG = 0	LD	D,H	LD	E,L		;DE AUF MARKENANFANG	CALL	CSTR0		;DE NACH MAKENENDE	EX	DE,HL	CP	':'	JR	NZ,DCLP2	INC	HLDCLP2	LD	A,(ASSFLG)	RLA	JR	C,DCLP0		;2. PASS;-----------------------------------DCONT	EX	DE,HL		;1.PASS	PUSH	DE	CALL	FNDLBL	POP	DE	JR	C,DECLOK	;MARKE NICHT GEFUNDEN	DEC	HL	LD	(HL),1		;MARKE SCHON VORHANDEN (FEHLER)	EX	DE,HL	JR	DCLP0		;HL NACH MARKENENDE;-----------------------------------DECLOK	PUSH	DE		;NEUE MARKE EINTRAGEN, DE NACH MARKENENDE	EX	DE,HL	LD	A,':'	DEC	HL	CP	(HL)	JR	NZ,LDLPCLDLPB	LD	A,(HL)	CALL	CAPIT		;IN GROSSBUCHSTABEN UMWANDELN	DEC	HLLDLPC	LD	(DE),A	DEC	DE	CP	20H	JR	NC,LDLPB	LD	HL,(IXREG)	EX	DE,HL	LD	(HL),D	DEC	HL	LD	(HL),E	LD	(LABEND),HL	POP	HL	JR	DCLP0;-----------------------------------HASH	LD	DE,0		;OPERATIONSCODE ERMITTELNHSHLP1	SUB	'A'-1	LD	B,A	ADD	E	LD	E,A	LD	A,D	ADD	D	ADD	B	LD	D,A	INC	HL	LD	A,(HL)	CALL	CAPIT	JR	NC,HSHLP1;-----------------------------------HASHDN	PUSH	HL	CP	SPACE	JR	Z,HSHLP2	CP	TAB	JR	Z,HSHLP2	CP	';'	JR	Z,HSHLP2	CP	CR	JR	NZ,HSHERRHSHLP2	AND	A	LD	HL,04B2BH	;EQU ?	SBC	HL,DE	JR	Z,HSHEQU	LD	A,DWCRPT	LD	BC,WCTABX-WCTAB	LD	HL,WCTAB	CPIR	JR	NZ,HSHDN2	LD	A,3	CP	C	JR	C,WCNORM	LD	A,DWCLP1	ADD	E	CP	73H	JR	C,WCLP1	JR	WCRPT;-----------------------------------HSHEQU	LD	A,C	OR	A	LD	A,FEHL7	JR	NZ,HSHE0	POP	HL		;+	CALL	GETFLD	LD	A,(ASSFLG)	RLA	JR	C,CLNUP		;2. PASS	PUSH	HL		;+ HL NACH FELD	LD	HL,(LABEND)	LD	(HL),E	INC	HL	LD	(HL),D	POP	HL		;+	JR	CLNUP;-----------------------------------WCNORM	LD	BC,WCTABX-WCTAB-1	ADD	HL,BC	LD	D,E	LD	E,(HL)HSHDN2	LD	A,D	LD	D,0	LD	HL,CTAB	ADD	HL,DE	LD	B,(HL)	LD	HL,CTAB2	ADD	HL,DE	LD	C,(HL)	AND	7	LD	D,A	LD	A,C	RRCA	RRCA	RRCA	RRCA			;RLD	AND	7	SUB	D	JR	Z,HSHE1;-----------------------------------HSHERR	LD	A,FEHL4			;FALSCHER OP-CODEHSHE0	LD	(PRBUFF),AHSHE1	POP	HL			;+	JR	NZ,CLNUP		;SPRUNG BEI FEHLER	PUSH	BC	XOR	A	LD	(TEMP2),A	LD	A,C	CP	4EH	JR	Z,DEFMNT	PUSH	HL;-----------------------------------PRIGET	CALL	CONTES	CALL	C,G2SUB	DEC	HL	LD	A,(HL)	INC	HL	CP	','	CALL	Z,G2SUB	LD	A,(TEMP2)	OR	A	CALL	NZ,PUTA	POP	HL;-----------------------------------DEFMNT	POP	AF	PUSH	AF	LD	A,0EDH	CALL	M,PUTA	LD	A,0FH	POP	BC	CALL	DSPTCH;-----------------------------------CLNUP	LD	(IXREG),IY;-----------------------------------FNDRCR	LD	A,CR	;CR RECHTS VON HL SUCHENFNDRA	PUSH	BC	;A    "     "   "   "	LD	BC,MAXLA	CPIR	LD	A,(HL)	CP	LF	JR	NZ,FNDR1	INC	HLFNDR1	POP	BC	RET	;-----------------------------------DSPTCH	PUSH	HL	PUSH	BC	AND	C	LD	HL,GROUP0	LD	DE,JPTABHRTIN1	INC	A	LD	B,0HRTLP	PUSH	AF	LD	A,(DE)	INC	DE	LD	C,A	ADD	HL,BC	POP	AF	DEC	A	JR	NZ,HRTLP	POP	BC	EX	(SP),HL	RET	;-----------------------------------GROUP0	LD	A,0CBH		;=GROUP1 CB-BEFEHLE	CALL	PUTA	LD	A,(IXIY)	OR	A	JR	Z,NOTIXY	LD	A,(ELEM1)	CALL	PUTANOTIXY	CALL	G2SUB	LD	A,EG1COMN	RLCA			;<<<<<	RLCA	RLCA	ADD	B	PUSH	AFGCOM2	CALL	G2SUB	JR	NZ,GCINX2	LD	A,E	DEC	AGCINX2	POP	BC	JP	RLB1;-----------------------------------GROUP2	PUSH	HL		;LD	XOR	A	LD	(TEMP2),A	CALL	G2SUB	JR	Z,EXCF1	LD	C,A	CALL	G2SUB	JR	Z,EXCF2	LD	E,A	ADD	C	CP	0FH	JP	NC,EXCF3	POP	HL	LD	A,E	ADD	40H	LD	B,A	LD	A,C	CALL	RLB	LD	A,(TEMP2)	OR	A	RET	Z	LD	A,(TEMP2+1)	JR	EX102EXCF1	POP	DE	LD	A,(REG)	INC	A	JR	Z,EX1NN	INC	A	JR	EX102EX1NN	LD	BC,(ELEM1)	CALL	G2SUB	LD	(ELEM1),BC	CP	7	JR	NZ,EX1NTA	LD	A,32HEX1213	CALL	PUTA	JR	EX104EX1NTA	CP	20H	LD	B,22H	JR	Z,EXTNAC	PUSH	AF	LD	A,0EDH	CALL	PUTA	POP	AF	ADD	43H	LD	B,AEXTNAC	LD	A,B	CALL	PUTA	JR	EX104EXCF2	POP	HL	CP	'('	JR	NZ,EX2NB	LD	(TEMP2),A	LD	A,(REG)	CP	0FFH	JR	Z,EX2NB	ADD	0AHEX102	CALL	PUTA	RET	EX2NB	CALL	GETFLD	LD	A,(REG)	CP	7	JR	NZ,EX2NAF	LD	A,(TEMP2)	CP	'('	JR	NZ,EX2NAF	LD	A,3AH	CALL	PUTA	CALL	GETFLDEX104	JP	PUTNNEX2NAF	CP	6	JR	Z,EX2NAG	LD	A,(REGCOD)	CP	12H	LD	A,(REG)	JR	NC,EX2DBREX2NAG	LD	B,6	CALL	RLB	CALL	G4IN4	CALL	GETFLD	LD	A,EEX103	JR	EX102EX2DBR	PUSH	AF	CALL	G2SUB	CP	'('	LD	C,1	JR	NZ,EX2IND	LD	C,4BH	POP	AF	PUSH	AF	CP	20H	JR	NZ,EXTNHL	LD	C,0AH	JR	EX2INDEXTNHL	LD	A,0EDH	CALL	PUTAEX2IND	LD	A,C	POP	BC	CALL	RLB1	JR	EX104EXCF3	POP	HL	CALL	G2SUB	CP	30H	JR	NZ,EX3IR	LD	A,0F9H	JR	EX103EX3IR	CP	7	JR	NZ,EX3IRX	CALL	G2SUB	ADD	10HEX3IRX	PUSH	AF	LD	A,0EDH	CALL	PUTA	POP	AFEX105	JR	EX103;-----------------------------------GROUP3	PUSH	BCG3JP	JP	GCOM2;-----------------------------------GROUP4	CALL	G2SUB		;=G42ER	JR	NZ,G4REG	LD	A,46H	ADD	B	CALL	PUTA	LD	A,E	JR	EX105G4REG	CP	6	JR	Z,G4IN1	LD	A,(REGCOD)	CP	0CH	JR	NC,G3G4G4IN1	DEC	HL	LD	A,(HL)	INC	HL	CP	','	JR	Z,GROUP4G4IN2	LD	A,5		;<<<<<	CP	B	LD	A,(REG)	JR	C,G4IN3	CALL	RLB	JR	G4IN4G4IN3	CALL	RLB1G4IN4	LD	A,(IXIY)	OR	A	RET	Z	LD	A,(ELEM1)EX107	JR	EX105G3G4	EX	DE,HL	LD	HL,G34TAB	LD	A,B	CPIR	LD	B,(HL)	EX	DE,HL	DEC	HL	LD	A,(HL)	INC	HL	CP	','	LD	A,(REG)	JP	NZ,RLB1	LD	A,B	CP	40H	JR	C,GROUP3	PUSH	BC	LD	A,0EDH	CALL	PUTA	JR	G3JP;-----------------------------------G34TAB	DEFB	005H	DEFB	00BH	DEFB	004H	DEFB	003H	DEFB	080H	DEFB	009H	DEFB	088H	DEFB	04AH	DEFB	098H	DEFB	042H;-----------------------------------GROUP5	CALL	GETFLD		;IM	LD	A,E	LD	DE,IMTAB	ADD	E	LD	E,A	LD	A,(DE)	JR	G6PA;---------------;IMTAB DARF HUNDERTER NICHT UEBERSCHREITEN !!!IMTAB	DEFB	046H		;IM 0	DEFB	056H		;IM 1	DEFB	05EH		;IM 2;-----------------------------------GROUP6	CALL	G2SUB		;IN	LD	C,A	CALL	G2SUB	LD	A,(REG)	CP	0FFH	JR	NZ,EDIN		;(C) NICHT GETESTET !!!	LD	A,0DBH		;IN A,	CALL	PUTA	LD	A,EG6PA	CALL	PUTA	RET	EDINX	LD	C,EEDIN	LD	A,0EDH	CALL	PUTA	LD	A,CG6INX	JP	RLB;-----------------------------------GROUP7	CALL	G2SUB		;OUT	LD	A,(REG)	CP	0FFH	PUSH	AF	LD	C,E	CALL	G2SUB	LD	E,A	POP	AF	JR	NZ,EDINX	LD	A,0D3H		;OUT ,A	CALL	PUTA	LD	A,C	JR	EX107;-----------------------------------GROUP8	LD	A,0CBH		;CB	CALL	PUTA	CALL	G2SUB	ADD	B	LD	B,A	LD	A,(IXIY)	OR	A	JR	Z,G8NIXY	LD	A,E	CALL	PUTAG8NIXY	JR	G92;-----------------------------------GROUP9	CALL	G2SUB		;EX	LD	B,0E3H	CP	'('	JR	Z,G92		;(SP)	LD	B,0EBH	CP	10H		;REG. DE IN RCOMPX	JR	Z,G92	LD	B,8	CP	30H		;REG. AF IN RCOMPX	JR	Z,G92	LD	A,FEHL9	JP	OPERR		;FALSCHER OPERANDG92	JP	PUTB;-----------------------------------GROUPA	CALL	CONTES		;JP+CALL	JR	NC,GARNDX	CALL	G2SUB	JR	Z,GANOBR	;KEIN REGISTER	LD	A,(REGCOD)	CP	3AH	LD	B,0E9H		;JP (HL)	JR	Z,G92CONERR	LD	A,FEHLA	LD	(PRBUFF),A	RETGARNDX	CALL	RLB	CALL	GETFLD	JP	PUTNNGANOBR	LD	A,B	LD	B,0C3H	CP	0C2H	JR	Z,GAEX	LD	B,0CDHGAEX	LD	A,B	JP	EX1213;-----------------------------------GROUPB	CALL	CONTES		;RET	JP	NC,RLB	CALL	G2SUB	LD	A,(FLDFND)	OR	A	JR	NZ,CONERR	LD	A,0C9H	JP	PUTA;-----------------------------------GROUPC	CALL	CONTES		;JR	JR	NC,GRC1	CALL	G2SUB	JR	NZ,CONERR	JR	GCUNCGRC1	LD	B,20H	CALL	RLB	CALL	GETFLDGCHERE	PUSH	HL	PUSH	IY	EX	DE,HL	POP	DE	SCF	SBC	HL,DE	LD	E,L	LD	A,H	RLC	E	ADC	0	JR	Z,GCHE1	LD	A,FEHL6	LD	(PRBUFF),AGCHE1	LD	A,L	POP	HL	CALL	PUTA	RET	GCUNC	LD	A,B	CALL	PUTA	JR	GCHERE;-----------------------------------GROUPD	CALL	G2SUB		;DEFW B=2	LD	A,E		;DEFB B=1GDLOOP	CALL	PUTA	LD	A,D	DJNZ	GDLOOP	RET	;-----------------------------------GROUPE	CALL	IGNBLK		;DEFM	CP	27H	JR	Z,GELOOPGEERR	LD	A,FEHL8OPERR	LD	(PRBUFF),A	RETGELOOP	INC	HLGELP2	LD	A,(HL)	CP	20H	JR	C,GEERR	INC	HL	CP	27H		;'	RET	Z	CALL	PUTA	JR	GELP2;-----------------------------------GROUPF	CALL	GETFLD		;ORG	PUSH	DE	POP	IY	RET	;-----------------------------------G2SUB	CALL	GETFLD	LD	A,(IXIY)	OR	A	JR	Z,G2IN1	LD	(TEMP2),A	LD	A,(ELEM1)	LD	(TEMP2+1),AG2IN1	LD	A,(BFLAG)	CP	'('	RET	ZG2IN2	LD	A,(REG)		;<<<<<	CP	0FFH	RET	;-----------------------------------PUTNN	LD	BC,(ELEM1)PUTNNX	LD	A,C		;<<<<<	CALL	PUTA	JR	PUTB;-----------------------------------RLB	RLCA	RLCA	RLCARLB1	ADD	B	JR	PUTA;-----------------------------------PUTB	LD	A,BPUTA	EXX	LD	C,A	LD	A,(ASSFLG)	RLA	RLA	JR	NC,PUTENT		;KEIN MC IN SPEICHER	LD	HL,(OFFSET)		;MC SCHREIBEN	PUSH	IY	POP	DE	ADD	HL,DE	LD	(HL),CPUTENT	RRA	JR	NC,PUTOUT		;1. PASS, ORG. BIT 7	LD	HL,(LAENG)	INC	HL	LD	(LAENG),HL	BIT	5,A			;ORG. BIT 4	JR	Z,PUTPRT;---------------	IF	HC900	CALL	WRTCA	ENIF;---------------	JR	PUTOUTPUTPRT	LD	HL,PRBUFF+15	LD	A,L	LD	HL,(TEMP)	CP	L	JR	Z,PUTOUT	LD	A,C	CALL	WRITA			;HEX-CODE IN DB	LD	(TEMP),HLPUTOUT	EXX	INC	IY			;PC ERHOEHEN	RET	;-----------------------------------CONTES	PUSH	BC	PUSH	HL	CALL	IGNBLK	CALL	CAPIT	JR	C,CONT4			;KEIN BUCHSTABE	LD	D,A	LD	E,' '	INC	HL	LD	A,(HL)	CALL	CAPIT	JR	C,CONT1			;1 BUCHSTABE	LD	E,A	INC	HL	LD	A,(HL)	CALL	CAPIT	JR	NC,CONT4		;MEHR ALS 2 BUCHST.CONT1	CALL	IGNBLK	CP	','	JR	NZ,CONT11	INC	HLCONT11	PUSH	HL	LD	HL,CONTAB+CONLAE-1	LD	BC,CONLAECONT2	LD	A,E	CPDR	JR	NZ,CONT3	LD	A,D	CP	(HL)	JR	NZ,CONT2	SRL	C	JR	NC,CONT3		;GERADE	LD	A,C	POP	HL	POP	DE	POP	BC	CCF	RET				;CY=0, GEFUNDENCONT3	POP	HLCONT4	POP	HL	POP	BC	SCF	RET				;CY=1, NICHT GEF.;-------CONTAB	DEFM	'NZZ NCC POPEP M 'CONLAE	EQU	$-CONTAB;-----------------------------------JPTAB	DEFB	GROUP0-GROUP0	DEFB	GROUP0-GROUP0		;DA GROUP0=GROUP1	DEFB	GROUP2-GROUP0	DEFB	GROUP3-GROUP2	DEFB	GROUP4-GROUP3	DEFB	GROUP5-GROUP4	DEFB	GROUP6-GROUP5	DEFB	GROUP7-GROUP6	DEFB	GROUP8-GROUP7	DEFB	GROUP9-GROUP8	DEFB	GROUPA-GROUP9	DEFB	GROUPB-GROUPA	DEFB	GROUPC-GROUPB	DEFB	GROUPD-GROUPC	DEFB	GROUPE-GROUPD	DEFB	GROUPF-GROUPE;-----------------------------------GETFLD	PUSH	BC		;=X1GFDCLN	XOR	A		;AB ELEM1 6 BYTE LOESCHEN	EXX	LD	B,8	LD	HL,ELEM1-1CLPRLD	INC	HL	LD	(HL),A	DJNZ	CLPRLD	DEC	(HL)		;REG=0FFH	EXX	LD	A,'+'	LD	(NEGFLG),A	JR	LPGF1LOOPGF	INC	HLLPGF1	CALL	IGNBLK	LD	A,(HL)	CP	';'	JR	Z,RETNR	CP	20H	JR	C,RETNR		;STEUERZEICHEN	LD	(FLDFND),A	CP	27H		;'	JP	Z,GFCHAR	CP	','	JR	Z,COMINC	CP	'('	JR	Z,BFLGST	CP	')'	JR	Z,LOOPGF	CP	'-'	JR	Z,NGHNDL	CP	'+'	JR	Z,NGHNDL	CP	'$'		;PC EV. #	JR	Z,DOLLAR	CP	'#'	JR	NZ,GFDTNM;-----------------------------------DOLLAR	LD	BC,(IXREG)	JP	DONCHR;-----------------------------------COMINC	INC	HL		;ENDE VON GETFLDRETNR	LD	DE,(ELEM1)	;=CRHNDL	POP	BC	LD	A,(FLDFND)	OR	A	RET	;-----------------------------------BFLGST	LD	(BFLAG),A	JR	LOOPGF;-----------------------------------NGHNDL	LD	(NEGFLG),A	JR	LOOPGF;-----------------------------------GFDTNM	CALL	CAPIT	JP	NC,GFDREG	;REGISTER ODER LABEL	PUSH	HL	LD	C,0AH	CALL	TESTZ	JR	C,GFDLP0	POP	HL	INC	HL	PUSH	HL	LD	A,FEHL5		;FALSCHES ZAHLENFORMAT	LD	(PRBUFF),AGFDLP0	LD	C,10HGFDLP1	CALL	TESTZ	JR	C,GFDLP1	POP	HL	CP	11H		;LETZTES ZEICHEN WAR H	JR	Z,GFDLP2	LD	C,0AH		;DEZIMALZAHLGFDLP2	PUSH	HL	LD	HL,0NLBLF	EX	(SP),HL	CALL	TESTZ	EX	(SP),HL	JR	C,GFDLP3	CP	11H		;H	JP	Z,DONE	EX	(SP),HL	DEC	HL	EX	(SP),HL	JP	DONETESTZ	LD	A,(HL)	CALL	CAPIT	INC	HL	CP	3AH		;'9'+1	JR	NC,TSTZ1	SUB	'0'TSTZ1	CP	'A'	JR	C,TSTZ2	SUB	37HTSTZ2	CP	C	RETGFDLP3	LD	E,A	XOR	A	LD	D,A	ADD	HL,DE	EX	DE,HL	LD	L,A		;HL=0	LD	B,CGFDLP4	ADD	HL,DE	DJNZ	GFDLP4	JR	NLBLF;-----------------------------------GFCHAR	LD	BC,0	LD	A,(REGCOD)	CP	2DH		;AF	JP	Z,LOOPGF	;WEGEN AF'GFCHLP	INC	HL	LD	A,(HL)	CP	27H		;'	JR	Z,DONCHR	CP	20H	JR	C,GFCERR	LD	B,C	LD	C,A	JR	GFCHLPGFCERR	LD	A,FEHL8		;HOCHKOMMA FEHLT	LD	(PRBUFF),A	JR	DONCH1DONCHR	INC	HLDONCH1	PUSH	HLMIDWAY	JR	INHERE;-----------------------------------FNDLBL	PUSH	HL		;MARKE IM MARKENTABELLE SUCHEN	LD	HL,(LABSTK)	;OBERES ENDE	PUSH	HL	LD	DE,(LABEND)	DEC	DE	OR	A	SBC	HL,DE	LD	B,H	LD	C,L		;LAENGE DER MARKENTAB.+1	POP	HL	POP	DEEDLP1	LD	A,(DE)	CALL	CAPIT	CPDR	SCF	RET	PO	CALL	CMPSTR	JR	C,EDLP1	RET;-----------------------------------NOREG1	POP	AFNOREG2	DEC	DENOREG3	DEC	DE	EX	DE,HL		GFDLBL	CALL	FNDLBL	PUSH	DE	DEC	HL	LD	A,(HL)	DEC	A	JR	NZ,GFDL1	LD	A,FEHL2		;MEHRFACH DEFINIERTE MARKE	LD	(PRBUFF),AGFDL1	DEC	HL	LD	B,(HL)	DEC	HL	LD	C,(HL)	JR	NC,INHERE	POP	HL	CALL	CSTR0	PUSH	DE	LD	A,FEHL3		;MARKE NICHT DEFINIERT	LD	(PRBUFF),A	LD	BC,0INHERE	LD	HL,NEGFLG	;=CKINV	LD	A,(HL)	LD	(HL),0	LD	HL,(ELEM1)	CP	'-'	JR	NZ,NEGNOT	SBC	HL,BC	JR	NEGEND;-----------------------------------NEGNOT	CP	'+'	JR	Z,NEGADD	LD	A,FEHLB	LD	(PRBUFF),ANEGADD	ADD	HL,BCNEGEND	LD	(ELEM1),HL	POP	HLNGENT	JP	LPGF1;-----------------------------------DONE	PUSH	DE	POP	BC	JR	INHERE;-----------------------------------GFDREG	PUSH	AF	INC	HL		;AUF 2.ZEICHEN	LD	A,(HL)	EX	DE,HL	CALL	LBTES	JR	NC,GFDRG1	POP	AF		;NUR 1 ZEICHEN	CP	'M'	JR	NZ,GFDRG0	LD	A,'('	LD	(BFLAG),A	EX	DE,HL	JR	NOTHL1GFDRG0	LD	HL,RGTB1	LD	BC,RGLG1	CPIR	JR	NZ,NOREG3	;KEIN REGISTER	SLA	C		;*2	JR	GFDRG2GFDRG1	INC	DE		;2 ODER MEHR ZEICHEN	LD	HL,RGTB2+RGLG2-1	LD	BC,RGLG2	CPDR	JR	NZ,NOREG1	SUB	'A'-28H	LD	B,A	BIT	0,C	JP	Z,NOREG1	;REIHENFOLGE	LD	A,(DE)		;3.ZEICHEN	CALL	LBTES	JP	NC,NOREG1	;ZU LANG	POP	AF	CP	(HL)	JP	NZ,NOREG2	ADD	BGFDRG2	SUB	'A'	LD	B,0	EX	DE,HL		;HL NACH REGISTERHLRIN	LD	(REGCOD),A	CP	3AH	JR	NZ,NOTHLHLRTST	LD	A,(BFLAG)		;<<<<<	OR	A	LD	A,20H	JR	Z,RLOAD	XOR	A	LD	(BFLAG),A	LD	A,6RLOAD	LD	(REG),A	JR	NGENT;-----------------------------------NOTHL	PUSH	HL	LD	HL,RCOMPN	ADD	HL,BC	LD	A,(HL)	POP	HL	OR	A	JP	P,RLOAD	LD	(IXIY),ANOTHL1	LD	A,3AH	JR	HLRIN;-----------------------------------RGTB1	DEFM	'IR'RGTB2	DEFM	'BCDEHLA'RGLG1	EQU	$-RGTB1	DEFM	'FSPIXIY'RGLG2	EQU	$-RGTB2;***************************************************************CTAB	DEFB	040H	DEFB	0B8H	DEFB	040H	DEFB	0C2H	DEFB	045H	DEFB	038H	DEFB	028H	DEFB	018H	DEFB	088H	DEFB	080H	DEFB	0C4H	DEFB	018H	DEFB	005H	DEFB	0F4H	DEFB	0FCH	DEFB	040H	DEFB	000H	DEFB	001H	DEFB	070H	DEFB	0A0H	DEFB	0A9H	DEFB	0B9H	DEFB	047H	DEFB	0AAH	DEFB	098H	DEFB	0A1H	DEFB	004H	DEFB	0ABH	DEFB	0A2H	DEFB	000H	DEFB	010H	DEFB	030H	DEFB	0A3H	DEFB	0B0H	DEFB	008H	DEFB	068H	DEFB	018H	DEFB	020H	DEFB	028H	DEFB	008H	DEFB	010H	DEFB	077H	DEFB	080H	DEFB	0C0H	DEFB	0C0H	DEFB	001H	DEFB	0B2H	DEFB	0C1H	DEFB	000H	DEFB	038H	DEFB	0B3H	DEFB	0BAH	DEFB	04EH	DEFB	0DAH	DEFB	010H	DEFB	0B1H	DEFB	041H	DEFB	046H	DEFB	0BBH	DEFB	0C8H	DEFB	0ACH	DEFB	020H	DEFB	0B4H	DEFB	0BCH	DEFB	0C5H	DEFB	0A4H	DEFB	0A8H	DEFB	000H	DEFB	000H	DEFB	002H	DEFB	090H;-----------------------------------CTAB2	DEFB	043H		;RECHTES HALBBYTE IST GRUPPE	DEFB	034H	DEFB	076H	DEFB	02AH	DEFB	0A3H	DEFB	043H	DEFB	033H	DEFB	04CH	DEFB	074H	DEFB	004H	DEFB	04AH	DEFB	073H	DEFB	054H	DEFB	013H	DEFB	033H	DEFB	071H	DEFB	042H	DEFB	02DH	DEFB	0A3H	DEFB	044H	DEFB	0C3H	DEFB	0E3H	DEFB	0F5H	DEFB	083H	DEFB	034H	DEFB	093H	DEFB	034H	DEFB	0C3H	DEFB	0D3H	DEFB	029H	DEFB	008H	DEFB	003H	DEFB	093H	DEFB	004H	DEFB	073H	DEFB	083H	DEFB	068H	DEFB	053H	DEFB	018H	DEFB	078H	DEFB	073H	DEFB	003H	DEFB	051H	DEFB	06BH	DEFB	021H	DEFB	063H	DEFB	0C3H	DEFB	063H	DEFB	00FH	DEFB	048H	DEFB	0C3H	DEFB	093H	DEFB	0D3H	DEFB	043H	DEFB	06CH	DEFB	0B3H	DEFB	027H	DEFB	0A3H	DEFB	0D3H	DEFB	013H	DEFB	083H	DEFB	008H	DEFB	0C3H	DEFB	093H	DEFB	023H	DEFB	0D3H	DEFB	014H	DEFB	04EH	DEFB	018H	DEFB	06DH	DEFB	024H;-----------------------------------RCOMPN	DEFB	007H	;A	DEFB	000H	;BC	DEFB	005H	;L	DEFB	010H	;DE	DEFB	004H	;H	DEFB	020H	;HL	DEFB	003H	;E	DEFB	030H	;AF	DEFB	002H	;D	DEFB	030H	;SP	DEFB	001H	;C	DEFB	0DDH	;IX	DEFB	000H	;B	DEFB	0FDH	;IY	DEFB	04FH	;R	DEFB	0FFH	;FREI	DEFB	047H	;I;-----------------------------------WCTAB	DEFB	0E2H	DEFB	018H	DEFB	016H	DEFB	020H	DEFB	08CH	DEFB	07DH	DEFB	058H	DEFB	026H	DEFB	040H	DEFB	04DH	DEFB	061H	DEFB	02EH	DEFB	085H	DEFB	063H	DEFB	064H	DEFB	08AH	DEFB	057H	DEFB	098H	DEFB	067H	DEFB	072H	DEFB	078H	DEFB	094H	DEFB	09AH	DEFB	082H	DEFB	090H;-------	DEFB	024H	DEFB	049H	DEFB	065H	DEFB	070H;-----------------------------------WCTABX	DEFB	03FH	;STELLE IN CTAB	DEFB	000H	DEFB	001H	DEFB	002H	DEFB	003H	DEFB	004H	DEFB	005H	DEFB	007H	DEFB	00AH	DEFB	043H	DEFB	00BH	DEFB	00FH	DEFB	03DH	DEFB	044H	DEFB	012H	DEFB	015H	DEFB	045H	DEFB	023H	DEFB	030H	DEFB	033H	DEFB	046H	DEFB	037H	DEFB	03AH	DEFB	03BH	DEFB	042H;***************************************************************CAPIT	CP	'A'		;UMWANDELUNG IN GROSSBUCHST.	RET	C		;CY=0 - BUCHST., CY=1 - KEIN BUCHST.	CP	'Z'+1	CCF	RET	NC		;GROSSB.	CP	'a'	RET	C	CP	'z'+1	CCF	RET	C	AND	0DFH	RET;-----------------------------------	IF	HC900;TYPEA	LD	B,1	CP	' '	JR	NC,TYPLP	CP	CR	JR	NZ,TYPE1	LD	D,-1	JR	TYPLPTYPE1	CP	LF	JR	NZ,TYPE2	DEC	D	INC	E	JR	TYPLPTYPE2	CP	TAB	JR	NZ,TYPE3	LD	A,D	CPL	AND	7	INC	A	LD	B,ATYPE3	LD	A,' 'TYPLP	PUSH	BC	PUSH	DE	PUSH	HL	CALL	CAOS	DEFB	OCHR	POP	HL	POP	DE	POP	BC	INC	D	DEC	E	JR	Z,TYPE4	DJNZ	TYPLPTYPE4	CALL	CAOS	DEFB	KBDS	LD	A,(IX+13)	CP	STOP	RET	NZ	JP	TASTE;-----------------------------------OPCA	CALL	CAOS	DEFB	NOUT	CALL	CLRPU	CALL	NAMIN		;HL=ANF. DES NAMEN	CALL	CAOS	DEFB	OSTR	DEFM	'COM'	DEFB	0	LD	DE,CASPU	LD	BC,11	LDIR	LD	A,2	LD	(CASPU+16),A	LD	HL,(LAENG)	LD	(CASPU+19),HL	RET;-----------------------------------WRTCA	PUSH	BC		;+	BIT	4,A		;ORG. BIT 3 VON ASSFLG	JR	Z,WRTC2		;AUSGABE SCHON OFFEN	LD	HL,CASPU	LD	(IX+5),L	LD	(IX+6),H	PUSH	IY	POP	DE	LD	HL,(CASPU+19)	ADD	HL,DE	LD	(CASPU+17),DE	;ANFANG	LD	(CASPU+19),HL	;ENDE+1	LD	A,20	LD	(CURSO),A	EX	DE,HL	CALL	CAOS	DEFB	HLDE	CALL	CAOS	DEFB	CRLF	CALL	CAOS	DEFB	ISRO		;INIT. AUSGABE	LD	HL,ASSFLG	RES	3,(HL)		;FLAG OFFEN	EX	AF,AF'WRTC1	XOR	A		;ZAEHLER RUECKSETZEN	EX	AF,AF'	LD	A,(IX+2)	CALL	CAOS	DEFB	AHEX	CALL	CAOS	DEFB	OSTR	DEFM	'  '	DEFB	0WRTC2	LD	HL,CASPU	EX	AF,AF'		;ZAEHLER HOLEN	CP	80H	JR	NZ,WRTC3	LD	BC,0A0H		;CASPU VOLL	CALL	CAOS	DEFB	MBOT		;CASPU AUSGEBEN	JR	WRTC1WRTC3	LD	L,A	INC	A	EX	AF,AF'	POP	BC	LD	(HL),C	RET;	ENIF;-----------------------------------	IF	A5130;TYPEA	PUSH	BC	PUSH	HL	LD	E,A	LD	C,2	CALL	BDOS	LD	C,11	CALL	BDOS	OR	A	JR	Z,WEITERSTOP	LD	C,1	CALL	BDOS	CP	' '	JR	NZ,STOPWEITER	POP	HL	POP	BC	RET;TYPET	POP	HLTYPE2	LD	A,(HL)	INC	HL	OR	A	JR	Z,TYPE3	CALL	TYPEA	JR	TYPE2TYPE3	JP	(HL);***************************************************************ASSFLG	DEFB	0		;STEUERFLAGS DES ASSEMBLERSOFFSET	DEFW	0		;OFFSET FUER MC-ABLAGE IM SPEICHERTEMP	DEFW	0TEMP2	DEFW	0ASTXT	DEFW	04000H		;QUELLTEXTANFANGMCODE	DEFW	0A000H		;MC-ANFANGLABEND	DEFW	0		;ENDE DER MARKENTABELLE (UNTEN)LABSTK	DEFW	0A000H		;ANFANG DER MARKENTABELLE (OBEN)IXREG	DEFW	0		;FUER IX-REGISTERERROR	DEFW	0		;ZAEHLER FUER FEHLERLAENG	DEFW	0		;LAENGE DES OBJEKTCODESPRBUFF	DEFS	ZEIL2+1		;AUSGABEBUFFER;  LOESCHT GFDCLN: (=0)ELEM1	DEFW	0IXIY	DEFB	0BFLAG	DEFB	0FLDFND	DEFB	0NEGFLG	DEFB	0REG	DEFB	0REGCOD	DEFB	0		;SETZT GFDCLN AUF 0FFH;	ENIF;***************************************************************ASSEND	DEFS	0		;PROGRAMMENDE;***************************************************************	END