-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmon.txt
210 lines (124 loc) · 3.36 KB
/
mon.txt
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
/////// PC-8801 ////////
/// 'mon' ///
Brief overview of usage for the native assembly language monitor. The ROM's
machine language monitor has mini-assembler functionality, display for
octal and hex, ability to read/write to I/O ports, and disassemble.
][ BASIC Commands ][
====================
| mon
Starts the machine language monitor
| print hex$(peek(&HE7E9)*256+peek(&HE7E8))
Displays hex address of highmem
| print hex$(peek(&HEB1C)*256+peek(&HEB1B))
Displays hex address of lowmem
| clear ,&Hnnnn
Sets the base address of the ML program (usually clear ,&H9000)
][ MONITOR COMMANDS ][
======================
| ctrl+B
Return to BASIC
| STOP or ctrl+C
Return to previous line (e.g. typo)
| A
Assemble. Begin assembling, using Intel mnemonic, at the specified address.
e.g.
h] a9000 (enter)
9000 FF-(begin typing asm)
Z80 Equivalent
jr x jmpr x
jr z,x jrz x
jr nz,x jrnz x
jr c,x jrc x
jr nc,x jrnc x
djnz x djnz x
| B
Base. Change number base for display and input - bh is hex, bq is octal.
e.g.
h] bq
q]
| D
Dump memory. Shows hex representation of range provided.
e.g.
h] d
0000 F3 31 A0 E1 C3 ...
or
h] d9000,9020
(lists memory from 9000h to 9020h)
| E
Edit memory. Opens a hex editor where you can enter values manually. Ctrl+C
or ESC will return to mon.
e.g.
h] e9000
(opens hex editor at address 9000h)
| F
Fill memory. Fills from start address to target address with value N.
e.g.
h] f9000,9010,ff
h] d9000
9000 FF FF FF FF FF FF ...
| G
Go. Runs code starting at the specified address. Can optionally take 2
breakpoint addresses as arguments.
e.g.
h] g9000,9050,9080
(Runs code from 9000h and stops either 9050h and 9080h)
h] g
(Resets the machine - same as g0000)
| I
Input. Read a byte from the specified port address.
| L
Disassemble. Shows disassembly with mnemonic beginning at the specified
address (takes an optional end address).
e.g.
h] l9000
9000 FF RST 7 ...
| M
Move memory. Takes three arguments: start address of copy, end address of
copy, destination address.
e.g.
h] m9000,9100,a000
(Copies 9000h-9100h to a000h-a100h.)
| O
Output. Outputs the given data byte to the specified port.
e.g.
h] o10,ff
(Writes FFh to port 10)
| P
Printer switch. When enabled, any D, L and Ctrl+D command will be sent to
the printer instead of the screen.
| R
Read tape. Only for tape access.
e.g.
h] rGAME
(Tries to load GAME from tape.)
| S
Set memory. Inline version of 'E' command. Use the spacebar to quickly tab
forward to the next byte without modifying it, or ESC to cancel. Pressing
return will commit to memory and return to mon.
e.g.
h] s9000
(Edit the byte at 9000h.)
| TM
Test memory. Valuable memtest tool if you have real hardware.
| V
Verify tape. Checks to see if what is present in memory is equivalent to what
is on tape. Optionally takes filename argument, like R.
e.g.
h] vGAME
| W
Write tape. Writes given filename to tape from given start and end memory
addresses.
e.g.
h] wGAME,9000,9100
| X
eXamine register. Optionally takes register name as argument (a, f, b, d,
h, i, x, y, p (pc), s (sp)). No argument will print all registers.
| HELP key or Ctrl+A
Prints online help. In English, no less!
[With DISK BASIC:]
| Ctrl+D
Dump Disk. Prints disk data to screen.
| Ctrl+R
Read disk. Reads disk into memory.
| Ctrl+W
Write disk. Writes memory to disk.