;INSITE ORDER NO: BB38
;
;TITLE/VERSION:   CONVERSION: ISIS-II TO/FROM CP/M, V1.0
;
;AUTHOR:          PETER RAJCAN
;                 VS MARTIN
;                 JANKA KRALA 50
;                 03601 MARTIN
;                 CZECHOSLOVAKIA
;
; THIS PROGRAM  CONVERTS FILES BETWEEN OPERATING
;SYSTEMS ISIS-II AND CP/M AND LISTS DIRECTORY OF
;THE CP/M DISK IN A SPECIFIC DRIVE. THE PROGRAM
;IS INITIATED BY TYPING THE COMMAND:
;-CONVER
;PROGRAM CONVERSION PROMPTS:
;TYPE OF CONVERSION :
;AND WAITS FOR ANSWER. ANSWER MAY BE ONE OF FOLLOWING:
;SYSTEM1 TO SYSTEM2
;OR
;DIR [TO <LIST FILE>] [<SWITCH>]
;WHERE:
;  - "SYSTEM1", "SYSTEM2" ARE ISIS OR CP/M
;  - <LIST FILE>  IS THE NAME OF THE FILE TO
;                 CONTAIN THE DIRECTORY LISTING.
;                 IF FILE IS DISK FILE THEN
;                 CP/M AND ISIS DISK MUST BE
;                 IN DIFFERENT DRIVE.
;   - <SWITCH> CAN BE ONE OR MORE OF THE
;              FOLLOWING:
;            - 0 OR 1  LISTS THE DIRECTORY OF 
;                      THE DISK IN :F0: OR :F1:.
;                      IF OMITTED, THE DIRECTORY
;                      OF THE DISK IN :F0: IS
;                      LISTED
;            - Z  PRINTS THE NUMBER OF SECTORS
;                 PRESENTLY USED  ON THE SPECIFIED
;                 DISK AS A FRACTION OF THE NUMBER
;                 OF AVAILABLE SECTORS.
;THE PROGRAM CONVERSION RUNS UNDER THE ISIS-II SYSTEM.
;
;
;
	NAME	CONVER
	EXTRN	OPEN,READ,WRITE,EXIT,ERROR,CLOSE
SECLN	EQU	80H	;SECTOR LENGTH
NOSEC	EQU	1AH	;NUMBER OF SECTORS ON TRACK
READF	EQU	4	;READ FUNCTION
WRITF	EQU	6	;WRITE FUNCTION
RETRY	EQU	10	;NUMBER OF RETRIES ON DISK
			; ERROR
DSTAT	EQU	78H	;DISK STATUS
RBYTE	EQU	7BH	;RESULT BYTE
RTYPE	EQU	79H	;RESULT TYPE
ILOW	EQU	79H	;LOW ADDRESS
IHIGH	EQU	7AH	;HIGH ADDRESS
IMASDE	EQU	0	;DISK ERROR MASK
IORDY	EQU	4	;I/O FINISHED MASK
CI	EQU	0F803H	;ADDRESS OF CONSOL INPUT
			;ROUTINE
CO	EQU	0F809H	;ADDRESS OF CONSOL OUTPUT
			;ROUTINE
SVP	EQU	3
	CSEG
CONVER:	MVI	A,55H	;START OF PROGRAM
	STA	SVP
	LXI	SP,STACK
	LXI	D,MEMORY
	LXI	H,80H
	CALL	CITA
	LXI	D,MEMORY
	LXI	H,TEXT0
	MVI	C,2
	CALL	POROV
	JNZ	KONPOR
	JMP	POKRK	;TYPE OF CONVERSION
TYPZS:	LXI	D,MEMORY	;END RETURN
	LXI	H,40
	CALL	CITA	;READ INPUT DATA FROM CONSOLE
	LXI	D,MEMORY
	CALL	KMV	;UPPER CASE CONVERSION
	DCR	B	;ISIS TO CP/M?
	MOV	C,B
	LXI	D,MEMORY
	LXI	H,UVOD1
	CALL	POROV
	JZ	OSD	;JUMP IF ISIS TO CP/M
	MOV	C,B	;CP/M TO ISIS?
	LXI	D,MEMORY
	LXI	H,UVOD2
	CALL	POROV
	JZ	OSM	;JUMP IF CP/M TO ISIS
	MVI	C,3	;DIR?
	LXI	D,MEMORY
	LXI	H,UVOD3
	CALL	POROV
	JNZ	KONPOR
	CALL	DIRECT	;DISPLAY DIRECTORY OF THE
			;CP/M DISK
	JMP	FC
