Google
 

Trailing-Edge - PDP-10 Archives - BB-P363B-SM_1985 - mcb/drivers/dtedat.r16
There are no other files named dtedat.r16 in the archive.
! [Beginning of DTEDAT]
!
!
!                    COPYRIGHT (c) 1980, 1981, 1982
!                    DIGITAL EQUIPMENT CORPORATION
!                        Maynard, Massachusetts
!
!     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: MCB DTE Driver
!
! ABSTRACT:
!
!	This contains the data structure definitions for the DTE DLC.
!
! ENVIRONMENT: MCB V3.0
!
! AUTHOR: Alan D. Peckham	CREATION DATE: 28-May-80
!
! MODIFIED BY:
!
!	Alan D. Peckham, 28-May-80: Version 1
! 01	- Move to seperate module for dump analyzer access.
! 02	- Cahnge $LENGTH references to $FIELD_SET_SIZE.
! 03	- Support counters required by Network Management.
! 04	- Add debugging status codes
! 05	- Bug found! Remove status codes.
! 06	- Add data base length symbol.
! 07	- Add transmit buffer.
! 08	- Look for empty queues.
! 09	- Map the data base.
! 10	- Add Network Management event logging.
! 11	- Add interrupt vector/priority.
! 12	- Enlarge event logging buffer.
! 13	- Add DTE directory process data base.
! 14	- Add Line/Circuit name entry.
! 15	- Ron Platukis..... Add D_DOORBELL_LOST counter
! 16	- Add system specific line counters.
! 17	- Add CIRCUIT COST for Transport.
! 18	- Add time counters zeroed.
!--

%if not %declared (XPO$K_VERSION) %then library 'XPORT'; %fi

%if not %declared (MCB$K_VERSION) %then library 'MCBLIB'; %fi

library 'NMXLIB';

$SHOW (FIELDS) $SHOW (LITERALS)

!
! Status Codes:
!

DECLARE_SEVERITY (DTE, INFO, SEVERE);

$DTE_INFO (DTE$_EVT, 'Network event')
$DTE_SEVERE (DTE$_INI, 'Unable to initialize DTE process')
$DTE_SEVERE (DTE$_PWF, 'Unable to handle power failure')
$DTE_SEVERE (DTE$_QUE, 'Unexpected empty queue')
$DTE_INFO (DTE$_XMT_MTL, 'Message from line owner too long')
$DTE_INFO (DTE$_SEG, 'Multi-segment message being received')
$DTE_INFO (DTE$_LOG, 'Event logging buffer too small')

macro
    PARAMETER_DEVICE = P1000 %,
    PARAMETER_DEVICE_REGISTERS = PLL0 %,
    PARAMETER_LINE_COUNTERS = PLN %,
    PARAMETER_STATION_COUNTERS = PST %;

literal
    DTE_K_PAUSE_TIMEOUT = 30,
    DTE_K_START_TIMEOUT = 5,
    DTE_K_TRANSMIT_DOORBELL_TIMEOUT = 3,
    DTE_K_LINE_PROVIDER = 0^1,
    DTE_K_LINE_OWNER = 1^1,
    DTE_K_CIRCUIT_PROVIDER = 2^1,
    DTE_K_NMID_HIGH = 2^1;

!
! Data base creation items
!

macro
    $SKIP_FIELD [] =
	%bliss36 [%bliss32 [%remaining]] %,
    !
    ! Allocate room for process handle
    !
    $PROCESS_HANDLE = $SHORT_INTEGER %;

$FIELD
    !
    ! List head definition
    !
    LIST_FIRST = [$ADDRESS],
    LIST_LAST = [$ADDRESS];

compiletime
    $dte$length = $FIELD_SET_SIZE;

macro
    $LIST_HEAD = $SUB_BLOCK (%expand %number ($dte$length)) %;

$FIELD
    !
    ! Physical 18 bit address
    !
    PHYSICAL_HIGH = [$BITS (16)],
    PHYSICAL_LOW = [$BITS (16)];

%assign ($dte$length, $FIELD_SET_SIZE)

macro
    $PHYSICAL_ADDRESS = $SUB_BLOCK (%expand %number ($dte$length)) %;

$FIELD
    !
    ! Communications region word
    !
    COMM_WORD_0 = [$BITS (16)],
    COMM_WORD_1 = [$BITS (16)],
    COMM_WORD_2 = [$BITS (4)];

