I bought a couple of 3W power leds on Ebay recently. These 3 watt power leds have a forward voltage of 3,4V and need 700mA current to shine at their maximum rating. A led is a semiconductor and needs current limiting to make it work. With small leds you just put a small resistor in series with the led to accomplish this. With power leds this is a bit more difficult since you would need a resistor with a high power rating because of the high currents these leds need. You would waste a lot of energy heating up the resistor.
I’m far from an expert in these things but I had a look what I could make with parts I had on hand. With a bit of googling I quickly found a solution to make the leds work with a minimum of parts. I still had to order some big resistors, I got me some 1,8Ohm 2W resistors. To further limit the current I used an LM317 regulator. To dim the led I used a n-channel mosfet, the IRF510. I connected the gate of the mosfet to an Arduino PWM pin so that I could control the brightness of the leds. The IRF510 is not an ideal mosfet to drive with an Arduino, it is not a logic level mosfet. It needs 10V at its gate to fully open. But in this case driving it with an Arduino PWM pin did the trick.
The LM317 regulator consumes quite a bit of heat driving the leds so its best that you put a heatsink on it. The leds came fitted to a small aluminium star but they need a bigger heatsink to use them as they get quite hot. I connected a 10K potentiometer to the Arduino and mapped the value of the pot to the PWM pin. So my Arduino is now a led dimmer 🙂