KONPOR:	LXI	B,19
	LXI	H,TEXT0
	CALL	VYPIS	;INCORRECT INPUT
	JMP	KONIEC
OSD:	LXI	B,18
	LXI	H,TEXT2
	CALL	VYPIS	;WRITE OUT "ISIS SOURCE FILE:"
	LXI	D,ISISN
	LXI	H,20
	CALL	CITA	;READ ISIS FILE NAME
	LXI	D,ISISN
	CALL	KMV
	LXI	B,23
	LXI	H,TEXT3
	CALL	VYPIS	;WRITE OUT "CP/M DESTINATION FILE:"
	LXI	D,CPMN
	LXI	H,20
	CALL	CITA	;READ CP/M FILE NAME
	LXI	D,CPMN
	CALL	KMV
	CALL	ISCPM	;CONVERSION ISIS TO CP/M
	JMP	FC
OSM:	LXI	B,18
	LXI	H,TEXT4
	CALL	VYPIS	;WRITE OUT "CP/M SOURCE FILE:"
	LXI	D,CPMN
	LXI	H,20
	CALL	CITA	;READ CP/M FILE NAME
	LXI	D,CPMN
	CALL	KMV
	LXI	B,23
	LXI	H,TEXT5
	CALL	VYPIS	;WRITE OUT "ISIS DESTINATION
			;FILE:"
	LXI	D,ISISN
	LXI	H,20
	CALL	CITA	;READ ISIS FILE NAME
	LXI	D,ISISN
	CALL	KMV
	CALL	CPMIS	;CONVERSION CP/M TO ISIS
FC:	LHLD	CPOS	;CLOSE OPENING FILE
	MOV	C,L
	MOV	B,H
	LXI	D,ACCH
	CALL	CLOSE
	LDA	ACCH
	ORA	A
	JNZ	CHYBA
	LXI	B,21	;FUNCTION COMPLETE
	LXI	H,TEXT6
	CALL	VYPIS
	JMP	KONIEC
CITA:	LXI	B,1	;PREPARE PARAMETERS FOR READING
	PUSH	B
	PUSH	D	;ADDRESS OF INPUT BUFFER
	PUSH	H	;LENGTH OF READ REQUESTED
	LXI	B,APPB	;COUNT OF BYTES READ
	LXI	D,ACCH	;ERROR NUMBER FIELD
	CALL	READ
	LDA	ACCH
	ORA	A
	JNZ	CHYBA
	RET
POROV:	LDAX	D
	CMP	M
	RNZ
	INX	D
	INX	H
	DCR	C
	JNZ	POROV
	RET
KMV:	LDA	APPB	;LOWER CASE TO UPPER CASE
	MOV	C,A
	MOV	B,A
ER:	LDAX	D
	CPI	61H
	JC	ER1
	CPI	7BH
	JNC	ER1
	SUI	20H
	STAX	D
ER1:	INX	D
	DCR	C
	JNZ	ER
	RET
CHYBA:	LHLD	ACCH	;ERROR
	MOV	B,H
	MOV	C,L
	LXI	D,ACCH
	CALL	ERROR	;OUTPUT ERROR MESSAGE
KONIEC:	LHLD	CPOS	;CLOSE FILE WITH
	MOV	C,L	;IGNORING ERROR
	MOV	B,H
	LXI	D,ACCH
	CALL	CLOSE
STPO:	LXI	H,TPOKR	;CONTINUE (Y/N)? :
	LXI	B,19
	CALL	VYPIS
	CALL	CI
	MOV	C,A
	CALL	CO
	ANI	7FH
	CPI	59H
	JZ	POKRK
	CPI	79H
	JZ	POKRK
	CPI	4EH
	JZ	WAITCR
	CPI	6EH
	JZ	WAITCR
	MVI	C,0AH
	CALL	CO
	MVI	C,0DH
	CALL	CO
	JMP	STPO
