I am referring to a typical audio jack (found on an PC) -the three part type with gnd, left and right on its tip. I am considering using only one channel (lets say left). What is a safe, cheap and minimal circuit? that will boost the voltage to 5v (when some frequency is played and stay at 0v (when silence is output) on the left channel. The question is easy when the circuit to consider isnt the minimal or cheapest. Typically an audio output is peak 0.14v at full volume . So -for this question-when some frequency is played the output is considered to be peak 0.14v . I think answer can be done (for less than 20 cents) with two npn transistors and some resistors and a single capacitor- thats a guess so I dont actually know the answer. The answer is to explain clearly how it works because Im new to electronics.
2 Answers
My preferred solution would be based on a line signal detector I designed decades ago: -
Q1 and Q2 form a precision half wave rectifier with output at Q2's emitter. Basically, as an audio signal of a few milli volts is applied, C2 rapidly charges up towards the supply rail (9 volts in this design). It can be made to run from 5 volts and then C2 will charge up to about 4 volts. You don't need Q3 for just a voltage detector.
When no signal is present, the capacitor (C2) voltage will be about 0.6 volts. The circuit can be desensitized by increasing the value of R3.
Be aware though, that if you are wanting any signal converting to a dc level the concept of "attack" and "decay" apply; in other words you can't instantly produce a DC voltage when a signal appears and you can't instantly reduce that dc voltage to zero when the signal dissapears.
Picture taken from here.
-
-
1C1 blocks any dc voltages coming from the input (your line output) from influencing the bias point on Q1. It only lets AC voltages pass. It "protects" the bias point of Q1 (fed via Q2). It also stops the DC bias voltage being fed to the input source voltage. In other words it stops DC both ways. – Andy aka Jan 06 '17 at 13:01
-
So at the same time C1 protects the line output (i.e. the circuit in the PC that creates the AC signal) too (as a capacitor is not polarised) from the DC current (the 9V) in your circuit and at the same time it allows the AC signal to pass. Is what you say is happening. I would imagine putting 9v into a headphone jack is not a good idea. – Pete Jan 06 '17 at 13:09
-
There won't be 9 volts - it'll be no more than about 1 volt and probably nearer to 0.7 volts. The base-emitter junction of Q1 is basically a diode that will clamp to less than 1 volt. So yes, C1 stops that voltage feeding the headphone jack. – Andy aka Jan 06 '17 at 13:22
-
There will still be some small leaked in the "diodes reverse direction" voltage (potentially unsafe for the PC) by the transistor because it doesnt act like a perfect dioide? So the C1 is necessary to make the circuit open there for the DC 9v. Also wouldnt your circuit still work if you replace the 100nf capacitor with a capacitor of the same order (another some nf capacitor).?-but it woudnt work with some pf capacitor – Pete Jan 06 '17 at 13:29
-
The diode is not reverse biased so no. 100 nF and 10k start to limit the circuit's sensitivity to frequencies lower than 159 Hz. At 15.9 Hz as an input, the sensitivity will be reduced by 10:1. If you used a 1nF capacitor, desensitization starts to occur at frequencies below 15.9 kHz. – Andy aka Jan 06 '17 at 13:37
-
-
I said 159 Hz not "159Khz". Cut-off frequency is \$\dfrac{1}{2\pi RC}\$ – Andy aka Jan 06 '17 at 13:50
-
Aren't you amplifying the half-wave rectified signal with this? My assumption would be that the asker needs the whole signal. – Scott Seidman Jan 06 '17 at 19:37
-
@ScottSeidman He wants a line signal detector from what I can tell and that's what I have named and described in my answer. – Andy aka Jan 06 '17 at 19:45
-
-
@Andyaka So it a low pass RC filter then. Which means for 159Hz it will detect that frequency that is input. But if you replaced it with a high value capacitor such as 470uf -would the LED still visibly be on or flash at very high frequencies then (say 20Khz or more)? Becuase the cut of frequency would be more than 20Khz – Pete Jan 07 '17 at 02:13
-
It's a high pass filter or dc block. Increasing capacitance lowers the frequency. – Andy aka Jan 07 '17 at 09:16
What you want is something called a amplifier. These can be made with discrete transistors, but considering the level you're at, and that this appears to be a one-off problem, just go buy one. A small "headphone" amp can probably put out 5 V.
Another cheap way to get such a amp is from a "powered PC speaker". Those plug into exactly the output you want to take the signal from, and boost it enough to drive a speaker. Open the unit and tap into the speaker connections.
For a little more do-it-yourself, get a off the shelf power amplifier chip. These take the signals you have and can drive small speakers directly. This is probably what's in the powered PC speaker. You'll have to supply the infrastructure around it, like the power supply, and possibly a heat sink. Many of these integrated power amps draw enough quiescent current to require a heat sink even when no input signal is present.
You could also use a opamp if you don't need a high power output signal. It wouldn't be able to drive a speaker directly, for example.
There are ways of doing all this with discrete transistors, but you're not at the level yet where a reasonable answer with such a solution is possible.

- 310,974
- 36
- 428
- 915
-
There woould be 10k resistors at base of transistor and where the 5v poswer supply is to limit the current from the 5v battery – Pete Jan 06 '17 at 12:40
-
1*"Can a capacitor pass AC and block DC at the same time?"* The fact that you're asking this confirms you're not ready (yet) for us to describe a transistor circuit to you. It's OK to be learning, but any answer with a transistor circuit will necessarily include information you can't understand yet. You're getting ahead of yourself. Start with more basic questions than how to build a whole audio amp. – Olin Lathrop Jan 06 '17 at 14:32
-
Yes it can. Its because each capacitor has a frequency associated with it. – Pete Jan 06 '17 at 14:42