Very confused about negative voltage

Thread Starter

aomahony

Joined Jan 23, 2020
11
Hey guys, sorry if this is in the wrong thread, but I'm confused about a circuit's behavior.

Here is the circuit, on Falstad.

http://tinyurl.com/ubkmuvu

I'm just setting a negative voltage reference by placing ground before the final resistor, so I get -2.5V at that point. I then pass it through a buffer to be able to use it with a load without it affecting my generator circuit.

What I'm so confused about is the current flow: I understand from my 5V source to the -2.5V output there will be current flow...but is that normal? Is that safe? I just am mocking an LCD contrast circuit with the potentiometer, but the current flow in the opposite direction is concerning. I tried a diode at the output of the buffer, but it seemed to then result at -2.5V on the anode and 2.5V on the Cathode, which makes no sense to me either.

Thanks,
Andrew
 

BobaMosfet

Joined Jul 1, 2009
1,207
Rebuilding your simulator, I get this:

1581524727034.png

and with the potentiometer in the other direction--
1581524831462.png

I think your simulation is faulty compared to mine. Your OpAmp can ONLY output positively because the positive input is a negative voltage (because of the way you created a ground loop.
 

Thread Starter

aomahony

Joined Jan 23, 2020
11
Thanks for the reply @BobaMosfet.

One difference is that I'm using a separate 5V source for the pot input...so it's essentially like I have 2 5V batteries. Could that make a difference in the overall design?
 

panic mode

Joined Oct 10, 2011
1,856
What I'm so confused about is the current flow: I understand from my 5V source to the -2.5V output there will be current flow...but is that normal? Is that safe?
yes, it is normal - if there is a path current will flow from higher potential to lower potential.
when potentiometer wiper is set to 0V, there is no current through 1k resistor.
when potentiometer wiper is set closer to OpAmp output, it's potential is negative and current will flow from GND, through 1k into wiper.
when potentiometer wiper is set closer to 5V source, it's potential is positive and current will flow from wiper, through 1k into GND.

since potentiometer wiper cannot reach voltage lower (more negative) than OpAmp output, there is ALWAYS current from potentiometer INTO OpAmp ouptut. Part of that current is coming from 5V source, part from GND through 1k resistor (of wiper is set above 0V). when wiper is below GND potential (0V), then some of current from 5V source is diverted through 1k resistor to GND, leaving less current from potentiometer to OpAmp output.

if you connect diode between pot and opamp output:

if diode is forward biased (anode at lower end of pot, cathode at opeam output), then lower end of pot will not be -2.5V but higher by Vf of the diode (usually about 0.7V).

if diode is reverse biased, there will be no current through lower side of pot, all current will flow from 5V source, through top portion of pot, through 1k to GND. depending on wiper setting, this current will be larger or smaller but always from 5V towards GND.

since voltage is fixed (5V - 0V at GND) = 5V
and resistance in this branch is sum of resistances of pot (0-1k) and resistor (1k), current range in this case will be
5V/(1k+0k) = 5mA
5V/(1k+1k) = 2.5mA

without diode, max current through pot is with wiper at 5V.
1k resistor will get 5mA
OpAmp output will get (5V-(-2.5V))/1k=7.5mA

is this safe? that depends on ratings of your components.

Ppot_max = Vpot_max*Ipot_max = 7.5V*7.5mA=56.25mW
Presistor_max=Vres_max*Ires_max = 5V * 5mA = 25mW
and Opamp output current of -7.5mA need to be something your OpAmp should handle.
 
Last edited:

BobaMosfet

Joined Jul 1, 2009
1,207
Thanks for the reply @BobaMosfet.

One difference is that I'm using a separate 5V source for the pot input...so it's essentially like I have 2 5V batteries. Could that make a difference in the overall design?
If you are using two power-supplies you MUST tie the grounds together. Otherwise, you don't know what your voltage levels are in the circuit (they aren't consistant. Remember 5V is only 5V to the other side of that same battery. Without a connection between grounds, the other battery could the thousands of volts in the negative or positive direction in relation to the other battery.
 

Thread Starter

aomahony

Joined Jan 23, 2020
11
Thanks so so much guys!!

@BobaMosfet...in the simulator, is simply wiring to a generic ground source the same thing? I understand in real life, but I figured that if I wired to ground as a schematic is drawn, it would be tied to any other ground?

My next question is...what exactly is the need for the negative value? Can't it all be done with a positive value? I do understand the concept that it is relative to a certain point and all. So like with an LCD, it wants a pot between 5 and -5 V or whatever...can't it just be between 10V and 0V? Same with serial comms? Instead of +5-10V for positive and -5-10V for negative or whatever, can't it just be 0-5 for negative and 5-10 for positive?

-Andrew
 

atferrari

Joined Jan 6, 2004
4,086
Thanks so so much guys!!

@BobaMosfet...in the simulator, is simply wiring to a generic ground source the same thing? I understand in real life, but I figured that if I wired to ground as a schematic is drawn, it would be tied to any other ground?

My next question is...what exactly is the need for the negative value? Can't it all be done with a positive value? I do understand the concept that it is relative to a certain point and all. So like with an LCD, it wants a pot between 5 and -5 V or whatever...can't it just be between 10V and 0V? Same with serial comms? Instead of +5-10V for positive and -5-10V for negative or whatever, can't it just be 0-5 for negative and 5-10 for positive?

-Andrew
What is a "generic ground source"?
 

Thread Starter

aomahony

Joined Jan 23, 2020
11
What is a "generic ground source"?
In a schematic, anytime you want to pull to ground, you draw it as the 3 bars. I took that as a reference to the unified ground point on the circuit (the - wire on the breadboard, for instance). So, in a simulator, the "generic" ground is just the one drawn to represent the - wire on the breadboard or the battery - terminal.
 

atferrari

Joined Jan 6, 2004
4,086
Unified ground point. What if you call it "common"?

To be understood and understand others you should use a language that everybody uses. Too late to start creating new terms.
 

BobaMosfet

Joined Jul 1, 2009
1,207
Thanks so so much guys!!

@BobaMosfet...in the simulator, is simply wiring to a generic ground source the same thing? I understand in real life, but I figured that if I wired to ground as a schematic is drawn, it would be tied to any other ground?

My next question is...what exactly is the need for the negative value? Can't it all be done with a positive value? I do understand the concept that it is relative to a certain point and all. So like with an LCD, it wants a pot between 5 and -5 V or whatever...can't it just be between 10V and 0V? Same with serial comms? Instead of +5-10V for positive and -5-10V for negative or whatever, can't it just be 0-5 for negative and 5-10 for positive?

-Andrew
The polarity determines which direction current flows- and that _is_ important. That's why negative .v. positive matters.
 

Thread Starter

aomahony

Joined Jan 23, 2020
11
The polarity determines which direction current flows- and that _is_ important. That's why negative .v. positive matters.
That makes sense...but when voltage is dropped over a pot for an LCD, does the direction of current also determine the contrast? Yes, yes, I realize I keep getting deeper here :D . Thanks a lot.
 

WBahn

Joined Mar 31, 2012
26,139
In a schematic, anytime you want to pull to ground, you draw it as the 3 bars. I took that as a reference to the unified ground point on the circuit (the - wire on the breadboard, for instance). So, in a simulator, the "generic" ground is just the one drawn to represent the - wire on the breadboard or the battery - terminal.
All voltages are actually voltage differences. So any time you say that the voltage at some point in the circuit is 15 V, what you are really saying is that the voltage on that node is 15 V higher than the voltage on some other node. But what node? It is understood that the node in question is the common reference node (often mistakenly called "ground"). Simulators are no different and they work with voltages on nodes relative to a common reference node. Any node in the circuit could be chosen and it has no relationship to any node in the physical world unless you make it that way. Regardless of which node we choose as the reference node, we have to have a way of communicating that information to the simulator. Most SPICE-based simulators (and probably most other simulators, too) require that one of the nodes be called '0' and that node is the common reference node that all other node voltages are referred to. When you put a "ground" symbol in a schematic, all you are doing is declaring that the node it is attached to is directly connected to the node called '0'.
 

Thread Starter

aomahony

Joined Jan 23, 2020
11
All voltages are actually voltage differences. So any time you say that the voltage at some point in the circuit is 15 V, what you are really saying is that the voltage on that node is 15 V higher than the voltage on some other node. But what node? It is understood that the node in question is the common reference node (often mistakenly called "ground"). Simulators are no different and they work with voltages on nodes relative to a common reference node. Any node in the circuit could be chosen and it has no relationship to any node in the physical world unless you make it that way. Regardless of which node we choose as the reference node, we have to have a way of communicating that information to the simulator. Most SPICE-based simulators (and probably most other simulators, too) require that one of the nodes be called '0' and that node is the common reference node that all other node voltages are referred to. When you put a "ground" symbol in a schematic, all you are doing is declaring that the node it is attached to is directly connected to the node called '0'.
Thanks! I actually am starting to wrap my head around the concept when it comes to circuitry.

For instance, if you have a comparator and you pass a negative value into one end and a positive value into another end, both of those values are RELATIVE to whatever the ground is for the comparator and the transistors inside? So a comparator is made up of a set of NPN's, and those NPN's common ground is the same common ground that the negative voltage is measured against (like, say, a battery terminal), so there is no way the negative one can activate, therefore the positive voltage wins the comparison?
 

WBahn

Joined Mar 31, 2012
26,139
Thanks! I actually am starting to wrap my head around the concept when it comes to circuitry.

For instance, if you have a comparator and you pass a negative value into one end and a positive value into another end, both of those values are RELATIVE to whatever the ground is for the comparator and the transistors inside? So a comparator is made up of a set of NPN's, and those NPN's common ground is the same common ground that the negative voltage is measured against (like, say, a battery terminal), so there is no way the negative one can activate, therefore the positive voltage wins the comparison?
Ideally a comparator compares its two input voltages to each other and nothing else. If V1 is applied to the non-inverting input and V2 is applied to the inverting input, then the output is dependent only on whether (V1-V2) is positive or negative.

If V1=-4V and V2=-5V, then (V1-V2)=1V and the output of the comparator is HI. If V1=-5V and V2=-4V, then (V1-V2)=-1V and the output of the comparator is LO. It doesn't matter what either input voltage is relative to the comparator's internal reference node (again, in an ideal world), only what they are relative to each other.

In the real world, most comparator circuits have limits on the maximum voltage difference between each signal and the comparator's power supply rails -- this is usually referred to as the input common mode range.
 
Top