diff options
author | Dimitri Sokolyuk <demon@dim13.org> | 2018-02-11 12:28:42 +0100 |
---|---|---|
committer | Dimitri Sokolyuk <demon@dim13.org> | 2018-02-11 12:28:42 +0100 |
commit | c2c1402d532ebf3cfd8ef8d24f319fa071194a50 (patch) | |
tree | 32ba6923aa0874d0ac3377fbdb6773ddf95e782e /core.go | |
parent | b0338898e59cb90ea82c4cacd3dc9ec2db5a5486 (diff) |
move io ops to lower address range for single instruction literals
Diffstat (limited to 'core.go')
-rw-r--r-- | core.go | 8 |
1 files changed, 4 insertions, 4 deletions
@@ -70,9 +70,9 @@ func (c *Core) writeAt(addr, value uint16) error { c.memory[addr>>1] = value } switch addr { - case 0xf000: // key + case 0x7000: // key c.console.Write(value) - case 0xf002: // bye + case 0x7002: // bye return ErrStop } return nil @@ -83,9 +83,9 @@ func (c *Core) readAt(addr uint16) uint16 { return c.memory[addr>>1] } switch addr { - case 0xf000: // tx! + case 0x7000: // tx! return c.console.Read() - case 0xf001: // ?rx + case 0x7001: // ?rx return c.console.Len() } return 0 |