[Steven] likes music. Like many of us, he uses Pandora to enjoy the familiar and to discover new music. Now, Pandora means well, but she gets it wrong sometimes. [Steven] has had a Mindwave Mobile EEG headset lying around for a while and decided to put it to good use. With the aid of a Raspberry Pi and a bluetooth module, he built a brainwave-controlled Pandora track advancing system.
The idea is to recognize that you dislike a song based on your brainwaves. The Mindwave gives data for many different brainwaves as well as approximating your attention and meditation levels. Since [Steven] isn’t well-versed in brainwavery, he used Bayesian estimation to generate two multivariate Gaussian models. One represents good music, and the other represents bad music. The resulting algorithm is about 70% accurate, so [Steven]’s Python script waits for four “bad music” estimations in a row before advancing the track.
[Steven] streams Pandora through pianobar and has a modified version of the control-pianobar script in his GitHub repo. His script will also alert you if the headset isn’t getting good skin contact, a variable that the Mindwave reports on a scale of 0 to 200.
Stick around for a demo of [Steven] controlling Pandora with his mind. If you don’t have an EEG headset, you can still control Pandora with a Pi, pianobar, and some nice clicky buttons.
Continue reading “Thumbs-Down Songs on Pandora with Your Mind”
[Ynze] has built an audio amplifier that looks and sounds great. His amplifier uses a National Instruments (now TI) LM3886 Overture series 68 Watt power amp. The LM3886 places [Ynze’s] amp squarely in the “Gainclone” catagory. Gainclone or Chipamp are terms long used by the DIY community to describe audio amps based upon highly integrated semiconductor amplifiers. The Gainclone name stems from the original Gaincard audio amplifier sold by 47 labs. The Gaincard used less than $100 USD of parts when it was introduced in 1999. It sounded good enough to command a $3300 USD price tag on the audiophile market. The low parts count and simple construction spawned the audio DIY community to build their own versions of the Gaincard. Hundreds of variants exist now, and wading through the different versions can be a bit of a daunting task. [Ynze] found a basic design that works, and built from there.
One of the interesting things about [Ynze’s] amp, as well as many of the Gainclones, is the fact that they use no circuit board. All wiring is done point to point. resistors are soldered directly to the pins of the amplifier chip. This can be some tricky soldering for beginners, but several PCB kits are available. [Ynze] built his amp in two cases. One case holds the power supply, and the other contains the amplifier itself. [Ynze] is using a large toroid transformer to drop his local 230V mains down to +25V and -25V. The amplifier circuit itself is simple – a few discrete components surround the LM3886 and it’s heat sink. [Ynze] also did some very nice carpentry work on his wood chassis. The resulting amp looks like it’s right out of the 1960’s – but hides 1990’s electronics inside.
Continue reading “Build a Simple Audio Amp”
[Noah Farrington] has just accomplished a major milestone in his life, purchasing his first car! A glorious 2001 Ford Focus wagon. While it may be a fully loaded luxury vehicle, it is missing one thing poor [Noah] can’t live without. An aux-in port.
He had a few options for rectifying the situation. Live with it as is, hack the strange Ford media protocol out of the back, or fool the CD player into playing his input. Naturally he chose the third option.
His first challenge was removing the deck from the car. People told him he’d have to buy fancy stereo removal tools — he made do with tent pegs and coat hangers. Using the same method as described in a past aux-in hack, he identified the audio in leads on the CD player’s ribbon cable. By carefully soldering in his own aux-in plug, he’s almost ready for business! Unfortunately, the CD player also needs to think that it is on for it to properly output the audio. [Noah] chose the simple solution — record a silent CD to always leave in the deck.
Stick around after the break to see it in action.
Continue reading “Un-crapifying a Car Stereo”
[Jason] just tipped us off about his recent experiment, in which he creates a sonar system using standard audio equipment and a custom Python program. In case some of our readers don’t already know it, Sonar is a technique that uses sound propagation to detect objects on or under the surface of the water. It is commonly used in submarines and boats for navigation. [Jason]’s project uses active sonar, which consists in sending short audio bursts (chirps) and listening for echoes. The longer it takes for the echo to return, the further the object is. Though his proof of concept is not used underwater, that may change if he continues the project.
The audio editing software Audacity was used to make a fast frequency changing chirp, along with PyAudio libraries for the main Python program. Exact time of arrival is detected by correlating the microphone output with the transmitted signal. Given that [Jason] uses audible frequencies, we think that the final result shown in the video embedded below is quite nice.
Continue reading “Sonar With Python and Conference Call Hardware”
Hearing aids are expensive little devices, typically costing a few thousand dollars each. They need to be highly integrated to fit in the ear, while still providing signal processing to ensure good audio quality.
This DIY hearing aid does some intelligent signal processing. It uses an electret to capture audio, then uses a pre-amplifier to increase the gain 100 times. The next stage consists of four filters, dividing the input signal by frequency into four parts. These are passed into four LTC6910 programmable gain amplifiers, which allow an Arduino to control the gain of each channel. The LTC6910 takes 3 digital inputs that are used to set the gain value.
To determine which gain to use for each frequency band, the Arduino needs to know how much power is in each band. This could be done using a Fast Fourier Transform, but that would require quite a bit of processing power. Instead, an envelope detector averages the signal, which can be read by an analog input on the Arduino. Using this information, the hearing aid can boost specific frequencies when it detects conversation.
This hearing aid won’t quite fit in your ear, but there is a lot of interesting signal processing going on. The schematic, Arduino source code, and a MATLAB simulation are provided.
This Bluetooth Audio Adapter is meant to connect a Bluetooth audio source (like a smartphone or tablet) to a speaker system with a plain old line-in connection. It has the ability to automatically connection when the Bluetooth device comes into range. Sounds convenient until [Andreas Pösch] points out that he still has to switch the speakers on and off manually. This hack automates the entire thing using a bit of additional hardware.
If you look closely you’ll see that the black cables have barrel jacks. This is a power pass-through rig that he whipped up. The protoboard includes a 7805 linear regulator which feeds power to the green circuit board in lieu of it’s original power adapter. A MOSFET switches outbound power headed for the speakers. All of it fits inside of the original enclosure, and he only had to add one port for the AC adapter.
This would be absolutely perfect for an antique radio retrofit. One of these adapters can be had for just over thirty bucks!
You know Halloween is coming around when the tweet reading skulls start popping up. [Marc] wanted to bring the Halloween spirit into his workplace, so he built “Yorick”. In case you’re worried, no humans were harmed (or farmed for parts) in the creation of this hack. Yorick started life as an anatomical skull model, the type one might find in a school biology lab. Yorick’s skull provided a perfect enclosure for not one but two brains.
A Raspberry Pi handles his higher brain function. The Pi uses the Twitter API to scan for tweets to @wedurick. Once a tweet is found, it is sent to Google’s translate server. A somewhat well-known method of performing text to speech with Google translate is the next step. The procedure is simple: sending “http://translate.google.com/translate_tts?tl=en&q=hackaday” will return an MP3 file of the audio. To get a British accent, simply change to google.co.uk.
The Pi pipes the audio to a speaker, and to the analog input pin of an Arduino, which handles Yorick’s lower brain functions. The Arduino polls the audio in a tight loop. An average of the last 3 samples is computed and mapped to a servo position. This results in an amazingly realistic and automatic mouth movement. We think this is the best part of the hack.
It wouldn’t’ be fair for [Marc] to keep the fruits of his labors to himself, so Yorick now has his own Livestream channel. Click past the break to hear Yorick’s opinion on the Hack A Day comments section! Have we mentioned that we love pandering?
Continue reading “Alas, Poor Yorick! I Tweeted Him”