LFO idea and schematic

Started by mth5044, June 29, 2013, 08:08:23 PM

Previous topic - Next topic

amptramp

Since you are using discrete devices, equal emitter resistors may be needed for all of the transistors to minimize the effect of slightly different junction temperatures.  Even current mirrors in op amps made on the same die with transistor temperatures within a degree of each other tend to use emitter resistors for accurate balance.  As shown, a very small difference in junction temp would cause a small variation in Vbe which would cause a large variation in current.

R.G.

Quote from: amptramp on July 03, 2013, 11:02:32 AM
Since you are using discrete devices, equal emitter resistors may be needed for all of the transistors to minimize the effect of slightly different junction temperatures.  Even current mirrors in op amps made on the same die with transistor temperatures within a degree of each other tend to use emitter resistors for accurate balance.  As shown, a very small difference in junction temp would cause a small variation in Vbe which would cause a large variation in current.
Yep. That's what I meant when I said:
QuoteFive NPNs make a one-in, four-out current mirror, and four PNPs on the top side make four independent current switches. You can linearize the NPNs with a 22 ohm or so resistor if you want to make them track well, but usually you get away with any five from the same batch being close enough.

Quote from: mth5044 on July 03, 2013, 02:25:23 AM
Feeding the noninverting side with 5.2V, when 0V is coming in from the LFO to the inverting side, we get 5.2V out. When we feed 4.5V into the inverting side we get 0.7V out, the turn on voltage for Vbe. That was a bit of a shot in the dark, but it seem to make sense? Not too big of a deal, what's two TL074's and five transistors anyway

How about the inverting buffers on the current mirror side, would they do their job?
That's kind of the idea on the buffer. I'll look at it a bit. You don't need the opamp buffers on the current mirror outputs, as these are already currents, and that's what LEDs understand.
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

mth5044

Check and check - 22ohm resistors on the emitters of all five transistors.

The 180 ohm current resistor is up'd to 220 ohms for the increased voltage coming in to keep the LED's happy.

As far as the buffer on each of the current mirror outputs, I was using them to invert the LFO, which I have no idea if it will work or not anymore since we have been talking about current.

This is truly a learning experience, thanks everyone.

jonasx26

#23
Hi!
Try this;



I'm 99% sure it'll work just fine. Resistor values around pots might need some tweaking though.
Put some kind of inverting op amp config between LFO and this circuit for inverted response.

EDIT: What the analog gurus said. Emitter resistors just might be a big deal after all.. Experiment!

pinkjimiphoton

wow,
good to know RG has solved the time travel dillemma, and can bring back examples from 21013!!
;)


Quote from: R.G. on June 30, 2013, 07:00:42 PM
Here's what I had in mind.



The input takes in a current, Iin, which may be driven by a voltage through a resistor to give Iin = (Vin-Vbe)/Rin. This isn't shown.

The four NPNs follow the input current. It's not perfect in this version of a current mirror, but probably good enough.

The PNPs switch LEDs on and off. They must be pulled to ground to turn an LED on, left open or pulled up to +9V to turn it off.
  • SUPPORTER
"When the power of love overcomes the love of power the world will know peace."
Slava Ukraini!
"try whacking the bejesus outta it and see if it works again"....
~Jack Darr

mth5044

jonasx26 - thanks for the schematic! Very helpful. Is there anything to gain in using pnp's for the current mirror? Also, what is the purpose of the npn transistor?


jonasx26

Quote from: mth5044 on July 04, 2013, 01:07:24 PM
jonasx26 - thanks for the schematic! Very helpful. Is there anything to gain in using pnp's for the current mirror? Also, what is the purpose of the npn transistor?

You can use whatever topology. Depends on what kind of response you need.
The current through Q1 controls the PNP current mirror. Adjust R12 for different mA/V ratio.

R.G.

Quote from: mth5044 on July 04, 2013, 01:07:24 PM
jonasx26 - thanks for the schematic! Very helpful. Is there anything to gain in using pnp's for the current mirror? Also, what is the purpose of the npn transistor?
The setup that jonas suggests is probably what I'd have done. I didn't want to toss too much into it.

The PNP current mirror works the same as the NPN one, just polarity swapped. Any current pulled out of the input is mirrored at the outputs. PNPs don't help or hurt directly, as they act the same way, but they are useful in this case for getting past the minimum voltage on the input, as you'll see in a bit.

The opamp and NPN operate together to pull a defined current through the NPN's collector, and that current is pulled from the PNP current mirror input. The NPN's emitter current flows in its emitter resistor, and that voltage is fed back to the input. The opamp tries to make the voltage across R12 be the same as the voltage on the (+) input, and the only way this can happen is if the collector current of the NPN is essentially the same. So a signal into the + side of the opamp is processed to force the current in the NPN emitter to match the (+) input, and this same current flows into the collector. Now you have your signal as a current, not a voltage, and you can "suck" that current out of the PNP current mirror.

The advantage of this more-complex setup is that now the current can go all the way to zero linearly, as long as the opamp's inputs can do the same.

It's also possible to simply use one NPN and one opamp per LED, and just drive all them from the same signal at the (+) inputs, but that's more circuitry.
R.G.

In response to the questions in the forum - PCB Layout for Musical Effects is available from The Book Patch. Search "PCB Layout" and it ought to appear.

mth5044

Gaddamn you guys are smart. I brought some trotter and you guys made it into charcuterie  :icon_lol:

Jonasx26 mentioned putting an inverting opamp before the current mirror to invert the phase, but is it possible to do this on each LED? Or have we changed the way the brightness is controlled to a point were what I'm saying is nonsense. I suppose it wouldn't be too bad to split the LFO and have one LED driver setup for normal and one for inverted.

jonasx26

Sure it's possible. But it'd get pretty complicated.
Only simple (and not very elegant) solution I can think of right now, several beers later.. Is to build two sets of my suggested circuit.
Put an inverting op amp between the LFO and one of them. Then switch the LED anodes between either current mirror..

But I'd try the suggested circuits first. Approach it one step at a time, "Divide and conquer".

mth5044

Very true! I've ordered some of the parts I was missing to build up your schematic. Can't wait to see four tiny little LED dudes doing their thing  :D I will report back when I get things sorted out. Cheers!

mth5044

This may sound crazy, but what if an npn current mirror like RG posted was used on the emitter side of Q1 in Jonas's schematic in conjunction with the PNP current mirror already there... it's kind of like this idea that puretube posted but with current mirrors:


mth5044

I finally got around to trying this out (moving, new job, etc was in the way). Took a while for me to figure out, but the LFO was actually causing problems. So I'm working on that, but it got me thinking back to some of the original comments about ditching the LED's and going with transistors. I came back to this when I was looking at the LFO of the echobase which uses and LFO to supply current to the base of a transistor which varies the resistance in the delay time. It hit me that the schematic that jonasx26 so kindly posted - the four BC856A's on the end controlling the LED's (Q7, 5, 2 and 3) - are doing exactly that. The collector and emitter of each transistor is acting as a variable resistor - wow. I feel like I knew that when we were going through this thread before, but it seems to make more sense at this point. Essentially you could feed an LFO or PWM or even a stable voltage to a transistor and control it as a current controlled resistor. The current mirror just makes controling more than one possible. Cool. You guys are smart. Now to get the LFO working.