%assign ($dte$length, $FIELD_SET_SIZE)

macro
    $COMM_WORD = $SUB_BLOCK (%expand %number ($dte$length)) %;

undeclare
    $dte$length;
!
! DTE20 hardware register definitions
!

literal
    CSTOFF = %o'34'/%upval;		! Offset to STATUS register

field
    DTE_FIELDS =
	set

	 DLYCNT = [0 - CSTOFF, 0, 14, 1],
					!  Negative delay count.
					!  The software specifies how many 500
					!  nanosecond units of delay are to occur
					!  between each byte on byte transfers in
					!  either direction.  The delay also
					!  applies before the first byte.  The
					!  hardware upcounts a copy of this
					!  negative number once each 500 nano
					!  seconds, until bit 13 = 0.
					!  This location is never reset by
					!  hardware, including reset issued by
					!  the -10 or the -11.  Therefore software
					!  must set it to a particular value at
					!  system startup before doing the first
					!  transfer.
	 BUSEXT = [0 - CSTOFF, 14, 2, 0],
					!  UNIBUS address bits 16-17 specifies
					!  high order two bits of 18 bit PDP-11
					!  addresses.  Transfer cannot cross a 32K
					!  boundry.  To-11 and to-10 transfers
					!  must be in the same 32K bank.
	DEXWD = [1 - CSTOFF, 0, 36, 0],
	    DEXWD3 = [0, 0, 16, 0],	!  KL data word bits 20-35
	    DEXWD2 = [1, 0, 16, 0],	!  KL data word bits  4-19
	    DEXWD1 = [2, 0, 16, 0],	!  KL data word bits  0- 4
	TENAD = [4 - CSTOFF, 0, 22, 0],
	    TENAD1 = [0, 0, 16, 0],
					!  Except for PRTOFF, this word is not
					!  reset so that the -11 program need
					!  not write it for each operation.
		TENADM = [$SUB_FIELD (TENAD1, 0, 0, 7, 0)],
					!  KL address bits 13-19
		PRTOFF = [$SUB_FIELD (TENAD1, 0, 11, 1, 0)],
					!  Examine/deposit protection off.  This
					!  bit is ignored if the DTE20 is switched
					!  to restricted mode.  For a privledged
					!  front end, if a 1, examines and deposits
					!  are not relocated and no protection
					!  check is made on them.  Instead the
					!  address space desired is indicated by
					!  the SPACE field.  The DTE20 resets the
					!  associated hardware bit after every
					!  examine and deposit to reduce the chance
					!  that a runaway program in a privledged
					!  front end -11 will clobber the -10.
					!  A restricted front-end can only examine
					!  or deposit in the communications regions
					!  defined by the -10.  A read of TENAD1
					!  returns the value written by the last
					!  write of TENAD1 and so may differ from
					!  the associated hardware bit which
					!  controls the protection.  If PRTOFF = 0,
					!  examines are relocated by the EPT.
		DEP = [$SUB_FIELD (TENAD1, 0, 12, 1, 0)],
					!  -11 software specifies whether a
					!  deposit (1) or examine (0) function is
					!  to be done whenever the -11 writes word
					!  TENAD2.  On a read of TENAD1, DEP is
					!  a 1 if the last deposit/examine was
					!  a deposit or a diagnostic deposit; it
					!  is a 0 if the last deposit/examine was
					!  an examine or a diagnostic examine.
		SPACE = [$SUB_FIELD (TENAD1, 0, 13, 3, 0)],
					!  Address space.  This field is used for
					!  unprotected examines or deposits only
					!  on privledged front ends when
					!  TENAD1[PRTOFF] = 1.
					!    0  Exec process table.
					!    1  Exec virtual.
					!    2  User process table.
					!    3  User virtual.
					!    4  Physical
					!   5-7 (reserved to DEC)
	    TENAD2 = [1, 0, 16, 0],	!  KL address bits  0-12
					!  Depositing in this word starts the examine/deposit
	TO10BC = [6 - CSTOFF, 0, 16, 0],
	    TO10CM = [0, 0, 12, 0],
	TO11BC = [7 - CSTOFF, 0, 16, 0],
	    TO11CM = [0, 0, 12, 0],
	    TO11BM = [0, 13, 1, 0],
	    TO11IB = [0, 15, 1, 0],
	TO10AD = [8 - CSTOFF, 0, 16, 0],
	TO11AD = [9 - CSTOFF, 0, 16, 0],
	TO10DT = [10 - CSTOFF, 0, 16, 0],
	TO11DT = [11 - CSTOFF, 0, 16, 0],
	DIAG1 = [12 - CSTOFF, 0, 16, 0],
                                        !  Write-only bits:
	    DCOMST = [0, 0, 1, 0],      !   If 1 and DTE20 is switched to
                                        !   priviledged, sets diagnostic
                                        !   command start.  A 0 clears
                                        !   diagnostic command start.
	    DSEND  = [0, 2, 1, 0],      !   If 1, send data (to-10) during a
                                        !   diagnostic bus transfer.
                                        !   If 0, receive data (to-11) during
                                        !   a diagnostic bus transfer.
	    DIKL10 = [0, 3, 1, 0],      !   If 1 and DTE20 is switched to
                                        !   priviledged, put the DTE20 into
                                        !   KL10 diagnostic data transfer mode.
                                        !   Subsequent examines and deposits
                                        !   become diagnostic functions instead
                                        !   of accessing KL10 memory.
                                        !   If 0, put the DTE20 in normal data
                                        !   transfer mode.
                                        !   Subsequent examines and deposits
                                        !   will refer to KL10 memory.
                                        !  Read-only bits:
