From f2b32ba50bf2101aabec0a7fd55f575d455cb230 Mon Sep 17 00:00:00 2001 From: Miquel Sabaté Solà Date: Tue, 11 Mar 2025 16:40:39 +0100 Subject: Small code style cleanups MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Miquel Sabaté Solà --- shared/joypad.s | 6 +++--- space/include/apu.s | 2 -- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/shared/joypad.s b/shared/joypad.s index 7c3e44c..7bfc575 100644 --- a/shared/joypad.s +++ b/shared/joypad.s @@ -35,7 +35,7 @@ joypad_unsafe_read_x: lda #$01 sta Joypad::JOYPAD1 sta Joypad::m_buttons1, x ; Bit as a guard for the loop below. - lsr a + lsr sta Joypad::JOYPAD1 ;; Now the joypad is ready to accept reads. @@ -75,9 +75,9 @@ joypad_read_x: ;; but it sure is tricky. @joypad_read_x_reread: lda Joypad::m_buttons1, x - pha + tay jsr joypad_unsafe_read_x - pla + tya cmp Joypad::m_buttons1, x bne @joypad_read_x_reread diff --git a/space/include/apu.s b/space/include/apu.s index 32ccff2..65d9876 100644 --- a/space/include/apu.s +++ b/space/include/apu.s @@ -1,5 +1,3 @@ -.segment "CODE" - .scope APU DMC = $4010 FRAME_COUNTER = $4017 -- cgit v1.2.3