diff options
| author | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-03-11 16:40:39 +0100 |
|---|---|---|
| committer | Miquel Sabaté Solà <mikisabate@gmail.com> | 2025-03-11 16:40:39 +0100 |
| commit | f2b32ba50bf2101aabec0a7fd55f575d455cb230 (patch) | |
| tree | f832264902a0fe89c4999d4971647e6379058cc4 | |
| parent | 6f7a0d24cfa7c767e9eee8283c65b4480a6c231b (diff) | |
| download | code.nes-f2b32ba50bf2101aabec0a7fd55f575d455cb230.tar.gz code.nes-f2b32ba50bf2101aabec0a7fd55f575d455cb230.zip | |
Small code style cleanups
Signed-off-by: Miquel Sabaté Solà <mikisabate@gmail.com>
| -rw-r--r-- | shared/joypad.s | 6 | ||||
| -rw-r--r-- | 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 |
