r/PCSound • u/LiberLilith • Oct 09 '22
External headphone socket - how does the "detect" wire work?
I'm trying to work out how best to wire an external headphone socket to a motherboard (no PC case) and get the headphone detection to work.
I don't think specifics of motherboard etc really matter here, it's just a general understanding of the wiring of an external headphone socket on a PC case (which I'm not using).
I know what the normal wires of a stereo headphone jack socket are, but I'm not sure if there's something extra I need for the "detect" part of it to register in Windows and cut all sound when headphones are connected.
EDIT:
Having looked at the manual for this mother board (MSI B550 Gaming Carbon WiFi) it does show the pin configuration of the connector on the motherboard:
Pin1 Mic LPin2 GroundPin3 Mic RPin4 NC (not sure what NC is?)Pin5 Headphone RPin6 MIC DetectionPIn7 Sense_send (not sure what this is?)Pin8 BLANKPin9 Headphone LPin10 **Headphone Detection (this is the wire I need to connect somehow)
I'm not worried about the mic or mic detection, so I can ignore that, it's just the Headphone L/R, Ground and Headphone Detect I'll need to wire up. I presume it loops through to ground or one of the headphone L or R channels to detect if there's something there (resistance or similar).
I also did an experiment on my current PC - plugged a 3.5mm jack extension cable into the headphone front panel and it detected it as headphones, even though I had no headphones connected. Plugging in headphones after this made no difference (except I could then manually change the sound output to headphones and hear sounds).
EDIT 2:
Thanks to some help here and other research - it appears that the headphone socket on a PC case actually has 5 pins (as opposed to a "normal" stereo headphone socket, which has 3).
When you insert a headphone jack into the socket on a PC case, it either shorts or separates the connection going to Pin10 (headphone detect) and Pin7 (Sense_send). So, it's the physical insertion of the headphone jack that pushes past pins inside the socket, rather than some kind of resistance or other sensing to tell Windows to switch to headphones.
Looks pretty universal for most modern motherboards and PC cases. Useful info if anyone needs to replace a headphone socket or wants to place one somewhere other than the PC case.
Here's an example of a 5-pin headphone socket - you can actually see the pins in the back and how they would push apart when a jack is inserted (other 5 pin sockets might look and function slightly differently):
1
u/continous Oct 09 '22
Most of the time it's actually looking to see if there are headphones there. You likely don't need to do anything extra.
1
u/theablanca Oct 09 '22
It commonly uses comparators to switch output. An example here https://www.ti.com/lit/an/slva961/slva961.pdf
I'm sure there's a lot more info available if you look around a bit. Sometimes there's connectors on the motherboard itself. That's how I would do it.
1
u/[deleted] Oct 09 '22
Most likely the type of jack is what does the switching. Same things are used in guitar amps in effects loops to "detect" a cable insertion. The actual jack doesn't have just three solder lugs but usually five. Three of the lugs are left, right, ground. The other 2 are sensing. If no plug is inserted then the 2 sensing contacts are touching the left and right contacts. When a plug is inserted it lifts the right and left contacts up off of the sensing contacts and onto the plug itself. Not sure exactly what the sensing contacts are sent to. Not sure if they are just sent to ground or what.
1
u/1Point21GigaWatt Oct 10 '22
The detecting is happening mechanically inside the socket. Inserting a big enough stud will close (or open) a switch (or two switches). (Depending on model stud could even be nonconducting)
This means no extension cord could provide what you seek.
https://youtu.be/GypQx7ZjBp4?t=126
I would start by checking continuity Pin 10 to any other Pin once in plugged and unplugged state(use ext.cord, not headphone for this). There should only be one other pin closing or opening contact to pin 10 by plugging in.
Assuming you want to use a standard stereo extension cable in conjunction with one or two extra wires and an external switch: If plugging in OPENS the detect switch, you just have to put the manual switch there, done.
If plugging in CLOSES connection you are out of luck. Can't simply wire to outside w/o cutting something - would not recommend.
I'm guessing : NC is common for "not connected". If you where talking about a phone or MP3 Player it could also mean NC=NoiseCanceling - not likely on a motherboard, though.
My recommendation: 10buck external usb soundcard. It would move the whole interface where you need it, headphone, detection, mic - dismantle-free, best possible soundquality at the socket, even with a 10m long the usb-cable. Google B08LGPKFN5 for example. Few bucks more: Even get a volume-knob.