diff --git a/emul/forth/z80c.bin b/emul/forth/z80c.bin index 5bed93b..0884ccd 100644 Binary files a/emul/forth/z80c.bin and b/emul/forth/z80c.bin differ diff --git a/forth/forth.asm b/forth/forth.asm index a8a2788..a1756f2 100644 --- a/forth/forth.asm +++ b/forth/forth.asm @@ -733,23 +733,9 @@ PRINT: inc hl jr .loop -; ( port -- c ) - .db "PC@" - .fill 4 - .dw $-PRINT - .db 0 -PFETCH: - .dw nativeWord - pop bc - call chkPS - ld h, 0 - in l, (c) - push hl - jp next - .db "C," .fill 5 - .dw $-PFETCH + .dw $-PRINT .db 0 CWR: .dw nativeWord diff --git a/forth/z80a.fs b/forth/z80a.fs index 411021e..c98af54 100644 --- a/forth/z80a.fs +++ b/forth/z80a.fs @@ -124,7 +124,7 @@ OR A, ; 0xed41 OP2r OUT(C)r, -0xeb40 OP2r INr(C), +0xed40 OP2r INr(C), ( dd nn -- ) : OP3ddnn diff --git a/forth/z80c.fs b/forth/z80c.fs index 61fc883..1237216 100644 --- a/forth/z80c.fs +++ b/forth/z80c.fs @@ -90,3 +90,11 @@ CODE PC! chkPS, L OUT(C)r, ;CODE + +CODE PC@ + BC POPqq, + chkPS, + H 0 LDrn, + L INr(C), + HL PUSHqq, +;CODE