Electronic – OPAMP has voltage on its supply when it shouldn’t


I was trying to design a circuit after seeing this question. I know I used too much components than I should designing a circuit with this purpose. And sorry about the messiness of the schematic.

This circuit compares V1 and V2 and if V2>V1 than it outputs V2. If V1>V2, it outputs V1. I am going to combine U2 and U3's outputs later on. However I don't understand why this circuit behaves abnormally.

Even if the Q2's base shown to have about 20mV, Vbe of Q2 is negative, and V+ supply pin of U3 is 2.42V. Output of U1 is 8.39V and collector of Q3 is about 20mV. Output of U2 is 5V, where the output of U3 is 1.57V.

Why is this odd behavior?


Here is the LTspice file.

Best Answer

A couple of possibilities spring to mind:

One is that since the input is higher than V+, there is leakage through causing V+ to rise.
This looks quite possible since V+ appears to be about a diode drop from the input voltage (3V - 0.6V = 2.4V)
Most opamps don't like an input voltage higher than the supply.

The other thing to bear in mind is that the opamp model may not simulate accurately when used like this. Most are behavioural models rather than transistor models.
Some models do funny things when used in non obvious ways, so it may not be doing exactly what it would in real life. I think it looks reasonable though.
For interests sake, you could try putting a load on the output (and maybe a series resistor on the input) and see if it drops. Also you could change the input voltage to see if the V+ follows it (minus 0.6V)

A better solution to switching the opamp supply would be to do something like use an opamp with an enable input to switch on/off, or put an analogue switch before/after the opamps to cut the signal. A multiplexer like a 4052 would work okay (you can simulate it with the voltage controlled switch component if you can't find a model)

An analogue switch can be as simple as a PMOS:

PMOS Switch

This can't handle signals that swing negative though, for that you need something like this:


This configuration is used in most analogue switch ICs.

The 4052 (or 4053 could be used) suggested is basically just a few of these in one package, with some logic to switch between them.
For comparison, here is a diagram of one of the internal switches of a 4053:

4053 internal