H Bridge

Thread Starter

bdrmachine

Joined Jan 26, 2010
23
I have a control panel design that includes switches that have a bi-color led embedded. The leds are 24volt and light red if power is applied one way and green if power is reversed. To cut down on part count and / or avoiding the use of a addition -24v supply I would like to control these with H-bridges. Does anyone know of a IC that contains multiple H-bridge circuits? It would be great if it was controlled via SPI or I2C bus and had 4 bridges.
 

Tonyr1084

Joined Sep 24, 2015
7,905
My lack of experience leads me to assume you're talking about a bi-color LED with just two leads. Current passing one way you get green and the other way you get red. That sounds a lot like what you are describing. The part that bothers me is the 24 volt thing.

Is the system meant to detect 24 volts as well as polarity?

You mention switches. It's likely that each has its own internal resistance, so I'm assuming it's already set for the 24 volts. To be better able to solve your issue we need to know more about the switches and how they are intended to work. A solution may be more simple than an H bridge for each switch. Just that without good information we can't give you a good solution.
 

AlbertHall

Joined Jun 4, 2014
12,347
I have a control panel design that includes switches that have a bi-color led embedded. The leds are 24volt and light red if power is applied one way and green if power is reversed. To cut down on part count and / or avoiding the use of a addition -24v supply I would like to control these with H-bridges. Does anyone know of a IC that contains multiple H-bridge circuits? It would be great if it was controlled via SPI or I2C bus and had 4 bridges.
Do you want the LEDs to be always lit, just changing colour or do you want to be able to turn them off individually?
 

Tonyr1084

Joined Sep 24, 2015
7,905
What kind of switches are these? SPST? SPDT? DPST? DPDT? OTHER? How are the lights wired into the switches? All that makes a difference in how we answer your question.
 

Thread Starter

bdrmachine

Joined Jan 26, 2010
23
The switches are momentary contact spst that are separate from the indicator leds. The leds only have 2 terminals. As with most indicators I have seen, they have internal current limiters to set the voltage at 24V. I would like them to be in 1 of three states, off, green or red. I have no problem designing them into the circuit but was hoping for a IC that would control all 4 switches (led portion) yet only take up 1 or 2 pins on my processor (I2c od SPI). I will have to check the data sheet but I would be shocked if the leds draw more than 20ma each.
 

MrChips

Joined Oct 2, 2009
30,824
You can create your own SPI-style interface using an 8-bit serial-in parallel-out shift register such as 74HC164 or 74HC595.
You will only need 2 pins from your MCU, CLK and SDATA to control 4 bi-colour LEDs.
 

dendad

Joined Feb 20, 2016
4,481
Another way is to run them on AC and turn on a transistor for the half cycle depending on the colour. Both will be yellowish.
Of course, running a TRIAC and opto TRIAC driver will work too. A half wave rectifies signal is sent to the processor to identify the cycle.
Here is a very rough circuit for a start. It may not be correct, by the way.

triac.jpg
One port pin for sync, and one port pin per LED string. Or use an I2C driver like an MCP23017 and that will give you 16.
 
Top