dwhinham / mt32-pi

🎹🎶 A baremetal kernel that turns your Raspberry Pi 3 or later into a Roland MT-32 emulator and SoundFont synthesizer based on Circle, Munt, and FluidSynth.
https://twitter.com/d0pefish
GNU General Public License v3.0
1.21k stars 75 forks source link

Feature Request: Add OPL3 hardware support (re: RetroWave OPL3) #130

Closed sofakng closed 3 years ago

sofakng commented 3 years ago

I've just discovered the RetroWave OPL3 Sound Card which is basically a real Yamaha YMF262 on a small PCB that connects to a Raspberry Pi.

Would it be possible to merge these projects and create a single card/addon that supports baremetal MT32 and OPL3?

dwhinham commented 3 years ago

Possible? Yes Likely? No

What exactly would be the benefits of going to the trouble of purchasing this board and then spending a lot of effort porting its software stack and integrating it into mt32-pi when its own software solutions would probably do a better job?

It has its own independent audio output so it's not like the user gains any convenience in terms of cabling, apart from maybe MIDI input, but MIDI can be daisy-chained easily; audio has to be mixed.

Additionally, mt32-pi is a MIDI synthesizer and OPL3 does not speak MIDI. We can't just switch on "support" for OPL3, there needs to be something translating MIDI to FM data, and that "something" needs to be usefully defined. On a real PC, this is often done with FM patch-sets provided by games, and the game's music driver has direct access to the chip to program its patch data.

mt32-pi is on the end of a MIDI connection, so there'd probably have to be instrument banks on the SD card, and then you would just be able to play General MIDI music. You would not be able to play VGM music or music that hits the OPL3 directly.

The board looks very nice, but it seems better suited for software that can directly access the OPL3, like the DOSBox/VGM player examples provided by the authors that run under Linux on the Pi. I'm not convinced by the usefulness of limiting it to General MIDI and supporting it here; for most people the whole point of mt32-pi is to get away from General MIDI on OPL3!

PS: Please use the issue templates in future.