Sox Can Hear, Sox Can Talk!

Sox can now hear! Using I2S microphones from Adafruit, Sox can now hear in stereo across I2S communication standard. I thought I2S would be similar to I2C, but it is not similar at all. Both are digital serial communications but that is where the similarities stop. I2S is very strongly defined, and consists of alternately reading 2 (or more if they are supported) audio channels, and streaming the data into the controlling device. The Raspberry Pi only supports 2 channels. This information is not found anywhere so I am repeating it, THERE ARE ONLY 2 I2S CHANNELS ON THE RASPBERRY PI. This took way to long to find out, eventually I asked on the Adafruit forums and they replied after they had to test it on a pi themselves. 


Now that I managed to get audio in working on the raspberry pi, Sox can now hear. The audio quality is terrible, and has a buzz in it, but I am thinking that is caused by the high frequency switching inside a breadboard. I am hoping it is cleared up when Sox goes on PCBs. 


After getting Sox to hear, I needed to get Sox to talk. I accomplished this by using another breakout board, this time for the PAM 8302 chip. This chip is a complete class D amplifier, making it very efficient at amplification. I took the audio from the raspberry pi audio jack and fed it into this amplifier, but I found it too quiet, so I had to find a booster circuit before it is fed into the amp. 

After hunting around for a few days for a 3.3V amplfier finding nothing, I proposed the question on the electronics stack exchange. Shortly afterwards, periblepsis answered with a working system and simulations to back it up. I built the circuit and it works! It even sometimes is too loud and creates a buzzing sound. 

Now that Sox can see, hear, talk, be touched, know which way is up, and has the ability to eventually walk, it is time to more permanantly connect these boards together using custom PCBs. I have already designed them and I am waiting tor them to be shipped. 

Comments

Log in to add a comment.