Error: LP0 On 🔥

You don’t need fancy ICs and DACs to build a sound card for a PC. As [serdef]’s build over on shows, all you really need is a bunch of resistors. [serdef] built a clone of a sound card released for PC in the 80s, but with a few improvements. This mess of resistors features the best 8-bit sound you can get with a low-pass filter, volume divider, and a handy DB-25 connector.

The design of this LPT0 sound card is pretty much the same as when it was introduced to the world as the Covox Speech Thing. This ‘sound card’ was designed to clip onto the parallel port of a computer and send the 8-bit I/O of this port through a resistor ladder. Plug a pair of speakers into this thing, and you have a sound card that is completely made out of resistors. It was cheap, and in the demoscene it was popular.

There are a lot of amazing demos out there using this resistor DAC thing, and [serdef] has videos of his project playing a lot of them. You can check that out below.

63 thoughts on “Error: LP0 On 🔥

  1. Very cool, and a creative solution indeed.

    Though I’ll bet with a few 555s, op-amps, and logic gates, you could do multi-channel FM synthesis just as cheaply. I’ve been working on a homebrew microcomputer, and if my FM synthesis sound card doesn’t work out, I will keep this solution in mind.

    1. Doing musical FM in the analog domain is *really* hard due to drift. You’re not going to get reliable synthesis out of a bunch of 555 oscillators. Plus, FMing square waves isn’t pleasant, but you could try using the triangle-ish waveform with a diff amp across the capacitor.

      It might be interesting anyway.

      If you meant you’re going to build a digital synthesizer from chips and just use the 555 as a clock, well, why not have something stable provide the clock?

      1. That’s why when you tweak it just right, you lay down the riff on a reel to reel tape and loop it, then use the rest of the day setting up the next one…

        Then when you’ve got your collection on shuffle you know you’re in for a treat of a banging 80s synthpop classic when it starts SSSSSSSSSSSSSSSS

    2. Yep FM essentially requires sine waves to work right. As in I’m not sure the math works right without it and using even a triangle wave would limit you to a small subset of the sounds available. It fits FPGAs pretty well though. I bet someone could cream a couple notes with into even an ICE40. I’ll have a better idea on resource usage once I’m done with my current class project. If you want a synth that uses square waves subtractive synth make work better, if you can build yourself some programmable band-cut filters to shape your sound.

      1. Well, depends on your definitions of “FM” and “work right”. Some Yamaha FM synths (TX81Z and DX11 for example) provide non-sinusoidal waveforms and can use them to produce musical sounds, math notwithstanding.

    3. I am really interested in homebrew computers so I clicked on your link hoping it might go to your web site Damn!!!

      I am also building a homebrew and I am going to use CPLD / FPGA for sound to give it new features like holophonics.

      Neva guna …

      1. They dont have to be .1% but they need to be all the same value as they are used as divider.

        With these arrays they come from the same production run, chances are they are all pretty close in value to each other. Their value howevrr can be 5% of the advertized value..

        1. I would not rely on this, if the project is of any importance. You can probably expect some tracking in temperature variations but not in the laser trimming of the resistors. And you need more than 4 matched resistors, so you would need to select (measure) them. Better buy the right stuff upfront.

        1. They used to be omnipresent. Look at an old sound card like a Gravis Ultrasound and you’ll see some familiar brown SIP packages. Now there seems to be just that one manufacturer left. Hence the $1 per, for a part that’s just a bunch of passives.

          1. Yes, and as far as I can tell they’re also all 2% so your probably better off using discreet passives anyway. At least then you can get down to 1% or even 0.1%

          2. doing a search for high precision resistor array results in a number of different suppliers and manufacturers going down to .025% precision! For instance Vishay and Caddock’s. There are more suppliers than digikey out there.

          3. @[ThisGuy]

            Paste some links please. I couldn’t find anything decent. I probably doesn’t matter too much for me (I am just curious) because I use CPLD/FPGA and single bit DtoA – saves on pins.

        2. Tolerance only paints a partial picture. An overlooked property is the tracking. Resistor networks are going to track extremely close compared to most discrete packages due to their shared mass alone, and are indeed available in tolerances 0.1% and lower. Temperature coefficients themselves are important, too. For this, you really need to know what your acceptable temperature range is, so you can figure out whether your error rates are acceptable for a given application. Also, you need to take into account relative tolerance. A resistor array could have a part-to-part tolerance of 0.1%, but a relative tolerance (precision between the in-network resistors) of +/-0.05%, which grants you that much more precision compared to, say, a few individual resistors rated at +/-0.1%. Suddenly the lowly resistor gets really complicated given some applications :)

          Side note, it looks like Digikey filters out some useful results if you select “R2R”.

          1. @haydn jones yes it is, we call them eggplants. A penis emoji does not exist, so 99 percent of the time you see the eggplant emoji it’s acting as a stand in for a penis. Brian is saying WordPress is dicked up. For any other questions you have about emojis please consult the nearest teenager.

        1. TIL you can emoji in URLs…
          Damned emojis… Back in my day, we called emoji’s “emoticons”, and they were made with the lower 7 bits of the ASCII character set… Plain text… None of this fancy 💩… Oh, and why is the danged shit pile so happy! It’s crap!

        1. But they can’t beat Z̨͕̣̤͕͎̋̀̐̐̍ͮ̓ͥ͊͗́͟a̠̳̠̜̓̊̄̇ͧ̆̐͘l̗̟̭͙̠̲̝͉̘̉ͦ̾ͫͮ̓͛͘͠g̷͕̯͕̳̽̇̽̑̉̍̿̎͑̆ͪ̂ͭ͛͜o̫̾̾̿͟͜͜͞.̶̡̹̼͔̝̼̫̣̻̉͆̿͌ͫͨ͆̾ͨ̽̄̒̒ͣͫ̚̕͜, Illuminati (◬) and the Uni-Konami-code: ▲▲▼▼◄►◄►ⓑⓐ.
          Obviously, there are unwanted characters, too: ☭ is one of those.

  2. I made one of these for a Raspberry Pi last year for my Operating Systems class. I should get around to recording a demo video and uploading my source code. I had a workflow problem that gave me bad sound files and in the process of trying to debug I test-benched my ridiculous breadboard R-2R ladder wrong and tore it up to replace with an Analog Devices thing. But the principle is the same and the code should work with any parallel DAC.

        1. From memory there was a version that had two 8-bit latches but that was to provide stereo rather than 16 bits/channel.

          The argument about the required accuracy (tolerance) if R2R resistors has come up a number of times.

          My claim has been that, not as much accuracy is needed as others claim because it’s ratio that is being created with two Parallel networks of resistors – one network to logic ‘1’ and one network to logic ‘0’.

          I did start a proof of concept in JavaScript so perhaps I should go and revisit that.

          1. If you don’t have resistors that match precisely enough to get you your lowest positive value you can’t guarantee where the values of your numbers will lie. If you just throw imprecise resistors together you could end up with a situation where say 128 produces a lower value than 127 pretty easily. I think if you sort the resistors by measured value (I don’t wanna do the algebra to figure out which direction) you can at least ensure the values keep the right order which is probably good enough for audio.

          2. Is that how the math works out? That sounds like you’re just counting the next resistor down. If you sum up the errors among all the bits in the same direction they build up pretty fast. Here’s a worst case with 5% error by my guess of how the math works:
            (1*0.95) < (0.5*1.05) + (0.25*1.05) + (0.125*1.05) + (0.0625*1.05) which means 5%s only work to 4 bits if they are lined up wrong.

          3. @[Steven Clark]

            No, I made a mistake. You actually need a tolerance of over 600% to create your scenario.

            Imagine a 2 bit DAC. What tolerance do you need for the voltage of 01 to be above the voltage of 10

            If that doesn’t make sense them imagine a 1 bit DAC. What tolerance do you need for 0 to be above 1

          1. How do you figure it would be a lot more complex?
            Just split up a 12 bit, send 8 bits to address 0x378 and the remaining 4 to 0x37A.
            Of course thou, you would have to create your own demo to use 12 bits instead of 8.

  3. Quote [Benchoff]: “and in the demoscene it was popular”

    That’s probably because you had to be a demo scene super coder to conger up the magic MIPS to drive this thing with assembly code.

    I wonder how it is being done in the above video’s. As far as I can remember, direct Port/IRQ access wasn’t available after Windows, XP or Win98.

    1. How it’s done? Running on MSDOS, those are DOS demos after all. Hook the timer interrupt, reprogram it to occur at the wanted sample rate and output a byte on the LPT port. Playing a sample is easy, mixing samples could be a bit harder.

      To use something like this in Windows one have to have a driver, I assume the Covox was supported.

    2. Support for either this or Disney’s Sound Source (a stereo version) was actually pretty common in DOS games. Wolfenstein 3d for example could send sound effects to one. Music probably took quite a bit more effort as RAM limitations would have limited the length of a sample that could be played, and FM synthesis would have required some serious sine calculation for an interrupt routine. Some games did have Speech thing music (Pinball Fantasies for example) but it was probably MOD based which would have required a completely different production pipeline from the FM music used by most DOS (and Sega Genesis) developers. I’m guessing almost only stuff by Amiga game houses had MOD music produced.

  4. I actually made one of these back in the day! It was my first time reading a schematic (of sorts), I think it was a text file I downloaded from some BBS along with the command line software to play sound files. Wasn’t really much more than a novelty, but still neat nonetheless!

  5. Way back when, I had a COVOX Sound Master II. It was a Speech Thing (their parallel DAC) combined with an Adlib clone and something else COVOX made- while deleting the two Atari 2600 DE-9 joystick ports the SoundMaster had.

    Using the LPT DAC meant LPT1 had to be moved to LPT2 because the resources on the Sound Master II couldn’t be changed. They did make Windows 3.1 drivers to make the card emulate an 8 bit Soundblaster.

    Would it be possible to use two LPT DACs on two ports and mix data to both of them to create a 16 bit mono or 8 bit stereo output? Join the analog outs and span the bytes across the two for 16 bit mono. The Disney version was A. Cheaper, and B. slightly more complex than the Speech Thing.

    The sound card I wanted in the 90’s was a Media Vision ProZonic. I don’t know if any were actually made but the advert I remember said it was SoundBlaster 8 and 16 bit, Pro Audio Spectrum 16, COVOX/Disney LPT DAC, Adlib and I forget what all else in a single card. One card and you had the best sound option for most any game for DOS and Windows. ISTR it must have been before 1992, I’ve never been able to find a thing about it on the web. The ads I saw were most likely in PC Magazine or Computer Shopper.

    I just googled Mediavision prozonic and turned up various sites claiming to have drivers, and a couple other people mentioning the card, so they must have shipped some – but who actually has one to get the lowdown on what, precisely, a ProZonic *is*?

  6. Here’s a mod player for the PC that supports parallel output…
    Mods still available all over, big directory on Aminet mirrors.

    There used to be a sound driver for Linux that supported them too, but not sure if it got left behind. Was module parsp.o and associated to mount point /dev/dsp so anything that output to that worked. Just what you needed with the ascii video4linux drivers so you could watch movies on a mono monitor. Think mplayer does it now.

  7. My friend made those by the boxful, he had a really nice design, and collected tons of mod files for playing. He hawked them at computer shows all over the northeast for a few bucks a pop. The good old days..

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s