Electronic – arduino – How to dim 50 high-power LEDs in series with an Arduino

arduinodimmerdimmingled

What I'm trying to do is to use an Arduino to control the brightness of two series of 50 high-power LEDs independently.

Each series has an independent LED driver, and each LED has a foward voltage and current of 2V and 700mA respectively.

What I want to do is to be able to vary the brightness of each series from 0% (OFF) to 100% (full brightness) with 0.5% or 1% steps using my PC or my smartphone (with a BT module) and an Arduino.

I've searched on the internet about how to do this, and I found that maybe I could use an n-MOSFET to control the current provided by the LED Driver using an analog output of the Arduino (as far as I know controlling the current I can control the brightness which is the main point), but I saw that those MOSFET can get very hot (and I don't want this) and the current doesn't change linearly, so I'm afraid of not being able to precisely control the brightness. So now I'm completely lost on this problem, if someone could help me I would be extremely grateful.

OBS: I'm a complete noob in electronics and with Arduino, so if it's not asking too much, please explain exactly how I should build this circuit to get it to work.

Best Answer

An n-channel MOSFET is a great way to dim LEDs. Something like the IRFZ24N is likely what you'd want - it can handle way more amperage than you'll ever need, and pretty cheap.

The way you drive an LED with a MOSFET is to view the MOSFET as a switch - because it is! Current will flow between the Drain and Source, but only when the voltage between Gate and Source is high enough (Vgs). Because the switch is voltage-controlled, you'll want a pull-down resistor to make the switch OFF when the Arduino isn't driving it.

schematic

simulate this circuit – Schematic created using CircuitLab

The code you'll want to look up is the Arduino function analogWrite. This will let you pulse an output on and off for different amounts of time (pulse-width modulation is the key term here, or PWM). For your application, PWM will let you control brightness.

R2 is to limit the current to 500mA - just for example. If you post exactly what "LED Drivers" you're using, we could help you utilize them, but this is a valid solution for driving the LEDs without those drivers.

Your MOSFET isn't likely to get hot passing 300mA, or even the full 700mA. This is because a MOSFET has a really low "switch resistance" (RDS_ON), around 70mΩ in the IRFZ24N. 700mA through 70mΩ is only 0.03W, maybe 2 or 3 degrees hotter than ambient! If anything will get hot, it'll be the LEDs themselves and the resistor (300mA through 10Ω is 0.9W, hence the need for a beefy resistor!)

A switching LED driver prevents this resistor heat issue by converting the voltage to the right place instead of shedding it as additional heat. Yours might do that, so if you can let us know what those are we could avoid a lot of heat problems!

EDIT REVOKED: Didn't realize you wanted independent control.