	.TITLE	FALMACROS - MACRO DEFINITIONS FOR FAL

	.IDENT	/X0.1-7/



;

;			  COPYRIGHT (c) 1977, 1978 BY

;	      DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.

;

; THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED

; ONLY  IN  ACCORDANCE  WITH  THE  TERMS  OF  SUCH  LICENSE AND WITH THE

; INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR  ANY  OTHER

; COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY

; OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY

; TRANSFERRED.

;

; THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT  NOTICE

; AND  SHOULD  NOT  BE  CONSTRUED  AS  A COMMITMENT BY DIGITAL EQUIPMENT

; CORPORATION.

;

; DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR  RELIABILITY  OF  ITS

; SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.

;



;++

; FACILITY: DECNET FILE ACCESS LISTENER (FAL)

;

; ABSTRACT: MACRO DEFINITIONS USED BY FAL MODULES.

;

; ENVIRONMENT:

;

;	THE FAL IMAGE EXECUTES IN THE CONTEXT OF A PROCESS CREATED BY

;	NETACP. IT RUNS IN USER MODE AND REQUIRES NETWORK PRIVILEGE.

;

; AUTHOR: JAMES A. KRYCKA,	CREATION DATE: 16-JUN-77

;

; MODIFICATIONS:

;

;--



	.SBTTL	SYMBOL DEFINITION MACROS



;++

; MISC_SYMBOLS DEFINES MISCELLANEOUS CONSTANTS AND OFFSETS USED

; BY VARIOUS FAL MODULES.

;--



	.MACRO	MISC_SYMBOLS

RCVEFN=1				; RECEIVE QIO EVENT FLAG

XMTEFN=2				; TRANSMIT QIO EVENT FLAG

MBXEFN=3				; READ MAILBOX QIO EVENT FLAG



FAL$V_LOG_STAT=0			; LOG STATISTICAL INFORMATION

FAL$V_LOG_MSG=1				; LOG EACH MESSAGE



FAL$K_MBXBUF=64				; MAILBOX BUFFER LENGTH

FAL$K_MBXQUOTA=FAL$K_MBXBUF*8		; MAILBOX QUOTA

FAL$K_MBXPROT=^X0000			; MAILBOX PROTECTION MASK

	.MACRO	MISC_SYMBOLS		; REDEFINE MACRO TO NULL TO

	.ENDM	MISC_SYMBOLS		; RECLAIM SPACE

	.ENDM	MISC_SYMBOLS



	.SBTTL	CODE GENERATION MACROS



;++

; QBLOCK GENERATES A QUADWORD DESCRIPTOR BLOCK FOLLOWED BY THE

; CHARACTER STRING AND/OR ALLOCATED SPACE.

;--



	.MACRO	QBLOCK	TEXT,SPACE=0,BUFADR,?LABEL1,?LABEL2

	.LONG	LABEL2-LABEL1

	.LONG	LABEL1

	.IF NB	BUFADR

BUFADR==.

	.ENDC

LABEL1:

	.IRP	STR,<TEXT>

	.ASCII	\STR\

	.ENDR

	.IF NE	SPACE

	.BLKB	SPACE

	.ENDC

LABEL2:

	.ENDM	QBLOCK



;++

; SSB SETS A SINGLE BIT IN A FIELD.

;--



	.MACRO	SSB	POS,BASE,?DISPL

	BBSS	POS,BASE,DISPL

DISPL:

	.ENDM	SSB



;++

; CSB CLEARS A SINGLE BIT IN A FIELD.

;--



	.MACRO	CSB	POS,BASE,?DISPL

	BBCC	POS,BASE,DISPL

DISPL:

	.ENDM	CSB



;++

; MAPBIT MAPS THE DESIGNATED BIT FROM R1 INTO THE DESIGNATED BIT IN R2.

; THE BIT IS SET IN R2 ONLY IF THE CORRESPONDING BIT IS SET IN R1.

;--



	.MACRO	MAPBIT	SRCBIT,DSTBIT,?LABEL

	BBC	#SRCBIT,R1,LABEL

	BBCS	#DSTBIT,R2,LABEL

LABEL:

	.ENDM	MAPBIT



;++

; ZERO_FILL WRITES ZEROES INTO THE SPECIFIED BUFFER. ON COMPLETION R0-R5 ARE

; DESTROYED (WITH R3 CONTAINING THE ADDRESS OF ONE BYTE BEYOND THE BUFFER).

; THE DEFAULT IS TO ZERO 512 BYTES (1 PAGE) AT THE SPECIFIED ADDRESS.

;--



	.MACRO	ZERO_FILL DST=,SIZE=#512

	MOVC5	#0,DST,#0,SIZE,DST

	.ENDM	ZERO_FILL



;++

; CHECK_SS BRANCHES TO A SUBROUTINE THAT CHECKS THE STATUS CODE IN R0

; FOLLOWING A CALL TO A SYSTEM SERVICE.

;--



	.MACRO	CHECK_SS

	BSBW	FAL$CHECK_SS

	.ENDM	CHECK_SS



;++

; CHECK_RMS BRANCHES TO A SUBROUTINE THAT CHECKS THE COMPLETION CODE IN R0

; FOLLOWING A CALL TO RMS.

;--



	.MACRO	CHECK_RMS

	BSBW	FAL$CHECK_RMS

	.ENDM	CHECK_RMS



;++

; $CASEB, $CASEW, AND $CASEL GENERATE A CASEB, CASEW, CASEL INSTRUCTION,

; RESPECTIVELY, FOLLOWED BY THE CASE DISPLACEMENT TABLE. THE PARAMETERS

; FOR EACH MACRO ARE:

;	SELECTOR= THE SELECTOR OPERAND

;	BASE	= THE BASE OPERAND

