From ca28e3c64e3ac3600f1c41628d578a4f7dcefebd Mon Sep 17 00:00:00 2001 From: Thomas Harte Date: Tue, 18 Oct 2016 22:21:06 -0400 Subject: [PATCH] Ensured the AY is pumped linearly, not exponentially. --- Machines/Oric/Oric.hpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/Machines/Oric/Oric.hpp b/Machines/Oric/Oric.hpp index 5c3167602..d37a9429d 100644 --- a/Machines/Oric/Oric.hpp +++ b/Machines/Oric/Oric.hpp @@ -145,12 +145,13 @@ class Machine: std::shared_ptr tape; std::shared_ptr keyboard; - inline void synchronise() { ay8910->run_for_cycles(_half_cycles_since_ay_update >> 1); } + inline void synchronise() { ay8910->run_for_cycles(_half_cycles_since_ay_update >> 1); _half_cycles_since_ay_update = 0; } private: void update_ay() { ay8910->run_for_cycles(_half_cycles_since_ay_update >> 1); + _half_cycles_since_ay_update = 0; ay8910->set_control_lines( (GI::AY38910::ControlLines)((_ay_bdir ? GI::AY38910::BCDIR : 0) | (_ay_bc1 ? GI::AY38910::BC1 : 0) | GI::AY38910::BC2)); } bool _ay_bdir, _ay_bc1;