Optocoupler Node is Floating error

Altair Forum User
Altair Forum User
Altair Employee
edited August 2023 in Community Q&A

Hello everyone,
I am designing for a Project a circuit to detect zero-crossing using a microcontroller. I want to use an optocoupler for isolation between the high voltage (coming from 3 phase) and the microcontroller. I have a transformer to reduce the voltage, a diode bridge rectifier and a comparator (as op-amp). I tried putting the optocoupler just before the comparator (in parallel to rectifier output); I got:
One of the nodes of the optocoupler (connected to comparator) is floating.
What to do to solve the issue? Please if I can get help.
Thank youu

Tagged:

Welcome!

It looks like you're new here. Sign in or register to get started.

Answers

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2023

    please post a screenshot or your schematic.

    hard to see what is going on without these

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2023


    Thank you for your reply @Albert_Dunford
    I think I connected the transistor wrong. What to do to correct?

    This gave the needed result, but with a DC offset of 4-5 V. Could the pic16f877 detect rising edges?

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2023

    Yes, the first schematic has control elements on the output stage, there needs to be a resistor over here as the output is generating a current.

    image

     

    In your second image you are using a resistor. Please have a look at the example circuit:

    image

  • Altair Forum User
    Altair Forum User
    Altair Employee
    edited August 2023

    So my second circuit is correct? And I something more: my Vout_min = 4V. How to make it 0 V?
    -Edit- Now I changed the high output of the comparator to 5 V in the first circuit (with optocoupler removed) and fixed!
    In the second circuit I added the same comparator and an inverter and fixed! Thank youu

Welcome!

It looks like you're new here. Sign in or register to get started.

Welcome!

It looks like you're new here. Sign in or register to get started.