Hi,
I'm working on a system that uses the Arduino Mega to trigger connections in other circuits, via an array of optocouplers. I was nearly about to buy the LEDs and perfboard and whatnot, but the more I thought about it, the more I became concerned that if multiple digital pins were HIGH at once, it would fry the Arduino or simply not work. So I'm here to get advice from people who actually know what they're doing (I am just an enthusiastic amateur who hasn't had any formal electronics education).
Here is a simplified version of the circuit; just imagine 10 to 50 resistor/optocoupler/LED assemblies running concurrently (with, say, 1 to 20 digital pins set to HIGH at any given time):
The sort of electronics I'm triggering connections in are circuit-bent instruments: old battery-powered toy keyboards and audio-producing things like that. For each connection, the transistor side of a given optocoupler will be hooked up to a set of terminals in the instrument; said terminals are originally only linked when a button is pushed, to produce a sound.
This circuit is meant to be used alongside SerialMIDI, so there's no MIDI jack involved in the circuit.
Note: I've tested this system, but without the LEDs, and with only one digital-out pin set HIGH at a time. Those are the concerns I have, which caused me to make this post: I've read that if you have many digital pins set to HIGH, and they're powering LEDs with any considerable operating current, then it will fry the Arduino. But I don't have the electronics knowledge to put this in context.
Well, I hope that made sense. I'd appreciate any help or opinions.