The classic SP0256-AL2 speech chip has featured a few times on these pages, and if you’ve not seen the actual part before, you almost certainly have heard the resulting audio output. The latest Python library from prolific retrocomputing enthusiast [Nick Bild] brings the joy of the old chip to the Raspberry Pi platform, with an added extra trick; support for the venerable AY-3-8910 sound generator as well.
The SP0256-AL2 chip generates vaguely recognisable speech using the allophone system. Allophones are kind of like small chunks of speech audio which when reproduced sequentially, result in intelligible phonemes that form the basis of speech. The chip requires an external device to feed it the allophones at a regular rate, which is the job of his Gi-Pi library.
This speech synthesis technology is based on Linear-predictive coding, which is used to implement a human vocal tract model. This is the same coding method utilized by the first generation of GSM digital mobile phones, implementing a system known as Full-Rate. Both an LPC encoder and an LPC decoder are present on the handset. The LPC encoder takes audio in from the user, breaks it into the tiny constituent parts of speech, and then simply sends a code representing the audio block, but not the actual audio. Obviously there are a few more parameters sent as well to adjust the model at the receiving side. The actual decoding side is therefore not all that dissimilar to what the AY-3-8910 and related devices are doing, except you the user have to create the list of audio blocks up-front and feed the chip at the rate it demands.
Acorn BBC Master. Apple IIe. Ampex 270 Terminal. Vectrex game console. You’d be hard pressed to find a more diverse hardware collection in the average hacker’s lab. When you add seven Raspberry Pi’s, five CRT monitors, an analog oscilloscope and an LED wall to the mix, one starts to wonder at the menagerie of current and retro hardware. What kind of connoisseur would have such a miscellaneous collection? That’s when you spot smoke and fog machines sitting next to an RGB Laser.
Finally, you learn that all of this disparate paraphernalia is networked together. It is then that you realize that you’re not just dealing with a multi-talented hacker- you’re dealing with a meticulous maestro who’s spent lockdown finishing a project he started nearly twenty years ago!
The machine is called AUVERN and it’s the product of the creative mind of [Owen]. Taking advantage of advances in technology (and copious amounts of free time), [Owen] laboriously put his collection of older rigs to work.
A Python script uses a Kinect sensor’s input to control a Mac Mini running Digital Audio Workstation software. The operator’s location, poses and movements are used to alter the music, lights, and multimedia experience as a whole. MIDI, Ethernet, and serial communications tie the hardware together through Raspberry Pi’s, vintage MIDI interfaces, and more. Watch the video below the break for the technical explanation, but don’t miss the videos on [Owen]’s website for a mesmerizing demonstration of AUVERN in full swing.
Geeks of a certain vintage will have fond memories of games that were simplistic by today’s standards, but drew one in all the same. Their low fidelity graphics were often complimented by equally low fidelity music being forced through the afterthought of a speaker that inhabited most computers. Despite the technical constraints of the era, these games didn’t just offer gameplay. They told stories, and they were immersive in a way that some would think wouldn’t be relatable to a younger generation.
That didn’t stop [Thanassis Tsiodras] from sharing the classic “The Secret of Monkey Island” with his niece and nephew when they were young. Excited to see his family after a year of separation due to COVID-19, [Thanassis] wanted to give them a handmade gift: The music from “The Secret of Monkey Island” on a custom player. What an uncle!
[Thanassis] could have just recorded the music and played it back using any number of chips made for the purpose, but being a long time software engineer, he decided to take the scenic route to his destination. First, DOSBox was hacked to dump the speaker output into a file. Python, C, and 30 years of experience were leveraged to squeeze everything into the 8 KB storage of an ATtiny85. Doing so was no small feat, as it required that he create a custom implementation of Huffman compression to get the data small enough to fit on chip. And when it fit, but didn’t work, even more optimization was needed.
The end result was worth it however, with the music from “The Secret of Monkey Island” playing in its original form from a speaker driven by the ever so humble but useful 2n2222. [Thanassis]’ site is replete with details too intricate to post here, but too neat to miss. Watch the video below the break for a demonstration.
If you’re an automotive enthusiast of taste, you can’t stand the idea of fitting a janky aftermarket stereo into your nice, clean ride. Flashy, modern head units can spoil the look of a car’s interior, particularly if the car is a retro, classic, or vintage ride.
Thus, we’re going to look at how to modify your existing stock car stereo to accept an auxiliary cable input or even a Bluetooth module. This way, you can pump in the latest tunes from your smartphone without a fuss, while still maintaining an all-original look on the dash.
Depending on your choice of audio player, you may prefer a 3.5 mm aux jack, or you might want to go with Bluetooth audio if your smartphone no longer has a headphone port. Whichever way you go, the process of modifying the stereo is largely the same. To achieve your goal, you need to find a way of injecting the audio signal into the head unit’s amplifier stage, while making sure no other audio sources are getting sent there as well.
Whether that audio source is a 3.5 mm jack or a Bluetooth module doesn’t matter. The only difference is, in the latter case, you’ll want to buy a Bluetooth module and hardwire it in to the auxiliary input you create, while also splicing the module into the stereo’s power supply. In the case of a simple headphone jack input, you simply need to wire up an aux cord or 3.5 mm jack somewhere you can get to it, and call it done.
This guide won’t cover every stereo under the sun, of course. Edge cases exist and depending on the minute specifics of how your original car radio works, these exact methods may or may not work for you. However, this guide is intended to get you thinking conceptually about how such mods are done, so that you can investigate the hardware in front of you and make your own decisions about how to integrate an external audio input that suits your usage case. Continue reading “How To Modify Your Car Stereo For Bluetooth Or Aux-In”→
WART is a Python script that converts a WAV file into a C formatted byte array that can be baked into your microcontroller code, and for which playback is as simple as streaming it to the UART. The example uses a Teensy and a transistor to drive a small speaker, we’re guessing that better quality might come with using a dedicated low-pass filter rather than relying on the speaker itself, but at least audio doesn’t come any simpler.
The code can be found in a GitHub repository and there’s a few recordings of the output in the files section Hackaday.io page, one is embedded below. It’s better than we might have expected given that the quality won’t be the best at the PWM data rate of even the fastest UART. But even if you won’t be incorporating it into your music system any time soon we can see it being a useful addition for such things as small warning sounds. Meanwhile if persuading serially driven speakers to talk is of interest, there’s always the venerable PC speaker.
Raise your hand if you remember when PulseAudio was famous for breaking audio on Linux for everyone. For quite a few years, the standard answer for any audio problem on Linux was to uninstall PulseAudio, and just use ALSA. It’s probably the case that a number of distros switched to Pulse before it was quite ready. My experience was that after a couple years of fixing bugs, the experience got to be quite stable and useful. PulseAudio brought some really nice features to Linux, like moving sound streams between devices and dynamically resampling streams as needed.
Deciding to go for a full digital design for the circuitry, the peripheral is based off of a MEMS microphone and an STM32 microcontroller doing the heavy lifting between it and a USB connection. [Andy] notes that MEMS microphones are very delicate and you have to design the PCB around the hole where the sound enters, which is why he went with a breakout board which has the component already soldered onto it.
As for the MCU, he reasons that since this is a off-one project which won’t be produced in large numbers, the 180 MHz ARM core shouldn’t be seen as overkill, since it also gives him more than plenty of headroom to do signal processing to make the sound clearer before sending it through to a computer by the USB audio device descriptor.
Once the components are chosen and the board designed, [Andy] goes into detail explaining the firmware he wrote for the STM32 to translate the PCM samples from the microphone’s I²S interface into a format better suited for the computer. He also describes how it then processes the audio, applying a graphic equalizer to reduce noise and then ST’s own Smart Volume Control filter, which works more like a compressor than a simple amplitude multiplication.
Finally, all files for the project, including board gerbers and the STM32 firmware are available at the bottom of his post, and to boot, a video demonstrating the project which you can check here after the break. [Andy]’s choice of microcontroller for this project is no surprise to us, given he’s already made his own development board for the STM32 G0 series. But if this digital microphone project is a bit too modern for you, why not try your hand at building a ribbon microphone instead?