Supersonic Speed Measurement With A Sound Card

You might think that if you have a need to measure the speed of a projectile that is too fast for your high-speed camera, you would have to invest in some significantly expensive equipment.

That was the problem facing [Nick Moore], and the solution he arrived at is extremely elegant in its simplicity. He’s arranged a pair of foil tapes in the path of the projectile, as it passes through them they break, and he measures the time between those breaks. The clever bit though lies not in the tapes, but in how he measures the timing. Instead of relying on a lab stuffed with equipment, he’s using his computer sound card. The outputs send a tone through each tape to the inputs, and using Audacity he can capture both tones and measure the time between the end of each one on left and right channels.

In the video below the break he demonstrates measuring the speed of a supersonic particle at 496.5 metres per second, which for such relatively simple equipment is rather an achievement. He could certainly improve his resolution by increasing the sampling frequency, but we are guessing that the choice of 48 kHz owes much to the quality of his sound card. Still, to achieve this with such a relatively basic piece of equipment is a neat achievement.

Continue reading “Supersonic Speed Measurement With A Sound Card”

A Reproduction Vintage Sound Card

Before the AdLib sound card, sound on PCs was in a terrible shape. Since the dawn of IBM, all PCs included a speaker, but this PC speaker was only capable of sounding one note at a time. Chords on the PC speaker produced a weird ‘bubbling’ effect. Just a few years later, 8-bit sound could be created with the Covox Speech Thing, effectively a resistor ladder, with the parallel port on one side, and an 1/8″ plug on the other. These solutions for PC sound sucked.

It wasn’t until the first AdLib cards that superior sound showed up on the PC. Recently, [eric] had been fixing up an old IBM XT and quickly realized the original AdLib sound cards were collector’s items and far too expensive for what they were. He decided to build a reproduction Ad Lib. completely compatible and nearly identical to the original 1990 version of the best sound card on the market.

The first Ad Lib sound card is a relatively simple circuit based on the Yamaha YM3012 (OPL2) and YM3014B chips. These chips are frequently available on eBay, and [Sergey] already has a complete circuit for turning these chips into an ISA sound card. While this modern card is compatible with the AdLib Music Synthesizer Card, it doesn’t look like one. [eric] wanted a card that looked like the real thing, and sounded like one, too.

PCB design has come a long way in a generation, and where the AdLib card was once a wonder of modern technology, anyone with enough patience can now design an identical board, send the file off to China, and receive a reproduction of the first successful sound card. All the files are up on Github should you want to build your own. Now all we need is someone making modern 486 motherboards.

 

One Dollar USB Sound Card Turned O-Scope

Using the inputs on a computer’s sound card is an old trick to fake a very simplistic, AC coupled, slow oscilloscope. You can get DC operation by desoldering a couple capacitors, but if the sound card is integrated into the motherboard it raises the stakes if you mess that up.

[TMSZ] has a better option, a ~1 dollar USB sound card which is easily hacked to work as a simple oscilloscope. Easily found on eBay, the 7.1 virtual channel sound card is identical in brains to a more expensive c-media model, but the layout of the PCB makes it easier to bypass the DC blocking caps. Software and DLL files to use the sound card with Miniscope v4 — a Windows GUI for oscilloscopes — are also linked, so getting set up should be fairly simple.

Now of course this is not lab-grade measurement equipment: the sampling rate is limited to 44KHz and the voltages must be in the typical “line level” range, under two volts. If you don’t mind a little extra noise, you can increase the input impedance with a single resistor. This extends the input range up to six volts, which covers most hobby and microcontroller usage.

So if you’re really in need of a scope, but only have a buck to spend, this may be just the hack for you! Those willing to shell out a hefty sum for a high-end headless oscilloscope should look onto the virtual bench.

Sound Card Tachometer Rises From The Junkbox

