Chat freely about anything...

User avatar
By Harold Bradshaw
#92361 I'm completely new in hobby electronics, and I assembled the following circuit to control a power LED over wifi using esp8266. The problem is, that it is always, on and sometimes flicker , no matter,what I send via GPIO1 port. I know that this is not an esp8266 problem, I tested my program with a simple low power LED, without the NPN TIP41C transistor (datasheet). I'm sure, I do something wrong with connecting that transistor. What should i do?
Image
User avatar
By btidey
#92366 In principle you should not need a resistor to 0V if the GPIO1 is set to OUTPUT mode as then the voltage at that pin is either 3.3V or 0V.

The reason for maybe adding a resistor to 0V is to ensure the output is 0 if the mode might be set to INPUT or during start up before the mode is set.

The TIP41 transistor can accommodate a load of up to 6A but the leakage current when it is OFF (VB=0) can be relatively high (~0.7mA) this may be enough to turn the LED on although not bright. TO check this disconnect the base of the TIP41 from the GPIO and connect it direct to 0V. This then shows what the LED is doing when the transistor is 'off'.

If that proves to be the case then either use a different transistor with a current rating suitable for your LED but with lower leakage current or better still use a MOSFET which will have a much lower leakage ( 5uA).