Table of Contents

ECDMP

Table Of Contents

  • [00003] ECDMP - ECS DUMPER FOR PLATO.
  • [00038] MAIN LOOP
  • [00104] ECSERR – REPORT ECS ERRORS

Source Code

ECDMP.txt
  1. ECDMP
  2. IDENT ECDMP,111B,ECDMP
  3. TITLE ECDMP - ECS DUMPER FOR PLATO.
  4. *
  5. *
  6. *
  7. * DUMPS CONTENTS OF GIVEN ECS LOCATIONS INTO FILE
  8. * NAMED IN FIRST ARGUMENT. FILE IS WRITTEN AS A
  9. * SERIES OF 1000B (512) WORD RECORDS AND IS ENDED
  10. * WITH AN END-OF-FILE. JOB CALLING ECDMP MUST
  11. * ALREADY HAVE AN ECS FIELD LENGTH SET, ECDMP DOES
  12. * NOT REQUEST ANY ECS OF ITS OWN.
  13. *
  14. * THE FIRST RECORD OF EVERY DUMP IS A HEADER RECORD
  15. * CONTAINING THE NAME OF THE JOB WHICH DID THE DUMP
  16. * AND THE DATE AND TIME OF THE DUMP.
  17. *
  18. *
  19. *
  20. * ECDMP(FILE,FFFF,LLLL)
  21. *
  22. * FILE = FILE NAME TO RECEIVE DUMP (ASSUMES *ECFILE*)
  23. * FFFF = FIRST WORD OF ECS TO DUMP/1000B (IN OCTAL)
  24. * LLLL = LAST WORD OF ECS TO DUMP/1000B (IN OCTAL)
  25. *
  26. *
  27. *
  28. *
  29. * COMMENT COPYRIGHT CONTROL DATA CORP. 1978.
  30. *COMMENT ECDMP - ECS DUMPER FOR PLATO.
  31. *
  32. ABS
  33. SST
  34. SYSCOM B1
  35. *CALL COMCMAC
  36. *
  37. BUFL EQU 1001B CIO BUFFER LENGTH
  38. TITLE MAIN LOOP
  39. ORG 111B
  40. *
  41. ECDMP RJ PRS
  42. SA1 ECSL CHECK FOR NOTHING TO DO
  43. ZR X1,ECDONE
  44. NG X1,ECDONE
  45. OPEN ECFILE,WRITE,R
  46. RECALL ECFILE
  47. REWIND ECFILE,R
  48. RECALL ECFILE
  49. *
  50. * WRITE HEADER RECORD
  51. *
  52. GETJN BUFF SET JOB NAME IN HEADER
  53. DATE BUFF+1 SET DATE IN HEADER
  54. CLOCK BUFF+2 SET TIME IN HEADER
  55. SX6 BUFF+3 SET IN POINTER
  56. SA6 ECFILE+2
  57. SX6 BUFF SET OUT POINTER
  58. SA6 A6+B1
  59. WRITER ECFILE,R WRITE HEADER
  60. RECALL ECFILE
  61. *
  62. * SET ERROR EXIT ADDRESS TO ALLOW ORDERLY EXIT
  63. *
  64. EREXIT ECDONE
  65. *
  66. * SET UP FOR ECS DUMP
  67. *
  68. SA0 BUFF CM ADDRESS
  69. SA1 ECSF SET BEGINNING ECS ADDRESS
  70. LX1 9
  71. BX0 X1
  72. *
  73. ECLOOP BX1 X0 ISSUE MESSAGE
  74. RJ COD
  75. SA6 MSG+1
  76. MESSAGE MSG,1,R
  77. RE BUFL-1 READ WORDS INTO BUFFER
  78. - RJ ECSERR
  79. SX6 BUFF+BUFL-1 RESET CIO POINTERS FOR TRANSFR
  80. SA6 ECFILE+2
  81. SX6 BUFF
  82. SA6 A6+B1
  83. WRITER ECFILE,R TRANSFER DATA
  84. RECALL ECFILE
  85. SX1 BUFL-1 INCREMENT ECS ADDRESS
  86. IX0 X0+X1
  87. SA2 ECSL DECREMENT LENGTH TO READ
  88. AX1 9
  89. IX6 X2-X1
  90. ZR X6,ECDONE IF ALL DUMPED
  91. NG X6,ECDONE IF ALL DUMPED
  92. SA6 A2
  93. EQ ECLOOP
  94. *
  95. ECDONE BSS 0
  96. WRITEF ECFILE,R TACK ON AN EOF
  97. RECALL ECFILE
  98. ENDRUN QUIT
  99. *
  100. *
  101. MSG CON 10LDUMPING -
  102. BSS 1
  103. CON 0
  104. TITLE ECSERR -- REPORT ECS ERRORS
  105. **
  106. * ECSERR - REPORT ECS ERRORS
  107. *
  108. * ON ENTRY - X0 = ADDRESS OF ECS READ
  109. *
  110. * ISSUES ERROR MESSAGE
  111. *
  112. *
  113. ECSERR EQ *+400000B
  114. BX1 X0 CONVERT ADDRESS TO DISPLAY CODE
  115. RJ COD
  116. SA6 ADDR
  117. MESSAGE ERR,0,R
  118. SX1 BUFL-1 DUMMY UP A RECORD
  119. AX1 1 DIVIDE BY TWO
  120. SB2 X1
  121. SA1 DUMMY
  122. SA2 A1+B1
  123. BX6 X1
  124. BX7 X2
  125. SA6 BUFF
  126. SA7 A6+B1
  127. *
  128. ECSERR1 SB2 B2-B1
  129. ZR B2,ECSERR IF DONE
  130. NG B2,ECSERR IF OVER-DONE
  131. SA6 A6+2
  132. SA7 A6+B1
  133. EQ ECSERR1
  134. *
  135. *
  136. ERR DIS 2,(ECDMP) ECS ERROR -
  137. ADDR BSS 1
  138. CON 0
  139. *
  140. DUMMY DIS ,/*** ECS ERROR ***/
  141. *
  142. COD TITLE CONVERSION ROUTINES
  143. **
  144. * COD - CONSTANT TO OCTAL DISPLAY CODE CONVERSION
  145. *
  146. * CONVERT 10 OCTAL DIGITS TO DISPLAY CODE WITHOUT
  147. * LEADING ZERO SUPPRESSION
  148. *
  149. * MODIFICATION OF KRONOS COMMON DECK COMCCOD
  150. *
  151. * ENTRY X1=NUMBER TO CONVERT
  152. *
  153. * EXIT X6=DPC CONVERSION
  154. *
  155. * USES - A - NONE
  156. * X - 1,2,3,4,6
  157. * B - 3
  158. *
  159. * CALLS NONE
  160. *
  161. *
  162. COD EQ *+400000B
  163. SB3 10 CONVERT 10 DIGITS
  164. MX2 -3 DIGIT MASK
  165. MX6 0
  166. SX3 1R0 CONVERSION CONSTANT
  167. *
  168. COD1 BX4 -X2*X1 GET DIGIT
  169. IX4 X4+X3 CONVERT
  170. LX4 -6
  171. LX6 -6
  172. BX6 X6+X4 INSERT CHAR
  173. SB3 B3-B1
  174. EQ B3,B0,COD JUMP IF 10 DIGITS
  175. AX1 3 GO TO NEXT DIGIT
  176. EQ COD1 LOOP TILL 10 DIGITS
  177. *
  178. *
  179. *
  180. *
  181. *CALL COMCCPM
  182. *CALL COMCCIO
  183. *CALL COMCSYS
  184. *
  185. *
  186. *
  187. ECSF BSS 1 FIRST WORD TO DUMP/1000B
  188. ECSL BSS 1 ECS DUMP LENGTH/1000B
  189. *
  190. *
  191. * FET AND BUFFER
  192. *
  193. ECFILE FILEB BUFF,BUFL
  194. *
  195. *
  196. BUFF EQU *
  197. *
  198. *
  199. RFL= EQU BUFF+BUFL+2
  200. *
  201. * INITIALIZATIONS GO INTO CIO BUFFER
  202. *
  203. PRS EQ *+400000B
  204. SB1 1
  205. *
  206. * SET OUTPUT FILE NAME
  207. *
  208. SA1 ARGR SET FILE NAME
  209. MX6 42
  210. BX6 X6*X1
  211. ZR X6,INIT1 IF NONE, USE *ECFILE*
  212. SX7 B1
  213. BX6 X6+X7
  214. SA6 ECFILE
  215. *
  216. * CONVERT ECS FWA TO OCTAL
  217. *
  218. INIT1 MX0 -6
  219. MX6 0 CLEAR NUMBER BUILDING
  220. SA1 ARGR+1 LOAD ECS FWA
  221. ZR X1,W10
  222. BX2 -X0*X1 CHECK FOR LEGAL ARGUMENT
  223. NZ X2,W10
  224. RJ ATOO
  225. *
  226. W10 SA6 ECSF
  227. *
  228. * CONVERT ECS LWA TO OCTAL
  229. *
  230. MX0 -6
  231. MX6 0 CLEAR NUMBER BUILDING
  232. SA1 ARGR+2 LOAD ECS LWA
  233. ZR X1,W100
  234. BX2 -X0*X1 CHECK FOR LEGAL ARGUMENT
  235. NZ X2,W100
  236. RJ ATOO
  237. *
  238. W100 SA1 ECSF CHANGE TO ECS LENGTH TO DUMP
  239. IX6 X6-X1
  240. SA6 ECSL
  241. EQ PRS
  242. *
  243. *
  244. *
  245. ATOO EQ *
  246. LX1 6 POSITION NEXT CHARACTER
  247. BX2 -X0*X1
  248. ZR X2,ATOO EXIT IF END
  249. SX2 X2-1R0 CONVERT TO OCTAL
  250. LX6 3
  251. IX6 X2+X6 ADD TO NUMBER BUILDING
  252. EQ ATOO+1
  253. *
  254. *
  255. *
  256. *
  257. *
  258. END