1
\$\begingroup\$

I have the following optoisolator  PC817. It is a 4-Pin Phototransistor Optoisolator. My idea is basically to control electrical appliances in my home. The power supply in my country is 230V 50Hz.

I specifically want to control tube lights in my room. The control of 5V comes from an AVR microcontroller.

My circuit connections are shown in the picture.PC817 connections

Hoping that my connections are correct, my question: is it safe to run them with optoisolator for a prolonged duration. And also how reliable are they?

I also want some suggestions on additional safety precautions.

\$\endgroup\$
  • 4
    \$\begingroup\$ That circuit won't work and will possibly hurt you when you power it. Please seek an expert advice and/or use a ready made commercial product if you don't know how to deal with the mains. \$\endgroup\$ – Vladimir Cravero May 14 '15 at 8:12
1
\$\begingroup\$

The circuitdiagram has some very basic problems:

left side:
There is no series resistor for the LED to limit the current.

right side:
I don't see an power source. And if there were any: the max. voltage between C and E of the PC817 is allowed to be 35V. Don't be tempted to switch 230V with the transistor of the optoisolator. You must use something like a triac or thyristor to do the high voltage switching.

|improve this answer|||||
\$\endgroup\$
  • \$\begingroup\$ What I meant to show was just the switch socket. The power source and everything is already connected to the switch. \$\endgroup\$ – Naveen Chakravarthy May 14 '15 at 7:43
  • 1
    \$\begingroup\$ @Naveen Chakravarthy: And how are we supposed to know that there is not also a triac and you just didn't "mean to show" it? \$\endgroup\$ – Curd May 14 '15 at 8:20
  • \$\begingroup\$ Lol, can you suggest me any other Optoisolator that I can use for my requirements. \$\endgroup\$ – Naveen Chakravarthy May 14 '15 at 8:22
  • \$\begingroup\$ @Naveen Chakravarthy: see the one used in the linked question above, e.g. MOC3041 fairchildsemi.com/datasheets/MO/MOC3041M.pdf (important: for 230V AC you have to use the 400V variant, 250V would not be enough). See application on p. 7 \$\endgroup\$ – Curd May 14 '15 at 8:28
  • \$\begingroup\$ This one is great. Thanks. Seems like I should use a triac externally. \$\endgroup\$ – Naveen Chakravarthy May 14 '15 at 8:35

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