0
\$\begingroup\$

This question already has an answer here:

I purchased a number of these relay module boards off AliExpress. They consist of the following

  1. 16x relays, 12 volt coils
  2. A LM2596 setup as a buck converter
  3. 2x ULN2803A darlington arrays
  4. 16x 817C photocouplers
  5. Header for inputs (current sinks)
  6. Terminal for DC voltage input

There are some LEDs on the board as well but they don't really have any function other than convenience of display.

When I purchased these, I had some ideas about how they work. However, what I discovered is there is a terminal (blue) labeled "VCC" and "GND". If you feed this with 12 volts, the 12 volts is used by the LM2596 to make 5 volts. The 5 volts is actually measured at 4.83 VDC, but that doesn't matter here. It drives the the "isolated" side of each 817C via some resistor. The 12 volt input is also carried to relay coil. So when one of the transistors in a ULN2803A pull a relay coil to ground, it closes the relay. Each 817C is normally high and if you sink current from the output pins it closes a relay.

The nominal "+5VDC" rail that is created by the buck converter is obviously not isolated. Measuring with a continuity tester confirms the ground of the entire board is common.

Do the photocouplers on this board actually accomplish anything when wired in this manner? I know they function as a logic inverter, allowing any current sink to actuate a relay. But that isn't really significant, for example a 2N3904 could do that.

enter image description here

enter image description here

enter image description here

\$\endgroup\$

marked as duplicate by The Photon, Nick Alexeev Apr 23 at 2:58

This question has been asked before and already has an answer. If those answers do not fully address your question, please ask a new question.

1
\$\begingroup\$

Based on the information you've provided and from what I was able to figure out by looking at the pictures I agree with you: I don't see too much value in using the 817 photocoupler either.

It seems like the input of this board is supposed to be driven by an open-collector or open-drain driver. I would have used a PNP transistor between the board input and the inputs of the ULN2803 instead of the photocoupler and save a few cents per part.

\$\endgroup\$
0
\$\begingroup\$

If you use an isolated 12VDC supply for the relays the optoisolators will help keep transients away from the circuit driving the LED side.

If you connect the grounds, they won't do much of value.

The transients I am referring to are coupled from the loads being switched to the coil. Relays do not provide perfect isolation, especially to fast-switching high voltage transients. Cheap crappy relays like those ones, probably worse than most.

\$\endgroup\$
  • \$\begingroup\$ so u mean the noise (at load side) will come from the coil of the relay back to your isolated system? \$\endgroup\$ – Hasan alattar Apr 19 at 4:33
  • \$\begingroup\$ @Hasanalattar Correct. It can disrupt an MCU if it doesn't have a well designed path. \$\endgroup\$ – Spehro Pefhany Apr 19 at 14:42

Not the answer you're looking for? Browse other questions tagged or ask your own question.