They need 350 mA. It's not clear if that is for all three LEDs or for each LED.
An Arduino pin is only capable of 40 mA maximum so you can't drive them directly.
You will need an NPN transistor for each channel. It's not clear if you want to have three channels (one per color) or 27 channels (one per LED). The UNO is capable of 6 channels of PWM and has another 12 pins or so for ON/OFF control so 27 separate channels won't be easily done.
The onboard voltage regulator is capable of about 1 Amp. That less than three LEDs. To run 9*3 you will need about 10 Amp power supply.
You might want to get constant-current regulators to control the current.
The UNO should control other circuits that will turn on/off the LEDs.
My suggestion is the same as johnwasser's: consider a FET or NPN to turn on/off the LEDs, let the UNO control the NPN or FET, which will be powered separately from the UNO (but with a common GND).
There is one caveat: you don't have enough ports to do all that. In that case, you should use a 74HC595 shift register, which will stand between the UNO and the transistors. In this case you only use 3 pins (plus 5V and GND) in the UNO to send data to the 74HC595, and you can chain up to 8 of these. They are pretty cheap, BTW.
I guess we'd need ot knwo how you plan on USING these to really offer the best solution?
each individual RGB controlled separately?..and each of the channels on each RGB to be controlled separately?
Or all REDS on/of/fade at same time? all blues fade/on/off at same time.. and same for greens?
probably NOT what you are going for (all reds act same, all greens act same..etc)
but here is a diagram I made a while back to visualize the wiring..
Your post/diagram was really helpful. As for my intentions, I'm looking to have 3 series of 3 rgb's. I plan to make a light with three sources, each with a cluster of 3 rgb's. I want rgb control of each cluster.
3 x set/groups, with 3 RGB LEDS in each group/set........correct?
For any given group of '3' RGB leds... you want all three (3) to be the same color?
so if you had a,
group of 3 on the left
group of 3 in the middle
group of 3 on the right...
and you want to change the 3 on the left.... you would be changing ALL 3 RGB's to the same color.. hence making the LEFT side a solid/single color...yes?
if yes.. your 'closer' (I believe).. but still wont have enough PWM pins..
For each RGB led (whether single or a group of RGB that are to act as one color).. you need 3 PWN pins...
1 for red
1 for blue
1 for green
without other IC's.. you wont be able to run more than 2-groups...
dont forget your current limiting resistors too!
being common Anode and RGB leds.. you will need 3 resistors for EACH RGB LED because each 'color' has a different vF (well red is usually lower vF..so you cant use 1 resistor value for all leds/colors)
I’ve used the following circuit recently on a high power LED project and it has worked quite well. Just be sure to calculate the power loss in the FET and add appropriate heat sinking to make sure you don’t burn it up.
In your case it seems that the Mega2560 would have enough PWM channels to do the job.