What resistor do I need?

The TIP120 Darlington transistor really needs an opto isolator to use it safely and it has other disadvantages such as high voltage drop on the load circuit.

I prefer using MOSFETs like the IRLB8721.

Here’s a good tutorial on controlling LED strips with an Arduino, but the same circuit can be used with a NodeMCU.

Note that if you’re using code written for the Arduino then you needs to change the PWM values from 0-255 to 0-1027 otherwise you’ll only get quarter brightness on your LED strip.

Remember also that Blynk requires a clean void loop.

Although I’ve previously designed a custom PCB using these MOSFETs I’ve now moved over to using off the shelf RGB controllers that have a built-in ESP8266 and flashing them with my own code, simply because it makes for a much smaller and neater package:

The code in this example could be used with the MOSFETs described above, if you change the GPIOs to reflect the ones you’re using.

Pete.

1 Like