Because my work-in-progress produces sound garbage by itself, I think I'm missing some initialisation. I reduced it to a simple example, taking tune and patches from the Dr Mario example game. I use the latest kernel from svn trunk, which works fine with the games I compiled myself.
Well, these *are* the actual sources. Hex file attached. It should play the tune from the Dr. Mario game, but all it produces is a fast "rap, rap, rap, rap", like a small sound sample is always repeated. It depends on VRAM contents, too, when I clear VRAM, rapping turns into yelling.
All I hear from the hex is a buzz? Sounds like some kernel reserved RAM overwriting issue, the sound buffer repeats some trash. Hard to tell what's the problem, do you address ram directly? Array bound issue? You can PM me the sources if you want, I'll give it a look.
Sorry. In the last post, I mixed in the patches set from uzepede. When I use the patches set from Dr. Mario, I get no sound at all. Please see another hex file.
Hmm, something is wrong...the emulator (v1.15) hangs on that last hex. Are you sure you are using the latest kernel files from the trunk? I have taken your file and just did make and everything works as expected. What's your environment: linux, windows, mac? I've attached your project with the latest kernel. The hex in the /default folder works, try running make again to see what happens.
Do you need PCM samples in your game? If so indeed you need -DMIXER_CHAN4_TYPE=1 and you don't need -DSOUND_CHANNEL_4_ENABLE=0, since that turns off the PCM channel. You can use -DSOUND_MIXER=1 to use the inline mixer and recover some ram. Also what's the RAM/Flash utilization when you compile?