Electron Pi

My notebook on Raspberry Pi and Arduino projects

More with a transistor and resistors

Did I say I was finished with one transistor plus some resistors? It turns out there’s at least one last thing to try – feedback! As ever, a schematic:

inv_amp_schem

So this is the inverter from a few posts ago, plus R3 and R4. Forget R4 for now – most of the graphs (how did you guess?) will be done without R4 (i.e. empty air where R4 is on the diagram). The idea of R3 is negative feedback. Simply: imagine R3 wasn’t there, and the DAC was at low voltage. The inverter would be “on” – i.e. there would be a high voltage at the ADC. Then put R3 in – this would mean that current could go through R3 to the base of the transistor, switching the transistor on, thus dropping the voltage at the transistor, and thus meaning that there’s less scope for current through R3. So R3 doesn’t switch the transistor on… wait a moment… what this means it that the system will reach an equilibrium whereby the transistor is on but not saturated, and lets some current through, but not too much. Then, varying the DAC voltage should gently alter this. OK, some graphs. I’ve used slightly different settings to try and make things a bit clearer:

inv_amp

OK, that’s complicated. You might recognise the navy blue line, “No R3”, which shows the behaviour of an inverter without R3. If we put in a 1k resistor at R3, we get the red line. 10k gives us green, 100k gives us dark violet. Interesting point: all four of these lines so far go through the same point, at about 1V on the DAC, 0.7 or so on the ADC. So, as expected, adding R3 has lowered the voltage at the ADC at low DAC voltages. The slope is more shallow. Also, without R3, it takes about 0.7V of DAC voltage to turn the transistor on – with R3, we seem to be past that already. At high DAC voltage, the circuit seems to give a higher ADC voltage than without R3 – maybe current is flowing along R3 the other way at those voltages.

Adding R4 to the circuit that gives the green line, gives the greenish-blue line. It’s like using R3 and R4 as a voltage divider, to get a bias point, or something like it. Finally, there’s the orange line, and the pale violet line, which come from adjusting R2. It’s interesting how the orange line is like the red line, shifted upwards.

Anyway, this circuit is starting to look like some of the amplifier circuits I saw when I was investigating electret microphones. If I recall right, there should be a resistor from the emitter to ground, and a capacitor where R2 is – also a capacitor from the emitter to ground maybe??? At any rate, I’m starting to understand what’s going on here – I’m also starting to understand why a friend of mine said that op-amps were the way forward.

So that’s negative feedback (i.e. what this blog post deserves – ed.) – what about positive feeback? I don’t think you can do that with a single transistor. But with two, yes, it should be pretty easy – just take the output from transistor A, use transistor B in an inverter, then feed that back to transistor A. Stay tuned.

Leave a comment