1

I have looked at the schematics of a few 5V power relays and noticed different designs. Some use just a transistor to draw the higher current to switch the coil and some use optocoupler (surge protection) with a phototransistor.

Regarding this schematic: opto_relay Why do I need an extra transistor to switch the relay? Can I not just switch with the relay with the transistor of the optocoupler.

v3xX
  • 415
  • 2
  • 16
  • What part number for the opto coupler? [Answer that is helpful](https://electronics.stackexchange.com/questions/452162/understanding-the-difference-of-optocouplers-vs-relays-and-choosing-the-right-re?rq=1) – Andy aka Jan 28 '20 at 11:32
  • common 4N25 http://www.vishay.com/docs/83725/4n25.pdf – v3xX Jan 28 '20 at 11:35
  • And the relay data sheet? – Andy aka Jan 28 '20 at 11:40
  • https://www.mycomkits.com/reference/Songle_SRD(T73)_Relay.pdf – v3xX Jan 28 '20 at 11:45
  • just an aside: it's nice to put an LED in series (where DS1 is) so you get visual feedback when output is enabled. (So long as Vcc is enough for the LED and the optocoupler LED.) – jonathanjo Jan 28 '20 at 14:46

2 Answers2

3

Why do I need an extra transistor to switch the relay? Can I not just switch with the relay with the transistor of the optocoupler.

The 4N25 has a minimum current transfer ratio of 20% and that means that if you push the absolute limit of continuous current into the photodiode (60 mA), the photo-transistor might pull 12 mA through the relay coil.

enter image description here

And, for most 5 volt relays that won't be enough current.

You might have noticed that the absolute maximum figure for continuous collector current is 50 mA and, you might wonder how that can that be achieved given the minimum CTR and maximum diode current. Answer: the typical CTR may be around 50 % but it might be higher in some cases so, it's important to design around minimum and maximum figures.

Andy aka
  • 434,556
  • 28
  • 351
  • 777
  • 1
    The 4N25 has a current transfer ratio of 20% ... not complete true .. the CTR is **bigger than** 20%. So, typically, it might (just) work, but worst case, it will not work – Huisman Jan 28 '20 at 11:43
  • 1
    @Huisman oops yes, I forgot the word minimum. Fixed. – Andy aka Jan 28 '20 at 11:45
  • thanks for clearing this up. I found some design notes where the opto characteristics are explained in more detail. – v3xX Jan 28 '20 at 11:54
  • " it's important to design around minimum and maximum figures." Exactly. I have not been on this site very long, but a recurring problem seems to be users designing to data sheet typicals rather than worst case values. Oh, and not being able to read a data ahset properly. – SteveSh Jan 28 '20 at 15:43
2

I have looked at the schematics of a few 5V power relays and noticed different designs. Some use just a transistor to draw the higher current to switch the coil and some use optocoupler (surge protection) with a phototransistor.
[...]
Why do I need an extra transistor to switch the relay?

  • Some optocouplers cannot provide with the current requried to operate the relay. An additional (power) transistor is needed to control the relay.
  • Some cheap optocouplers have bad (current ransfer ratio) CTR or a too wide spread in CTR. Using the optocoupler to control the next (power) transistor solves this.
Huisman
  • 10,594
  • 2
  • 19
  • 40