GBA Audio: Implement audio reset for channels A/B

This commit is contained in:
Jeffrey Pfau 2015-06-29 00:24:52 -07:00
parent 735d7642e0
commit 841a0909b9
3 changed files with 7 additions and 2 deletions

View File

@ -86,6 +86,7 @@ Misc:
- ARM7: Reduce the size of the Thumb instruction table
- GBA: Don't include GBACLIDebugger struct unless needed
- SDL: Clean up GL context
- GBA Audio: Implement audio reset for channels A/B
0.2.1: (2015-05-13)
Bugfixes:

View File

@ -104,7 +104,6 @@ Footnotes
- OBJ window for modes 3, 4 and 5 ([Bug #5](http://mgba.io/b/5))
- Mosaic for transformed OBJs ([Bug #9](http://mgba.io/b/9))
- BIOS call RegisterRamReset is partially stubbed out ([Bug #141](http://mgba.io/b/141))
- Audio channel reset flags ([Bug #142](http://mgba.io/b/142))
- Game Pak prefetch ([Bug #195](http://mgba.io/b/195))
- BIOS call Stop, for entering sleep mode ([Bug #199](http://mgba.io/b/199))

View File

@ -456,7 +456,12 @@ void GBAAudioWriteSOUNDCNT_HI(struct GBAAudio* audio, uint16_t value) {
audio->chBRight = GBARegisterSOUNDCNT_HIGetChBRight(value);
audio->chBLeft = GBARegisterSOUNDCNT_HIGetChBLeft(value);
audio->chBTimer = GBARegisterSOUNDCNT_HIGetChBTimer(value);
// TODO: Implement channel reset
if (GBARegisterSOUNDCNT_HIIsChAReset(value)) {
CircleBufferClear(&audio->chA.fifo);
}
if (GBARegisterSOUNDCNT_HIIsChBReset(value)) {
CircleBufferClear(&audio->chB.fifo);
}
}
void GBAAudioWriteSOUNDCNT_X(struct GBAAudio* audio, uint16_t value) {