!	    DCOMST = [0, 0, 1, 0],      !   If 1, a diagnostic command is
                                        !   in progress.
	DIAG2 = [13 - CSTOFF, 0, 16, 0],
                                        !  Write-only bits:
	    DRESET = [0, 6, 1, 0],      !   DTE20 reset.
            EDONES = [0, 14, 1, 0],     !   If 1, set EBUS done.  If 0,
                                        !   clear EBUS done.
                                        !  Read-only bits:
!                  = [0, 1, 4, 0],      !   Loads 04,03,02,01 into minor state
                                        !   counter 8,4,12,1.  For diagnostic
                                        !   use only.  During normal operation
                                        !   must be zero.
            RFMAD3 = [0, 12, 1, 0],     !   Contents of RFM address bit 3.
            RFMAD2 = [0, 13, 1, 0],     !   Contents of RFM address bit 2.
            RFMAD1 = [0, 14, 1, 0],     !   Contents of RFM address bit 1.
            RFMAD0 = [0, 15, 1, 0],     !   Contents of RFM address bit 0.
	STAT11 = [14 - CSTOFF, 0, 16, 0],
                                        !  Write-only bits:
	    ERR11C = [0, 0, 1, 0],
            ERR11S = [0, 1, 1, 0],
            EBUSPS = [0, 2, 1, 0],
	    INTROF = [0, 3, 1, 0],
            EBUSPC = [0, 4, 1, 0],
	    INTRON = [0, 5, 1, 0],
	    DON11C = [0, 6, 1, 0],
            DON11S = [0, 7, 1, 0],
            INT10S = [0, 8, 1, 0],
            PERCLR = [0, 9, 1, 0],
	    INT11C = [0, 10, 1, 0],
            INT11S = [0, 11, 1, 0],
	    ERR10C = [0, 12, 1, 0],
            ERR10S = [0, 13, 1, 0],	!   If 1, set to-10 error termination
					!   status [TO10ER].
					!   This bit is provided for diagnostic
					!   purposes only.
	    DON10C = [0, 14, 1, 0],	!   If 1, clear to-10 normal
					!   termination status [TO10DN].
            DON10S = [0, 15, 1, 0],	!   If 1, set to-10 normal termination
					!   status [TO10DN].
					!   This bit is provided for diagnostic
					!   purposes only.
					!   Writing a 1 does not terminate a
					!   transfer in progress.
                                        !  Read-only bits:
	    INTSON = [0, 0, 1, 0],      !   If 1, the DTE20 is enabled
                                        !   to generate -11 BR requests.
                                        !   If 0, it is disabled.
                                        !   (INTRON enables, INTROF disables)
	    TO11ER = [0, 1, 1, 0],      !   An error occurred during a to-11
                                        !   byte transfer, or the -11 program
                                        !   set the bit STAT11 [ERR11S].
                                        !   STAT11 [TO11DN] will not be set
                                        !   if an error termination occurred.
                                        !   Thus programs must test for both
                                        !   TO11DN and TO11ER.
	    DEXDON = [0, 2, 1, 0],      !   The last deposit or examine operation
                                        !   has completed.  No interrupt occurrs.
                                        !   The -11 must watch for this watch
                                        !   for this bit to be set after every
                                        !   deposit or examine.  The DTE20 clears
                                        !   STAT11 [DEXDON] whenever a deposit or
                                        !   examine is started (by writing TENAD2).
	    RM     = [0, 3, 1, 0],      !   If 1, the attached PDP-11 is in
                                        !   restricted mode.  If 0, the attached
                                        !   PDP-11 is in privledged mode.  The
                                        !   value of this bit is determined by
                                        !   the setting of the privledged switch
                                        !   on the DTE20.
	    BPARER = [0, 4, 1, 0],      !   The DTE20 detected an EBUS parity
                                        !   error during a to-11 DTE20 byte
                                        !   transfer or examine transfer.
            NULSTP = [0, 5, 1, 0],      !   The to-11 transfer stopped because the
                                        !   stop bit was set (TO11BC [ZSTOP] = 1).
            EBSEL  = [0, 6, 1, 0],      !   E buffer select.  This bit is provided
                                        !   on a read for diagnostic purposes only.
                                        !   It has no meaning and is unpredicatable
                                        !   unless the DTE20 is being single
                                        !   stepped.
	    TO11DN = [0, 7, 1, 0],      !   The to-11 byte count became equal to 0
                                        !   (TO11BC = 0), the trasnfer stopped on
                                        !   a null character (STAT11 [NULSTP] = 1),
                                        !   or the -11 program set the bit
                                        !   (STAT11 [DON11S]).
	    TO10DB = [0, 8, 1, 0],      !   The -11 has requested a -10 doorbell
                                        !   interrupt STAT11 [INT10S] and the -10
                                        !   has not yet cleared the bit
                                        !   (CONO DTEN, CL11PT).
	    MPE11  = [0, 9, 1, 0],      !   Indicates the -11 memory had a parity
                                        !   error during a data fetch for a to-10
                                        !   byte transfer.  Parity errors are
                                        !   detected only if the -11 has the
                                        !   MF11UP or MF11LP parity option.
            DXWRD1 = [0, 10, 1, 0],     !   This bit is provided on a read for
                                        !   diagnostic purposes only.  It has
                                        !   no meaning and is unpredicatable
                                        !   unless the DTE20 is being single
                                        !   stepped.
	    TO11DB = [0, 11, 1, 0],     !   The -10 has requested (CONO DTEN, TO11DB)
                                        !   an -11 doorbell interrupt.
            RAMIS0 = [0, 12, 1, 0],     !   The data out of a RAM location is all
                                        !   0's.  This bit is provided on a read
                                        !   for diagnostic purposes only.  It has
                                        !   no meaning and is unpredicatable unless
                                        !   the DTE20 is being single stepped.
	    TO10ER = [0, 13, 1, 0],     !   An NPR UNIBUS parity error (DIAG3 [NUPE]),
                                        !   PDP-11 memory parity (STAT11 [11MPE]),
                                        !   or a UNIBUS timeout (no bit) occurred
                                        !   during a to-10 byte transfer, or the
                                        !   -11 program set the STAT11 [ERR10S].
                                        !   STAT11 [TO10DN] will not be set, if
                                        !   an error termination occurred.  Thus
                                        !   -11 programs must test for both TO10DN
                                        !   and TO10ER.
	    TO10DN = [0, 15, 1, 0],     !   The to-10 byte count went to 0 or the
                                        !   the -11 program set the bit
                                        !   STAT11 [DON10S].  TO10DN will not be
                                        !   set if an error termination occurred.
                                        !   See STAT11 [TO10ER].
	DIAG3 = [15 - CSTOFF, 0, 16, 0],
                                        !  Write-only bits:
	    TO10BM = [0, 0, 1, 0],      !   If 1, to-10 byte trasnfers are to be
                                        !   done in byte mode from -11 memory.
                                        !   If 0, to-10 byte transfers are to be
                                        !   done in word mode from -11 memoty.
            CNUPE  = [0, 1, 1, 0],      !   Clear NUPE.
            WEP    = [0, 3, 1, 0],      !   If 1, write even UNIBUS parity.
                                        !   Results in DTE20 generating even (bad)
                                        !   parity on all UNIBUS trasnfers which
                                        !   have parity.  If 0, the DTE20 will
                                        !   generate off (good) parity on all
                                        !   subsequent UNIBUS transfers which have
                                        !   parity.  This bit is provided for
                                        !   diagnostic purposes to check the
                                        !   parity networks.
            CDD    = [0, 4, 1, 0],      !   Clear DUPE and DURE error flags.
            SCD    = [0, 5, 1, 0],      !   Shift captured data so next read
                                        !   of DIAG3 will change bits 13-08.
                                        !  Read-only bits:
            NUPE   = [0, 1, 1, 0],      !   If 1, a unibus parity error has
                                        !   occurred on an NPR (byte) transfer.
            DURE   = [0, 2, 1, 0],      !   A UNIBUS receiver error has occurred.
