We want to play with our IPhone, use it for some work shop projects. There are two connectors to work with, I stared with the audio headset. The IPhone uses a 4 pin 3.5mm (2.5mm) plug connector for access to right and left audio and the microphone input. I started looking online for a plug and remembered that I tossed an old Slingbox into the scrounging bin recently, it had a Audio/Video cable which used a 4 pin plug, so I dug it up.
I made a solderless breadboard adaptor using one of the Slingbox cables and a prototype adaptor PCB I’ve been working on for an adaptor kit at Curious Inventor. This kind of problem is exactly what that prototype adaptor was made for. I have a bunch of connections that need to be kept together and adapted to the solderless breadboard.
The left and right audio outputs are shown on an oscilloscope in the picture here. The IPhone breadboard adaptor is plugged in next to an audio tip jack adaptor. I used this setup to test the audio outputs and the Microphone input.
Output from an IPhone signal generator application is shown on the scope. The application is called “Oscillator” but I cant find a good direct link to it. Let me know if you do. Its available in the IPhone App store. There are some other audio generators, scopes, and spectrum analyzer applications for the IPhone, some are very expensive. Let us know with a comment If you have used any of these.
With this adaptor setup we can do some audio interfacing projects. I think its nice to have it directly connected to a breadboard. Next is to get something working with the Arduino, with audio interfacing or with the docking connector.
More after the jump…
The PCB from my old Slingbox and the adaptor cable are shown above. In addition to the cable we can scrounge two 4-Pin jacks form the PCB. The other connectors might be useful too. From left to right, DC Power jack, mono tip jack, RJ45 jack, S-Video jack, 4-Pin Jack (score!), old TV RF module (almost useless today), another S-Video jack, another 4-Pin Jack (score again!), and finally a big button. The board also has two crystals, an oscillator, and a few power devices that can be reused.
A close-up of the 4-Pin tip jack and the adaptor end I put together. The two wires at the base of the adaptor (at top in picture) are strain reliefs. There are 5 available pins on the prototype bread board adaptor plus two that bring the power rails forward (labeled GND and VCC). I pinned them as Right Audio, Ground, Left Audio, Ground, then Microphone input. All the grounds are common.
Future project Plans
- Scrounge the useful connectors and parts from the Slingbox PCB.
- Make an adaptor which allows the use of an IPhone headset with with the PC/Laptop.
- Separate audio and microphone jacks
- Make an adaptor which lets me use a standard headset with my IPhone
- I don’t want to carry two headsets anymore… one for laptop and one for IPhone.
- Tackle the dock connector, there is a serial port there!
I would like to interface the IPhone with the Arduino. Has this been done? Using audio or the docking connector? I know some have done interfaces that use networking. The control signals are sent wirelessly. What about direct connections?
Audio Interfacing Ideas
- Use tones to send data. The Arduino would listen with an A/D and send using an I/O pin data back to the IPhone.
- Could implement a slow serial port using this approach. Maybe even a faster one using some tricks. I would be happy with 1200BPS but 9600BPS would be great. Use MODEM technology, FSK etc.. Start with two tone detection.
- At the very least, an Arduino or other microcontroller could receive and send basic signals using Audio.
- How about a X/Y scope driving display for the IPhone. Like the oscilloscope clock. I think this would be neat if not too useful.
- IPhone applications!
- The first that comes to mind is to use the IPhone as a display/interface for embedded projects. For example an Arduino could send data to the IPhone for display and receive button press information back. The key is to make the IPhone into an I/O expansion device, keep it simple and let the Arduino have control. It could even use the Wi-Fi and internet access via the IPhone.
- How about using the IPhone to drive a robot. A simple way would be to use two Frequency-to-Voltage convertors (done in software) on the left and right audio, left might control forward/backward movement with right controlling steering. Mount the IPhone so the camera can be used by an application to give input to the software.
- I remember seeing a robot using the IPhone, is that what they did?
- Maybe use OpenCV for some kind of navigation or follow thing, there has been a lot of these kinds of robot projects recently.
- Use Voltage to Frequency converters to get a slow dual channel D/A output and a slow DC input to the IPhone for recording projects. The idea is to get DC voltage output and measurement by converting tones to and from the IPhone.
If I can find all the parts I would like to make a breadboard adaptor for the IPhone audio to enable some neat hobbyist projects.