summaryrefslogtreecommitdiff
path: root/sound.c
diff options
context:
space:
mode:
authorDavid G. F2021-06-27 01:30:50 +0200
committerGitHub2021-06-27 01:30:50 +0200
commit48f1a71fb7b1d551295aec7ea44f5529c87bff93 (patch)
treecc50bd05fd8fd14444825c4929fb94ea6e98b1dc /sound.c
parentd5ff18d3cebc56c351d95a3eec1873cd7112e31f (diff)
parent8dbf5f6c17e3d217877119620e5bbfeba05abd7a (diff)
downloadpicogpsp-48f1a71fb7b1d551295aec7ea44f5529c87bff93.tar.gz
picogpsp-48f1a71fb7b1d551295aec7ea44f5529c87bff93.tar.bz2
picogpsp-48f1a71fb7b1d551295aec7ea44f5529c87bff93.zip
Merge pull request #137 from davidgfnet/master
Enable big-endian devices: gc/wii
Diffstat (limited to 'sound.c')
-rw-r--r--sound.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sound.c b/sound.c
index 10a3261..bc88fff 100644
--- a/sound.c
+++ b/sound.c
@@ -437,7 +437,7 @@ void update_gbc_sound(u32 cpu_ticks)
s32 volume_left, volume_right;
u32 envelope_volume;
s32 current_sample;
- u32 sound_status = address16(io_registers, 0x84) & 0xFFF0;
+ u16 sound_status = read_ioreg(REG_SOUNDCNT_X) & 0xFFF0;
s8 *sample_data;
s8 *wave_bank;
u8 *wave_ram = ((u8 *)io_registers) + 0x90;
@@ -521,7 +521,7 @@ void update_gbc_sound(u32 cpu_ticks)
}
}
- address16(io_registers, 0x84) = sound_status;
+ write_ioreg(REG_SOUNDCNT_X, sound_status);
gbc_sound_last_cpu_ticks = cpu_ticks;
gbc_sound_buffer_index =