WAITCR:	MVI	C,0AH
	CALL	CO
	LXI	H,TEXT1	;END OF PROGRAM
	LXI	B,52
	CALL	VYPIS	;WRITE OUT "INSERT ISIS SYSTEM
			;DISK ..."
	CALL	CI	;READ <CR>
	ANI	7FH
	CPI	0DH
	JNZ	WAITCR	;WAIT FOR CRLF
	MVI	C,0AH
	CALL	CO
	MVI	C,0DH
	CALL	CO
	LXI	D,ACCH
	CALL	EXIT	;EXIT
	HLT
POKRK:	LXI	H,CELKPS
	MVI	C,12
	MVI	M,0
	INX	H
	DCR	C
	JNZ	POKRK+5
	CMA
	STA	YYY
	LXI	H,NCPMN
	MVI	C,11
	MVI	M,20H
	DCR	C
	INX	H
	JNZ	$-4
	LXI	H,TYPC	;TYPE OF CONVERSION :
	LXI	B,23
	CALL	VYPIS
	JMP	TYPZS
;
; SUBPROGRAM TO CONVERSION CP/M TO ISIS
;
CPMIS:	LXI	H,CPMN
	MOV	A,M	;WHERE IS CP/M DISK ?
	CPI	3AH
	JNZ	NADR0	;DRIVE 0
	MVI	C,3
	INX	H
	LXI	D,DRIVE0
	CALL	ZHODA
	MOV	A,C
	ANA	A
	JNZ	SKUS1	;NO DRIVE 0,TRY DRIVE 1
NADR0:	XRA	A
	CALL	VYPCPM
	JMP	HLPRGR	;JMP TO MAIN SECTION
VYPCPM:	STA	PARBD	;WRITE OUT "INSERT CP/M DISK ..."
	LXI	H,INCPM
	LXI	B,28
	CALL	VYPIS
	LDA	PARBD
	ORI	30H
	MOV	C,A
	CALL	CO
	LXI	H,NAVR
	LXI	B,18
	CALL	VYPIS
NEBLB:	CALL	CI
	ANI	7FH
	CPI	0DH
	RZ
	JMP	NEBLB
ZHODA:	LDAX	D	;COMPARE C-BYTES ON ADDRESS
			;IN DE AND HL
	CMP	M	;IF EQUAL THEN C = 0
	RNZ		;ELSE RETURN WITH C # 0
	INX	D
	INX	H
	DCR	C
	JNZ	ZHODA
	RET		;EQUAL
CITDIR:	MVI	A,IMASDE ;READ DIRECTORY OF CP/M DISK
	STA	PARBI
	STA	PARBF	;FUNCTION NUMBER
	INR	A
	STA	PARBS	;SECTOR NUMBER
	INR	A
	STA	PARBT	;TRACK NUMBER
	LXI	H,MEMORY
	SHLD	PARBA	;ADDRESS FOR READING
	MVI	A,16
	STA	PARBN	;NUMBER OF SECTORS
	CALL	PERFUN	;PERFORM READING
PLDISK:	ANA	A
	RZ
	LXI	H,CHPDO
	LXI	B,22
	CALL	VYPIS	;WRITE OUT "DISK OPERATION
			;ERROR"
	JMP	KONPOR
PERFUN:	LDA	PARBD	;PERFORM DISK FUNCTION
	MOV	C,A
	CALL	SELDSK
PERFUL:	LDA	PARBN	;FUNCTION COMPLETED
	ANA	A
	RZ		;YES RETURN WITH A=0
	LDA	PARBS	;SET SECTOR
	MOV	C,A
	CALL	SETSEC
	LDA	PARBT	;SET TRACK
	MOV	C,A
	CALL	SETTRK
	LHLD	PARBA	;SET ADDRESS
	MOV	C,L
	MOV	B,H
	CALL	SEDMA
	LDA	PARBF	;SELECT FUNCTION
	ANA	A
	JZ	PERFUR	;PERFORM READ FUNCTION
	CALL	WRITED	;PERFORM WRITE FUNCTION
	JZ	PERFUE