!           WEP    = [0, 3, 1, 0],      !   Read status of Write Even UNIBUS
                                        !   Parity flip-flop.
            DUPE   = [0, 4, 1, 0],      !   If 1, a DATAO UNIBUS parity error
                                        !   has been detected by the DTE20.
!                  = [0, 8, 6, 0],      !   Ann means UNIBUS register address
                                        !   bit n, Dnn means UNIBUS data bit
                                        !   when UNIBUS parity error detected.
                                        !
                                        !   initial    D15 D14 D13 D12 D11 A00
                                        !   1st shift  D10 D09 D08 D07 D06 A00
                                        !   2nd shift  D05 D04 D03 D02 D01 A00
                                        !   3rd shift  D00 A04 A03 A02 A01 A00
                                        !   4th shift  D15 D14 D13 D12 D11 A00
                                        !   ...        ...
                                        !
            DPS4   = [0, 14, 1, 0],     !   DPS4 [N] parity flop is on a DNE.
                                        !   Diagnostic use only.
            SWSLLT = [0, 15, 1, 0]      !   CNT1 [N] Swap sel lt
	tes;
!
! Communications Region offsets and fields
!

literal

    !
    ! General section
    !

    PIDENT = 0,                         !Processor identification
    CHNPNT = 1,                         !Pointer to next Comm area
    KPALIV = 5,                         !Keep-alive of owning processor (private)

    !
    ! "To" sections
    !

    FORPRO = 0,                         !"To" processor identication
    PROPNT = 1,                         !Pointer to "to" processors Comm region
    STATUS = 2,                         !Status word
    QSIZE = 3,                          !Current transfer size
    RELOAD = 4,                         !Reload parameter for "to" processor
    CPKPLV = 5;                         !Copy of "to" processors keep-alive

