2
\$\begingroup\$

I am trying to make a LED strip light controlled by wemos D1 mini with N-MOSFET. I have a working circuit but the led strip is not completely turned off when the wemos pin is low and I do not fully understand why.

Should I try to increase the pull down resistor value from 10k or is the circuit wrong?

I use IRLML2502 (specs) which can switch on 3.3V. Is it a good choice?

Another question is, is this going to sustain working let's say for 10h/daily without heatsink and frying?

Circuit note - 3.3V is the wemos pin.

schematic

simulate this circuit – Schematic created using CircuitLab

EDIT

Readings on the voltmeter says:

  • ESP pin off state - 0.0V
  • R2 off state - 4.5V

I see where the power is coming from. I removed the R2 and all is working now. Why would R2 be needed there? M1 is charged off immediately anyway.

When the R2 is in the circuit

LEDs in mosfet off state are clearly visibly illuminated in lighted up room. All pictures are same camera settings - a bit underexposed. (From left - powered off, mosfet off, full brightness) LEDs in power off, mosfet off and full brightness

\$\endgroup\$
7
  • 2
    \$\begingroup\$ When the ESP is commanding "off" measure the voltage at the ESP pin, the voltage across R2, and the drain vs source of M1. How bright are the LEDs in this state? \$\endgroup\$ Sep 30, 2020 at 19:42
  • 1
    \$\begingroup\$ I've added in a redrawn schematic for you. Note that now signal flow is from left to right and current flows from top to bottom. This is the convention. You can edit and delete either version of the schematic as you see fit. \$\endgroup\$
    – Transistor
    Sep 30, 2020 at 19:51
  • \$\begingroup\$ @Transistor thank you for editing. I accepted your drawing. \$\endgroup\$
    – GTessa
    Sep 30, 2020 at 20:33
  • \$\begingroup\$ @ChrisStratton I will measure voltage tomorrow and will write it here. LEDs are about one third/fourth of the brightness. I will attach picture also. \$\endgroup\$
    – GTessa
    Sep 30, 2020 at 20:33
  • 1
    \$\begingroup\$ I think that in the real assembly, R2 is not connected to GND. It doesn't make sense that it works properly without a pull down resistor and not with a pull down. The schematics is correct. But does your physical wiring really match the schematics ? \$\endgroup\$
    – Blup1980
    Nov 25, 2021 at 13:38

3 Answers 3

0
\$\begingroup\$

It's the off state current of the mosfet 1uA. Put 10K resistor across the LED.

\$\endgroup\$
6
  • \$\begingroup\$ I doubt it. The OP says they are "one third/fourth" of the normal brightness. One microamp would give a faint glow you could only see in a darkened room. \$\endgroup\$ Sep 30, 2020 at 22:57
  • \$\begingroup\$ @Elliot Alderson He had the lights on in the room when the LEDs are on, and the room darkened when the LEDs are turned off. \$\endgroup\$
    – Moty
    Sep 30, 2020 at 23:31
  • \$\begingroup\$ Ah, I guess I lack your ability to read the mind of the OP. \$\endgroup\$ Sep 30, 2020 at 23:41
  • \$\begingroup\$ I'm even more impressed with your ability to read his mind, you know exactly what "one third/fourth" means. Look at the specs, at 70 c the current is 25uA, maybe he lives in Florida. \$\endgroup\$
    – Moty
    Oct 1, 2020 at 1:46
  • \$\begingroup\$ @Moty I attached pictures with how bright are LEDs. Anyway I think I solved it by removing R2 which seemed to allow 4.5V to flow to LEDs. \$\endgroup\$
    – GTessa
    Oct 1, 2020 at 7:50
0
\$\begingroup\$

I think what's happening is that the MOSFET is not completely turning off, working in weak inversion mode. You could try a stronger pull down - 1k instead of 10k. However, you would need to replace the 1 K with 100ohms to maintain the ratio. You could also try making this a high side driver.

I also notice you don't have a current set resistor for the LEDs, you may want to add one to improve the life span of the LED string.

\$\endgroup\$
1
  • \$\begingroup\$ @Hdc: The LED strings have current limiting resistors visible in the photos. \$\endgroup\$
    – JRE
    May 5, 2021 at 10:29
0
\$\begingroup\$

Your gate is being driven by the output of a voltage divider 1:10. That reduces the gate voltage to 3V if your WeMos is putting out 3V3. I would take a SWAG and say it is slightly less. At this point the MOSFET is not fully enhanced with your load (look at the Vgs curves). Move the 10K to where it should be, the port pin of the processor (WeMos) or what is driving it and ground. Removing the resistor has the same effect This schematic is in error but is published thousands of times on the WWW. The resistor is there to keep the MOSFET off during reset etc until it is initialized and has control of the outputs. Before this happens the MOSFET can turn on. Assume it is an "Air Bag" or any other load you do not want it to come on for any reason unless determined by the processor.

\$\endgroup\$
2
  • \$\begingroup\$ This schematic is in error The one without any resistor from control terminal to ground? \$\endgroup\$
    – greybeard
    Dec 15, 2022 at 4:11
  • \$\begingroup\$ ((voltage divider 1:10 I'd call it 11:10) Agreed on avoidable reduction of gate voltage. Then again, the data sheet shows a \$V_{DS}\$ difference of about .05 volts @ 25°C, \$I_D\$ 10 A.) \$\endgroup\$
    – greybeard
    Dec 15, 2022 at 4:33

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.