I am assuming you have a Mega so see section 38 of the data sheet. There is a 200mA limit on the power pin.
In addition it says:-
Although each I/O port can source more than the test conditions (20mA at VCC = 5V, 10mA at VCC = 3V) under steady state conditions (non-transient), the following must be observed:
1)The sum of all IOH, for ports A0-A7, G2, C4-C7 should not exceed 100 mA.
2)The sum of all IOH, for ports C0-C3, G0-G1, D0-D7 should not exceed 100 mA. 3)The sum of all IOH, for ports G3-G5, B0-B7, E0-E7 should not exceed 100 mA. 4)The sum of all IOH, for ports F0-F7 should not exceed 100 mA. ATmega640/1280/2560:
1)The sum of all IOH, for ports J0-J7, G2, A0-A7 should not exceed 200 mA.
2)The sum of all IOH, for ports C0-C7, G0-G1, D0-D7, L0-L7 should not exceed 200 mA.
damn thats what i thought so, i had totally forgot about any current limitations besides the 40ma absolut max on every pin when i did all the programming.
its my first arduino and my first try at programming it, the arduino i bought hasnt yet arrived but i did started to write the code and i was checking it on the simulator.
the truth is that i did a lot of hard work trying to make this code work if you consider that i've never written code before so i cant just delete all this code i wrote and start coding from scratch considering that the new code is going to operate some other device like a shift register instead of a led because it is just too difficult for me at this point and i dont have a clue on how a shift register works...
in order to keep my code the same and not change anything on it, what i need is a device in each output pin of the microcontroller which will take all the current weight from the microcontroller.
im guessing i transistor acting as a switch that will connect each led at an external +5v supply whenever an output is set to HIGH will do just fine but then i will need 50 transistors and some resistors so it will be a mess....
so i have to ask.... : is there any magical chip with lots of inputs-outputs that is able to do exactly what i said without the need to change my code?
(a chip that when it takes the +5v signal of each microcontroller's output pin it will supply the proper led with the current that is needed without overloading the microcontroller)