Audio: DMC

I’ve spent this entire week implementing the 5 audio channels on the NES, and the work has finally paid off:

Red: Pulse 1, Orange: Pulse 2, Green: Triangle, Blue: Noise, Purple: DMC, White: Final Output

Simon’s Quest:

The sample above demonstrates The Silence of the Daylight, from Castlevania II - Simon’s Quest. The DMC channel in particular was tricky to get right. It took an embarassing amount of debugging for me to realize that I was repeatedly playing the first byte of each sample, and forgetting to advance the current address. That tends to not sound very good!

Here’s some more quick examples:

Zelda II - Now with more Ganon Laughing:

Super Mario Bros:

I’m pretty happy with audio at this point! There are some remaining minor issues, mostly related to mixing and channel muting, but now I can move on to more interesting things. Working audio means a working frame counter, and hooking the APU’s IRQ up should let me run blargg’s timing tests, and put a number on just how overclocked my CPU is. Exciting times!

-Zeta