Connect with us

How to make a mains detection unit using an optocoupler

Discussion in 'General Electronics Discussion' started by EES2017, Mar 17, 2017.

Scroll to continue with content
  1. EES2017

    EES2017

    1
    0
    Mar 17, 2017
    For an engineering project we need to make a mains detection circuit to detect our mains input and send a signal to a microprocessor. I need to know whether it should be contact or non contact and what other parts i'll require
     
  2. Harald Kapp

    Harald Kapp Moderator Moderator

    11,662
    2,697
    Nov 17, 2011
    Starting with an optocoupler in mind is a good idea as it will provide potential isolation and thus is a major step in ensuring safety.

    Here's an exemplary circuit.
     
    hevans1944 likes this.
  3. AnalogKid

    AnalogKid

    2,515
    718
    Jun 10, 2015
    Are you looking for a circuit to be added to a pc board design, or a stand alone unit? If you think about it, any cell phone charger or other low voltage power supply is a mains detection unit.

    For an on-board design or if you want to detect loss-of-mains very rapidly, that is a bit more work. For isolation, start with either a small power transformer or an optical coupler. The transformer can be either a standard small power transformer or a current transformer that has one of the mains leads fed through it. A standard transformer is larger, but the output voltage does not vary with the mains current going somewhere else.

    These will give you a sine or square wave output proportional to the mains voltage or current. What happens next depends on what aspect of the mains you are testing for.

    ak
     
    Arouse1973 and HellasTechn like this.
  4. Externet

    Externet

    773
    168
    Aug 24, 2009
    Done that, and as I was unable to find it on the market, took :
    - 1 phototransistor
    - 1 neon bulb
    - 1 resistor for the bulb
    - superglued together and
    - wrapped in black shrink tubing.
     
  5. Minder

    Minder

    3,103
    664
    Apr 24, 2015
    Also check out Fairchild App note AN3006 and Microchip AN958.
    M.
     
  6. Alec_t

    Alec_t

    2,969
    804
    Jul 7, 2015
    Years ago I used Externet's post #4 method, except that I used an LDR instead of a phototransistor.
     
  7. Minder

    Minder

    3,103
    664
    Apr 24, 2015
    Alot will depend on the nature of the detection required?
    Simply the presence or not, or zero crossing or random phase etc.
    M.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-