field
    COM_FIELDS =
	set

	!
	! Header word
	!

	RELADR = [0, 0, 16, 0],         !Relative address of this processor's area
	PRCNUM = [1, 8, 4, 0],          !Processor number

	!
	! PIDENT
	!

	NAME = [0, 0, 16, 0],           !Serial number of owning processor
	NPRSIZ = [1, 0, 3, 0],          !Size of owner's section/(8 words)
	NPRCNT = [1, 3, 5, 0],          !Number of processors including owner
	PROVER = [1, 8, 6, 0],          !Protocol version (2)
	VR = [2, 0, 3, 0],              !Comm area version (3)
	X = [2, 3, 1, 0],               !1=This area belongs to -10

	!
	! FORPRO
	!

	TOPRCN = [0, 0, 16, 0],         !"To" processor number
	PROSIZ = [1, 0, 3, 0],          !Size of block/(8 words)
	PROTYP = [1, 3, 5, 0],          !Protocol type:
                                        ! 0=RSX20F
                                        ! 1=NSP
	DTN = [2, 0, 2, 0],             !DTE number if D is set
	D = [2, 2, 1, 0],               !1=DTE used in connection
!	X = [2, 3, 1, 0],               !1=Communicates with -10

	!
	! STATUS
	!

	QCOUNT = [0, 0, 8, 0],          !Bumped by owning process for transfer request
	CPQCNT = [0, 8, 8, 0],          !Copy of "to" processor's QCOUNT
	RCV = [1, 0, 1, 0],
	V = [2, 0, 1, 0],               !Valid examine bit
	I = [2, 1, 1, 0],               !Init requested
	L = [2, 2, 1, 0],               !Reload requested

	!
	! QSIZE
	!

	CSIZE = [0, 0, 16, 0],          !Number of bytes in current transfer
	PSIZE = [1, 0, 16, 0],          !Number of bytes left in current packet
	TMODE = [2, 0, 4, 0]            !Transfer mode:
                                        ! 0=8 bit bytes, byte mode
                                        ! 1=8 bit bytes, word mode
                                        ! 2=16 bit bytes, word mode

    tes;
