User Tools

Site Tools


cdc:nos2.source:nam5871:csesns

CSESNS

Table Of Contents

  • [00006] PROC CSESNS
  • [00007] SEND NPU STATUS.
  • [00010] SEND NPU STATUS.
  • [00030] PROC CSESLE
  • [00031] PROC SSBSBF
  • [00032] PROC SSTAQE
  • [00033] FUNC XCDD C(10)

Source Code

CSESNS.txt
  1. *DECK CSESNS
  2. USETEXT TEXTCS
  3. USETEXT TEXTSS
  4. USETEXT TXTAPSS
  5. USETEXT TXTSMCS
  6. PROC CSESNS;
  7. # TITLE - SEND NPU STATUS. #
  8. BEGIN
  9. #
  10. ** CSESNS - SEND NPU STATUS.
  11. *
  12. * D.K. ENDO 82/03/18
  13. *
  14. * THIS PROCEDURE FORMATS NPU STATUS MESSAGES AND SENDS THEM OUT TO
  15. * THE APPROPRIATE OPERATORS.
  16. *
  17. * PROC CSESNS
  18. *
  19. * ENTRY 1. STU/NP/U OR STU/NP/N SM.
  20. *
  21. * EXIT 1. ENTRY IN OPERATOR RESPONSE QUEUE WITH NPU STATUS.
  22. * 2. NPU STATUS TO THE OPERATOR VIA THE C-LAYER QUEUE.
  23. *
  24. #
  25. #
  26. **** PROC CSESNS - XREF LIST BEGINS.
  27. #
  28. XREF
  29. BEGIN
  30. PROC CSESLE; # SEND LOG (FILE) ENTRY #
  31. PROC SSBSBF; # STORE BIT FIELD #
  32. PROC SSTAQE; # ADD QUEUE ENTRY #
  33. FUNC XCDD C(10); # CONVERT DECIMAL INTEGER TO DISPLAY CODE #
  34. END
  35. #
  36. ****
  37. #
  38. DEF ASCII$Y # X"59" #; # VALUE FOR A ASCII -Y- #
  39. DEF DOC$TXTL # 50 #; # CHAR COUNT OF -DUMP OPTION CHANGED- TEXT#
  40. DEF NPS$TXTL # 50 #; # CHAR COUNT OF NPU STATUS TEXT #
  41. DEF OP$GO # 1 #; # INDICATES AN OPERATOR GO IS NEEDED #
  42. ITEM CNST1; # CONSTANT ---> 1 #
  43. ITEM CNST2; # CONSTANT ---> 2 #
  44. ITEM CNST3; # CONSTANT ---> 3 #
  45. ITEM I; # LOOP INDUCTION VARIABLE #
  46. #
  47.   THIS ARRAY IS USED TO STORE A TEXT STRING THAT WILL LATER BE ADDED
  48.   TO THE MESSAGE TEXT.
  49. #
  50. ARRAY CTEMP$WORD [00:00] S(1);
  51. BEGIN
  52. ITEM CTEMP C(00,00,10);
  53. ITEM CTEMP3 C(00,42,03);
  54. END
  55. #
  56.   THIS ARRAY DEFINES THE -DUMP OPTION CHANGED- TEXT. IT IS SENT OUT
  57.   WHEN A STU/NP/U SM HAS A REASON CODE SET TO THREE.
  58. #
  59. ARRAY DOC$TXT [00:00] S(5);
  60. BEGIN
  61. ITEM DOC$TIM C(00,00,10) = [" "];
  62. ITEM DOC$NPU C(01,00,05) = ["NPU: "];
  63. ITEM DOC$NNM C(01,30,07);
  64. ITEM DOC$MSG C(02,12,21) = [", DUMP OPTION CHANGED"];
  65. ITEM DOC$ZBYT U(04,18,42) = [ 0 ];
  66. END
  67. #
  68.   THIS ARRAY DEFINES THE NPU STATUS MESSAGE FORMATTED FROM THE IN-
  69.   COMING SM.
  70. #
  71. ARRAY NPS$TXT [00:04] S(1);
  72. BEGIN
  73. ITEM NPS$TIM C(00,00,10);
  74. ITEM NPS$NPU C(01,00,05) = ["NPU: "];
  75. ITEM NPS$NNM C(01,30,07);
  76. ITEM NPS$C1 C(02,12,01) = [","];
  77. ITEM NPS$ST C(02,18,02) = ["AC"];
  78. ITEM NPS$C2 C(02,30,01) = [","];
  79. ITEM NPS$NID C(02,36,03);
  80. ITEM NPS$C3 C(02,54,01) = [","];
  81. ITEM NPS$GO C(03,00,06);
  82. ITEM NPS$C4 C(03,36,01) = [","];
  83. ITEM NPS$DP C(03,42,03);
  84. ITEM NPS$ZBYT U(04,00,60) = [ 0 ];
  85. END
  86. CONTROL EJECT;
  87. # #
  88. # CSESNS CODE BEGINS HERE #
  89. # #
  90. #
  91. * FORMAT THE NPU STATUS TEXT. SEARCH THE NPUCB-S FOR THIS NPU.
  92. * APPEND THE NAME IN THE NPUCB TO THE TEXT. CONVERT THE NODE-ID AND
  93. * APPEND IT TO THE TEXT. IF GO-NEEDED FLAG IS SET THE APPEND -NEED
  94. * GO- TO THE TEXT. IF THE DUMP INDICATOR IS SET TO -Y- THEN APPEND
  95. * -ON- TO THE TEXT, ELSE APPEND -OFF- TO THE TEXT.
  96. #
  97. FOR I=0 STEP 1 WHILE ABHSN[0] NQ NPU$NID[I] AND
  98. I LS CSNPCNT
  99. DO
  100. BEGIN
  101. END
  102. IF I LS CSNPCNT
  103. THEN
  104. BEGIN
  105. CNST1 = 1;
  106. CNST2 = 30;
  107. CNST3 = 42;
  108. SSBSBF(NPS$TXT,CNST1,CNST2,CNST3,B<0,42>NPU$WORD[I]);
  109. END
  110. CTEMP[0] = XCDD(1000 + ABHSN[0]);
  111. NPS$NID[0] = CTEMP3[0];
  112. IF STUDP[0] EQ ASCII$Y
  113. THEN
  114. BEGIN
  115. NPS$DP[0] = " ON";
  116. END
  117. ELSE
  118. BEGIN
  119. NPS$DP[0] = "OFF";
  120. END
  121. IF STUGO[0] EQ OP$GO
  122. THEN
  123. BEGIN
  124. NPS$GO[0] = "NEEDGO";
  125. END
  126. ELSE
  127. BEGIN
  128. NPS$GO[0] = " ";
  129. END
  130. #
  131. * IF THIS SM IS A STU/NP/U, THEN APPEND THE CURRENT TIME TO THE
  132. * TEXT. SEND THE TEXT OFF TO THE OPERATOR RESPONSE QUEUE WITH AN
  133. * AUDIENCE GROUP OF ONE. IF THE REASON CODE IS SET TO THREE (DUMP
  134. * OPTION CHANGED), THEN APPEND THE TIME NPU NAME AND MESSAGE TO
  135. * INDICATE THE CHANGE AND SEND IT OFF TO THE OPERATOR RESPONSE QUEUE
  136. * WITH AN AUDIENCE GROUP OF ONE.
  137. #
  138. IF WCB$SMID[0] EQ SMID"STUNP"
  139. THEN
  140. BEGIN
  141. NPS$TIM[0] = CTM$CLOCK[0];
  142. WCB$WORD[1] = 0;
  143. WCB$WC[1] = 2 + (NPS$TXTL / 10);
  144. ABHWORD[1] = NPS$TXTL;
  145. ABHADR[1] = AUDGR3$;
  146. ABHABN[1] = I;
  147. SSTAQE(P<ORQ>,WCBUF[1],ABH[1],NPS$TXT[0]);
  148. CSESLE(ABHSN[0],WCBUF[1],NPS$TXT);
  149. IF STURCL[0] EQ RRCN"DO"
  150. THEN
  151. BEGIN
  152. CNST1 = 1;
  153. CNST2 = 30;
  154. CNST3 = 42;
  155. SSBSBF(DOC$TXT,CNST1,CNST2,CNST3,B<0,42>NPU$WORD[I]);
  156. WCB$WC[1] = 2 + (DOC$TXTL / 10);
  157. ABHTLC[1] = DOC$TXTL;
  158. SSTAQE(P<ORQ>,WCBUF[1],ABH[1],DOC$TXT[0]);
  159. CSESLE(ABHSN[0],WCBUF[1],DOC$TXT);
  160. END
  161. END
  162. #
  163. * IF THIS SM IS A STU/NP/N , THEN SEND THE TEXT TO THE
  164. * OPERATOR IDENTIFIED BY ACN VIA THE C-LAYER QUEUE WITH THE INPUT
  165. * ALLOWED FLAG CLEARED.
  166. #
  167. ELSE # IF NOT STU/NP/U, THEN ASSUME THIS SM IS #
  168. BEGIN # STU/NP/N. #
  169. WCB$WORD[1] = 0;
  170. WCB$SMID[1] = SMID"TTEXT";
  171. WCB$WC[1] = 2 + (NPS$TXTL / 10) - 1;
  172. ABHWORD[1] = 0;
  173. ABHADR[1] = ABHCN[0];
  174. ABHTLC[1] = NPS$TXTL - 10;
  175. SSTAQE(P<CNQ>,WCBUF[1],ABH[1],NPS$TXT[1]);
  176. END
  177. RETURN; # **** RETURN **** #
  178. END # CSESNS #
  179. TERM
cdc/nos2.source/nam5871/csesns.txt ยท Last modified: 2023/08/05 17:21 by Site Administrator