aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDimitri Sokolyuk <demon@dim13.org>2018-02-12 05:13:39 +0100
committerDimitri Sokolyuk <demon@dim13.org>2018-02-12 05:13:39 +0100
commitc0727804dd12084f49d043046e564c5583d6860f (patch)
tree95ef2b09074a667db5b6bc00e61a0774e6d615a9
parent13ec1cdc343da5a309ca4ac448cfe3033ac791b2 (diff)
...
-rw-r--r--core.go7
1 files changed, 6 insertions, 1 deletions
diff --git a/core.go b/core.go
index 41b4fea..df89425 100644
--- a/core.go
+++ b/core.go
@@ -19,7 +19,12 @@ type Console interface {
// Core of J1 Forth CPU
//
-// memory: 0x2000 words (16k) addressed by byte
+// 33 deep × 16 bit data stack
+// 32 deep × 16 bit return stack
+// 13 bit program counter
+// memory is 16 bit wide and addressed by bytes
+// 0..0x3fff RAM, 0x4000..0x7fff mem-mapped I/O
+//
type Core struct {
memory [0x2000]uint16 // 0..0x3fff RAM, 0x4000..0x7fff mem-mapped I/O
pc uint16 // 13 bit