Odd voltage with simple N-Channel MOSFET circuit - Page 1
Forum section: electronics / beginners

author: jewelie
author_rank: Regular Contributor
timestamp: April 25, 2016, 06:04:25 pm
content: Hi folksI started originally with a circuit designed by Scullcom Hobby Electronics (for reference, the original circuit uses a P-Channel Power MOSFET with a resistor+switch and RC on the gate to make a time-delay poweroff for a voltage reference IC - along with some Red/Green LEDs to indicate power status and when the voltage has dropped too low to trust.)In the interest of learning, I've fiddled with the values of the components to change the power-off timings and on/off voltage points of the indicator LEDs and have attempted to hack the circuit to use a much cheap N-Channel BS170/2N7000.See the attached picture for the current schematic. (Using a 2N7002 in the schematic as I don't have a model for BS270.)It almost works well, except for one little issue-The problem: Without a resistor across the output, when the circuit is supposed to be off, there's actually about 0.6V there according to LTSpice IV and in the real world I see it hovering up and down around 0.2V. I don't seem to be able to measure any current being pulled from the battery (<0.1microAmps?) when this is happening, but that could be just that I'm at the limits of my meters.Qs: What's happening?!?! Have I done something very silly? (Very probably.) Is this MOSFET not properly turning off? (It's important that it does turn off properly else it could just drain the battery, which somewhat defeats the purpose of the auto-off circuit.)I noticed that by default all loads on the output are non-linear (LEDs, transistors etc) and so wondered if it might need a linear load for the MOSFET to switch off properly, hence adding the output load resistor. Doing this it seems to work correctly but I'm just guessing and would like to know what's going on, and why, and how I should really properly do this circuit.Any thoughts and re-education with a clue-by-four much appreciated.Warm regardsJuliex

author: danadak
author_rank: Super Contributor
timestamp: April 25, 2016, 06:49:40 pm
content: Leakage path thru 2N7002 and Vzs developing across LEDs ?Or 2N7002 gate picking up AC line coupling and turning on due to hi Z gatewhen off ? Seems unlikely as thats ~ 560 ohms.Not sure, place a jumper on gate to source and measure.Regards, Dana.

author: jewelie
author_rank: Regular Contributor
timestamp: April 25, 2016, 09:54:36 pm
content: Thanks DanaYes, measuring Vgs helped, I had a few doh moments-Just because after 1 minute the Vgs from C1 drops below the Vgs threshold and turns the MOSFET off doesn't mean that voltage on the gate suddenly disappears entirely and so I imagine that the MOSFET is still very very slightly on for quite a long while as of course the RC circuit drops voltage logarithmically.LT Spice is an analog simulator and the switch in the circuit is very very slightly on when it's supposed to be off.When the MOSFET is very very nearly off, I presume that its Rds(off) is going to much higher than the impedance of the meters I'm using, which explains the odd voltages measured, as I guess I'm trying to measure a voltage across a nearly open circuit?It seems to use less than a tenth of a microamp when in it's off state; even for my poorly old 50mAh 8.4V NiMH that's at least 500,000hours/50years, i.e. far far longer than any battery is ever going to last without anything attached to it, so I really don't have to worry about that much current in the off state. (Also, I've noticed that the Zero Gate Voltage Ids leakage current appears to be smaller for this BS170 than the P-channel Power MOSFET used in the original circuit, which is good.)So I'm guessing it's probably okay with or without that 4K7ohm load resistor, but I suspect it's probably it's not a hugely bad idea to leave it in (or perhaps increase it nearer to a 10Kohm.) In particular, with one in, it means that when Rds(off) is a really high impedance there's still some load across the output which will then mean some load across be the input to the Vref IC - that seems sensible and safer rather than having it practically floating?RegardsJulie

author: danadak
author_rank: Super Contributor
timestamp: April 25, 2016, 11:04:29 pm
content: Just because after 1 minute the Vgs from C1 drops below the Vgs threshold and turns the MOSFET off doesn't mean that voltage on the gate suddenly disappears entirely and so I imagine that the MOSFET is still very very slightly on for quite a long while as of course the RC circuit drops voltage logarithmically.If my memory serves me there are no minority carrier lifetime issues in a MOSFET, so when Vgs = 0 it had betterbe off.LT Spice is an analog simulator and the switch in the circuit is very very slightly on when it's supposed to be off.Thats odd, I am familiar with LTC, that switch should be infinite ......When the MOSFET is very very nearly off, I presume that its Rds(off) is going to much higher than the impedance of the meters I'm using, which explains the odd voltages measured, as I guess I'm trying to measure a voltage across a nearly open circuit?It seems to use less than a tenth of a microamp when in it's off state; even for my poorly old 50mAh 8.4V NiMH that's at least 500,000hours/50years, i.e. far far longer than any battery is ever going to last without anything attached to it, so I really don't have to worry about that much current in the off state. (Also, I've noticed that the Zero Gate Voltage Ids leakage current appears to be smaller for this BS170 than the P-channel Power MOSFET used in the original circuit, which is good.)Just look at leakage spec to get a handle on off stateR, order of magnitude. Even thoughleakage is a current source effectivley, eg. insensitive to V (within normal circuit elementoperating range).Regards, Dana.

