FM synthesis is the sound of the 1980s, it’s the sound of shopping malls and Macintosh Plus. It’s the sound of the Motorola DynaTAC, busts of Helios, and the sound of vaporwave サ閲ユ. The chips most responsible for this sound is the OPL2 and OPL3, tiny little FM synthesizers on a chip, produced by Yamaha, and the core of the AdLib and Sound Blaster sound cards. It’s the chip behind the music in all those great DOS games.
Unfortunately, computers don’t have ISA slots anymore, and cards don’t work in 486 and Pentium-based laptops, the latest hotness for retrocomputing enthusiasts. For his Hackaday Prize entry, [serdef] is bringing the sound of the 80s to the parallel port with the OPL2LPT. It’s a sound card for the parallel port that isn’t just a resistor DAC like the Covox Speech Thing.
The design of the OPL2LPT is pretty much what you would expect; it’s an OPL2 chip, opamp, a 1/8″ jack, and a few passive components. The real trick here is in the driver; by default, every DOS game around expects an Adlib card on port 338h, whereas the parallel post is at 378h. A driver takes care of this in software, but it is possible to patch a game to change every write to an Adlib card to a write to a parallel port.
Already, [serdef]’s parallel port graphics card is a real, working product and has caught the attention of Lazy Game Reviews and the 8-Bit-Guy, you can check out those video reviews below.
“Already, [serdef]’s parallel port graphics card is a real”.. uh, parallel port Adlib card.
I assume different device than written up here?
“Already, [serdef]’s parallel port graphics card is a real, working product and has caught the attention of Lazy Game Reviews and the 8-Bit-Guy, you can check out those video reviews below.” and then the videos are of the ad-lib sound card.
and with a RaspBerryPi and DOSBOX, I can reliably emulate AdLib, SoundBlaster, Tandy, or any other sound card of the era.
Also, why mess with parallel ports? Sounds like a good way to fry it.
The 8bit guy video touches on that, but basically it boils down to the fact that a lot of older hardware doesn’t have another bus or port you can connect to. Like the laptop he uses, there’s no ISA slots to put in a real card. And even on some machines you just wouldn’t have enough slots to put in such a card anyway without losing significant functionality (say you only have two or three slots and need them for graphics, serial in/out, and a parallel port already)
PCMCIA.
This laptop could be so old that it doesn’t even have that.
Looks like a compaq elite 4/75. I have an aero 4/33 and it has pcmcia. https://thex86generation.wordpress.com/2016/10/17/compaq-lte-elite-475cx/
Authenticity. Accuracy.
Emulation rarely perfectly captures the original device. Most emulators take shortcuts to minimize hardware requirements at the cost of timing and sound quality. Usually it’s not noticeable. Sometimes it is. Sometimes games flat-out sound *awful*.
So this is an opportunity to use a real chip on real hardware.
OPL2/3 emulators are effectively perfect at this point. The chip does all of its work in the digital domain, and it’s been disassembled, ROM-decoded, and bit-compared against emulated output until every difference is gone.
But that doesn’t really matter here. The point of the OPL2LPT is to use it together with real period hardware, when adding an ISA card is impractical for whatever reason. You’re not gaining anything by plugging it into your 2018 machine (and where did you find a parallel port on a 2018 machine anyway?)
Many projects seem to be still using OPL2/3 emulators that predate nukeykt’s work.
And I don’t know whether the rhythm channels are 100% accurate yet.
Before we had cheap micros and USB everyone used the parallel port for hacking this and that.
My CNC mill *still* runs off a parallel port. And while not modern, the mainboard (Intel D525MW) isn’t *that* ancient.
How would you connect it? Not via USB on vintage systems, Not via MIDI as that’s mostly only applicable to multi-chip devices that have instruments (think MT-32/GUS/SC) instead of single-chip devices with operators. PCMCIA wasn’t all that common on low end systems in my experience, and to use it you’d need to build a very compact and complicated adapter board to a port that’s a lot harder to get than DB-25. And these chips are available all over the place on eBay, already harvested or just some gigantic stockpile.
Sure, if you’re emulating, MUNT and VirtualMIDISynth, with software FM will get you huge compatibility, but emulation isn’t the point here.
I play FM tunes live on real hardware because I happen to like messing around with DOS based industrial gear. Though I really like emulation sometimes you just want the chance to tinker with old hardware : )
If you can fix the LPT IO address thru bios settings, it should allow use without patches or tsr.
The OPL2LPT, CVX4, and other parallel port sound cards are a viable option for folks who are using retro laptops. They are also great additions to lowend x86 thin clients with DOS installed. Several Enterprise Rent-A-Car locations have been tossing their old thin clients into the local recycling centers. I got a dozen for a steal a few weeks ago. Any Via Eden or 600+ MHz Geode units have terrible sound support in DOS and Win9x. But every last one has a parallel port.
Wikipedia’s OPL3 article says “In 2015 an open-source RTL implementation of the OPL3 was written in SystemVerilog and adapted to an FPGA.” Here it is in GitHub: https://github.com/gtaylormb/opl3_fpga
Awesome, thanks.
Problem is this is an implementation with an ARM block already available on the chip. Pure VHDL or Verilog is probably possible on a big enough chip, but it would be massively more complex unless a Micro/Pico Blaze could run the control system.
README says the OPL3 is about 6K LUTs, 1 DSP block and 1 BRAM. With a modest MicroBlaze it’ll fit in most low-end 7-series FPGAs, like the Artix 35 that’s in Digilent’s Arty A7 (20K LUTs).
I’ve got a Basys 3 so I could run that! Given I’ve already gotten essentially real-time FM running in an interrupt routine of an STM32 I won’t be putting in the effort to port it myself though. I’ve got to build my MIDI state machine instead.
I haven’t actually set mine up yet, but the FleaFPGA Ohm has a core that includes a 80186 processor and OPL3 sound in a small amount of space. I think there’s only 12k LUTs or so on the fpga there.
Macs have not used FM synthesis. From the original Mac 128K, they’ve always played samples through a DAC. Some later Macs did have fancy DSPs.
I think they’re referring to an album, not an actual Macintosh plus. Good point though.
Err not album in fact, my mistake. A vaporware artist.
I was helping someone build a hot new gaming computer, and was surprised to see the motherboard had pins to attach a parallel port.
I wonder how hard it would be to get this project working with Windows 10?
Microsoft nerfed low-level access to the parallel port some version after XP
ISA ports?
I, uh, I have bad news also about parallel ports.
You can still buy PCIe parallel ports now. They’re accessed via funny high PCI addresses (e.g. 0xE010 instead of 0x378) but if you really wanted to hook up a legacy ISA-like peripheral you can.
And these aren’t meant for use on modern systems. Modern systems have more than enough power to do it in software or emulate a better PCM MIDI device. These are meant for laptops or thin clients from the Windows 3.11 era that don’t have enough card slots to fit a sound card.
i built one of these some time back, and they are awesome:
http://ucapps.de/midibox_fm.html
“FM synthesis is the sound of the 1980s, it’s the sound of shopping malls and Macintosh Plus. It’s the sound of the Motorola DynaTAC, busts of Helios, and the sound of vaporwave サ閲ユ.”
I’m not sure anyone understands what you’re talking about here :) Of course the Macintosh Plus didn’t support FM sound (at least it didn’t have an FM chip), so you’re probably referring to some obscure band which used the alias “Macintosh Plus” for one of their albums. How this then relates to DynaTAC is still a mystery to me, as this Motorola phone surely didn’t use FM either. Not even sure this “band” “Macintosh Plus” used FM in their recordings. And “busts of Helios”?? Well, as long as the writer enjoys it, I guess..
Well I dunno about that specific model of phone, but the later Yamaha FM synth chips did and up in phones, back when ‘polyphonic ringtones’ were a selling point. Little QFN chips with built-in LED- and vibration-related functions, and the documentation is online, or at least it was once.
They would have made nice little keyboards, if only the kids’s keyboard market hadn’t devolved into garbage for some reason…
“The real trick here is in the driver; by default, every DOS game around expects an Adlib card on port 338h, whereas the parallel post is at 378h. A driver takes care of this in software, but it is possible to patch a game to change every write to an Adlib card to a write to a parallel port.”
You’re missing an important possibility: You can print a history of your game session.