!
! DTE driver data base
!

$FIELD
    D_FIELDS =
	set
	D_TIM = [$BYTE],                ! MCB timer (used to count the seconds)
	DC_SET_REQUESTED_STATE = [$BIT],
	DF_NXM = [$BIT],
	DF_NOTIFY_OFF = [$BIT],
	DF_NOTIFY_STATE = [$BIT],	! Notify owner of circuit state
	DF_CONTROL_WAITING = [$BIT],	! CCB waiting on resource returns
	DF_FLUSHING_DTE = [$BIT],	! Waiting for DTE I/O to finish.
	DF_SYNCHRONIZING = [$BIT],	! SYNCH block is active
	    $ALIGN (FULLWORD)
	D_REGISTER = [$ADDRESS],	! Address of hardware status register
	D_VECTOR = [$ADDRESS],		! Interrupt vector
	D_PRIORITY = [$TINY_INTEGER],	! Interrupt priority
	D_CONTROLLER = [$TINY_INTEGER],	! Controller number
	D_SYNCH_BLOCK = [$ADDRESS],	! Address of SYNCH block
	D_PROTOCOL_STATE = [$TINY_INTEGER], ! Protocol status byte
	D_REQUESTED_STATE = [$TINY_INTEGER], ! Requested state
	D_REPORTED_STATE = [$TINY_INTEGER],
	D_LINE_STATE = [$TINY_INTEGER],	! Network management line state
	D_DEVICE_STATE = [$TINY_INTEGER],
	D_NMX_PIX = [$BYTE],		! NMX process index
	    $ALIGN (FULLWORD)
	D_LONG_TIMER = [$BYTE],
	D_START_THRESHOLD = [$BYTE],
	D_OWNER_HANDLE = [$PROCESS_HANDLE],
	D_TRANSIENT_ERROR = [$SHORT_INTEGER], ! Unreported transient error
	D_PERSISTENT_ERROR = [$SHORT_INTEGER], ! Unreported persistent error
	D_PENDING_CONTROLS = [$LIST_HEAD], ! Pending control function queue
	D_ACTIVE_BUFFERS = [$SHORT_INTEGER], ! Receive buffers at user and
					! transmit buffers from user.
	D_CIRCUIT_COST = [$SHORT_INTEGER], ! ** FOR TRANSPORT **
	D_CIRCUIT_ENTITY = [$SHORT_INTEGER], ! Circuit event logging ID
	D_LINE_ENTITY = [$SHORT_INTEGER], ! Line event logging ID

	D_MPN = [$TINY_INTEGER],        ! My processor number
	D_HPN = [$TINY_INTEGER],        ! His processor number
                                        ! Comm region offsets:
	D_EHG = [$SHORT_INTEGER],       !  Examine His General
	D_EHM = [$SHORT_INTEGER],       !  Examine His to Me
	D_EMG = [$SHORT_INTEGER],       !  Examine My General
	D_DMH = [$SHORT_INTEGER],       !  Deposit My to Him

	D_RST = [$COMM_WORD],           ! His last STATUS
	D_RQZ = [$COMM_WORD],           ! His last QSIZE
	D_XST = [$COMM_WORD],           ! My STATUS
	D_XQZ = [$COMM_WORD],           ! My QSIZE
	D_MKA = [$SHORT_INTEGER],       ! My keep-alive

	D_RCB = [$ADDRESS],             ! Current receive CCB
	D_RBA = [$PHYSICAL_ADDRESS],    ! Current 18 bit receive buffer address
	D_RCT = [$SHORT_INTEGER],       ! Current transfer count
	D_XMQ = [$LIST_HEAD],           ! Transmit buffer queue
	D_XLN = [$SHORT_INTEGER],	! Current message length
	D_XCB = [$ADDRESS],             ! Current transfer CCB
	D_XBA = [$PHYSICAL_ADDRESS],    ! Current 18 bit transmit buffer address
	D_XCT = [$SHORT_INTEGER],       ! Current transmit count

	D_BYTES_RECEIVED = [$COUNTER (32)], ! Bytes received
	D_BYTES_SENT = [$COUNTER (32)], ! Bytes transmitted
	D_DATA_BLOCKS_RECEIVED = [$COUNTER (32)], ! Messages received
	D_DATA_BLOCKS_SENT = [$COUNTER (32)], ! Messages transmitted
	D_TIME_LINE_ZEROED = [$TIME],	    ! Time line counters zeroed
	    $ALIGN (FULLWORD)
	D_CONFIGURATION_ERRORS = [$COUNTER (8)],
	D_INVALID_CONTROLLER_REGISTER = [$COUNTER (1)],
	D_NXM_CONTROLLER_REGISTER = [$COUNTER (1)],
	D_INVALID_UNIT_REGISTER = [$COUNTER (1)],
	D_NXM_UNIT_REGISTER = [$COUNTER (1)],
	D_INVALID_VECTOR = [$COUNTER (1)],
	D_CONFLICTING_VECTOR = [$COUNTER (1)],
	D_INVALID_PRIORITY = [$COUNTER (1)],
	    $ALIGN (FULLWORD)
	D_DEVICE_SERVICE_ERRORS = [$COUNTER (8)],
	D_LOST_INTERRUPT = [$COUNTER (1)],
	D_LOST_RDYI = [$COUNTER (1)],
	D_LOST_HALT = [$COUNTER (1)],
	D_LOST_TRANSMIT = [$COUNTER (1)],
	D_LOST_DOORBELL = [$COUNTER (1)],
	    $ALIGN (FULLWORD)
	D_FATAL_DEVICE_ERRORS = [$COUNTER (8)],
	D_INVALID_REGISTER_CONTENTS = [$COUNTER (1)],
	D_RECEIVE_BA_MISMATCH = [$COUNTER (1)],
	D_TRANSMIT_BA_MISMATCH = [$COUNTER (1)],
	D_NXM_TO_DEVICE = [$COUNTER (1)],
	D_MICROCODE_ERROR = [$COUNTER (1)],
	D_COMPLETION_QUEUE_OVERRUN = [$COUNTER (1)],
	D_DOORBELL_STUCK = [$COUNTER (1)],
	    $ALIGN (FULLWORD)
	D_PROTOCOL_ERRORS = [$COUNTER (8)],
	D_INVALID_COMM_REGION = [$COUNTER (1)],
	D_INVALID_PROTOCOL = [$COUNTER (1)],
	D_INVALID_QCOUNT = [$COUNTER (1)],
	D_MESSAGE_TOO_LONG = [$COUNTER (1)],
	    $ALIGN (FULLWORD)
	D_DL_BLK = [$SHORT_INTEGER],	! Length of transmit buffer
	D_XBUF = [$SUB_BLOCK (0)]	! Transmit buffer.
	tes;

