Author Topic: MOSFET/uC current  (Read 2049 times)

0 Members and 1 Guest are viewing this topic.

Offline PerranOakTopic starter

  • Frequent Contributor
  • **
  • Posts: 581
  • Country: gb
MOSFET/uC current
« on: March 19, 2019, 02:42:17 pm »
I have a uC controlling a pMOSFET switch a power supply for the rest of the circuit.

The gate is pulled high by a 100k resistor and there is a 1k resistor between the MOSFET and the uC pin.

1. Do I need the 1k for current limiting - I saw it suggested but the current into the gate is minute?
2. Is the 100k over kill (I usually use 10k) though I want to limit current drain when the circuit is in sleep.

Thank you.
You can release yourself but the only way to go is down!
RJD
 

Offline ogden

  • Super Contributor
  • ***
  • Posts: 3731
  • Country: lv
Re: MOSFET/uC current
« Reply #1 on: March 19, 2019, 03:13:30 pm »
You don't need 1k for sure. 100k is optional as well. It is only for case when microcontroller is not (yet) initialized - during programming. You may use just bare MOSFET.
 

Offline PerranOakTopic starter

  • Frequent Contributor
  • **
  • Posts: 581
  • Country: gb
Re: MOSFET/uC current
« Reply #2 on: March 21, 2019, 01:51:10 pm »
Thank you, I'll ditch the 1k.

With the 100k, I need something to pull it high or when I reset/sleep the uC it doesn't turn it off the MOSFET. Is 100k too high though? It works as I look at it now but I wonder if it would be unstable.
You can release yourself but the only way to go is down!
RJD
 

Offline ogden

  • Super Contributor
  • ***
  • Posts: 3731
  • Country: lv
Re: MOSFET/uC current
« Reply #3 on: March 21, 2019, 02:14:51 pm »
Is 100k too high though?

No, its not. 100k is quite popular choice for MOSFET switch pull-up/down. Smaller resistance will lead to increased power draw while transistor is on.
 
The following users thanked this post: PerranOak

Offline exe

  • Supporter
  • ****
  • Posts: 3086
  • Country: nl
  • self-educated hobbyist
Re: MOSFET/uC current
« Reply #4 on: March 21, 2019, 02:16:34 pm »
1k could be to provide soft switching and reduce noise.
 

Offline madires

  • Super Contributor
  • ***
  • Posts: 9238
  • Country: de
  • A qualified hobbyist ;)
Re: MOSFET/uC current
« Reply #5 on: March 21, 2019, 02:44:19 pm »
There are two ways to drive the p-ch MOSFET. The first is to set the MCU's pin to output mode and switch it between low and high. The other one emulates an open collector. In this case the MCU's pin is set to output mode and low level (shorted to ground) or input mode (open). Let's assume you're going for the first method. The pull-up resistor is just for turning off the MOSFET when the MCU isn't ready. It will also limit the current passing through the MCU's pin when switched to low, i.e. limiting the power loss. On the other side you want it to be a not too high value to switch off the MOSFET fast enough. The MOSFET's gate requires a specific charge for switching. This brings us to the resistor protecting the MCU's pin. The MCU's pin has a limit for sourcing and sinking current. Without the resistor the MCU's pin would have to deal with a current limited just by the MCU's internal resistance of the output driver. For MOSFETs with a small gate charge it might work without the protection resistor. But for MOSFETs with a high gate charge you would exceed the pin's maximum current without the current limiting resistor. Again, there's a tradeoff between protecting the pin and the MOSFET's switching time. If the pin can't sink/source sufficient current but you want fast switching you have to add an external driver.
 
The following users thanked this post: PerranOak

Offline PerranOakTopic starter

  • Frequent Contributor
  • **
  • Posts: 581
  • Country: gb
Re: MOSFET/uC current
« Reply #6 on: March 22, 2019, 01:07:15 pm »
Thank you very much.

I shall use the 100k and the 1k.

Cheers.
You can release yourself but the only way to go is down!
RJD
 


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf

 

- - -
-->