From 91f3a27fe2b97b06161fabf3142ccb6fb3a27f91 Mon Sep 17 00:00:00 2001 From: Colby Date: Thu, 21 Jul 2016 18:08:34 +1000 Subject: [PATCH] move timer tick outside CPU non-halt loop, must always tick --- lib/waterfoul/cpu.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/waterfoul/cpu.rb b/lib/waterfoul/cpu.rb index 697bf47..82a4e94 100644 --- a/lib/waterfoul/cpu.rb +++ b/lib/waterfoul/cpu.rb @@ -78,8 +78,8 @@ module Waterfoul serve_interrupt if @ime instruction_byte = fetch_instruction perform_instruction instruction_byte - @timer.tick @m end + @timer.tick @m end def halted?