home *** CD-ROM | disk | FTP | other *** search
/ Compute! Gazette 1994 November / 1994-11b.d64 / supermon+64.doc (.txt) < prev    next >
Commodore BASIC  |  2022-09-20  |  7KB  |  229 lines

  1. 5 print"[147][144]
  2. 10 [143] supermon+ instr
  3. 20 [141] 10000
  4. 30 [153] "supermon+ is a new version of
  5. 40 print"'supermon'  the reason for the new
  6. 50 [153]"version is to provide identical
  7. 55 print"commands to those of the built-in
  8. 60 [153]"monitor of the commodore 128.
  9. 65 print"  the most visible changes from
  10. 70 [153]"earlier versions of supermon are:
  11. 75 print"  --decimal or binary input allowed;
  12. 80 [153]"  --disk status and commands (@);
  13. 85 print"  --looser (easier) syntax.
  14. 100 [141] 9000
  15. 110 [153]" number conversion "
  16. 120 [153]"   $2000
  17. 130 print" $2000
  18. 140 [153]" +8192
  19. 150 print" &20000
  20. 160 [153]" %10000000000000
  21. 170 print
  22. 180 print"     in the above example the user
  23. 190 [153]"has asked for the numeric equivalents
  24. 200 print"to hexadecimal 2000.  the reply shows
  25. 210 [153]"the value in hex ($), in decimal (+),
  26. 220 print"in octal (&), and in binary (%).
  27. 230 [153]"  the user could ask for a number to
  28. 240 print"be converted from any of these bases
  29. 250 [153]"by giving the appropriate prefix.
  30. 300 gosub9000
  31. 310 print" important note -- "
  32. 320 print" at any time in the following text,
  33. 330 [153]"you may enter any number in any base
  34. 340 print"and conversion will be done for you.
  35. 350 [153]"example:
  36. 360 print"   m +4096
  37. 370 [153]" ...  will cause a memory display
  38. 380 print"from decimal address 4096.  in the
  39. 390 [153]"display, the hex address ($1000) will
  40. 400 print"be shown.  similarly,
  41. 410 [153]"   a +2048 ldaclose#%10000000
  42. 420 print" ... will be converted to assemble:
  43. 430 [153]"   a $0400 lda #$80
  44. 440 print"   if you don't give a prefix, the
  45. 450 [153]"monitor will assume hexadecimal.
  46. 500 gosub9000
  47. 510 print" register display "
  48. 520 print"   r
  49. 530 [153]"   pc  sr ac xr yr sp
  50. 540 print"; 0000 01 02 03 04 05
  51. 550 [153]"     displays the register values saved
  52. 560 print"when supermon+[146] was entered.  values
  53. 570 [153]"may be changed by typing over the
  54. 580 print"display followed by a return character.
  55. 590 [153]"  pc - program counter
  56. 600 print"  sr - status register
  57. 610 [153]"  ac, xr, yr - a, x, and  y registers
  58. 620 print"  sp - stack pointer
  59. 700 [141]9000
  60. 720 [153]"   mwait 200wait 209
  61. 730 print">0200 4d 20 32 30 30 20 32 30:m 200 20"
  62. 740 print">0208 39 00 00 04 00 04 00 04:9......."
  63. 750 print"     display memory from 0200 hex to
  64. 760 [153]"0209 hex.  display is in lines of 8
  65. 770 print"so addresses $200 to $20f are shown.
  66. 780 [153]"  if one address only is given then
  67. 790 print"12 lines (96 locations) will be shown.
  68. 800 [153]"if no address is given display will go
  69. 810 print"from the last address.
  70. 820 [153]" equivalent ascii characters are shown
  71. 830 print"in reverse at the right.
  72. 840 [153]"values are changed by typing over the
  73. 850 print"display followed by a return character.
  74. 900 [141]9000
  75. 910 [153]" exit to basic "
  76. 920 [153]"   x
  77. 930 print"     return to basic ready[146] mode.
  78. 940 [153]"when you wish to return to supermon+,
  79. 950 print"command sys 8[146].
  80. 1000 [141]9000
  81. 1010 [153]" simple assembler "
  82. 1020 [153]"   await 2000wait ldawait #+18
  83. 1030 print"  (changes  to:)"
  84. 1040 print"a 2000 a9 12    lda #$12
  85. 1050 [153]"a 2002 ..next instruction
  86. 1060 print"     in the above example the user
  87. 1070 [153]"started assembly at 2000 hex.  the
  88. 1080 print"first instruction was load a register
  89. 1090 [153]"with immediate 18 decimal. in following
  90. 1100 print"lines the user need not type the
  91. 1110 [153]"a and address.  the simple assembler
  92. 1120 print"prompts with the next address.  to exit
  93. 1130 [153]"the assembler type a return after the
  94. 1140 print"the address prompt.
  95. 1150 [153]"  previous lines may be changed by
  96. 1160 print"typing over the right hand part.
  97. 1200 [141]9000
  98. 1220 [153]"   dwait 2000wait 2004wait
  99. 1230 print". 2000 a9 12    lda #$12
  100. 1240 [153]". 2002 9d 00 80 sta $8000,x
  101. 1250 print"     disassembles instructions from
  102. 1260 [153]"2000 to 2004 hex.  if one address is
  103. 1270 print"given, 20 bytes will be disassembled.
  104. 1280 [153]"if no address, start from the last
  105. 1290 print"used address.
  106. 1300 [153]"  code may be reassembled by moving
  107. 1310 print"the cursor back and typing over the
  108. 1320 [153]"right hand part.
  109. 1400 gosub9000
  110. 1410 print" fill memory "
  111. 1420 print"   f[146] 1000[146] 1100[146] ff
  112. 1430 [153]"     fills the memory from 1000 hex to
  113. 1440 print"1100 hex with the byte ff hex.
  114. 1500 [141]9000
  115. 1510 [153]" go (run)"
  116. 1520 [153]"   gwait 1000
  117. 1530 print"     go to address 1000 hex and begin
  118. 1540 [153]"running code.
  119. 1550 print"  if no address is given, the address
  120. 1560 [153]"from the <pc> register is used.
  121. 1570 print" jump (subroutine)"
  122. 1580 print"   j[146] 1000
  123. 1590 [153]"     call address 1000 hex and begin
  124. 1600 print"running code.  return to the monitor.
  125. 1700 [141]9000
  126. 2200 [153]" hunt memory "
  127. 2210 [153]"   hwait c000wait d000wait 'read
  128. 2220 print"     hunt thru memory from c000 hex to
  129. 2230 [153]"d000 hex for the ascii string readwait and
  130. 2240 print"print the address where it is found.  a
  131. 2250 [153]"maximum of 32 characters may be used.
  132. 2260 print"   h[146] c000[146] d000[146] 20[146] d2[146] ff
  133. 2270 [153]"     hunt memory from c000 hex to d000
  134. 2280 print"hex for the sequence of bytes 20 d2 ff
  135. 2290 [153]"and print the address.  a maximum of 32
  136. 2300 print"bytes may be used.
  137. 2390 [141]9000
  138. 2400 [153]" load "
  139. 2401 [153]"   lwait
  140. 2402 print"   load any program from cassette #1.
  141. 2403 [153]"    lwait ";[199](34);"ram test";[199](34)
  142. 2404 [153]"   load from cassette #1 the program
  143. 2405 print"named ram test[146].
  144. 2410 [153]"   lwait ";[199](34);"ram test";[199](34);",08wait
  145. 2420 print" load from disk (device 8) the program
  146. 2430 [153]"named ram testwait.
  147. 2440 print"this command leaves basic pointers
  148. 2450 [153]"unchanged.
  149. 2490 gosub9000
  150. 2700 print" save"
  151. 2710 print"   s[146] ";chr$(34);"program name";chr$(34);",01,0800,0c80"
  152. 2720 print"     save to cassette #1 memory from
  153. 2730 [153]"0800 hex up to but not including 0c80
  154. 2740 print"hex and name it program name[146].
  155. 2750 [153]"   swait ";[199](34);"0:program name";[199](34);",08,1200,1f50"
  156. 2760 [153]"    save to disk drive #0 memory from
  157. 2770 print"1200 hex up to but not including 1f50
  158. 2780 [153]"hex and name it program namewait.
  159. 2790 gosub9000
  160. 2800 print" transfer memory "
  161. 2810 print"   t[146] 1000[146] 1100[146] 5000
  162. 2820 [153]"     transfer memory in the range 1000
  163. 2830 print"hex to 1100 hex and start storing it at
  164. 2840 [153]"address 5000 hex.
  165. 2890 gosub9000
  166. 2900 print" compare memory "
  167. 2910 print"   c[146] 1000[146] 1100[146] 5000
  168. 2920 [153]"     compare memory in the range 1000
  169. 2930 print"hex to 1100 hex with memory starting
  170. 2940 [153]"at address 5000 hex.
  171. 2990 gosub9000
  172. 3000 print" check disk "
  173. 3010 print"   @[146]
  174. 3020 [153]"     get disk status message
  175. 3030 print"   @9[146]
  176. 3040 [153]"     get disk unit 9 status message
  177. 3050 print"   @,$0[146]
  178. 3060 [153]"     get drive 0 directory
  179. 3070 print"   @,s0:temp[146]
  180. 3080 [153]"     scratch file 'temp' from disk
  181. 3090 gosub9000
  182. 3100 print" output to printer"
  183. 3110 print"call supermon+ from basic with:
  184. 3120 [153]"  open 4,4:cmd 4:sys 8wait"
  185. 3130 [153]"all commands will go the printer.
  186. 3140 print"  when complete, return to basic
  187. 3150 [153]"with xwait and command:
  188. 3160 print"  print#4:close 4[146]"
  189. 3170 gosub9000
  190. 3500 print"[145]        summary                     "
  191. 3505 print"$[146],+[146],&[146],%[146] number conversion
  192. 3510 [153]"gwait go (run)
  193. 3515 print"j[146] jump  (subroutine)
  194. 3520 [153]"lwait load from tape or disk
  195. 3530 print"m[146] memory display
  196. 3540 [153]"rwait register display
  197. 3550 print"s[146] save to tape or disk
  198. 3560 [153]"xwait exit to basic
  199. 3600 print"a[146] simple assembler
  200. 3610 [153]"dwait disassembler
  201. 3620 print"f[146] fill memory
  202. 3630 [153]"hwait hunt memory
  203. 3660 print"t[146] transfer memory
  204. 3665 [153]"cwait compare memory
  205. 3670 print"@[146] disk status/command
  206. 4000 [141]9000
  207. 4010 [153]"onsupermonwait will load itself into the
  208. 4020 print"top of memory .. wherever that happens
  209. 4030 [153]"to be on your machine.
  210. 4060 print"be sure to note the sys command which
  211. 4070 [153]"links supermonwait to the commodore.  it
  212. 4080 print"may be used to reconnect the monitor
  213. 4090 [153]"if it