diff --git a/emul/Makefile b/emul/Makefile index e055c93..1728a8c 100644 --- a/emul/Makefile +++ b/emul/Makefile @@ -104,7 +104,7 @@ updatebootstrap: $(ZASMBIN) .PHONY: fbootstrap fbootstrap: forth/stage2 cat ./forth/conf.fs ../forth/boot.fs | ./forth/stage2 > forth/boot.bin - cat ../forth/z80c.fs forth/emul.fs ../forth/icore.fs | ./forth/stage2 | tee forth/z80c.bin > /dev/null + cat ./forth/conf.fs ../forth/z80c.fs forth/emul.fs ../forth/icore.fs | ./forth/stage2 | tee forth/z80c.bin > /dev/null .PHONY: clean clean: diff --git a/emul/forth/boot.bin b/emul/forth/boot.bin index 54d3ae6..13921e3 100644 Binary files a/emul/forth/boot.bin and b/emul/forth/boot.bin differ diff --git a/emul/forth/z80c.bin b/emul/forth/z80c.bin index c27d937..4b454a4 100644 Binary files a/emul/forth/z80c.bin and b/emul/forth/z80c.bin differ diff --git a/forth/boot.fs b/forth/boot.fs index 92eb1dc..59d269f 100644 --- a/forth/boot.fs +++ b/forth/boot.fs @@ -25,11 +25,11 @@ JP(IY), NOP, ( 17, nativeWord ) 0 JPnn, ( 1d, chkPS ) NOP, NOP, ( 20, numberWord ) NOP, NOP, ( 22, litWord ) -RAMSTART , ( 24, RAMSTART ) +NOP, NOP, ( 24, unused ) NOP, NOP, ( 26, unused ) 0 JPnn, ( 28, flagsToBC ) 0 JPnn, ( 2b, doesWord ) -RS_ADDR , ( 2e, RS_ADDR ) +NOP, NOP, ( 2e, unused ) NOP, NOP, ( 30, unused ) NOP, NOP, ( 32, unused ) NOP, NOP, ( 34, unused ) diff --git a/forth/z80c.fs b/forth/z80c.fs index ee00d88..8788330 100644 --- a/forth/z80c.fs +++ b/forth/z80c.fs @@ -18,6 +18,8 @@ Oh, also: KEY and EMIT are not defined here. There're expected to be defined in platform-specific code. + + This unit expects the same conf as boot.fs. ) ( dummy entry for dict hook ) @@ -333,13 +335,12 @@ CODE BYE ;CODE CODE (resSP) - ( INITIAL_SP == 36 ) - SP 36 @ LDdd(nn), + ( INITIAL_SP == RAM+0 ) + SP RAMSTART LDdd(nn), ;CODE CODE (resRS) - ( RS_ADDR == 46 ) - IX 46 @ LDddnn, + IX RS_ADDR LDddnn, ;CODE CODE SCMP