multi RGB led with the same PMW output in arduino

hey,
i want to operate several RGB led and applay to each the same volatge (just in order to get more of the same light)
the ones i have are common anode so i need to connect the anode to 5 volt and each of the rgb legs to the PMW output of the arduino (via limiting resistors).
as i understand the PMW output will act as a current sink for the led.
I thought to connect several RGB leds and connect all the red legs to the same PMW out put. same thing with the green and blue.
by doing this the total current going into the PMW will multiply itself.
what do you think? is this a problem?
so you have other idea on how to do this?
thanks,
have a nice week,
Etay

is this a problem?

Yes.
Two things, you need a resistor between the red cathode and the arduino output on all red cathodes. The same goes for other colours.

The other thing is that 35mA is the maximum current you should switch with one pin. With each LED taking 20mA then it is too much for even two LEDs. You need to use an external transistor on each pin.

Right as Thought...
Thanks for the comment

etayl:
i want to operate several RGB led and applay to each the same volatge (just in order to get more of the same light)
the ones i have are common anode so i need to connect the anode to 5 volt and each of the rgb legs to the PMW output of the arduino (via limiting resistors).

Use some AN6884s (or KA2284s - same thing).

Each chip can switch 5 LEDs on/off with proper current regulation and no resistors or transistors needed. You can connect loads of them to a single Arduino output pin - switch hundreds/thousands of LEDs with one output. All you do is connect the Arduino output to Pin 7 on the chip ("AMP Output") and the LED cathodes to the five LED pins.

eg. For five RGB LEDs you'll need three of them. Connect all the red cathodes to one chip, all the green cathodes to another, all the blue cathodes to another.

But aren't these for making a bar display? That is a display where the number of bars or LEDs lit is proportional to the applied input voltage.

I don't see how that answers the OP's question.

Grumpy_Mike:
But aren't these for making a bar display? That is a display where the number of bars or LEDs lit is proportional to the applied input voltage.

ie. All the LEDs light up if the input voltage is high enough (eg. +5V).

They work great as a switch for multiple LEDs. You get constant current drive with zero external components, they're quite cheap, don't take up much space on a PCB and PWM works perfectly.

http://www.shenzhensum.com/products/datasheet/KA2284%20.pdf

The only real downside is you can't set the LED current, it's fixed at 15mA.

Grumpy_Mike:
I don't see how that answers the OP's question.

One Arduino output can control an awful lot of LEDs using those.

Get three NPN transistors, each of these controlled by an arduino pin capable of PWM.

Connect leds in series to the transistors so the voltage drop of each led matches the input voltage and run as many strings of leds as you wish.

There is a 5 RGB LED tutorial and breakout board described at LucidTronix. All the LEDs show the same color, which is what you were looking for right? They use 3 NPN transistors one on each color channel. Check the link below: lucidtronix.com - lucidtronix Resources and Information.