From 302c2e94de53f1ab4c014b0b0ec0c93a060b54d1 Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Sun, 11 Jun 2017 21:27:46 -0400 Subject: [PATCH] Corrected lingering hard-coded mask. So titles for memory configurations above 1kb now load. --- Machines/ZX8081/ZX8081.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Machines/ZX8081/ZX8081.cpp b/Machines/ZX8081/ZX8081.cpp index bdd9b69e9..4fc60c433 100644 --- a/Machines/ZX8081/ZX8081.cpp +++ b/Machines/ZX8081/ZX8081.cpp @@ -76,7 +76,7 @@ int Machine::perform_machine_cycle(const CPU::Z80::MachineCycle &cycle) { int next_byte = parser_.get_next_byte(tape_player_.get_tape()); if(next_byte != -1) { uint16_t hl = get_value_of_register(CPU::Z80::Register::HL); - ram_[hl & 1023] = (uint8_t)next_byte; + ram_[hl & ram_mask_] = (uint8_t)next_byte; *cycle.value = 0x00; set_value_of_register(CPU::Z80::Register::ProgramCounter, tape_return_address_ - 1); return 0;