From 8e4f2bc11469ce8b6f94135ed8a8a7e2aa12ec9f Mon Sep 17 00:00:00 2001 From: Ry Date: Wed, 27 Jul 2022 14:24:05 -0700 Subject: [PATCH] First audio buffer refill interrupt should play from buffer 0 --- src/bus.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/bus.rs b/src/bus.rs index ec81fc8..bff0891 100644 --- a/src/bus.rs +++ b/src/bus.rs @@ -174,7 +174,7 @@ impl Bus { 0x80000600 => { // audio port let mut audio_lock = self.audio.lock().unwrap(); audio_lock.playing = word != 0; - audio_lock.current_buffer_is_0 = true; + audio_lock.current_buffer_is_0 = false; // the first buffer refill interrupt will invert this to true } 0x80001000..=0x80005003 => { // disk controller port let id = port as u8;