diff --git a/config/routines.tal b/config/routines.tal index 2912efd..aba9710 100644 --- a/config/routines.tal +++ b/config/routines.tal @@ -6,7 +6,7 @@ may be used from the `startup.tal` file. The symbols also need to be added to the dictionary in `symbols.tal` for them to become available within Merlin OS. ) %READY { "Ready \n \0 } -%BYE { "Type \s "`bye` \s "to \s "exit. } +%BYE { "Type \s "'bye' \s "to \s "exit. } ( Notify when the system is ready. ) @ready ( -- ) ;&ready !pstr diff --git a/etc/inspect.js b/etc/inspect.js new file mode 100644 index 0000000..5024a2d --- /dev/null +++ b/etc/inspect.js @@ -0,0 +1,16 @@ +print = (stack) => { + let out = ''; + let ptr = stack.ptr(); + for(let i = (~Math.abs(ptr - 7)) & 0xff; i != ptr + 1; i = (i + 1) % 256) { + let byte = stack.get(i); + byte = byte.toString(16); + byte = byte.length == 1 ? ("0" + byte) : byte; + out = out + byte + (i == 0 ? '|' : ' '); + } + return out + "< \n"; +} + +inspect = (uxn) => { + console.error("WST " + print(uxn.wst)); + console.error("RST " + print(uxn.rst)); +} diff --git a/rom/merlin.rom b/rom/merlin.rom index f1763ed..7c00d28 100644 Binary files a/rom/merlin.rom and b/rom/merlin.rom differ diff --git a/rom/merlin.rom.dis b/rom/merlin.rom.dis index 25c4ef7..7ad9cad 100644 --- a/rom/merlin.rom.dis +++ b/rom/merlin.rom.dis @@ -2723,11 +2723,11 @@ 0ec6: 79 SUB2r 0ec7: 70 LDZ2r 0ec8: 65 ROT2r -0ec9: 20 60 62 JCI +24674 +0ec9: 20 27 62 JCI +10082 0ecc: 79 SUB2r 0ecd: 65 ROT2r -0ece: 60 20 74 JSI +8308 -0ed1: 6f STH2r +0ece: 27 OVR2 +0ecf: 20 74 6f JCI +29807 0ed2: 20 65 78 JCI +25976 0ed5: 69 NEQ2r 0ed6: 74 LDA2r @@ -2795,11 +2795,11 @@ 0f34: 20 54 79 JCI +21625 0f37: 70 LDZ2r 0f38: 65 ROT2r -0f39: 20 60 62 JCI +24674 +0f39: 20 27 62 JCI +10082 0f3c: 79 SUB2r 0f3d: 65 ROT2r -0f3e: 60 20 74 JSI +8308 -0f41: 6f STH2r +0f3e: 27 OVR2 +0f3f: 20 74 6f JCI +29807 0f42: 20 65 78 JCI +25976 0f45: 69 NEQ2r 0f46: 74 LDA2r diff --git a/rom/merlin.rom.dmp b/rom/merlin.rom.dmp index 1b3bf6a..7e7293c 100644 --- a/rom/merlin.rom.dmp +++ b/rom/merlin.rom.dmp @@ -234,14 +234,14 @@ f61a a1a0 fbd6 af60 fe2f 60fe 3b6f 40f2 384d 3036 290a 2020 20d6 8320 2020 c2a9 2032 3032 3420 4973 6d61 656c 2056 656e 6567 6173 2043 6173 7465 6c6c c3b3 0a20 -2020 2020 2054 7970 6520 6062 7965 6020 +2020 2020 2054 7970 6520 2762 7965 2720 746f 2065 7869 742e 0a0a 0040 006d 60fe 3b0a 2020 207c 5f20 2020 4d65 726c 696e 204f 5320 2d2d 2076 302e 6520 2831 384d 3036 290a 207c 5f7c 207c 2020 2863 2920 3230 3234 2049 736d 6165 6c20 5665 6e65 6761 7320 4361 7374 656c 6c6f 0a20 2020 -7c20 2020 2054 7970 6520 6062 7965 6020 +7c20 2020 2054 7970 6520 2762 7965 2720 746f 2065 7869 742e 0a0a 006c 4c49 5449 4e43 504f 504e 4950 5357 5052 4f54 4455 504f 5652 4551 554e 4551 4754 484c 5448