Google
 

Trailing-Edge - PDP-10 Archives - BB-R595B-SM_11-9-85 - mcb/xpt/xpthel.bli
There is 1 other file named xpthel.bli in the archive. Click here to see a list.
module XPTHEL	(
		IDENT = 'X01170'
		) =
begin

!
!                    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:	Transport
!
! ABSTRACT:
!
!	Transport Hello module: Sends out Hello messages on each active
!	line.
!
! ENVIRONMENT:	MCB
!
! AUTHOR: L. Webber , CREATION DATE: 23-Oct-79
!
! MODIFIED BY:
!
!	L. Webber, 23-Oct-79 : VERSION 1.00
!
! 1.01	L. Webber, 19-Dec-79
!	Took out the Node Listener function (which went into Line Support)
!
! 1.02	L. Webber, 3-Apr-80
!	Modified to support node and line sub-data-bases
!
! 1.03	L. Webber, 30-Jun-80
!	Modify to use MCBLIB macros
!
! 1.04	L. Webber, 11-Dec-80
!	Modity to support MCB 3.1
!
! 1.05	L. Webber, 9-Feb-81
!	Change references to SNDBUF to CALL$E
!
! 1.06	L. Webber, 9-Feb-81
!	Change back to direct call; an interface routine has been added.
!
! 1.07	L. Webber, 10-Feb-81
!	Hello has gone into XPE; make HELLO CALL$ and call _SNDBUF instead
!	of SNDBUF.
!
! 1.08	L. Webber, 24-Feb-81
!	Add RCVHEL to validity-check received Hello messages
!
! 1.09	L. Webber, 17-Mar-81
!	Fix RCVHEL to terminate the function CCB and to return the correct
!	indication for line disposition.  Fix the data-testing code.
!
! 1.10	L. Webber, 31-Mar-81
!	Add reason code to "invalid data" event in RCVHEL.
!
! 1.11	L. Webber, 2-Apr-81
!	Add reason code to "node address change" event in RCVHEL; also,
!	change build of expected node parameter to call to EP_EXNODE.
!
! 1.12	L. Webber, 3-Apr-81
!	Add LIXes as NMXID for all event logging.
!
! 1.13	L. Webber, 7-Apr-81
!	Fix bug in RCVHEL which fails all HELLO messages with even length.
!
! 1.14	L. Webber, 16-Apr-81
!	Change the size of a Hello message from 72 data bytes to 12.
!
! 1.15	L. Webber, 3-Jun-81
!	Get a 16-byte buffer instead of a CSB.
!
! 1.16	L. Webber, 24-Sep-81
!	Modify event logging to use new macros for building parameters.
!
! 1.17	A. Peckham, 19-Apr-82
!	Eliminate calls to LOG_EVENT, GETLINE.
!       PKTA_HDR has gone to XPE.  Make local call now.
!
!--
!
! INCLUDE FILES:
!

require 'XPTMAC';

!
! TABLE OF CONTENTS
!

forward routine
	HELLO: LINKAGE_DB novalue;

!
! MACROS:
!

!
! EQUATED SYMBOLS:
!

!
! OWN STORAGE:
!

!
! EXTERNAL REFERENCES:
!
global routine HELLO (LINEb): LINKAGE_DB novalue =

!++
! FUNCTIONAL DESCRIPTION:
!
! This routine is called on a timer interval.  If the Hello_clock has expired,
! then for each line in the RU state, scanned in a round-robin fashion starting
! with NEXTline, a Hello message is constructed and sent out by calling _SNDBUF
! in Forwarding.  If an SDB is not available to construct the message, no
! message is sent.  The Hello message constructed will contain 12 bytes of test
! data.
!
! FORMAL PARAMETERS
!
!	NONE.
!
! IMPLICIT INPUTS
!
!	Hello_clock, NEXTline, Nty
!
! ROUTINE VALUE:
! COMPLETION CODES:
!
!	NONE.
!
! SIDE EFFECTS:
!
!	NONE.
!
!--

begin
require 'XPTSYM';
local CCB: ref block field (C_XPT_fields);

if .LINEstate eql RU
then selectone .Nty of
         set
         [Full,Small]:
             begin
             !
             !  Get an CCB for the message
             !
             if not $MCB_GET_CCB (CCB) then return;

             CCB[C_XPT_ALLOCATION] = 0; ! No buffer
             CCB[C_ADDR] = .Hello_msg_ADDR;     ! Copy address
             CCB[C_CNT] = .Hello_msg_CNT;       !  of canned message
             CCB[C_XPT_TYPE] = UPDATEcode;      ! Flag message as Routing/Hello
             CCB[C_XPT_SUBTYPE] = HELLOcode;    !  (with a side of Hello)
             !
             !  Send the message out
             !
             CALL$E(_SNDBUF,(PD_XPE),.LINEb,.CCB);
             end;
         [otherwise]:
             ;
         tes;

Send_hello = false;
end;				!End of HELLO
end				!End of module XPTHEL
eludom