|
Atari demoscene BBS
Re: STe 8-Bit sample play routine |
Posted by: Bod/STAX
|
Jun,08.2012-19:50
|
This snippet of code is how I play the sound effects in my game using the STE DMA chip:
move.b d6,$fffff8907.w
lsr.w #8,d6
move.l d6,$fffff8902.w
move.b d7,$fffff8913.w
lsr.w #8,d7
move.l d7,$fffff890e.w
move.b #%10000001,$fffff8921.w ; freq
move.b %%00000011,$fffff8901.w ; dma start
d6=start address of sample
d7=end address of sample
This code plays an 8-bit 12.5khz sample once.
See the link I posted above to change the bits to alter loop on/off and change the frequency.
Hope this is of some use to you. :)
|
[All messages in this thread] [Start new thread]
What's the anti-troll code? That's your personal code to be able to add comments and messages on the dhs.nu site.
Don't have a code or forgot it? Fix it here.
|