cdc:nos2.source:nam5871:cstrct
Table of Contents
CSTRCT
Table Of Contents
- [00007] PROC CSTRCT
- [00008] CSTRCT - RESET CHARACTERISTIC OF TERMINAL.
- [00012] RESET CHARACTERISTICS OF TERMINAL.
- [00037] PROC CSTSCD
- [00038] PROC CSTITR
- [00039] PROC MOVE
- [00040] PROC SSTAQE
- [00041] PROC SSTRTS
- [00042] FUNC SSDCAD U
Source Code
- CSTRCT.txt
- *DECK CSTRCT
- USETEXT TEXTCS
- USETEXT TXTCTCS
- USETEXT TXTSMCS
- USETEXT TXTAPSS
- USETEXT TXTSUSS
- PROC CSTRCT;
- # TITLE CSTRCT - RESET CHARACTERISTIC OF TERMINAL. #
- BEGIN # CSTRCT #
- #
- ** CSTRCT - RESET CHARACTERISTICS OF TERMINAL.
- *
- * LIEM THANH NGUYEN 84/12/06.
- *
- * CSTRCT RESET CHARACTERISTICS OF TERMINAL FROM THE LINE RECORDS
- * CONTAINED IN THE NCF DATA QUEUE.
- *
- * PROC CSTRCT
- *
- * ENTRY THE FIRST DATA ENTRY IN THE NCF DATA QUEUE.
- *
- * EXIT THE FIRST DATA QUEUE ENTRY IN THE NCF DATA QUEUE
- * HAS BEEN DELETED.
- * A RESET TERMINAL RESPONSE SM'S (NORMAL OR ABNORMAL),
- * CORRESPONDING TO THE NCF DATA QUEUE ENTRY THAT WAS
- * PROCESSED, HAS BEEN PLACED IN THE OUTGOING TRAFFIC
- * QUEUE.
- *
- #
- #
- **** PROC CSTRCT - XREF LIST.
- #
- XREF
- BEGIN
- PROC CSTSCD; #SELECT AND CONFIGURE CORRECT DEVICES #
- PROC CSTITR ; #ISSUE TERMINAL REPONSE #
- PROC MOVE; #MOVE STORAGE DIRECT ADDRESSING (MACREL) #
- PROC SSTAQE; #ACCEPT QUEUE ENTRY #
- PROC SSTRTS; #REMOVE STORAGE ANYWHERE IN TABLE #
- FUNC SSDCAD U ; # CONVERT ASCII TO DISPLAY CODE CHARACTER #
- END
- #
- ****
- #
- ARRAY CNF$NAME S(1) ;
- BEGIN
- ITEM CNFNAMU U(0,00,42) ;
- ITEM CNFNAME C(0,00,07) ;
- ITEM CNFROOT C(0,00,05) ;
- ITEM CNFSUF U(0,30,12) ;
- END
- ITEM CURDEV; # CURRENT OFFSET FOR DEVICE ENTRY #
- ITEM CURTERM; # CURRENT OFFSET FOR TERMINAL ENTRY #
- ITEM I, J, K, NB ; #LOOP INDUCTION VARIABLES #
- ITEM FOUND B ;
- ITEM LTES U ;
- FOUND = FALSE ; # RESET FOUND #
- # WE BEGIN THE PROCESSING OF A SINGLE NCF DATA QUEUE ENTRY BY #
- # INITIALIZING A WHOLE BUNCH OF STUFF. #
- # THE MEMORY MANAGEMENT ROUTINES GUARANTEE ONE ADDITIONAL WORD AT #
- # THE END OF EACH MANAGED TABLE (ABOVE AND BEYOND THE LENGTH OF THE#
- # TABLE). SETTING THIS WORD NON-ZERO FOR THE NCF DATA QUEUE #
- # INSURES THAT THE INNER LOOPS OF THIS ROUTINE AND PROC CSTSCD DO #
- # NOT ACT UPON STORAGE BEYOND THE END OF THE NCF DATA QUEUE. #
- NRDEV = 0; # INITIALIZE NUMBER OF DEVICES CONFIGURED #
- LTES = NDQ$LRSIZE[0] - LRHDRL$; # WORD COUNT OF TRM NTRYS #
- P<LINEREC> = P<NDQ> + NDQ$TCSIZE[0]; # BEGINNING OF LINE REC #
- ABHWORD[0] = NDQ$WORD[1]; # BREAK OUT CNF/RC/R SM ABH #
- MOVE (NDQ$TCSIZE[0]-2, NDQ[2], CSSM[0]); # AND SM BODY #
- # SET UP FIXED FIELDS OF CONFIGURE TERMINAL RESPONSE SM. #
- ABHWORD[1] = NDQ$WORD[1];
- ABHSN[1] = ABHDN[0]; # REVERSE DN AND SN FOR RESPONSE SM #
- ABHDN[1] = ABHSN[0];
- SPMSG0[1] = 0; # START CNF/RC RESPONSE SM BODY #
- PFCSFC[1] = CNFRCTN; # DEFINED IN TXTSUSS #
- CNFP[1] = CNFP[0]; # PORT NUMBER. THAT'S IT FOR NOW #
- #
- CONVERT 8 BIT ASCII CHARACTER NAME TO DISPLAY CODE NAME
- #
- FOR I = 0 STEP 1 UNTIL 6
- DO
- BEGIN
- B<(I*6),6>CNFNAMU[0] = SSDCAD(B<I*8,8>CNFRCNM[0]) ;
- END
- P<TRMINFO> = P<LINEREC> + LRHDRL$; # 1ST TERM NTRY IN LINREC#
- CURTERM = 0; # INITIAL OFFSET FOR TERMINAL ENTRY #
- FOR J=TE$WC[0] STEP TE$WC[0]
- WHILE J LQ LTES
- AND NOT FOUND
- DO # LOOP TIL END OF LINREC OR TERMINAL MATCH#
- BEGIN
- P<DEVNTRY> = P<TRMINFO> + TEHDRL$ ; # DEVICE ENTRY #
- CURDEV = 0; # INITIAL OFFSET FOR DEVICE ENTRY #
- FOR I = DE$WC[0] STEP DE$WC[0] WHILE I LQ TE$WC[0] - TEHDRL$
- AND NOT FOUND
- DO
- BEGIN # LOOP UNTIL END OF TRM AND DEV NTRY#
- IF LR$GC[0] EQ 0
- THEN
- BEGIN # NO GROUP #
- IF CNFNAME[0] EQ DE$NAME[0]
- THEN
- FOUND = TRUE ; # FOUND THE RIGHT ENTRY #
- END # NO GROUP #
- ELSE
- BEGIN # THERE IS GROUP #
- # USE ONLY THE ROOT NAME TO COMPARE TO NAME IN NCF #
- NB = 0 ; # RESET NON-BLANKS COUNT #
- FOR K = 0 STEP 6 UNTIL 36
- DO
- BEGIN # COUNTING NON-BLANKS #
- IF B<I,6>CNFNAMU[0] NQ O"55"
- THEN
- NB = NB + 1 ; # REMEMBER NUMBER OF NONBLANKS#
- END
- IF C<0,NB-2>CNFNAMU[0] EQ DE$NAME[0]
- THEN
- BEGIN # ROOT IS MATCHING #
- FOUND = TRUE ; # THIS ENTRY HAS SAME ROOT AND SUFIX #
- END # ROOT IS MATCHING #
- END # THERE IS GROUP #
- IF FOUND
- THEN
- BEGIN # READY TO RESPONSE #
- CSTITR(TRUE) ;
- #
- RESET BASED ARRAY POINTERS IN CASE NDQ ENTRY HAS BEEN
- MOVED
- #
- P<LINEREC> = P<NDQ> + NDQ$TCSIZE[0]; # LINE REC ARRAY #
- P<TRMINFO> = P<LINEREC> + LRHDRL$ + CURTERM;
- P<DEVNTRY> = P<TRMINFO> + TEHDRL$ + CURDEV;
- END
- CURDEV = CURDEV + DE$WC[0]; # OFFSET FOR NEXT DEV ENTRY #
- P<DEVNTRY> = P<TRMINFO> + TEHDRL$ + CURDEV;
- END # LOOP UNTIL THE END OF DEVICES #
- CURTERM = CURTERM + TE$WC[0]; # OFFSET FOR NEXT TERM ENTRY #
- P<TRMINFO> = P<LINEREC> + LRHDRL$ + CURTERM;
- END # GO THROUGH LINE RECORD FOR DEVICE #
- IF NOT FOUND
- THEN # NOTHING GOT CONFIGURED #
- BEGIN # ISSUE CNF/RC/A #
- ABHTLC[1] = NCNFA; # DEFINED IN TXTSMCS. ABH COMPLETE #
- PFCSFC[1] = CNFRCTA; # DEFINED IN TXTSUSS. SM COMPLETE #
- SSTAQE (P<OTQ>, CTEAQL$, ABH[1], CSSM[1]); # QUEUE CNF/TE/A#
- END
- SSTRTS (P<NDQ>, 0, NDQ$ESIZE[0]); # DEL 1ST NTRY IN NCF DATA Q#
- END # CSTRCT #
- TERM
cdc/nos2.source/nam5871/cstrct.txt ยท Last modified: 2023/08/05 17:22 by Site Administrator