Audio capabilities

append delete paulaftw

It says on C64wiki, that Mega65 will have "Sound: Dual soft-SIDs + dual 8-bit DACs". Does this mean that it will be possible to play digital audio in Mega65? How about using the DMA chip to play digital sounds without using all the CPU cycles?

It sure would be nice to have a mod player that could mix SID sounds and digital audio. :)

Reply RSS


append delete #1. LGB

Just my personal opinion on this, if I am not boring enough already: I'm not sure if there will be DMA-like stuff for that. I also had that thought, but honestly, it's kinda interesting that it worth at all, if you have 50MHz CPU as well ... Just think about that, the famous GLX player on IBM XT @4.77MHz could achieve playing something like 20 channel module playback or so? :-O Yeah, I guess it used SoundBlaster's DMA anyway too, to play the mixed sample, but still, compare the raw CPU power then. What I found more useful is to have a FIFO so you can "inject" some amount of samples quickly (btw even using the DMAgic of M65 ...) and it can have a full/empty (and especially almost/half empty for example) signals. A dedicated sound DMA is - I guess - more complicated and maybe not so much 8 bit-ish already at all, if I can say that. Even this is a bit that. I guess M65 can happily use just an IRQ or something at the given sample rate to send data and still has enough CPU power left for the work. Some time ago I wrote an SD-card audio play running on 4MHz Z80 (and Z80 has worse IPC than 65xx CPUs) and it was capable to play at around 30KHz, still having enough CPU time to send control to the SD-card to read the next block to the play buffer. Surely, there you don't need to mix channels, processing module commands etc, but don't forget, that M65 CPU @ 50MHz is kinda fast (in fact it can emulate an intel 8080 just in software to be something like a ~12MHz 8080, what I did for some primitive software only CP/M emulator for M65). So in nutshell: I guess there is plenty of enough power in M65 to do mod playback without dedicated hw support too for sample blackback, but surely, some "cheats" (like the FIFO) can't hurt anyway :)

append delete #2. Matt76

Implementing a FPGA circuit for easy playback of digital audio should be relatively trivial. Presumably the dual SID chips are done in FPGA logic as well, mixing digital audio before output would be simple. There is lots of free logic in the Artix 100.

append delete #3. gardners

The MEGA65 currently indeed has two soft SIDs and a left and right digital audio channel. You can also set a register that tells the MEGA65 to talk to external SIDs on a cartridge. The mixing circuitry for the audio would be part of that cartridge (which doesn't yet exist).

As for DMA or FIFO assistance for digital playback, this is of course quite feasible to do, and not that hard, but we haven't done it yet. Also, as LGB has said, at 50MHz, the cost of pushing a sample into the digital audio output lines, on every raster line if you so wish, is pretty cheap. That said, we will likely add at least some sort of digital audio FIFO.


append delete #4. LGB

Just a new thought here: I think, at least FIFO would be useful for one given purpose: using sole IRQ at the frequency of the playback rate is fine on a 50MHz CPU, right. However there is some problem if some would like to use DMA for whatever gfx trick for example (like fractional step to render "doom like corridor" or simply move memory areas etc) then DMA is "blocking" type on M65, so no CPU activity while DMA is working. Ergo, it's not possible to have playback during a DMA session as it blocks the execution of the CPU. However, if FIFO is "deep" enough, it can provide enough samples during a DMA transfer probably.


(Leave this as-is, it’s a trap!)

There is no need to “register”, just enter the same name + password of your choice every time.

Pro tip: Use markup to add links, quotes and more.

Your friendly neighbourhood moderators: Deft, gardners, MARCOM