PERFUR:	CALL	READD
PERFUE:	LXI	H,PARBI	;ERROR?
	MOV	C,A
	MOV	A,M
	CMA
	ANA	C
	RNZ		;RETURN WITH SET ERROR BITS
			;IN A
	LXI	H,PARBN
	DCR	M	;DECREMENT NUMBER OF SECTORS
	LHLD	PARBA	;INCREMENT BUFFER ADDRESS
	LXI	B,SECLN
	DAD	B
	SHLD	PARBA
	LDA	PARBS	;INCREMENT SECTOR NUMBER
	CPI	16H
	JNZ	PERFU1
	MVI	A,1
	STA	PARBS
	LXI	H,PARBT
	INR	M
	JMP	PERFUL	;AGAIN LOOP
PERFU1:	ADI	6	;ADD 6 MODULO 26
	CPI	NOSEC+1
	JNC	ALSEC
CALSEC:	STA	PARBS
	JMP	PERFUL	;AGAIN LOOP
ALSEC:	SBI	26
	CPI	1
	JNZ	CALSEC
	INR	A
	JMP	CALSEC
READD:	MVI	C,READF	;READ NEXT DISK RECORD
	CALL	SETFUN
	CALL	WAITIO	;PERFORM READ FUNCTION
	RET		;MAY HAVE ERROR BITS IN A
WRITED:	MVI	C,WRITF	;WRITE NEXT DISK RECORD
	CALL	SETFUN
	CALL	WAITIO	;PERFORM WRITE FUNCTION
	RET
SELDSK:	MOV	A,C	;INSERT DRIVE NUMBER GIVEN BY
	ORA	A	;C IN IOPB
	JZ	SELDS0	;DRIVE 0
	MVI	A,30H	;DRIVE 1
SELDS0:	MOV	C,A
	LXI	H,IOF	;I/O FUNCTION
	MOV	A,M
	ANI	0CFH	;MASK OUT DISK NUMBER
	ORA	C	;MASK IN NEW DISK NUMBER
	MOV	M,A	;AND SAVE IT IN IOPB
	RET
SEDMA:	MOV	L,C	;INSERT DMA ADDRESS GIVEN BY
	MOV	H,B	;C IN IOPB
	SHLD	IOD
	RET
SETTRK:	LXI	H,IOT	;INSERT TRACK NUMBER GIVEN BY
	MOV	M,C	;IN IOPB
	RET
SETSEC:	MOV	A,C	;INSERT SECTOR NUMBER GIVEN BY
	STA	IOS	;C IN IOPB
	RET
SETFUN:	LXI	H,IOF	;INSERT FUNCTION NUMBER GIVEN
	MOV	A,M	;BY C IN IOPB
	ANI	38H
	ORA	C
	MOV	M,A
	ANI	20H	;MASK THE DISK SELECT BIT
	LXI	H,IOS	;ADDRESS THE SECTOR NUMBER BYTE
	ORA	M	;SELECT PROPER DISK
	MOV	M,A	;SET DISK SELECT BIT
	RET
WAITIO:	MVI	C,RETRY	;MAX. NUMBER OF RETRIES BEFORE
			;PERF. ERROR
REWAIT:	IN	RTYPE
	IN	RBYTE	;CLEARS THE CONTROLLER
	LXI	H,IOPB
	MOV	A,L
	OUT	ILOW	;LOW ADDRESS OF IOPB TO CONTROLLER
	MOV	A,H
	OUT	IHIGH	;HIGH ADDRESS OF IOPB TO CONTROLLER
WAIT0:	IN	DSTAT	;WAIT FOR COMPLETION
	ANI	IORDY	;READY
	JZ	WAIT0
	IN	RTYPE
	ANA	A
	JNZ	WREADY	;UNIT NOT READY
	IN	RBYTE
	ANA	A
	RZ		;FUNCTION IS O.K.
TRYAG:	DCR	C
	JNZ	REWAIT	;ERROR BYTE IN A
	RET
WREADY:	IN	RBYTE
	MVI	A,0FFH
	JMP	TRYAG
VYPISS:	LXI	H,INISS	;TYPE: INSERT ISIS DISK ...
	LXI	B,28
	CALL	VYPIS
	LDA	ADAM
	ORI	30H
	MOV	C,A
	CALL	CO
	LXI	H,NAVR
	LXI	B,18
	CALL	VYPIS