literal
    D_LENGTH = $FIELD_SET_SIZE,
    D_ALLOCATION = D_LENGTH*%upval;

$LITERAL
    DD_CLEARED = 0,			! Device is not defined
    DD_RUNNING = 1,			! Device is ready for use.
    DL_ON = 0,
    DL_OFF = 1,
    DS_HALTED = 0,                      ! DTE is stopped
    DS_COM = $DISTINCT,                 ! Waiting to get Comm region offsets
    DS_INITIALIZING = $DISTINCT,        ! Initializing protocol
    DS_RUNNING = $DISTINCT,             ! Protocol running
    DS_PAUSED = $DISTINCT,              ! Protocol paused
    DS_STA_LOW = min (DS_HALTED, DS_COM, DS_INITIALIZING, DS_RUNNING, DS_PAUSED),
    DS_STA_HIGH = max (DS_HALTED, DS_COM, DS_INITIALIZING, DS_RUNNING, DS_PAUSED);

$FIELD
    DIR_FIELDS =
	set
	DIR_LOG_ADDRESS = [$ADDRESS],	! Address of event logging buffer.
	DIR_CONTROLLERS = [$BYTE],	! Number of controllers.
	DIR_DTE_PIX = [$BYTES (1)]	! PIXs of DTE processes
					!  indexed by controller number.
	tes;

!
! [End of DTEDAT]