*DECK DLRDW
IDENT DLRDW
ENTRY DLRDW
*IF DEF,IMS
*#
*1DC DLRDW
*
* 1. PROC NAME AUTHOR DATE
* DLRDW P.C.TAM 78/10/05
*
* 2. FUNCTIONAL DESCRIPTION.
* READ A BLOCK FROM CIO BUFFER
*
* 3. METHOD USED.
* CALL READW MACRO
*
* 4. ENTRY PARAMETERS.
* (A1) ADDRESS OF THE ADDRESS OF FET
* (A1)+1 ADDRESS OF THE ADDRESS OF REQUIRED SIZE
* (A1)+2 ADDRESS OF THE ADDRESS OF WORK BUFFER
*
* 5. EXIT PARAMETERS.
* ((A1)+3) 0 IF EOR ENCOUNTERED
* -1 IF EOF ENCOUNTERED
* -2 IF EOI ENCOUNTERED
*
* 6. COMMON DECKS CALLED.
* NONE.
*
* 7. ROUTINES CALLED.
* NONE.
*
* 8. DAYFILE MESSAGES.
* NONE.
*
*#
*ENDIF
DLRDW SUBR = ENTRY/EXIT
SX7 A1
SA7 SAVEA1
RD1 BSS 0
SB1 1
SA3 A1+B1
SA2 A3+B1 (X2)=ADDRESS OF WORK BUFFER
SA3 X3 (X3)=SIZE REQUIRED
READW X1,X2,X3
SA5 SAVEA1
SA4 X5+3
NZ X1,RD2
* DATA TRANSFER COMPLETE
SA3 X5+1 READ REQUIRED SIZE
SA3 X3
BX6 X3
EQ RD4
* DATA TRANSFER NOT COMPLETE
RD2 BSS 0
MI X1,RD3
SA3 X5+2 READ ADDR OF WB
IX6 X1-X3
NZ X6,RD4
* EOR ENCOUNTERED W/O READING ANYTHING
SX6 B0
EQ RD4
* EOI/EOF ENCOUNTERED
RD3 BSS 0
SX6 X1
RD4 BSS 0
SA6 X4
EQ DLRDWX RETURN
SAVEA1 BSS 1
END