ZASBLB:	CALL	CI
	ANI	7FH
	CPI	0DH
	RZ
	JMP	ZASBLB
POPISS:	LXI	H,ISISN
	MOV	A,M
	CPI	3AH
	JNZ	DNADR0	;ISIS DISK ON DRIVE 0
	INX	H
	INX	H
	MOV	A,M
	CPI	30H
	JZ	DNADR0
	CPI	31H
	JNZ	KONPOR	;WRONG INPUT OF ISIS FILENAME
	MVI	A,1	;ISIS DISK ON DRIVE 1
	JMP	DNADR
DNADR0:	XRA	A
DNADR:	STA	ADAM
	JMP	VYPISS
SKUS1:	MVI	C,3
	LXI	H,CPMN+1
	LXI	D,DRIVE1
	CALL	ZHODA	;IS CP/M DISK ON DRIVE 1
	MOV	A,C
	ANA	A
	JNZ	KONPOR	;IF NOT THEN WRONG FILENAME
	INR	A
	CALL	VYPCPM
HLPRGR:	CALL	CITDIR	;MAIN SECTION CP/M TO ISIS
	CALL	POPISS
	LXI	H,CPOS
	PUSH	H
	LXI	H,ISISN
	PUSH	H
	LXI	H,2
	PUSH	H
	LXI	B,0
	LXI	D,ACCH
	CALL	OPEN	;OPEN ISIS FILE FOR WRITING
	LDA	ACCH
	ORA	A
	JNZ	CHYBA
	LXI	H,CPMN	;ADAPTATION OF CP/M FILENAME
	MOV	A,M
	CPI	3AH
	JNZ	NEDR
	LXI	D,CPMN+4
	JMP	HLBOD
NEDR:	XCHG
HLBOD:	LXI	B,NCPMN
	MVI	L,11
PREHM:	LDAX	D
	CPI	2EH
	JZ	NASBOD	;FOUND POINT
	CPI	0DH
	JZ	KONMEN	;END OF FILENAME
	STAX	B
	INX	D
	INX	B
	DCR	L
	JNZ	PREHM
KONMEN:	LXI	H,MEMORY ;LOOK AT DIRECTORY
	MVI	B,64
ZNOVHL:	SHLD	SLPAM	;LOOK NEXT ENTRY
	MOV	A,M
	ANA	A
	CZ	OBSAD	;FULL ENTRY
	LXI	D,20H
	DAD	D
	DCR	B
	JNZ	ZNOVHL
	JMP	KONHL	;END OF LOOKING
NASBOD:	INX	D
	LXI	B,NCPMN+8
	MVI	L,3
	JMP	PREHM
OBSAD:	INX	H
	LXI	D,NCPMN
	MVI	C,11
	CALL	ZHODA	;COMPARE FILENAMES
	MOV	A,C
	ANA	A
	PUSH	B
	CZ	NASIEL	;IF EQUAL FIND OUT ATTRIBUTES OF FILE
	POP	B
	LHLD	SLPAM
	RET
NASIEL:	LXI	B,15
	LHLD	SLPAM	;FIND OUT NUMBER OF FULL SECTORS
	DAD	B	;AND MOVE SECOND 16 BYTES OF
	MOV	C,M	;FILE ENTRY AT ADDRESS MEMORY
	INX	H	;+800H ACCORDING TO EXTENSION
	XCHG
	LHLD	POCSEK
	DAD	B
	SHLD	POCSEK
	LHLD	SLPAM
	LXI	B,12
	DAD	B
	MOV	A,M
	LXI	B,16
	LXI	H,MEMORY+800H
HLEXT:	ANA	A	;WHAT EXTENSION WAS FOUND
	JZ	MOVE
	DCR	A
	DAD	B
	JMP	HLEXT
MOVE:	MOV	A,C	;MOVE BLOCK OF MEMORY FROM
			;SOURCE ADDRESS
	ANA	A	;IN DE TO DESTINATION ADDRESS
			;IN HL.
	RZ		;NUMBER OF BYTES IN C
	LDAX	D
	MOV	M,A
	INX	D
	INX	H
	DCR	C
	JMP	MOVE
