void write_byte(UInt16 adr, byte abyte) { if (adr < 0x1000) ram[adr & 0x7ff] = abyte; else write_byte_io(adr, abyte); }