[ttsiodras] tells an epic tale of getting a custom Debian kernel installed on an Asus MemoPAD (ME103K) tablet. Skipping to the end of the saga, he discovers what looks like serial data coming out on the headphone jack when the system boots, but the signal was so distorted that he couldn’t simply interpret it. The solution turns out to be attaching a level-converter chip.
A level converter is a non-inverting amplifier, usually with a Schmitt trigger for immunity against noise. In this case, it acts like a “binarizer” — outputting a high voltage when the input rises above a threshold, and a low when it drops below. It’s the right part when you need to clean up a messy digital signal, and in this case works just fine because the capacitive distortion effects slow down both the leading and trailing edges of the signal, keeping the serial data’s timing intact.
That was the spoiler. If you want to read up on putting a custom Linux on an Android device, check out [ttsiodras]’s first post where he backs the machine up, and the second where he gets his custom kernel up and running. If you’re ever faced with an Android tablet that hasn’t been owned yet, or if you just have a DIY streak, this should help you get started.
Using the audio jack for serial is actually not uncommon, and discovering a serial terminal that listens at boot time is our favorite way to wedge a Linux OS into odd devices. So when you see a funny, distorted signal coming out at 115,200 baud, take a moment to clean its edges up and see what you’ve got.
Nice work, know I’ll want to do this at some point. … lightbulb just went off in my head about some devices I noticed had a “glitch” of static when powering up and you’ve already got the phones on.
In this case, the level converter is a bunch of FETs and resistors :
https://www.adafruit.com/product/757
I used the same method years ago to add an infrared transmitter to my phone (attiny13 and a few other components). worked surprisingly well ^^
Didn’t some Samsung TVs also employ serial via headphones-jack?
hey employ serial over a 3.5mm stereo serial jack. it’s not ever meant to use for audio it’s simply an abused 3.5mm headphone jack wired for rs232.
a lot of companies abuse jacks for the wrong uses.
Then again, we don’t really have a standard connector for 3V asynchronous serial…
just pick an FTDI, and it might just become a defacto standard, http://uk.farnell.com/productimages/standard/en_GB/1740361-40.jpg
There isn’t a “right” use for a 3.5mm jack, it’s just a connector, like DIN plugs, “RCA” phono plugs, D connectors, molexes, gotta be very sure of your context and application before you go just plugging something in like a n00b.
Inspired much by:
http://web.eecs.umich.edu/~prabal/projects/hijack/
?
not really, there’s no power harvesting going on and the audio jack in this application seems to have a purpose built serial interface.
isn’t serial on the audio jack a standard (requirement?) for android?
Actually serial over audio is common for things like portable Ham radios, they connect and send data via the audio plug for frequency data and the like. So one way to program one – you plug the audio into the sound card on a PC.
Jawbone UP activity tracker synchronizes with smartphone using 4-pole audio jack. It can be synced wih PC over USB for firmware updates using the same connector, which is also used for charging. Unfortunately mine isn’t, because flex PCB that connects button and LEDs to the rest of electronics simply broke, and I can’t solder some wires to bypass it, because it’s too small, and I don’t have microscope or even loupe…
http://hackaday.com/2014/11/04/using-a-headphone-jack-as-a-uart/