DEL26:	LXI	B,26	;DIVISION BY 26:INPUT IN DE
	LXI	H,0	;               OUTPUT IN DE
	MVI	A,10H	;	        REMAINDER IN HL
DELDAL:	PUSH	PSW
	DAD	H
	XCHG
	SUB	A
	DAD	H
	XCHG
	ADC	L
	SUB	C
	MOV	L,A
	MOV	A,H
	SBB	B
	MOV	H,A
	INX	D
	JNC	DELBC
	DAD	B
	DCX	D
DELBC:	POP	PSW
	DCR	A
	JNZ	DELDAL
	RET
KONHL:	LHLD	POCSEK
	MOV	D,H
	MOV	A,L
	ORA	D
	ANA	A
	JZ	KONPOR	;IF FILE IS EMPTY THEN ERROR
	LXI	H,MEMORY+800H
DALTIS:	SHLD	SLPAM
	LXI	D,0	;FIND OUT TRACK AND SECTOR
			;WHEN IS BLOCK
	MOV	A,M
	RLC		;MULTIPLICATION BY 8
	RLC
	RLC
	MOV	E,A
	ANI	7
	MOV	D,A
	MOV	A,E
	ANI	0F8H
	MOV	E,A
	CALL	DEL26	;DIVISION BY 26
	INX	D
	INX	D	;INCREASE ABOUT 2 TRACKS WHEN
			;IS SYSTEM
	INX	H
	MOV	A,E
	STA	PARBT	;SAVE TRACK NUMBER
	XRA	A
	INR	A
	DCR	L
ZISCS:	JZ	MACS	;FIND OUT SECTOR NUMBER
	ADI	6
	CPI	NOSEC+1
	JNC	ODP26
ZNIZL:	DCR	L
	JMP	ZISCS
ODP26:	SBI	26
	CPI	1
	JNZ	ZNIZL
	INR	A
	JMP	ZNIZL
MACS:	STA	PARBS	;SAVE SECTOR NUMBER
	LXI	H,ADAM
	LDA	PARBD
	CMP	M
	CZ	VYPCPM
	MVI	A,8
	STA	PARBN
	LXI	H,MEMORY
	SHLD	PARBA
	CALL	PERFUN	;READ 8 SECTORS FROM CP/M FILE
	CALL	PLDISK
	LHLD	POCSEK
	MOV	A,H
	ANA	A
	JNZ	ODP8
	MOV	A,L
	CPI	9
	JC	POSLTS	;REMAIN TO READ ONLY LAST BLOCK
ODP8:	LXI	D,0FFF8H
	DAD	D
	SHLD	POCSEK
	LXI	H,400H	;NUMBER OF BYTES, WHICH IS
			;NECESSARY WRITE TO ISIS
	SHLD	POCZAP	;FILE
	CALL	ZAPIS
	LHLD	SLPAM
	INX	H
	JMP	DALTIS
ZAPIS:	LXI	H,ADAM
	LDA	PARBD
	CMP	M
	CZ	VYPISS
	LHLD	CPOS
	SHLD	COS
	LHLD	POCZAP
	MOV	C,L
	MOV	B,H
	LXI	H,MEMORY
	JMP	VYPIS
POSLTS:	LXI	B,SECLN	;WORKING LAST BLOCK
	LXI	D,0
	LXI	H,MEMORY-1
HLPOSK:	DAD	B	;FIND LAST SECTOR
	XCHG
	DAD	B
	XCHG
	DCR	A
	JZ	POSLSK
	JMP	HLPOSK
POSLSK:	MOV	A,M	;WORKING LAST SECTOR
	CPI	1AH
	JNZ	POBYTE	;FOUND LAST BYTE OF FILE
	DCX	D
	DCX	H
	JMP	POSLSK
POBYTE:	XCHG
	SHLD	POCZAP
	JMP	ZAPIS
;
;  SUBPROGRAM TO CONVERSION ISIS TO CP/M
;
ISCPM:	LXI	H,ISISN
	MOV	A,M
	CPI	3AH
	JNZ	INADR0
	INX	H
	INX	H
	MOV	A,M
	CPI	30H
	JZ	INADR0
	CPI	31H
	JNZ	KONPOR
	MVI	A,1	;ISIS FILE IS ON :F1:
	JMP	INADR
