Continue to Site

Welcome to our site!

Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

  • Welcome to our site! Electro Tech is an online community (with over 170,000 members) who enjoy talking about and building electronic circuits, projects and gadgets. To participate you need to register. Registration is free. Click here to register now.

Need help with MOSFETs

Status
Not open for further replies.

jbmillard

Member
I am working on a microcontroller (this post is not microcontroller specific) project, part of what has me stuck is controlling a voltage divider to check the battery level. What I have done is this:

186-schematic.png


The gate of T2 goes to a microcontroller pin, which is either 0 or 3.3 volts. The battery voltage is read between R1 and R2. I use the voltage divider to make sure the voltage is not too high for the ADC on the microcontroller. The battery is a 9 volt battery. R2 and R3 are 10K and R1 is 100K. Both of the MOSFETs are "logic level". The p-channel is a FDV304P and the n-channel is a BSS138LT1.

The circuit works OK, but still has 10-15 microamps of current flowing when the gate of T2 is zero. Since I haven't used MOSFETs before, I don't know if this is good or not. Ideally, I'd like to do better since this part of the circuit is before the regulator (which can be shutdown) so it is always "on".

I don't need high accuracy here, it's just a battery indicator.

Thanks!

Brad
 
Since T1 has a VGS of -5 or more volts when it is turned on, why not use a PFet which has a higher gate threshold? Read the voltage at the drain of T2. That will tell you if the leakage is happening in T1 or T2.
 
Last edited:
****, I have practically the same ckt in my current project at work for the same reason. 16uA leakage? ****, that would double my quiescent current consumption. I have to go look at my mosfet that I spec'd. Ugh.

Thanks for posting this though. How are you measuring the leakage?
 
Since T1 has a VGS of -5 or more volts when it is turned on, why not use a PFet which has a higher gate threshold? Read the voltage at the drain of T2. That will tell you if the leakage is happening in T1 or T2.

I'm not sure I understand what you mean by using a PFET. For leakage, I'm measuring the voltage across R2 and am getting 3mV, so I may have missed a decimal place when I measured the leakage since that's only about .3 uA (I'm not sure how accurate my voltmeter is in the last digit on the lowest scale).

I am also measuring about 40 mV across R3 which is considerably higher which makes sense.

Brad
 
****, I have practically the same ckt in my current project at work for the same reason. 16uA leakage? ****, that would double my quiescent current consumption. I have to go look at my mosfet that I spec'd. Ugh.

Thanks for posting this though. How are you measuring the leakage?

See post above. I may have messed up when I measured the voltage before...
 
I'm not sure I understand what you mean by using a PFET. ...

I meant to use a PFET with a higher Vt than the one you are using now...
 
Unfortunately, it seems to me that most of the logic level stuff has a low threshold. I picked these transistors because they're supposed to work with three volts.

Do they make FETs with a relatively high threshold voltage and a low "on voltage"?

Yes, in fact the "logic level" ones are more speacialized. Only the Nfet needs to turn on with a Vgs of ~1.5V, and since its pullup is ~100k, who cares what its on resistance is... The PFet in your circuit gets 5+V, so it doesn't need to have a low Vgs, and as long as it has an on resistance that is small compared to 100K (<=1K), then it will not degrade the accuracy of the ADC reading. I would dump T2, and replace it with an NPN transistor. It has a Vbe "threshold" of only 0.65V, and low-leakage when it is off...
 
Yes, in fact the "logic level" ones are more speacialized. Only the Nfet needs to turn on with a Vgs of ~1.5V, and since its pullup is ~100k, who cares what its on resistance is... The PFet in your circuit gets 5+V, so it doesn't need to have a low Vgs, and as long as it has an on resistance that is small compared to 100K (<=1K), then it will not degrade the accuracy of the ADC reading. I would dump T2, and replace it with an NPN transistor. It has a Vbe "threshold" of only 0.65V, and low-leakage when it is off...

Good points. I'll give that a try. I just have to adjust the base collector resistor for the range of the battery voltage (about 9 to 4.5 volts).

Thanks!
 
Good points. I'll give that a try. I just have to adjust the base collector resistor for the range of the battery voltage (about 9 to 4.5 volts).

Thanks!

Here is a suggestion:


ps: you need to check the Spec for the input current to the ADC. The source impedance of your voltage divider may be too high. That could cause a large error in reading the battery voltage. A capacitor across the ADC input will lower the AC impedance, but you will have to program a delay between turning on the voltage divider and then reading the ADC...
 

Attachments

  • Draft54.png
    Draft54.png
    40.9 KB · Views: 197
Last edited:
Status
Not open for further replies.

Latest threads

New Articles From Microcontroller Tips

Back
Top