How does iPhone headphone remote circuit work?

Discussion in 'iPhone Accessories' started by pcmofo, Dec 29, 2009.

  1. pcmofo macrumors member

    pcmofo

    Joined:
    Jan 11, 2008
    Location:
    New York
    #1
    I am trying to figure out how the magic "chip" inside the iPhone headphones works to control play/pause/volume.

    This Pinout shows the L/R/Gnd stereo connections + microphone connection of the 4 conductor iPod headphone jack. It also says that shorting out the mic to the ground is what the button does.

    It is impossible to find a diagram or any info on how the new 3GS remote with volume control works because most search results show only headphone reviews or products to buy.

    There is no power running to the remote so there can be no real circuit. This means they are most likely shorting out the mic with different resistors to create the additional 2 (vol +-) signals into the iPone.

    I would like to make my own iPhone remote so that I can make a larger one for use while skiing and operate it with gloves on and will require no batteries.

    If anyone has any idea how the remote works that would be a huge help. I will have to grab the multi meter and start testing things I guess.
     
  2. gunzmaiet macrumors regular

    Joined:
    Nov 18, 2009
    #2
    u could ask apple for how the remote works but i doubt that they'll tell u
     
  3. JellyUK macrumors newbie

    Joined:
    Jun 25, 2008
    #3
    Do let us know if you find anything :) I'd be really interested for a similar application. Making a breakout box with outputs for headphones and a separate remote would be cool.
     
  4. pcmofo thread starter macrumors member

    pcmofo

    Joined:
    Jan 11, 2008
    Location:
    New York
    #4
    OK so I took a look with the multimeter. According to the pinout I linked to, pin 4 is microphone + and pin 3 is Ground. When you press the play/pause/skip/back button on the remote it simply shorts these two pins together. Obviously this must be done before the microphone. I detected a 1.8-2.0 ohm resistance when pressing the button. This may just be the resistance in the line or it could be a very small resistor to prevent damage from shorting out the wires.... not sure yet... either way it would be super easy to recreate this effect by just adding a button connecting pins 3 and 4.

    I have a Giro headphone cord that came with my helmet that connects to a cellphone. I can rewire it to provide the iPhone functionality but this still does not solve the more difficult problem of how the + - volume buttons work...

    On the official headphones the mic/buttons are on the Right earphone line. This means it is very likely that the buttons only interact with the mic+ and ground (pins 3, 4) in some way. We know that the center button shorts out the pins. the + - buttons must send some type of signal. As I said before the "circuit" is unpowered so it must be some type of resistor etc.

    I was unable to detect any resistance value by testing the pins and pressing the + - button as I was able to do with the center button. When I set my multimeter to the diode setting, I got back a voltage reading. I have no idea what this means as I have never used this feature of my multimeter before but when I pressed either + - button I got back a consistent voltage result.

    As soon as I talk to my electrical engineering friend to figure out what this means I will attempt to recreate everything on a bread board as a prototype/proof of concept. If anyone has any idea or suggestion as to what this might be please let me know.
     
  5. ordan77 macrumors member

    Joined:
    Jun 11, 2009
    #5
    Interesting. I don't have the kit here to verify what I'm thinking, but it sounds quite simple... Option 1:
    • Center Button - simple ballast resistance
    • + Button - single Forward Biased Diode
    • - Button - Forward Biased Diode in combination w/ ballast resistance

    This is a simple design, which would require only three buttons, one passive and one semiconductor - all extremely cheap.

    To detect the difference, the phone would look regularly (25 times / second or so) at the resistance and voltage drop between pins 3 and 4. If the center button is pressed, resistance will increase, but there will be negligable voltage drop. If the + button is pressed, there will be a negligable change in resistance, but the applied voltage (from the handset) will drop by a detectable amount. Finally, if the - button is pressed, both resistance and voltage drop would change.

    Option 2 would be to use a slightly different combination:
    • Center Button - simple ballast resistance
    • + Button - Reverse Biased Zener Diode breakdown at say 0.15V
    • - Button - Reverse Biased Zener Diode breakdown at say 0.35V

    In this, slightly more complex scenario, the handset would (again, regularly) send a stepped waveform accross pins 3 & 4, 0.05V, 0.15V and 0.35V. The breakdown voltages may vary - these are just examples to aid the explanation below.

    If the center button were presed, the handset would detect a signal at the 0.05V step, through the ballast resistor. If the + button were pressed, the signal would be detected at the 0.15V step through the first Zener as it reached its breakdown voltage. Finally if the - button were pressed, the signal would be detected at the 0.35V step through the second Zener. No button pressed leaves the circuit 'high impedence' (not quite open circuit, as the microphone is still connected).

    Both of these scenarios would require that the system stop 'polling' for button presses when the microphone were in use, such as when using voice control, or when on a call - ar at the very least, significantly reduce the polling period. Any polling while the microphone was in use would cause distortion to the received audio.

    Of course, there are other possibilities, and Apple's engineers are smarter than me - but these are my thoughts based on your description so far.
     
  6. lemonademaker macrumors 6502a

    lemonademaker

    Joined:
    Jul 18, 2009
    Location:
    In a Van Down By The River! Metro Detroit!
    #6
  7. djrobsd macrumors 6502a

    Joined:
    May 2, 2008
    #7
    If you figure this out let me know!!

    I use the Bose on-ear headphones, and they have a mobile headset for it for $40 bucks, but it only has one button, to answer the calls on the iphone. I would like to have something like this and be able to use whatever headphones I want. The new apple ear buds that came with my 3GS iphone don't even stay in my ears!! WORTHLESS!!!!
     
  8. djrobsd macrumors 6502a

    Joined:
    May 2, 2008
    #8
  9. viggen61 macrumors 6502

    Joined:
    Jul 24, 2002
    Location:
    New Jersey
    #9
    Me too! Perfect for using in my car with the cassette adapter!

    The 3G does not support the volume control on the remote, while the 3GS does. I don't think the 3G has the right circuitry to make it work.

    :apple::apple:
     
  10. djrobsd macrumors 6502a

    Joined:
    May 2, 2008
    #10
    Not sure what you mean by this, I had a 3G Iphone that came with a headset that had the volume control on the headset. :)
     
  11. viggen61 macrumors 6502

    Joined:
    Jul 24, 2002
    Location:
    New Jersey
    #11
    According to Apple themselves, that shouldn't work!

    :apple::apple:
     
  12. viggen61 macrumors 6502

    Joined:
    Jul 24, 2002
    Location:
    New Jersey
    #12
    Actually, if you apply to their "Made for iPod" or "Works with iPhone" programs, and they let you in (for a fee, of course, and likely not a small one), they'll tell you. That's how all these other companies get the specs so their devices will work.

    A lot of pinouts used to be available on the pages at Apple's support site.

    :apple::apple:
     
  13. pcmofo thread starter macrumors member

    pcmofo

    Joined:
    Jan 11, 2008
    Location:
    New York
    #13
    Thanks for the detailed explanation. Like I said, I used the Diode setting on my multimeter and got back specific voltages so I am guessing that the second one is the way to go.

    I have a older Giro headset cable which has a 4 pin 2.5mm cellphone jack + a 3.5mm 3pin audio jack. The idea being that you can connect both your cellphone and your MP3 player at the same time. This also has a built in volume wheel.

    I have traced everything out but the Mic+/ground. Need to find a normal cell to plug in to test which is which. I picked up a 4 conductor inline remote similar to the iLuv one posted above but with a much longer cable and just one button and the mic. I am using the cable so that I can rewire the existing Giro headset to connect to my iPhone.

    I can then turn up the volume 100% on the phone and use the inline manual volume wheel to control the volume output manually.

    I tested the button. It definitely shorts out pin 3/4, through a small Capacitor.

    If this works then I wont need to recreate the iPhone + - button functionality. Hopefully trying this tonight.
     
  14. wisefire macrumors newbie

    Joined:
    Mar 1, 2010
    #14
    for posterity among other things, this volume button thing must be answered.

    i found a damaged iphone headset somewhere, and tried the short of the mic first. this works..

    i have a 3gs and the headset that comes with it, ive tried measuring it..
    it does indeed short out the mic when the middle button is pressed. but the 2 volume buttons dont.. also ive tried measuring both ways and there is no difference, so as far as i can tell there are no diodes in play..

    no resistance in play aswell, well, a lot of resistance but it isnt doing anything..

    im kind of out of ideas.. im hesitant to disassemble my headset, allthough i really dislike the in ear headphones..

    what is driving these volume buttons?

    i know it is a small condenser mic, so its getting some voltage, therefor a small chip could be driven by this voltage. if thats the case we can forget about fully diy headsets, and need the chip inside this headset to control volume..
     
  15. pcmofo thread starter macrumors member

    pcmofo

    Joined:
    Jan 11, 2008
    Location:
    New York
  16. wisefire macrumors newbie

    Joined:
    Mar 1, 2010
    #16
    thnx, it does explain things.. too bad though, would've loved to build my own.

    guess i'll leave out the volume buttons..
     
  17. Shenaniganz08 macrumors 6502

    Joined:
    Jan 26, 2010
    #17
    Damn do I love reading articles like that :):):)

    After reading it I was actually disappointed that there was no PayPal donate button ( we need to encourage more people like this ! )
     
  18. rgarjr macrumors 603

    rgarjr

    Joined:
    Apr 2, 2009
    Location:
    Southern Cal
    #18
    I'm wondering what fails when sweat gets into this control.
     
  19. Shenaniganz08 macrumors 6502

    Joined:
    Jan 26, 2010
    #19
    that's a no brainer

    sweat = short circuit
     
  20. dillon.mcinnes macrumors newbie

    Joined:
    Jul 30, 2010
    #20
    help

    so if i wanted to build a control button into my car, would i just need a button that shorts the microphone and ground? or are there some other components that are required?
     
  21. Infernex macrumors member

    Joined:
    Jul 6, 2010
    #21
    You have to read the article linked, but just having the single button should work by shorting those 2 lines (short control/mic line with the ground)

    To have volume control is more in depth, as you would need to replicate the voltage drops while also sending the identification 'chirp' (current chirp modulation) on startup to authenticate the remote.

    The author of that article has not been able to replicate this without applying external power, but for a car that should not be a problem. If you take the time and patience, you should be able to build an integrated circuit to replicate the remote. He posts a couple of schematics of the circuit at different points in his testing, and with a little tweaking it should work.
     
  22. LordG Guest

    #22
    Any of you dorks think about putting a 1M potentiometer in line with the headphones?

    You could even get one that has an SPST built in for an all-in-one solution.

    99 cents.

    2 minutes.
     
  23. DannyBres macrumors 65816

    DannyBres

    Joined:
    Oct 30, 2007
    Location:
    UK
    #23
    will this circuit work?!
    do i need a resistor (dashed lines) to imitate the microphone or not?!
    do i need a small resistor (not shown) inline with the switch aswell so that it is not a complete SC?

    Thanks

    [​IMG]
     
  24. leachboy macrumors newbie

    Joined:
    Jan 27, 2011
    #24
    I realize your post is a few weeks old, but I'm wondering if you've had any luck with this. I've been trying to wire up a play/pause button on a set of headphones, and I can't get it to work at all. I've tried the following things:

    shorting the mic connector directly to ground.

    connecting the mic connector to ground through a 2 ohm resistor (since the apple headset has a resistance of about 2 ohms when the button is pressed).

    trying both of the things listed above, but with a 1 megohm resistor simulating the mic (as in your diagram).

    I know my cable is not bad because I wired it between the iphone and the apple headset, and the button worked. Any ideas of what might be going on?
     
  25. leachboy macrumors newbie

    Joined:
    Jan 27, 2011
    #25
    I read the link above a little more closely, and now I know what is going on. The circuit that I built is not working because the iphone expects the power-on signalling that it's not getting.

    Not that it matters, but I also misread the circuit diagram above, thinking that the resistor was 800K ohm, which is why I subbed a 1M ohm for it.

    Anyway, my plan is to forgo the answer button on my customized headset, unless I can get my hands on a junked headset that I can scavange the parts from.
     

Share This Page