INADR0:	XRA	A	;ISIS FILE IS ON :F0:
INADR:	STA	ADAM
	CALL	VYPISS	;INSERT ISIS DISK ON DRIVE ...
	LXI	H,CPOS	;OPEN THE ISIS FILE FOR READING
	PUSH	H
	LXI	H,ISISN
	PUSH	H
	LXI	H,1
	PUSH	H
	LXI	B,0
	LXI	D,ACCH
	CALL	OPEN
	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IR 0
	CPI	20H
	JZ	DALPAR	;LOOK AT NEXT PARAMETERS
	JMP	KONPOR	;JMP TO ERROR
DIR0:	XRA	A
DIR:	CALL	VYPCPM	;TYPE "INSERT CP/M DISK ON
	LDA	PARBD	;DRIVE ... "
	ADI	30H
	STA	BUFDIR+13
	CALL	CITDIR	;READ DIRECTORY OF DISK TO
			;MEMORY
	LHLD	CPOS
	SHLD	COS
	LXI	H,TDIR-1
	MVI	M,0AH
	DCX	H
	MVI	M,0DH
	LXI	B,35
	CALL	VYPIS	;WRITE OUT HEADER OF TEXT
	LHLD	CPOS
	SHLD	COS
	DCX	B
	DCX	B
	LXI	H,TDIR
	CALL	VYPIS
	LHLD	CPOS
	SHLD	COS
	LXI	H,TDIR-2
	MVI	C,2
	CALL	VYPIS
	MVI	A,0FFH
	STA	NEVYP	;INDICATION OF WRITING:
			;       FF WRITE DIRECTORY
			;	00 NO
DIRPRE:	LXI	H,MEMORY
	MVI	B,64
ZNOVPR:	SHLD	SLPAM
	MOV	A,M
	ANA	A
	CZ	OBSADP
	LHLD	SLPAM
	LXI	D,20H
	DAD	D
	DCR	B
	JNZ	ZNOVPR
	JMP	VYPOB
OBSADP:	LHLD	SLPAM
	LXI	D,15
	DAD	D
	MOV	A,M
	CPI	80H
	RZ		;RETURN IF NOT LAST ENTRY OF
	PUSH	B	;FILE COMPUTE NUMBER OF SECTORS
	LXI	B,0	;AND WRITE OUT FILENAME
	MOV	C,A
	LXI	D,12
	LHLD	SLPAM
	DAD	D
	LXI	D,80H
	MOV	A,M
	LXI	H,0
	DAD	B
	ANA	A
CYKL:	JZ	UCHOV	;LAST EXTENSION
	DAD	D	;IN HL NUMBER OF SECTORS
	DCR	A
	JMP	CYKL
UCHOV:	SHLD	POCBL1	;NUMBER OF SECTORS OF ONE FILE
	LXI	D,0
	LHLD	POCBL1
	MVI	A,4
	LXI	B,BUFDIR+3
	CALL	PBIDEK	;TRANSFER TO DECIMAL FORM
	LHLD	POCBL1
	MOV	A,L
	OR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1
PBIDE2:	LXI	H,0
	LXI	B,NOT 9
	CALL	PBIDED	;DIVISION BY TEN
	XTHL
	XCHG
	CALL	PBIDED
	MVI	A,30H
	ADD	E	;TRANSFERING REMAINDER TO ASCII
	MOV	B,A	;AND SAVE ITS IN B
	POP	D
	MOV	A,L
	ORA	H
	ORA	D
	ORA	E
	JZ	PBIDE3
	XTHL
	MOV	M,B
	DCX	H
	XTHL
	PUSH	H
	JMP	PBIDE2
PBIDE3:	POP	H
	MOV	M,B
	RET
PBIDED:	MVI	A,3CH
	PUSH	H
PBIDE6:	INX	SP
	INX	SP
PBIDE7:	XCHG
	RAR
	DAD	H
	RAL
	JNC	$+4
	INX	H
	ADI	4
	RM
	XCHG
	DAD	H
	RAR
	JNC	$+4
	INX	H
	ADD	A
	PUSH	H
	DAD	B
	JC	PBIDE6
	POP	H
	JMP	PBIDE7
