User Tools

Site Tools


cdc:nos2.source:nam5871:cssatm

CSSATM

Table Of Contents

  • [00008] PROC CSSATM
  • [00009] CSSATM - ACTION TEST MESSAGE COMMAND
  • [00014] ACTION TEST MESSAGE COMMAND.
  • [00041] PROC SSBEBF
  • [00042] PROC SSBSBF
  • [00043] PROC SSBTBW
  • [00044] FUNC SSDCDA
  • [00045] PROC SSTAQE

Source Code

CSSATM.txt
  1. *DECK CSSATM
  2. USETEXT TEXTCS;
  3. USETEXT TEXTSS;
  4. USETEXT TXCMDCS;
  5. USETEXT TXTAPSS;
  6. USETEXT TXTSMCS;
  7. USETEXT TXTSUSS;
  8. PROC CSSATM;
  9. # TITLE CSSATM - ACTION TEST MESSAGE COMMAND #
  10.  
  11. BEGIN # CSSATM #
  12.  
  13. #
  14. ** CSSATM - ACTION TEST MESSAGE COMMAND.
  15. *
  16. * C. BRION 82/06/09.
  17. *
  18. * THIS PROCEDURE PROCESSES THE DIAGNOSTIC TEST MESSAGE (DATA)
  19. * COMMAND FROM AN OPERATOR TO THE ONLINE DIAGNOSTIC PROGRAM IN
  20. * AN NPU.
  21. *
  22. * PROC CSSATM
  23. *
  24. * ENTRY:
  25. *
  26. * HDRCMD = COMMAND HEADER WORD.
  27. * PARMS = COMMAND PARAMETER ARRAY.
  28. *
  29. * EXIT:
  30. *
  31. * AN OLDDT SM MAY BE SENT TO A NPU.
  32. * A TERMINAL TEXT ENTRY WILL BE SENT TO THE OPERATOR.
  33. #
  34.  
  35. #
  36. **** PROC CSSATM XREF LIST
  37. #
  38.  
  39. XREF
  40. BEGIN
  41. PROC SSBEBF; # SS-EXTRACT BIT FIELD #
  42. PROC SSBSBF; # SS-STOREBIT FIELD #
  43. PROC SSBTBW; # SS-TEST BIT IN WORD #
  44. FUNC SSDCDA; # SS-DISPLAY TO ASCII #
  45. PROC SSTAQE; # SS-ACCEPT QUEUE ENTRY #
  46. END
  47. #
  48. ****
  49. #
  50.  
  51.  
  52. ITEM OORD U; # OCB ORDINAL #
  53. ITEM NORD U; # NPUCB ORDINAL #
  54. ITEM I U; # LOOP INDUCTION VAR #
  55. ITEM DORD U; # CHAR MOVE VARS #
  56. ITEM DBIT U;
  57. ITEM AORD U;
  58. ITEM ABIT U;
  59. ITEM Y U; # LOOP INDUCTION VAR #
  60. ITEM SCHAR U; # CHARACTER VAR #
  61. ITEM FOUND B; # NPUCB ORDINAL FOUND FLAG #
  62. ITEM MCINDX U; # MSG COUNT PARM INDX #
  63. ITEM RUNNING B; # OLD RUNNING FLAG #
  64.  
  65.  
  66. #
  67. * MSGTXT - DIAGNOSTIC MESSAGE TEXT.
  68. #
  69.  
  70. ARRAY MSGTXT [00:00] S(4);
  71. BEGIN
  72. ITEM MSG$NP C(00,00,07); # NPU NAME #
  73. ITEM MSG$TXT1 C(00,42,06) = ["/OLD: "];
  74. ITEM MSG$TX2 C(01,18,20);
  75. ITEM MSG$ZRO U(03,18,42) = [0];
  76. END
  77.  
  78.  
  79.  
  80.  
  81. #
  82. * INITIALIZE OUTGOING ENTRY WORDS, OCB AND NPUCB ORDINALS, AND
  83. * MESSAGE TEXT MESSAGE.
  84. #
  85.  
  86. OORD = HDR$OPORD[0];
  87.  
  88. FOUND = FALSE;
  89. #
  90. * FIND NPUCB ORDINAL IN COMMAND PARAMETER ARRAY.
  91. #
  92.  
  93. FOR I = 0 STEP 1 WHILE NOT FOUND
  94. DO
  95.  
  96. BEGIN
  97. IF PAR$PCODE[I] EQ "NOR"
  98. THEN
  99.  
  100. BEGIN
  101. NORD = PAR$ORD[I];
  102. FOUND = TRUE;
  103. END
  104.  
  105. END
  106.  
  107. MSG$NP[0] = NPU$NAME[NORD];
  108. WCB$WORD[0] = 0;
  109. WCB$WORD[1] = 0;
  110. ABHWORD[0] = 0;
  111. ABHWORD[1] = 0;
  112. ABHADR[0] = OORD;
  113. WCB$WC[0] = 5;
  114.  
  115. #
  116. * ORIGIN OPERATOR MAY NOT BE CURRENT OLD OPERATOR. IF SO, SEND
  117. * ERROR MESSAGE.
  118. #
  119.  
  120. SSBTBW(NPU$OVFLGS[NORD],OORD,RUNNING);
  121.  
  122. IF NOT RUNNING
  123. THEN
  124. MSG$TX2[0] = "NO PRIOR REQUEST CMD";
  125. ELSE
  126.  
  127. #
  128. * CURRENT OLD OPERATOR SAME AS ORIGIN BUT OLD REQUEST MAY STILL BE
  129. * OUTSTANDING. IF SO, SEND INPROGRESS MESSAGE.
  130. #
  131.  
  132. #
  133. * EVERYTHING OK FOR SEND OF OLDDT SM TO OLD PROGRAM OF NPU.
  134. #
  135.  
  136. BEGIN
  137. WCB$SMID[1] = SMID"OLDDT";
  138. ABHDN[1] = NPU$NID[NORD];
  139. ABHSN[1] = NPU$HID[NORD];
  140. ABHABT[1] = APPSUP;
  141. ABHBT[1] = APPSUP;
  142. ABHACT[1] = ACTCSNP$;
  143. PFCSFC[1] = OLDDT;
  144. OLDDO[1] = OORD;
  145.  
  146. #
  147. * CONVERT THE MESSAGE TEXT TO ASCII AND STORE INTO OUTGOING SM
  148. #
  149.  
  150. FOUND = FALSE;
  151. FOR I = 0 STEP 1 WHILE NOT FOUND
  152. DO
  153.  
  154. BEGIN
  155. IF PAR$PCODE[I] EQ "MS0"
  156. THEN
  157.  
  158. BEGIN
  159. DORD = I + 1;
  160. MCINDX = I;
  161. FOUND = TRUE;
  162. END
  163. END
  164.  
  165. DBIT = 0;
  166. AORD = 0;
  167. ABIT = 24;
  168. ABHTLC[1] = PAR$MSGCL[MCINDX] + 3;
  169.  
  170. FOR Y = 1 STEP 1 UNTIL PAR$MSGCL[MCINDX]
  171. DO
  172.  
  173. BEGIN
  174. SSBEBF(PARMS[0],DORD,DBIT,6,SCHAR);
  175. SCHAR = SSDCDA(SCHAR);
  176. SSBSBF(CSSM[1],AORD,ABIT,8,SCHAR);
  177. END
  178.  
  179. WCB$WC[1] = ((ABHTLC[1] + 9)/10) + 2;
  180. SSTAQE(P<OTQ>,WCBUF[1],ABH[1],CSSM[1]);
  181. WCB$WC[0] = 2;
  182. END
  183.  
  184. #
  185. * SEND TTEXT TO OPERATOR
  186. #
  187.  
  188. WCB$IAF[0] = TRUE;
  189. WCB$SMID[0] = SMID"TTEXT";
  190. SSTAQE(P<CNQ>,WCBUF[0],ABH[0],MSGTXT[0]);
  191.  
  192. END # CSSATM #
  193. TERM
cdc/nos2.source/nam5871/cssatm.txt ยท Last modified: 2023/08/05 17:21 by Site Administrator