I want to control multiple LEDs at the same time using a microcontroller. The LEDs will all be enclosed in 3d printed blocks with contacts on the top and the bottom.There can be any number of LEDs connected at a time (limited only by either the power supply - 3A or the number of blocks that I can print before getting tired of printing them all). When stacked, the blocks can be orientated in different directions, meaning the polarity of the LEDs can be reversed from one block to another. A base plate will supply the power to the LEDs when they are stacked onto it.
If all LEDs were orientated in the same direction then I could just connect them to a MOSFET to supply power to them all from one control pin and they would be either lit or unlit. What I want to be able to do is reverse the polarity of the supply on the base plate so that when some blocks are reversed, it will be possible to alternate which LEDs are lit. A DPDT relay would be the easiest choice for reversing polarity at the possible current levels, but I am wanting to keep the base plate as thin as possible... thinner than any relay I've encountered in the past.
I am using a microcontroller so that I can have a mode selection to have the LEDs either constantly on, alternating the lit LEDs (by reversing polarity), fading (using PWM) or on a timer so that they stay on for a set period of time before turning off.
The 3d printed blocks will have limited space inside and will only be able to contain the LED and a current limiting resistor. All of the LEDs will have to be connected in parallel as there is an unknown number and limitless ways of stacking them.
Would the best way to implement this be to use an H-bridge? I have never thought of using one for anything other than motor control before, but at the moment that is the only way I can think of unless someone knows of thin (preferably DIP style packaging) SSRs which can handle the current.
Any suggestions would be greatly appreciated.
If all LEDs were orientated in the same direction then I could just connect them to a MOSFET to supply power to them all from one control pin and they would be either lit or unlit. What I want to be able to do is reverse the polarity of the supply on the base plate so that when some blocks are reversed, it will be possible to alternate which LEDs are lit. A DPDT relay would be the easiest choice for reversing polarity at the possible current levels, but I am wanting to keep the base plate as thin as possible... thinner than any relay I've encountered in the past.
I am using a microcontroller so that I can have a mode selection to have the LEDs either constantly on, alternating the lit LEDs (by reversing polarity), fading (using PWM) or on a timer so that they stay on for a set period of time before turning off.
The 3d printed blocks will have limited space inside and will only be able to contain the LED and a current limiting resistor. All of the LEDs will have to be connected in parallel as there is an unknown number and limitless ways of stacking them.
Would the best way to implement this be to use an H-bridge? I have never thought of using one for anything other than motor control before, but at the moment that is the only way I can think of unless someone knows of thin (preferably DIP style packaging) SSRs which can handle the current.
Any suggestions would be greatly appreciated.