Optocoupler project

Thread Starter

djreiswig

Joined Aug 8, 2008
120
Short background without going into too much detail.
I have a homelink garage door module that I am going to extend the original buttons on and mount the buttons remotely. I have the buttons figured out, but there is a small status led mounted on the circuit board that helps with programming and also flashes when a button is pressed.
My new buttons have LEDs built in and I would like to have them work as the status led. I tried to hook another normal led in parallel with the existing one to test since my switches haven't arrived yet. I was able to get a yell or green led to light, but red ones wouldn't work. I'm guessing they take more current or something.
It has 3 buttons that I will be extending, so I thought it would be nice to have each button's led light only when it is being pressed rather than all of them lighting together. I think I can use 4 optocouplers to accomplish this. One would be triggered by the board led circuit and it would power the emitters of the other 3. The collectors would then be connected to the LEDs in the buttons.
The + side of the LEDs is internally switched inside the switch, so I was going to use the collectors to provide the ground for each led individually.
I found a video that pretty much shows what I am thinking.
He uses a quad optocoupler that he supplies the part number for, but mouser says it is obsolete.
I have some dual relay module boards from eBay that have single optocouplers built in. I could scavenge them, but I'm not sure if they are rated for 12vdc.
They say dp817c. Also, which resistors would I need to use? I assume the led on the homelink board probably already has a resistor in the circuit as well as the buttons since they are designed for 12v, so I think I would only need them on the emitters of the 3 optocouplers.
Otherwise, if someone knows of a replacement for the quad optocoupler in the video, it would probably be simpler to just order that.
Let me know if that isn't enough information. And thanks in advance for the help.
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
I guess I could probably use a single optocoupler and then 3 diodes to separate the LEDs so only the ones that are powered from the buttons would light. But will my scavenged optocoupler work?
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
Look up these, same item https://www.mouser.ca/datasheet/2/308/1/FOD814_D-1809419.pdf
The diode resistor value set to limit the current shown on on the sheet dependant on supply voltage used.
Same for output load,
Supply voltage is 12vdc automotive. I'm not sure what the LEDs are in the switches, but they are powered by 12vdc.
Also, the one in the video is a quad. The ones in the document are singles. I don't see a quad. Would need 4 separate ics.
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
Okay. I will rewatch the video and compare the data sheets to see what value I need for the resistors. Thanks for your help.
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
Does this look functional? The LEDs in the buttons are internally switched to 12v when the switch is pressed. I only have access to the ground side of them externally. I'm assuming the required resistor is also built in.
If I am correct, only the buttons that are pressed will show the led from the homelink unit.IMG_20230318_120805666.jpg
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
I did some more research, and it looks like the built in led is on sometimes when there are no buttons pressed, so I might just connect one of the LEDs directly to the board or through a single opto. Doesn't look like it'll work through all of the buttons LEDs.
 

Thread Starter

djreiswig

Joined Aug 8, 2008
120
Worked on this a little bit more. I found out if I remove the original led from the board and connect the emitter terminals in place of the LEDs, I can get the opto to work.(There must be a resistor built in to the board, because there wasn't one by the LED I removed.
Then if I connect 12v into the opto and connect an led to remaining emitter terminal through a resistor & to ground I am able get any color led to light. I also figured out that I need to parallel the LEDs and provide each with it's own resistor.
I'm still waiting for the buttons to arrive, so I'm just testing.
I assume the button LEDs already have some sort of resistor built into the button since they're connected to the switch internally. I will be unhooking this internal connection so I can use the switch as a dry contact for the remote. It doesn't appear to use 12v for the original homelink buttons.
So I should be able to hook the LEDs in the switches in parallel and connect them to the emitter.
The question is do I need to put a resistor between the emitter and ground? I've seen this arrangement in schematics, but my test circuit seems to work without it. Do I need this resistor and if so how do I determine what size to use? I don't really have any ratings on the LEDs.
 
Top