We love writing up projects that re-use lots of old parts. In fact, we save the links and use them as defense when our significant other complains about the “junk” in the basement. No, that tactic hasn’t ever worked, but we’re going to keep trying. Case in point, [Wotboa] needed a non-contact tachometer. There are plenty of commercial products which do just that. After consulting his parts bin, [wotboa] realized he had everything he needed to hack out his own. An IR break beam sensor from an old printer was a perfect fit in an aluminum tube. With the outer shell removed, the emitter and detector were mounted in the nylon shell of an old PC power supply connector, effectively turning them pair into a reflective sensor. To amplify the circuit, [wotboa] used a simple 2n2222 transistor circuit. The key is to keep the voltage seen by the sound card the range of a line level signal. This was accomplished by adding a 2.2 Megohm resistor in line with the output. [wotboa] drew his schematic in eagle, and etched his own PCB for the project. Even the tachometer’s case came from the parts bin. An old wall wart power supply gave up its shell for the cause, though [wotboa] is saving the transformer for another project.

For sensing, [wotba] used [Christian Zeitnitz’s] Soundcard Oscilloscope software.  Measuring the RPM of the device under test is simply a matter of determining the frequency of the signal and multiplying by 60. A 400 Hz signal would correspond to a shaft turning at 24,000 RPM. The circuit performs well in the range of RPM [wotboa] needs, but using a sound card does have its limits. The signals on the scope look a bit distorted from the square waves one would expect. This is due to the AC coupled nature of sound cards. As the signal approaches DC, the waveform will become more distorted. One possible fix for this would be to remove the AC coupling capacitor on the sound card’s input. With the capacitor removed, an op amp buffer would be a good idea to prevent damage to the sound card.

[Via Instructables]

From Reference Design To USB Sound Card

[Entropia] decided to try his hand at rolling is own sound card. He picked out a DAC chip, started his prototyping by studying the reference design from the datasheet, then went through several iterations to arrive at this working model.

He chose to base the board around the PCM2706. It’s a digital to analog converter that has built-in USB support; perfect for his needs. It’s got a headphone amplifier, but is also capable of putting out S/PDIF signals for a digital amplifier to pick up and use. Not bad for a part that can be had for right around eight bucks.

The first PCB he designed had a few electrical and footprint errors. But he was able to get it to run by adding some point-to-point jumpers, and bending the legs of his capacitors to fit the board area. With those issued accounted for he ordered a second batch of boards. These went together nicely, but the headphone output was incredibly loud. Turns out the filtering circuit had the wrong resistor and capacitor values. Changing them around, and swapping the audio output so that the correct channels were patched to the audio jack brings it to the first release version seen above.

Program An Arduino Using Your Sound Card

audioino_programming_arduino_with_sound

[Chris] wrote us to share a neat technique he has been using to program the Arduinos he uses in his projects. He likes to build bare bones Arduino clones rather than sacrifice full dev boards, and instead of programming them via traditional means, he is using his computer’s sound card.

He builds a simple dead bug Arduino (which he calls an Audioino) using a handful of resistors, a pair of caps, an LED, a reset switch, and most importantly – an audio jack. After burning a special audio bootloader to the chip, he can connect the Arduino directly into his computer’s speaker port for programming.

Once the microcontroller is connected to his computer, he runs the IDE-generated hex file through a Java app he created, which converts the data into a WAV file. With the Arduino put into programming mode, he simply plays the WAV file with an audio player, and the code is uploaded.

He says that this method of programming comes in handy in certain cases where he builds things for friends, because they can easily update the software on their own without a lot of fuss.

Sound Card Microcontroller/PC Communication

The usual way send data from a microcontroller is either over RS-232 with MAX232 serial ICs, crystals, and a relatively ancient computer, or by bit-banging the USB protocol and worrying about driver issues. Not content with these solutions, [Scott] came up with sound card μC/PC communication that doesn’t require any extra components.

[Scott] bought a cheap USB sound card dongle on eBay (although a built-in sound card will do) and wired up the tip and ring of the plug to the microcontroller. The data is sent from the microcontroller a lot like Morse code – a short gap between pulses is a zero, a long gap is a one. This is parsed by a Python script using PyAudio. Synchronization, timing, and calibration is automatic because of a 10-bit ‘packet header’ explained in this video.

Continue reading “Sound Card Microcontroller/PC Communication”