*DECK NVFICTN
USETEXT TEXTSS
PROC NVFICTN;
# TITLE NVFICTN - CONNECT TO NETWORK. #
BEGIN # NVFICTN #
#
** NVFICTN - CONNECT TO NETWORK.
*
* D. G. DEPEW. 82/04/23.
*
* THIS PROCEDURE NETS ON AND SETS PARALLEL MODE.
*
* PROC NVFICTN
*
* ENTRY NONE.
*
* EXIT 1. IF NETON SUCCEEDED, AN APPROPRIATE DAYFILE MESSAGE HAS
* BEEN ISSUED AND PARALLEL MODE HAS BEEN SET. ALSO, A
* CALL TO NETFUNC HAS BEEN MADE WITH CODE 1, INDICATING
* THAT NVF IS TO BE SWAPPED OUT WHEN IT ISSUES A NETWAIT
* IF THERE IS NO DELIVERABLE DATA ON A NETGETL OR NETGTFL
* CALL.
* 2. IF NETON FAILED, THERE IS NO RETURN. NVF TERMINATES
* NORMALLY AFTER ISSUEING AN APPROPRIATE DAYFILE MESSAGE.
#
#
**** PROC NVFICTN - XREF LIST.
#
XREF
BEGIN
PROC MESSAGE; # ISSUE DAYFILE MESSAGE (MACREL) #
PROC NETFUNC; # ISSUE AIP COMMAND #
PROC NETON; # CONNECT TO NETWORK #
PROC NETSETP; # PARALLEL MODE CONTROL #
PROC RECALL; # PLACE JOB IN RECALL (MACREL) #
END
#
****
#
DEF SWAPOUT #1#; # SWAP OUT NVF AFTER IT ISSUES NETWAIT #
DEF OPTION$ #0#; # DAYFILE MESSAGE OPTION #
STATUS NETON$ # NETON STATUS LIST #
SUCCESS, # NETON SUCCESSFUL #
UNAVAIL, # NAM UNAVAILABLE #
DUPLICATE, # DUPLICATE NETON ATTEMPT #
DISABLED; # APPLICATION DISABLED #
$BEGIN
ITEM I; # LOOP INDUCTION VARIABLE #
$END
ITEM NSTAT S:NETON$; # NETON STATUS #
ARRAY TRYMSG [00:00] S(3);
BEGIN
ITEM TR$TEXT C(00,00,21) = ["NVF ATTEMPTING NETON."];
ITEM TR$ZERO U(02,06,54) = [0];
END
ARRAY BADMSG [00:00] S(3);
BEGIN
ITEM BD$TEXT C(00,00,25) = ["NVF NETON ATTEMPT FAILED."];
ITEM BD$ZERO U(02,30,30) = [0];
END
ARRAY OKMSG [00:00] S(3);
BEGIN
ITEM OK$TEXT C(00,00,21) = ["NVF NETON SUCCESSFUL."];
ITEM OK$ZERO U(02,06,54) = [0];
END
MESSAGE (TRYMSG, OPTION$);
FOR NSTAT = S"UNAVAIL"
WHILE NSTAT EQ S"UNAVAIL"
DO # LOOP UNTIL NAM IS AVAILABLE #
BEGIN
RECALL (0);
NETON ("NVF", NSUP, NSTAT, 2, 4095); # CONNECT TO NETWORK #
END
IF NSTAT NQ S"SUCCESS"
THEN # NVF NETON FAILURE SHOULD NEVER HAPPEN #
BEGIN
MESSAGE (BADMSG, OPTION$);
STOP;
END
$BEGIN
FOR I=0 STEP 1 UNTIL NSVT$
DO # CLEAR STATISTICS VALUES #
BEGIN
SVT$VAL[I] = 0;
END
$END
NET$ONF = TRUE; # SET NET ON FLAG #
MESSAGE (OKMSG, OPTION$);
NETSETP(0); # BEGIN PARALLEL MODE #
NETFUNC(SWAPOUT,0); # NVF WILL BE SWAPPED OUT WHEN IT ISSUES #
# NETWAIT IF NO DATA IS DELIVERABLE ON A #
# NETGETL OR NETGTFL CALL #
END # NVFICTN #
TERM