mirror of
https://github.com/mre/mos6502.git
synced 2025-02-20 09:29:02 +00:00
add single_step function (#62)
Co-authored-by: Sam M W <you@example.com>
This commit is contained in:
parent
fdf71425d3
commit
61b8dfe1f2
@ -415,6 +415,12 @@ impl CPU {
|
||||
};
|
||||
}
|
||||
|
||||
pub fn single_step(&mut self) {
|
||||
if let Some(decoded_instr) = self.fetch_next_and_decode() {
|
||||
self.execute_instruction(decoded_instr);
|
||||
}
|
||||
}
|
||||
|
||||
pub fn run(&mut self) {
|
||||
while let Some(decoded_instr) = self.fetch_next_and_decode() {
|
||||
self.execute_instruction(decoded_instr);
|
||||
|
Loading…
x
Reference in New Issue
Block a user