VYPIS:	PUSH	H	;WRITE TO SPECIFIC DEVICE TEXT
	PUSH	B	;TEXT FROM ADDRESS IN HL
	XCHG
	LHLD	COS
	PUSH	H
	PUSH	D
	LXI	D,ACCH
	CALL	WRITE
	LDA	ACCH
	ORA	A
	JNZ	CHYBA	;JUMP IF ERROR
	MOV	H,A
	MOV	L,A
	SHLD	COS
	POP	B
	POP	H
	RET
	DSEG
CELKPS:	DB	0,0
CPOS:	DB	0,0	;OPEN FILE NUMBER
POCSEK:	DB	0,0	;NUMBER OF SECTORS
ZAZNPT:	DB	0	;NUMBER OF BLOCKS
TROP:	DB	0
XXX:	DB	0
CEXT:	DB	0	;EXTENSION NUMBER
COS:	DB	0,0	;OPEN FILE NUMBER
NCPMN:	DB	'           '
YYY:	DB	0FFH
ACCH:	DS	2	;ERROR NUMBER FIELD
ISISN:	DS	20	;ISIS FILE NAME
CPMN:	DS	20	;CP/M FILE NAME
APPB:	DS	2	;COUNT OF BYTES READ
TEXT0:	DB	0DH,0AH,'INCORRECT INPUT',0DH,0AH
TEXT1:	DB	0DH,'INSERT ISIS SYSTEM DISK ON DRIVE 0 THEN TYPE RETURN'
TEXT2:	DB	'ISIS SOURCE FILE: '
TEXT3:	DB	'CP/M DESTINATION FILE: '
TEXT4:	DB	'CP/M SOURCE FILE: '
TEXT5:	DB	'ISIS DESTINATION FILE: '
TEXT6:	DB	0DH,0AH,'FUNCTION COMPLETE',0DH,0AH
UVOD1:	DB	'ISIS TO CP/M',0DH,0AH
UVOD2:	DB	'CP/M TO ISIS',0DH,0AH
UVOD3:	DB	'DIR'
TPOKR:	DB	'CONTINUE (Y/N) ? : '
TYPC:	DB	0DH,0AH,'TYPE OF CONVERSION : '
DRIVE0:	DB	'F0:'
DRIVE1:	DB	'F1:'
PARB:			;PARAMETER BLOCK FOR READ/WRITE
PARBD:	DS	1	;DRIVE NUMBER 0/1
PARBF:	DS	1	;FUNCTION NUMBER
PARBN:	DS	1	;NUMBER OF SECTORS
PARBT:	DS	1	;TRACK NUMBER
PARBS:	DS	1	;SECTOR NUMBER
PARBA:	DS	2	;BUFFER ADDRESS
PARBI:	DS	1	;ERROR MASK
INCPM:	DB	0DH,0AH,'INSERT CP/M DISK ON DRIVE '
NAVR:	DB	0DH,0AH,'THEN TYPE RETURN'
CHPDO:	DB	0DH,0AH,'DISK OPERATION ERROR'
INISS:	DB	0DH,0AH,'INSERT ISIS DISK ON DRIVE '
IOPB:			;I/O PARAMETER BLOK
	DB	80H	;NORMAL I/O OPERATION
IOF:	DS	1	;I/O FUNCTION
ION:	DB	1	;NUMBER OF SECTORS
IOT:	DS	1	;TRACK NUMBER
IOS:	DS	1	;SECTOR NUMBER
IOD:	DS	2	;I/O ADDRESS
SLPAM:	DS	2	;TRACE MEMORY
ADAM:	DS	1
POCZAP:	DS	2
NEVYP:	DS	1
PVOLTS:	DS	0F3H	;FIELD OF BLOCKS
SLISP:	DS	2	;TRACE ISIS MEMORY
KONBUF:	DS	2	;END OF ISIS FILE
SLTIS:	DS	2	;TRACE BLOCKS
ALB:	DS	1
CPS:	DB	0DH,0AH,'    /1996 BLOCKS USED',0DH,0AH
POCBL1:	DS	2
TDIR:	DB	'RECS BYTS EX D:FILENAME.TYP      '
BUFDIR:	DB	'        K                        '
	END	CONVER