;	(THE LIMIT OPERAND IS CALCULATED FROM THE # OF ENTRIES IN DISPL)

;	DISPL	= THE CASE DISPLACEMENT LIST

; NOTE THAT THE MACRO DEFINITIONS PLACE BASE AFTER SELECTOR AND DISPL

; SO THAT BASE CAN BE OMITTED WHEN KEYWORDS ARE NOT USED IN THE MACRO

; INVOCATION.

;--



	.MACRO	$CASEB	SELECTOR,DISPL,BASE=#0

	$CASE	SELECTOR,<DISPL>,BASE,TYPE=B

	.ENDM	$CASEB



	.MACRO	$CASEW	SELECTOR,DISPL,BASE=#0

	$CASE	SELECTOR,<DISPL>,BASE,TYPE=W

	.ENDM	$CASEW



	.MACRO	$CASEL	SELECTOR,DISPL,BASE=#0

	$CASE	SELECTOR,<DISPL>,BASE,TYPE=L

	.ENDM	$CASEL



;++

; $CASE IS A LEVEL 2 MACRO USED BY $CASEB, $CASEW, AND $CASEL.

; $CASE GENERATES A CASE[B/W/L] INSTRUCTION FOLLOWED BY THE CASE

; DISPLACEMENT TABLE. THE PARAMETERS FOR THE MACRO ARE:

;	TYPE	= OPERAND DATATYPE OF B, W, OR L

;	SELECTOR= THE SELECTOR OPERAND

;	BASE	= THE BASE OPERAND

;	(THE LIMIT OPERAND IS CALCULATED FROM THE # OF ENTRIES IN DISPL)

;	DISPL	= THE CASE DISPLACEMENT LIST

; NOTE THAT THE MACRO DEFINITION PLACES SELECTOR AND DISPL AHEAD OF BASE

; AND TYPE SO THAT THE LATTER CAN BE OMITTED WHEN KEYWORDS ARE NOT USED

; IN THE MACRO INVOCATION.

;--



	.MACRO	$CASE	SELECTOR,DISPL,BASE=#0,TYPE=B,?TABLE

	$$COUNT=0

	.IRP	EP,<DISPL>

	$$COUNT=$$COUNT+1

	.ENDR

	.IF	EQ,$$COUNT

	.ERROR	; ***** CASE DISPLACEMENT LIST IS NULL ***** ;

	.MEXIT

	.ENDC

	CASE'TYPE	SELECTOR,BASE,#<$$COUNT-1>

TABLE:

	.IRP	EP,<DISPL>

	.WORD	EP-TABLE

	.ENDR

	.ENDM	$CASE

	.END





;	.TITLE	$FALDEF - FAL CONTROL BLOCK DEFINITIONS

;	.IDENT	/X0.1-16/



;

;			  COPYRIGHT (c) 1977, 1978 BY

;	      DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.

;

; THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED

; ONLY  IN  ACCORDANCE  WITH  THE  TERMS  OF  SUCH  LICENSE AND WITH THE

; INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR  ANY  OTHER

; COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY

; OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY

; TRANSFERRED.

;

; THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT  NOTICE

; AND  SHOULD  NOT  BE  CONSTRUED  AS  A COMMITMENT BY DIGITAL EQUIPMENT

; CORPORATION.

;

; DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR  RELIABILITY  OF  ITS

; SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.

;



;++

; FACILITY: DECNET FILE ACCESS LISTENER (FAL)

;

; ABSTRACT:

;

;	THIS MODULE DEFINES SYMBOLS FOR THE FAL CONTROL BLOCKS WHICH ARE

;	INVOKED BY THE $FALWRKDEF AND $FALSTBDEF MACROS.

;

; ENVIRONMENT:

;

;	THE MDL TRANSLATOR MUST BE USED TO CONVERT FALDEF.MDL INTO

;	FALDEF.MAR (AND FALDEF.B32).

;

; AUTHOR: JAMES A. KRYCKA,	CREATION DATE: 16-JUN-77

;

; MODIFICATIONS:

;

;--



;++

; $FALWRKDEF DEFINES FAL WORK AREA OFFSETS AND SYMBOLS.

;--



	$STRUCT	FAL,WRKDEF

	F FLG,Q			; MISCELLANEOUS FLAG

	  V <			; FLAGS DENOTE:

	    CNF_MSG		;  PROCESSED CONFIGURATION MESSAGE

	    ATT_MSG		;  PROCESSED ATTRIBUTES MESSAGE

	    CONNECT		;  PERFORMED CONNECT FUNCTION

	    ,5			;

	    FILE_MODE		;  FILE TRANSFER MODE (VS RECORD TRANSFER MODE)

	    BLOCK_IO		;  BLOCK I/O MODE

	    EOF			;  END-OF-FILE ENCOUNTERED DURING RECORD ACCESS

	    ,5			;

	    RCVAST		; RECEIVE MESSAGE AST FLAG

	    XMTAST		; TRANSMIT MESSAGE AST FLAG

	    MBXAST		; MAILBOX MESSAGE AST FLAG

	    ,5			;

	    >			;

	F STATE_CTX,Q		; STATE TRANSITION TABLE CONTEXT:

;	  S TBL_ADDR,0,L	;  STATE TABLE ADDRESS

;	  S CUR_ADDR,4,L	;  CURRENT TABLE ENTRY ADDRESS

	F VALUE,B		; STATE TRANSITION VALUE

	F ,B,3			; SPARE LOCATIONS

	F MAXDAPSIZ,W		; MAXIMUM DAP MESSAGE SIZE (DETERMINED VIA

				;  EXCHANGE OF CONFIGURATION MESSAGES)

	F ACTUALSIZ,W		; ACTUAL SIZE OF ALLOCATED RCV AND XMT BUFFERS

	F LNKCHN,W		; LINK CHANNEL #

	F MBXCHN,W		; ASSOCIATED MAILBOX CHANNEL #

	F LNKIOSB,Q		; LINK CHANNEL I/O STATUS BLOCK

	F MBXIOSB,Q		; MAILBOX CHANNEL I/O STATUS BLOCK

	F MBX,Q			; MAILBOX MESSAGE DESCRIPTOR BLOCK

	  S NCB,0,Q		; NCB DESCRIPTOR BLOCK

	F BOUNDS,Q		; LOWER/UPPER ADDRESS BOUNDS OF THE

				;  COMBINED RCV AND XMT BUFFERS

	F RCV,Q			; RECEIVE DAP MESSAGE DESCRIPTOR

	F XMT,Q			; TRANSMIT DAP MESSAGE DESCRIPTOR

	F SPARE,L,13		; UNUSED LOCATIONS

				; ******** OFFSET = ^X80 = 128 ********

	F MBXBUF,T,64		; MAILBOX BUFFER

	  K MBXBUF,64		; MAILBOX BUFFER SIZE

	  S NCBBUF,0,T,64	; NCB BUFFER

	    K NCBBUF,64		; NCB BUFFER SIZE

	F STB,L,8		; STATISTICS BLOCK

	  K STB,32		; STATISTICS BLOCK SIZE

	F ,L,8			; UNUSED LOCATIONS

				; ******** OFFSET = ^X100 = 256 ********

	F DAP,T,192		; DAP CONTROL BLOCK STORAGE AREA

	  K DAP,192		; MAX DAP CONTROL BLOCK SIZE

	F ,L,16			; UNUSED LOCATIONS

				; ******** OFFSET = ^X200 = 512 ********

	F FAB,L,20		; FAB CONTROL BLOCK STORAGE AREA

	  K FAB,80		; FAB CONTROL BLOCK SIZE

	F RAB,L,17		; RAB CONTROL BLOCK STORAGE AREA

	  K RAB,68		; RAB CONTROL BLOCK SIZE

	F NAM,L,14		; NAM CONTROL BLOCK STORAGE AREA

	  K NAM,56		; NAM CONTROL BLOCK SIZE

	F ,L,13			; UNUSED LOCATIONS

				; ******** OFFSET = ^X300 = 768 ********

	F RESULTANT,T,128	; RESULTANT STRING STORAGE AREA

	  K RESULTSIZ,128	; RESULTANT STRING SIZE (MAX)

	F BUFFER,T,128		; SCRATCH BUFFER

	  K BUFFERSIZ,128	; SCRATCH BUFFER SIZE

	L WRKBLN		; DEFINE LENGTH OF THIS CONTROL BLOCK

	E			;



;++

; $FALSTBDEF DEFINES FAL STATISTICS BLOCK OFFSETS AND SYMBOLS.

;--



	$STRUCT	FAL,STBDEF

	F RCV_MSG,L		; TOTAL # OF DAP MESSAGES RECEIVED

	F XMT_MSG,L		; TOTAL # OF DAP MESSAGES TRANSMITTED

	F RCV_BYTE,L		; TOTAL # OF DAP MESSAGE BYTES RECEIVED

	F XMT_BYTE,L		; TOTAL # OF DAP MESSAGE BYTES TRANSMITTED

	F RCV_REC,L		; TOTAL # OF DATA RECORDS RECEIVED

	F XMT_REC,L		; TOTAL # OF DATA RECORDS TRANSMITTED

	F RCV_DATA,L		; TOTAL # OF DATA RECORD BYTES RECEIVED

	F XMT_DATA,L		; TOTAL # OF DATA RECORD BYTES TRANSMITTED

	L STBBLN		; DEFINE LENGTH OF THIS CONTROL BLOCK

	E			;

	.END





;	.TITLE	$DAPDEF - DATA ACCESS PROTOCOL DEFINITIONS

;	.IDENT	/X0.1-19/



;

;			  COPYRIGHT (c) 1977, 1978 BY

;	      DIGITAL EQUIPMENT CORPORATION, MAYNARD, MASS.

;

; THIS SOFTWARE IS FURNISHED UNDER A LICENSE AND MAY BE USED AND  COPIED

; ONLY  IN  ACCORDANCE  WITH  THE  TERMS  OF  SUCH  LICENSE AND WITH THE

; INCLUSION OF THE ABOVE COPYRIGHT NOTICE.  THIS SOFTWARE OR  ANY  OTHER

; COPIES  THEREOF MAY NOT BE PROVIDED OR OTHERWISE MADE AVAILABLE TO ANY

; OTHER PERSON.  NO TITLE TO AND OWNERSHIP OF  THE  SOFTWARE  IS  HEREBY

; TRANSFERRED.

;

; THE INFORMATION IN THIS SOFTWARE IS SUBJECT TO CHANGE  WITHOUT  NOTICE

; AND  SHOULD  NOT  BE  CONSTRUED  AS  A COMMITMENT BY DIGITAL EQUIPMENT

; CORPORATION.

;

; DIGITAL ASSUMES NO RESPONSIBILITY FOR THE USE OR  RELIABILITY  OF  ITS

; SOFTWARE ON EQUIPMENT WHICH IS NOT SUPPLIED BY DIGITAL.

;



;++

; FACILITY: DATA ACCESS PROTOCOL (DAP)--A COMPONENT OF DECNET

;

; ABSTRACT: THIS MODULE DEFINES THE DAP INTERNAL CONTROL BLOCK.

;

; ENVIRONMENT:

;

;	THE MDL TRANSLATOR MUST BE USED TO CONVERT DAPDEF.MDL INTO

;	DAPDEF.MAR (AND DAPDEF.B32).

;

; AUTHOR: JAMES A. KRYCKA,	CREATION DATE: 17-OCT-77

;

; MODIFICATIONS:

;

;--



;++

; NOTE:	COMMENT FIELDS THAT BEGIN WITH ';*' IN THE MDL DEFINITIONS BELOW,

;	INDICATE THAT THE DAP FIELD OR BIT DEFINITION IS AN IMPLEMENTATION

;	OF A 'RESERVED' ITEM IN THE DAP V4.1 SPECIFICATION OR THAT IT WAS

;	DEFINED AFTER THE DAP V4.1 SPECIFICATION.

;

; NOTE:	COMMENT FIELDS THAT BEGIN WITH ';#' IN THE MDL DEFINITIONS BELOW

;	INDICATE THAT THE DAP FIELD OR BIT DEFINITION WAS DEFINED IN THE

;	DAP V4.1 SPECIFICATION BUT WAS SUBSEQUENTLY REMOVED (MADE RESERVED).

;

; NOTE:	TO KEEP THE TOTAL NUMBER OF DAP SYMBOLS TO A MINIMUM, SYMBLOS NOT

;	REQUIRED FOR THIS IMPLEMENTATION ARE COMMENTED OUT.

;

; NOTE:	LONGWORD AND QUADWORD FIELDS ARE LONGWORD ALLIGNED WITHIN THE

;	CONTROL BLOCK.

;--



	$STRUCT	DAP



;++

; DEFINE SYMBOLS IN THE PROLOGUE OF THE DAP CONTROL BLOCK

;--



; *****	OFFSET = 00 *****



	F DCODE_FLG,Q		; DECODE ROUTINE FLAGS

				;  BITS 00-31 ARE DEFINED EXTERNAL TO DAP

				;  BITS 32-63 ARE DEFINED BY DAP

	  V <			;

	    ,32			;  SKIP OVER RESERVED BITS

	    AFTER_V41		;  PARTNER IMPLEMENTED TO DAP AFTER V4.1

	    VAXVMS		;  PARTNER IS VAX/VMS

	    >			;

	F DCODE_STS,L		; STATUS CODE OF MESSAGE DECODE ATTEMPT

	  S ,0,B		; MESSAGE DECODE SUCCESS/FAIL (1/0) INDICATOR

	  S FIELD_ID,1,B	; ID OF FIELD IN ERROR; ELSE 0

	  S MSG_TYPE,2,B	; MESSAGE TYPE (0 IF INVALID)

	  S MAC_CODE,3,B	; DAP MACCODE ERROR VALUE; ELSE 0

	F MSG_MASK,L		; BIT MASK OF VALID MESSAGES TO RECEIVE

				;  BIT OFFSETS AND BIT MASKS ARE:

				;	DAP$K_CNF_MSG;	<1@DAP$K_CNF_MSG>

				;  THRU	DAP$K_STS_MSG;	<1@DAP$K_STS_MSG>

	F MSG_BUF1,Q		; ON INPUT, DESCRIPTOR OF MESSAGE TO DECODE

				; ON OUTPUT, DESCRIPTOR OF NEXT BLOCKED

				;  MESSAGE IF COUNT NON-ZERO

	F MSG_BUF2,Q		; ON OUTPUT, DESCRIPTOR OF MESSAGE JUST

				;  DECODED; SAME AS MSG_BUF1 ON INPUT IF

				;  NO BLOCKED MESSAGE FOLLOWS



;++

; DEFINE SYMBOLS RELATED TO THE DAP MESSAGE HEADER.

;--



; *****	OFFSET = 20 *****



	F OPERATOR,L		; OPERATOR FIELD SUBDIVIDED INTO:

	  S TYPE,0,B		; DAP MESSAGE TYPE FIELD (1) : B

	    K <			; DAP MESSAGE TYPE:

	      CNF_MSG,1		;  CONFIGURATION MESSAGE

	      ATT_MSG,2		;  ATTRIBUTES MESSAGE

	      ACC_MSG,3		;  ACCESS MESSAGE

	      CTL_MSG,4		;  CONTROL MESSAGE

	      CON_MSG,5		;  CONTINUE TRANSFER MESSAGE

	      ACK_MSG,6		;  ACKNOWLEDGE MESSAGE

	      CMP_MSG,7		;  ACCESS COMPLETE MESSAGE

	      DAT_MSG,8		;  DATA MESSAGE

	      STS_MSG,9		;  STATUS MESSAGE

	      >			;

	  S FLAGS,1,B		; DAP MESSAGE FLAGS FIELD (EX-5) : BM

	    V <			; MENU OF FIELDS TO FOLLOW:

	      STREAMID		;  STREAMID

	      LENGTH		;  LENGTH

	      TMP1..,6		;  UNDEFINED

;	      LEN256		;* LEN256

	      >			;

	    K FLAGS_I,<-	; DEFINE FLAGS OPTIONS THAT ARE INVALID:

	      <1@DAP$V_TMP1..>!-;  RESERVED AND UNDEFINED BITS

	      0>		;

;	    K FLAGS_U,<-	; DEFINE FLAGS OPTIONS UNSUPPORTED BY VAX:

;	      0>		;

;	    K FLAGS_D,0		; DEFINE DEFAULT FLAGS VALUE

	  S STREAMID,2,B	; DATA STREAM IDENTIFICATION FIELD (1) : B

;	    K STREAM_D,0	; DEFINE DEFAULT STREAMID VALUE

	  S LENGTH,3,B		; LENGTH (OF REST OF MESSAGE) FIELD (1) : B

;	    K LENGTH_D,0	; DEFINE DEFAULT LENGTH VALUE



;++

; DEFINE SYMBOLS RELATED TO THE CONFIGURATION MESSAGE (TYPE=1).

;--



; *****	OFFSET = 24 *****



	F BUFSIZ,W		; BUFFER SIZE FIELD (2) : B

	  K BUFSIZ_V,<4096+256>	;  MAXIMUM VALUE FOR VAX

	F OSTYPE,B		; OPERATING SYSTEM TYPE FIELD (1) : B

	  K <			; OPERATING SYSTEM TYPE:

;	    RT11,1		;  RT-11

;	    RSTS,2		;  RSTS/E

;	    RSX11S,3		;  RSX-11S

;	    RSX11M,4		;  RSX-11M

;	    RSX11D,5		;  RSX-11D

;	    IAS,6		;  IAS

	    VAXVMS,7		;  VAX/VMS

;	    TOPS20,8		;* TOPS-20

;	    TOPS10,9		;* TOPS-10

;	    RTS8,10		;* RTS-8

;	    OS8,11		;* OS-8

	    >			;

	F FILESYS,B		; FILE SYSTEM TYPE FIELD (1) : B

	  K <			; FILE SYSTEM TYPE:

;	    RMS11,1		;  RMS-11

;	    RMS20,2		;  RMS-20

	    RMS32,3		;  RMS-32

;	    FCS11,4		;  FCS-11

;	    RT_FILSYS,5		;  RT-11

;	    NO_FILSYS,6		;  NO FILE SYSTEM PRESENT

;	    TOPS20F,7		;* TOPS-20

;	    TOPS10F,8		;* TOPS-10

;	    OS8F,9		;* OS-8

	    >			;

	F VERSION,Q		; DAP VERSION FIELD SUBDIVIDED INTO:

	  S VERNUM,0,B		;  DAP VERSION NUMBER FIELD (1) : B

	    K VERNUM_V,4	;  VALUE FOR VAX

	  S ECONUM,1,B		;  ECO VERSION NUMBER FIELD (1) : B

	    K ECONUM_V,2	;  VALUE FOR VAX

	  S USRNUM,2,B		;  USER PROTOCOL VERSION NUMBER FIELD (1) : B

	    K USRNUM_V,0	;  VALUE FOR VAX

	  S SOFTVER,3,B		;  DEC SOFTWARE RELEASE NUMBER FIELD (1) : B

	    K SOFTVER_V,1	;  VALUE FOR VAX

	  S USRSOFT,4,B		;  USER SOFTWARE RELEASE NUMBER FIELD (1) : B

	    K USRSOFT_V,0	;  VALUE FOR VAX

	  S ,5,B,3		;  PADDING

	F SYSCAP,Q		; SYSTEM CAPABILITIES FIELD (EX-12) : BM

	  V <			; PARTNER NODE SUPPORTS:

	    FILALL		;  ALLOCATION OF SPACE AT FILE CREATION

	    SEQORG		;  SEQUENTIAL FILE ORGANIZATION

	    RELORG		;  RELATIVE FILE ORGANIZATION

	    ,2			;  RESERVED FOR:

;	    HSHORG		;  HASHED FILE ORGANIZATION

;	    IDXORG		;  SINGLE KEYED INDEXED FILE ORGAIZATION

	    SEQREC		;  SEQUENTIAL RECORD ACCESS

	    RANREC		;  RANDOM ACCESS BY RECORD #

	    RANVBN		;  RANDOM ACCESS BY VIRTUAL BLOCK #

	    ,5			;  RESERVED FOR:

;	    RANKEY		;  RANDOM ACCESS BY KEY

;	    RANHSH		;  RANDOM ACCESS BY USER GENERATED HASH CODE

;	    RANRFA		;  RANDOM ACCESS BY RECORD FILE ADDRESS

;	    MULKEY		;  MULTI-KEYED INDEXED FILE ORGANIZATION

;	    SWMODE		;  DYNAMIC SWITCHING OF ACCESS MODE

	    APPEND		;  APPEND RECORD ACCESS

	    SUBMIT		;  COMMAND FILE SUBMISSION/EXECUTION

	    ,2			;  RESERVED FOR:

;	    COMPRS		;  FILE COMPRESSION

;	    MDS			;  MULTIPLE DATA STREAMS PER FILE

	    STSRTN		;  RETURN OF STATUS MSG AFTER XFR

	    MSGBLK		;  BLOCKING OF DAP MESSAGES UP TO RESPONSE

	    ,10			;  RESERVED FOR:

;	    UNRBLK		;* UNRESTRICTED BLOCKING OF DAP MESSAGES

;	    BIGBLK		;* BLOCKING OF DAP MESSAGES OVER 256 BYTES

;	    CHKSUM		;* FILE CHECKSUM OPTION

;	    KEYXAB		;* KEY DEFINITION XAB MESSAGE

;	    ALLXAB		;* ALLOCATION XAB MESSAGE

;	    SUMXAB		;* SUMMARY XAB MESSAGE

;	    FHCXAB		;* FILE HEADER CHARACTERISTICS XAB MESSAGE

;	    DATXAB		;* DATE AND TIME XAB MESSAGE

;	    PROXAB		;* FILE PROTECTION XAB MESSSAGE

;	    ACLXAB		;* ACCESS CONTROL LIST XAB MESSAGE

	    FOPSPL		;* FILE SPOOLING ON CLOSE FOP OPTION

	    FOPSCF		;* COMMAND FILE EXECUTION ON CLOSE FOP OPTION

	    FOPDLT		;* FILE DELETION OF CLOSE FOP OPTION

	    ,2			;  RESERVED FOR:

;	    DFSPEC		;* DEFAULT FILE SPECIFICATION STRING

;	    RLSPEC		;* RELATED FILE SPECIFICATION STRING

	    ,30			;  UNDEFINED

	    >			;

	  K SYSCAP_V,<-		; DEFINE SYSCAP OPTIONS SUPPORTED BY VAX

	    <1@DAP$V_FILALL>!-	;  FILALL

	    <1@DAP$V_SEQORG>!-	;  SEQORG

	    <1@DAP$V_RELORG>!-	;  RELORG

	    <1@DAP$V_SEQREC>!-	;  SEQREC

	    <1@DAP$V_RANREC>!-	;  RANREC

	    <1@DAP$V_RANVBN>!-	;  RANVBN

	    <1@DAP$V_APPEND>!-	;  APPEND

	    <1@DAP$V_SUBMIT>!-	;  SUBMIT

	    <1@DAP$V_STSRTN>!-	;  STSRTN

	    <1@DAP$V_MSGBLK>!-	;  MSGBLK

	    <1@DAP$V_FOPSPL>!-	;  FOPSPL

	    <1@DAP$V_FOPSCF>!-	;  FOPSCF

	    <1@DAP$V_FOPDLT>!-	;  FOPDLT

	    0>			;



;++

; DEFINE SYMBOLS RELATED TO THE ATTRIBUTES MESSAGE (TYPE=2).

;--



; *****	OFFSET = 38 *****



	F ATTMENU,L		; ATTRIBUTES MENU FIELD (EX-6) : BM

	  V <			; MENU OF FIELDS TO FOLLOW:

	    DATATYPE,,,M	;  DATA TYPE

	    ORG,,,M		;  FILE ORGANIZATION

	    RFM,,,M		;  RECORD FORMAT

	    RAT,,,M		;  RECORD ATTRIBUTES

	    BLS,,,M		;  BLOCK SIZE

	    MRS,,,M		;  MAXIMUM RECORD SIZE

	    ALQ,,,M		;  ALLOCATION QUANTITY

	    BKS,,,M		;  BUCKET SIZE

	    FSZ,,,M		;  FIXED CONTROL AREA SIZE

	    MRN,,,M		;  MAXIMUM RECORD NUMBER

	    RUNSYS,,,M		;  RUN-TIME SYSTEM IDENTIFICATION

	    DEQ,,,M		;  DEFAULT EXTENSION QUANTITY

	    FOP,,,M		;  FILE OPTIONS

	    TMP1..,1		;  RESERVED FOR BSZ

	    DEV,,,M		;* DEVICE CHARACTERISTICS

	    TMP2..,1		;  RESERVED FOR SDC

	    TMP3..,16		;  UNDEFINED

	    >			;

	  K ATTMENU_I,<-	; DEFINE ATTMENU OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP2..>!-	;  "

	    <1@DAP$V_TMP3..>!-	;  "

	    0>			;

;	  K ATTMENU_U,<-	; DEFINE ATTMENU OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K ATTMENU_D,0		; DEFINE DEFAULT ATTMENU VALUE

	F DATATYPE,B		; DATATYPE FIELD (EX-2) : BM

	  V <			; DEFINE OFFSETS AND MASKS:

	    ASCII		;  DATA IN ASCII FORMAT

	    IMAGE,,,M		;  DATA IN IMAGE FORMAT

	    TMP1..,2		;  RESERVED FOR EBCDIC

				;  "		CMPFMT

	    EXEC		;  FILE CONTAINS EXECUTABLE CODE

	    PRIV		;  FILE CONTAINS PRIVILEGED CODE

	    TMP2..,1		;# RESERVED (IGNORE IF RECEIVED)

	    TMP3..,1		;  UNDEFINED

	    >			;

	  K DATATYP_I,<-	; DEFINE DATATYPE OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP3..>!-	;  "

	    0>			;

;	  K DATATYP_U,<-	; DEFINE DATATYPE OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K DATATYP_D,<-	; DEFINE DEFAULT DATATYPE VALUE

;	    DAP$M_IMAGE!-	;  IMAGE

;	    0>			;

	F ORG,B			; FILE ORGANIZATION FIELD (1) : B

	  K <			; FILE ORGANIZATION:

	    SEQ,0		;  SEQUENTIAL

	    REL,16		;  RELATIVE

	    IDX,32		;  INDEXED

; 	    HSH,48		;  HASHED

	    >			;

;	  K ORG_D,DAP$K_SEQ	; DEFINE DEFAULT ORG VALUE

	F RFM,B			; RECORD FORMAT FIELD (1) : B

	  K <			; RECORD FORMAT:

	    UDF,0		;  UNDEFINED

	    FIX,1		;  FIXED LENGTH

	    VAR,2		;  VARIABLE LENGTH

	    VFC,3		;  VARIABLE WITH FIXED CONTROL

	    STM,4		;  ASCII STREAM

	    LSA,5		;  LINE SEQUENCED ASCII

	    >			;

;	  K RFM_D,DAP$K_FIX	; DEFINE DEFAULT RFM VALUE

	F RAT,B			; RECORD ATTRIBUTES FIELD (EX-3) : BM

	  V <			; MEANING:

	    FTN			;  FORTRAN CARRIAGE CONTROL

	    CR			;  LF-RECORD-CR CONTROL

	    PRN			;* PRINT FILE FORMAT

	    BLK			;  RECORDS DO NOT CROSS BLOCK BOUNDARIES

	    EMBEDDED,,,M	;  RECORDS HAVE EMBEDDED CONTROL CHARACTERS

	    TMP1..,3		;  UNDEFINED

	    >			;

	  K RAT_I,<-		; DEFINE RAT OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    0>			;

;	  K RAT_U,<-		; DEFINE RAT OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K RAT_D,<-		; DEFINE DEFAULT RAT VALUE

;	    DAP$M_EMBEDDED!-	;  RECORDS HAVE EMBEDDED CONTROL CHARACTERS

;	    0>			;

	F BLS,W			; BLOCK SIZE FIELD (2) : B

	  K BLS_D,512		; DEFINE DEFAULT BLS VALUE

	F MRS,W			; MAXIMUN RECORD SIZE FIELD (2) : B

;	  K MRS_D,0		; DEFINE DEFAULT MRS VALUE

	F ALQ,L			; ALLOCATION QUANTITY FIELD (I-5) : B

;	  K ALQ_D,0		; DEFINE DEFAULT ALQ VALUE

	F BKS,B			; BUCKET SIZE FIELD (1) : B

;	  K BKS_D,0		; DEFINE DEFAULT BKS VALUE

	F FSZ,B			; FIXED CONTROL AREA SIZE FIELD (1) : B

;	  K FSZ_D,0		; DEFINE DEFAULT FSZ VALUE

	F DEQ,W			; DEFAULT EXTENSION QUANTITY FIELD (2) : B

;	  K DEQ_D,0		; DEFINE DEFAULT DEQ VALUE

	F MRN,L			; MAXIMUM RECORD NUMBER FIELD (I-5) : B

;	  K MRN_D,0		; DEFINE DEFAULT MRN VALUE

	F RUNSYS,Q		; RUN-TIME SYSTEM FIELD (I-40) : A

				;  DESCRIPTOR

	F FOP,L			; FILE OPTIONS FIELD (EX-6) : BM

	  V <			; OPTIONS:

	    RWO,,,M		;  REWIND MAGTAPE ON OPEN

	    RWC,,,M		;  REWIND MAGTAPE ON CLOSE

	    TMP1..,1		;  RESERVED BIT IN DAP SPEC

	    POS,,,M		;  POSITION MAGTAPE PAST LAST CREATED FILE

	    DLK,,,M		;  DO NOT LOCK IF NOT PROPERLY CLOSED ??????

	    TMP2..,2		;  RESERVED BIT IN DAP SPEC

				;# "

	    CTG,,,M		;  CONTIGUOUS FILE EXTENSION

	    SUP,,,M		;  SUPERSEDE EXISTING FILE

	    NEF,,,M		;  INHIBIT MAGTAPE END OF FILE POSITIONING

	    TMP,,,M		;  CREATE TEMPORARY FILE

	    TMD,,,M		;  CREATE TEMPORARY FILE AND MARK FOR DELETE

	    FID,,,M		;  OPEN FILE BY FILE ID

	    DMO,,,M		;  DISMOUNT MAGTAPE ON CLOSE

	    WCK,,,M		;  ENABLE WRITE CHECKING

	    RCK,,,M		;  ENABLE READ CHECKING

	    CIF,,,M		;  CREATE IF NO FILE PRESENT ELSE OPEN FILE

	    TMP3..,1		;  RESERVED FOR LKO

	    SQO,,,M		;* SEQUENTIAL ACCESS ONLY

	    MXV,,,M		;* MAXIMIZE VERSION NUMBER

	    SPL,,,M		;* SPOOL FILE ON CLOSE

	    SCF,,,M		;* SUBMIT COMMAND FILE ON CLOSE

	    DLT,,,M		;* DELETE FILE ON CLOSE

				;   IT MAY BE USED STAND-ALONE, OR AS A

				;   SUB-OPTION TO SCF OR SPL

	    CBT,,,M		;* CONTIGUOUS BEST TRY

	    TMP4..,8		;  UNDEFINED

	    >			;

	  K FOP_I,<-		; DEFINE FOP OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP2..>!-	;  "

	    <1@DAP$V_TMP3..>!-	;  "

	    <1@DAP$V_TMP4..>!-	;  "

	    0>			;

;	  K FOP_U,<-		; DEFINE FOP OPTIONS UNSUPPORTED BY VAX:

;	    DAP$M_DLK!-		;  DLK

;	    DAP$M_FID!-		;  FID

;	    0>			;

;	  K FOP_D,0		; DEFINE DEFAULT FOP VALUE

;	F BSZ,B			; BYTE SIZE FIELD (1) : B

	F DEV,L			;*DEVICE CHARACTERISTICS FIELD (EX-6) : BM

	  V <			; MEANING:

	    DEVREC		;* DEVICE IS RECORD ORIENTED

	    DEVCCL		;* CARRIAGE CONTROL DEVICE

	    DEVTRM		;* DEVICE IS A TERMINAL

	    DEVDIR		;* DEVICE IS DIRECTORY STRUCTURED

	    DEVSDI		;* DEVICE IS SINGLE DIRECTORY STRUCTURED

	    DEVSQD		;* SEQ. BLOCK ORIENTED DEVICE (E.G., MAGTAPE)

	    TMP1..,1		;  RESERVED BIT IN DAP SPEC

	    DEVFOD		;* FILES ORIENTED DEVICE (E.G., DISK, MAGTAPE)

	    DEVSHR		;* DEVICE IS SHARABLE

	    DEVSPL		;* DEVICE IS BEING SPOOLED

	    DEVMNT		;* DEVICE IS MOUNTED

	    DEVDMT		;* DIVICE IS MARKED FOR DISMOUNT

	    DEVALL		;* DEVICE IS ALLOCATED

	    DEVIDV		;* DEVICE IS CAPABLE OF PROVIDING INPUT

	    DEVODV		;* DEVICE IS CAPABLE OF PROVIDING OUTPUT

	    DEVSWL		;* DEVICE IS SOFTWARE WRITE LOCKED

	    DEVAVL		;* DEVICE IS AVAILABLE

	    DEVELG		;* DEVICE HAS ERROR LOGGING ENABLED

	    DEVMBX		;* DEVICE IS A MAILBOX

	    DEVRTM		;* DEVICE IS REALTIME IN NATURE

	    DEVRND		;* DEVICE ALLOWS RANDOM ACCESS

	    DEVRCK		;* DEVICE HAS READ CHECKING ENABLED

	    DEVWCK		;* DEVICE HAS WRITE CHECKING ENABLED

	    DEVFOR		;* DEVICE IS MOUNTED AS FOREIGN (NOT FILES-11)

	    DEVNET		;* NETWORK DEVICE

	    DEVGEN		;* GENERIC DEVICE

	    TMP2..,6		;  UNDEFINED

	    >			;

	  K DEV_I,<-		; DEFINE DEV OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  "

	    <1@DAP$V_TMP2..>!-	;  "

	    0>			;

;	  K DEV_U,<-		; DEFINE DEV OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K DEV_D,0		; DEFINE DEFAULT DEV VALUE

;	F SDC,L			; SPOOLING DEVICE CHARACTERISTICS FIELD (EX-6) : BM



;++

; DEFINE SYMBOLS RELATED TO THE ACCESS MESSAGE (TYPE=3).

;--



; *****	OFFSET = 60 *****



	F ACCFUNC,B		; ACCESS FUNCTION FIELD (1) : B

	  K <			; ACCESS FUNCTION:

	    OPEN,1		;  OPEN A FILE

	    CREATE,2		;  CREATE A FILE

;	    RENAME,3		;* RENAME A FILE

	    ERASE,4		;  ERASE (DELETE) A FILE

;	    DIR_LIST,6		;* RETURN DIRECTORY LIST

	    SUBMIT,7		;  SUBMIT (COPY AND EXECUTE) A COMMAND FILE

	    EXECUTE,8		;  EXECUTE A COMMAND FILE

	    >			;

	F ACCOPT,B		; ACCESS OPTIONS FIELD (EX-5) : BM

	  V <			; MEANING:

	    NONFATAL,,,M	;  I/O ERRORS ARE NOT FATAL

	    STS_STORE		;  RETURN STATUS MSG AFTER STORAGE OPERATION

	    STS_RETRV		;  RETURN STATUS MSG AFTER RETRIEVAL OPERATION

	    TMP1..,5		;  UNDEFINED

;	    SND_CHECK,,,M	;* RETURN CHECKSUM ON CLOSE

	    >			;

	  K ACCOPT_I,<-		; DEFINE ACCOPT OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    0>			;

;	  K ACCOPT_U,<-		; DEFINE ACCOPT OPTIONS UNSUPPORTED BY VAX:

;	    DAP$M_SND_CHECK!-	;  RETURN CHECHSUM

;	    0>			;

	F FAC,B			; FILE ACCESS FIELD (EX-3) : BM

	  V <			; ACCESS FOR:

	    PUT			;  PUT RECORD

	    GET,,,M		;  GET RECORD

	    DEL			;  DELETE RECORD

	    UPD			;  UPDATE RECORD

	    TRN			;  TRUNCATE FILE

	    BIO			;  BLOCK I/O OPERATIONS

	    TMP1..,2		;  UNDEFINED

	    >			;

	  K FAC_I,<-		; DEFINE FAC OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    0>			;

;	  K FAC_U,<-		; DEFINE FAC OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K FAC_D,<-		; DEFINE DEFAULT FAC VALUE

;	    DAP$M_GET!-		; GET

;	    0>			;

	F SHR,B			; FILE SHARING FIELD (EX-3) : BM

	  V <			; SHARED ACCESS FOR:

	    ,1			;  PUT RECORD

	    ,1			;  GET RECORD

	    ,1			;  DELETE RECORD

	    ,1			;  UPDATE RECORD

	    TMP1..,2		;# RESERVED

	    NIL,,,M		;  NO SHARED ACCESS ALLOWED

	    TMP2..,1		;  UNDEFINED

	    >			;

	  K SHR_I,<-		; DEFINE SHR OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP2..>!-	;  "

	    0>			;

;	  K SHR_U,<-		; DEFINE SHR OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K SHR_D,<-		; DEFINE DEFAULT SHR VALUE

;	    DAP$M_GET!-		;  GET REOCRD

;	    0>			;

	F FILESPEC,Q		; FILE SPECIFICATION FIELD (I-128) : A

				;  DESCRIPTOR

;	F DISPLAY,W		; DISPLAY ATTRIBUTES FIELD (EX-4) : BM

;	F PASSWORD,Q		; PASSWORD FIELD (I-40) : B

;				;  DESCRIPTOR



;++

; DEFINE SYMBOLS RELATED TO THE CONTROL MESSAGE (TYPE=4).

;--



; *****	OFFSET = 6C *****



	F CTLFUNC,B		; CONTROL FUNCTION FIELD (1) : B

	  K <			; CONTROL FUNCTION:

	    GET_READ,1		;  GET/READ A RECORD/BLOCK

	    CONNECT,2		;  ESTABLISH A DATA STREAM

	    UPDATE,3		;  UPDATE A RECORD

	    PUT_WRITE,4		;  PUT/WRITE A RECORD/BLOCK

	    DELETE,5		;  DELETE A RECORD

	    REWIND,6		;* REWIND A FILE

;	    TRUNCATE,7		;* TRUNCATE SEQUENTIAL FILE

;	    RELEASE,9		;* RELEASE RECORD

;	    FREE,10		;* FREE ALL RECORDS

	    SPACE,11		;* FORWARD OR BACKWARD SPACE A FILE

;	    FLUSH,12		;* FLUSH ALL RECORDS

;	    NXTVOL,13		;* PERFORM END-OF-VOLUME PROCESSING

	    FIND,14		;* FIND A RECORD

;	    EXTEND,15		;* EXTEND FILE

;	    DISPLAY,16		;* DISPLAY FILE ATTRIBUTES

	    >			;

	F CTLMENU,B		; CONTROL MENU FIELD (EX-4) : BM

	  V <			; MENU OF FIELDS TO FOLLOW:

	    RAC,,,M		;  RAC

	    KEY,,,M		;  KEY

	    TMP1..,1		;  RESERVED FOR KRF

	    ROP,,,M		;  ROP

	    TMP2..,2		;  RESERVED FOR HSH

				;  "		DISPLAY

	    TMP3..,2		;  UNDEFINED

	    >			;

	  K CTLMENU_I,<-	; DEFINE CTLMENU OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP2..>!-	;  "

	    <1@DAP$V_TMP3..>!-	;  "

	    0>			;

;	  K CTLMENU_U,<-	; DEFINE CTLMENU OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K CTLMENU_D,0		; DEFINE DEFAULT CTLMENU VALUE

	F RAC,B			; RECORD ACCESS FIELD (1) : B

	  K <			; RECORD ACCESS TYPE:

	    SEQ_ACC,0		;  SEQUENTIAL RECORD ACCESS

	    KEY_ACC,1		;  KEYED ACCESS

	    RFA_ACC,2		;  ACCESS BY RFA

	    SEQ_FILE,3		;  SEQUENTIAL FILE TRANSFER

	    BLK_VBN,4		;  BLOCK MODE ACCESS BY VBN

	    BLK_FILE,5		;  BLOCK MODE FILE TRANSFER

	    >			;

;	  K RAC_D,DAP$K_SEQ_FILE ; DEFINE DEFAULT RAC VALUE

	F ,B			; PADDING

;	F KRF,B			; KEY OF REFERENCE FIELD (1) : B

	F KEY,Q			; KEY FIELD (I-255) : B

;	  K KEY_D,0		; DEFINE DEFAULT KEY VALUE

	F ROP,L			; RECORD OPTIONS FIELD (EX-6) : BM

	  V <			; MEANING:

	    EOF			;  POSITION TO END-OF-FILE

	    TMP1..,10		;  RESERVED BIT IN DAP SPEC

				;  "

				;  RESERVED FOR HSH

				;  "		LOA

				;  "		ULK

				;  RESERVED BIT IN DAP SPEC

				;  "		RAH

				;  "		WBH

				;  "		KGE

				;  "		KGT

	    TMP2..,21		;  UNDEFINED

	    >			;

	  K ROP_I,<-		; DEFINE ROP OPTIONS THAT ARE INVALID:

	    <1@DAP$V_TMP1..>!-	;  RESERVED AND UNDEFINED BITS

	    <1@DAP$V_TMP2..>!-	;  "

	    0>			;

;	  K ROP_U,<-		; DEFINE ROP OPTIONS UNSUPPORTED BY VAX:

;	    0>			;

;	  K ROP_D,0		; DEFINE DEFAULT ROP VALUE

;	F HSH,L			; HASH CODE FIELD (I-5) : B

;	F DISPLAY2,W		; DISPLAY ATTRIBUTES FIELD (EX-4) : BM



;++

; DEFINE SYMBOLS RELATED TO THE CONTINUE TRANSFER MESSAGE (TYPE=5).

;--



; *****	OFFSET = 7C *****



	F CONFUNC,B		; CONTINUE TRANSFER FUNCTION FIELD (1) : B

	  K <			; RECOVERY ACTION:

	    RETRY,1		;  TRY ACCESS FUNCTION AGAIN

	    SKIP_REC,2		;  SKIP RECORD IN ERROR AND CONTINUE

	    ABORT,3		;  ABORT TRANSFER

	    >			;

	F ,B,3			; PADDING









;++

; DEFINE SYMBOLS RELATED TO THE ACKNOWLEDGE MESSAGE (TYPE=6).

;--



;	NONE



;++

; DEFINE SYMBOLS RELATED TO THE ACCESS COMPLETE MESSAGE (TYPE=7).

;--



; *****	OFFSET = 80 *****



	F CMPFUNC,B		; ACCESS COMPLETE FUNCTION FIELD (1) : B

	  K <			; ACCESS COMPLETE FUNCTION:

	    CLOSE,1		;  CLOSE THE FILE

	    RESPONSE,2		;  RESPONSE TO PARTNER'S CMPFUNC REQUEST

	    PURGE,3		;  CLOSE AND ERASE THE FILE

	    DISCON,4		;  DISCONNECT RECORD STREAM

	    >			;

	F ,B,3			; PADDING

;	F CHKSUM,W		; CHECKSUM FIELD (2) : B

	F FOP2,L		; FILE OPTIONS FIELD (EX-6) : BM

				;  (SEE FOP FIELD OF ATTRIBUTES MESSAGE

				;  FOR ALL BIT DEFINITIONS)









;++

; DEFINE SYMBOLS RELATED TO THE DATA MESSAGE (TYPE=8).

;--



; *****	OFFSET = 88 *****



	F NUMBER,Q		; RECORD NUMBER FIELD (I-8) : B

	F FILEDATA,Q		; FILE DATA FIELD (REST OF MESSAGE)

				;  DESCRIPTOR



;++

; DEFINE SYMBOLS RELATED TO THE STATUS MESSAGE (TYPE=9).

;--



; *****	OFFSET = 98 *****



	F STSCODE,W		; DAP STATUS CODE FIELD (2) : B

;	  V <M			; SUBFIELDS:

;	    MICCODE,12		;  MICRO STATUS CODE

;	    MACCODE,4		;  MACRO STATUS CODE

;	    >			;

	  K <,$_		; MACCODE FIELD STATUS CODES:

	    PENDING,0		;  OPERATION IN PROGRESS

	    SUCCESS,1		;  SUCCESSFUL COMPLETION

	    UNSUPPORT,2		;  DAP IMPELMENTATION DOES NOT SUPPORT REQUEST

	    FILE_OPEN,4		;  ERRORS RELATED TO OPENING A FILE

	    FILE_XFER,5		;  ERRORS ENCOUNTERED WHILE FILE IS OPEN;

				;  I.E., DURING FILE TRANSFER OR RECORD ACCESS

	    FILE_CLOS,7		;  ERRORS RELATED TO CLOSING A FILE

	    FORMAT,8		;  PARSE ERROR CAUSED BY INCORRECT FORMAT

	    INVALID,9		;  INVALID FIELD VALUE

	    MSG_SYNC,10		;  DAP MESSAGE RECEIVED OUT-OF-ORDER

	    >			;

	F ,W			; PADDING

	F RFA,Q			; RECORD FILE ADDRESS FIELD (I-8) : B

	F RECNUM,L		; RECORD NUMBER FIELD (I-8) : B

	F STV,L			; SECONDARY STATUS FIELD (I-8) : B









; *****	OFFSET = AC *****



	F ,L,5			; UNUSED LOCATIONS

	L BLN			; DEFINE LENGTH OF THIS CONTROL BLOCK

	E			;



;++

; $DAPFLDDEF DEFINES DAP FIELD IDENTIFICATION SYMBOLS.

;--



	$STRUCT	DAP,FLDDEF



	K <,$_			; MISCELLANEOUS FIELD ID CODES:

	  UNKNOWN,0		;  UNKNOWN FIELD

	  TYPE,8		;  DAP MESSAGE TYPE FIELD

	  >			;

	K <,$_			; MESSAGE HEADER FIELD ID CODES:

	  FLAGS,8		;  DAP MESSAGE FLAGS FIELD

	  STREAMID,9		;  DATA STREAM IDENTIFICATION FIELD

	  LENGTH,10		;  LENGTH FIELD

	  >			;

	K <,$_			; CONFIGURATION MESSAGE FIELD ID CODES:

	  BUFSIZ,16		;  BUFFER SIZE FIELD

	  OSTYPE,17		;  OPERATING SYSTEM TYPE FIELD

	  FILESYS,18		;  FILE SYSTEM TYPE FIELD

	  VERNUM,19		;  DAP VERSION NUMBER FIELD

	  ECONUM,20		;  ECO VERSION NUMBER FIELD

	  USRNUM,21		;  USER PROTOCOL VERSION NUMBER FIELD

	  SOFTVER,22		;  DEC SOFTWARE RELEASE NUMBER FIELD

	  USRSOFT,23		;  USER SOFTWARE RELEASE NUMBER FIELD

	  SYSCAP,24		;  SYSTEM CAPABILITIES FIELD

	  >			;

	K <,$_			; ATTRIBUTES MESSAGE FIELD ID CODES:

	  ATTMENU,16		;  ATTRIBUTES MENU FIELD

	  DATATYPE,17		;  DATA TYPE FIELD

	  ORG,18		;  FILE ORGANIZATION FIELD

	  RFM,19		;  RECORD FORMAT FIELD

	  RAT,20		;  RECORD ATTRIBUTES FIELD

	  BLS,21		;  BLOCK SIZE FIELD

	  MRS,22		;  MAXIMUM RECORD SIZE FIELD

	  ALQ,23		;  ALLOCATION QUANTITY FIELD

	  BKS,24		;  BUCKET SIZE FIELD

	  FSZ,25		;  FIXED CONTROL AREA SIZE FIELD

	  MRN,26		;  MAXIMUM RECORD NUMBER FIELD

	  RUNSYS,27		;  RUN-TIME SYSTEM FIELD

	  DEQ,28		;  DEFAULT EXTENSION QUANTITY FIELD

	  FOP,29		;  FILE OPTIONS FIELD

;	  BSZ,30		;  BYTE SIZE FIELD

	  DEV,31		;  DEVICE CHARACTERISTICS FIELD

				;  RESERVED FOR SDC,32

	  >			;

	K <,$_			; ACCESS MESSAGE FIELD ID CODES:

	  ACCFUNC,16		;  ACCESS FUNCTION FIELD

	  ACCOPT,17		;  ACCESS OPTIONS FIELD

	  FILESPEC,18		;  FILE SPECIFICATION FIELD

	  FAC,19		;  FILE ACCESS FIELD

	  SHR,20		;  FILE SHARING FIELD

;	  DISPLAY,21		;  DISPLAY ATTRIBUTES FIELD

;	  PASSWORD,22		;  PASSWORD FIELD

	  >			;

	K <,$_			; CONTROL MESSAGE FIELD ID CODES:

	  CTLFUNC,16		;  CONTROL FUNCTION FIELD

	  CTLMENU,17		;  CONTROL MENU FIELD

	  RAC,18		;  RECORD ACCESS FIELD

	  KEY,19		;  KEY FIELD

;	  KRF,20		;  KEY OF REFERENCE FIELD

	  ROP,21		;  RECORD OPTIONS FIELD

;	  HSH,22		;  HASH FIELD

;	  DISPLAY2,23		;  DISPLAY ATTRIBUTES FIELD

	  >			;

	K <,$_			; CONTINUE TRANSFER MESSAGE FIELD ID CODES:

	  CONFUNC,16		;  CONTINUE TRANSFER FUNCTION FIELD

	  >			;

				; ACKNOWLEDGE MESSAGE FIELD ID CODES:

				;  NONE

	K <,$_			; ACCESS COMPLETE MESSAGE FIELD ID CODES:

	  CMPFUNC,16		;  ACCESS COMPLETE FUNCTION FIELD

	  FOP2,17		;  FILE OPTIONS FIELD

	  >			;

	K <,$_			; DATA MESSAGE FIELD ID CODES:

	  NUMBER,16		;  RECORD NUMBER FIELD

	  FILEDATA,17		;  FILE DATA FIELD

	  >			;

	K <,$_			; STATUS MESSAGE FIELD ID CODES:

	  STSCODE,16		;  STATUS CODE FIELD USED FOR BOTH:

				;   MACCODE,16

				;   MICCODE,17

	  RFA,18		;  RECORD FILE ADDRESS FIELD

	  RECNUM,19		;  RECORD NUMBER FIELD

	  STV,20		;  SECONDARY STATUS FIELD

	  >			;

	E			;

	.END