author: jewelie
author_rank: Regular Contributor
timestamp: April 25, 2016, 11:14:46 pm
content: Hi againQuote from: danadak on April 25, 2016, 11:04:29 pmUnless I'm missing something, Vgs isn't entirely 0 for an awfully long time due to C1 & R1... that's what I was forgetting before I posted this.I got myself into a tis until you suggested checking Vgs. When I measured it I realised that when the lights go out and there's no current flowing the load it's because Vgs has fallen below the threshold voltage (about 2.1V for this BS170) but it Vgs != 0 for ages (or theoretically, ever) because of the RC bit.Quote from: danadak on April 25, 2016, 11:04:29 pmThere's probably a way of setting it to infinite but I only knew how to set it to 1 followed by a lot of 0s.Quote from: danadak on April 25, 2016, 11:04:29 pmYes.Many thanks! :0xxx

author: danadak
author_rank: Super Contributor
timestamp: April 25, 2016, 11:54:49 pm
content: Re switch, not an LTC expert but use another MOSFET to function asswitch, if available an "ideal" MOSFET with Rdson = 0. Or use the V con-trolled switch.http://www.electro-tech-online.com/threads/ltspice-frustration-voltage-controlled-switch.118789/Regards, Dana.

author: amspire
author_rank: Super Contributor
timestamp: April 26, 2016, 12:24:30 am
content: It is pretty simple. Definitely the voltage you are seeing is caused by the mosfet leakage current. Without a resistor to ground, the output voltage of that circuit could be anywhere from near 0 to perhaps -1v depending on component variation. Above about -1v, the LED1-R will start to turn on.In the real world it is probably not -0.2V as the multimeter input resistance will be changing the voltage. If it is a 10M input multimeter, then that 0.2v is actually a measurement of the mosfet leakage current. Leakage = 0.2V/10M = 20nA 2N7002 leakage current. For measuring very low currents, multimeter voltage ranges can be used. With the voltage across the multimeter at -0.2V, I would guess that essentially all the 2N7002 leakage current is going through the multimeter as the current though the other parts will be negligible.For than circuit, you do not need a load resistor R7 as with the mosfet off, there is not enough current to turn on any of the LEDS visibly.

author: jewelie
author_rank: Regular Contributor
timestamp: April 26, 2016, 12:34:46 am
content: Thank you! That makes perfect sense.

author: danadak
author_rank: Super Contributor
timestamp: April 26, 2016, 11:03:27 am
content: Question for amspire, 10M spec on multimeter, thats a min value, andis that a leakage or sampling current for a S/H front end for the A/D ?If it is you cannot use 10M as a current sense value as it probably hasa strong T dependence, ie could be 100M or more...I am sure this is strongly architecture dependent as well, and franklyI do not know how the meters these days are doing their conversions,just assume its some form of a delsig approach.Your thoughts on this would be helpful.Regards, Dana.

author: amspire
author_rank: Super Contributor
timestamp: April 26, 2016, 11:24:00 am
content: First you have to find out what impedance you have, since there is no law that a multimeter has to have 10M input impedance. Go through the voltage ranges on the multimeter, and connect another multimeter across the input to check out the resistance. There is usually a fixed resistance input due to the way the input divider/autoranging/protection is done.Now in high end desktop DVMs, it is common for the low voltage ranges (often up to 20V) to have a super high input impedance - well into the gigohms. If you have a meter with a high impedance input, then it is not usable for current without an added shunt resistor.Back though to the standard multimeter, if the input measures 10M, 20M, etc, that will be a high stability resistance and the multimeter is measuring the voltage across that resistance. The multimeter A/D sampling circuit cannot add a significant extra current as it would mess up the voltage divider accuracy. Use Ohm's Law with the measured resistance and you will get an accurate current. You often want to add a capacitor across the leads - the impedance is so high, the noise signals that the probes may pick-up can overload the multimeter input circuit. A simple check for this is to switch to a higher range. If the measured voltage reading changes signifigantly, it was probably overloading the sensitive range.