mirror of
https://github.com/mre/mos6502.git
synced 2024-11-25 02:33:26 +00:00
Add BEQ to execute_instruction().
This commit is contained in:
parent
8febc74788
commit
a0ad2d47be
@ -122,6 +122,12 @@ impl Machine {
|
||||
self.branch_if_carry_set(addr);
|
||||
}
|
||||
|
||||
(instruction::BEQ, instruction::UseRelative(rel)) => {
|
||||
let addr = self.registers.program_counter
|
||||
+ AddressDiff(rel as i32);
|
||||
self.branch_if_equal(addr);
|
||||
}
|
||||
|
||||
(instruction::BIT, instruction::UseAddress(addr)) => {
|
||||
let a: u8 = self.registers.accumulator as u8;
|
||||
let m: u8 = self.memory.get_byte(addr);
|
||||
|
Loading…
Reference in New Issue
Block a user