This post is older than 2 years and might not be relevant anymore
More Info: Consider searching for newer posts

Crazy plan for 220V zero-crossing detection - which one is less bad?

Hi, I want to use a couple of 0805 resistors, hook them up in tandem to 220V AC power source, and then do some zero-crossing detection.

I know I know, this totally isn't how you are supposed to get it done, but bear with me.

My question is which one of the follow 2 scheme is the least evil way to get it done?

Plan 1:

Hook the resistors directly to an AIN pin. The pin and the resistors will be in serial connection, the current will go directly through the MCU to the ground.

The major problem with that is I don't know the impedence of the MCU, so it could take a really long time via trial and error to evetually settle down an appropriate value.

Plan 2: connect those resistors to the ground, then draw voltage from in between 2 resistors.

At least on surface this one sound better. It's simpler, l;et's say I want to user the max range of the nrf51822's ADC, which is 3.6V. So all I have to do is to

calculate the proportion of those resistors, since 3.6/220 = 0.01636, my resistor ratio could be 500k : 500k :16k, the current will be minuscule although again questions stand as how tiny a current will not be sufficient enough to trigger nrf51822's AIN input.

Anyway, your opinion?

Parents
  • The effective input impedance of the SAADC has been thoroughly covered both in the spec's and also in this forum.  Just search for it and you will find your answers.

    With regard to your application you will, of course, need to float the ground of the nRF solution and it will need to be well isolated for safety.  All global power systems utilize an earth ground with the corresponding safety issues. If you plan to ship a product, you will have some big safety hurdles there. Since it is floating, you will need to power off of the 220vac source.  Pretty trivial to do this and lots of shipping examples in the world.  The first example that comes to mind is zigbee/smarthome/z-wave/homekit light switches.

    On the zero crossing aspect, not sure what your application is, but hopefully you are aware that just because you have zero crossing voltage does not mean you have zero crossing current.  And, switching inductive loads during non-zero current times will result in very large voltages and the possibility of destructive arcing.

    If you want to avoid a lot of the safety/grounding issues, you should look at opto-couplers/isolators.  This is a common approach to provide feedback in mains powered DC/DC switchers so they can have a local DC ground that is safe.

Reply
  • The effective input impedance of the SAADC has been thoroughly covered both in the spec's and also in this forum.  Just search for it and you will find your answers.

    With regard to your application you will, of course, need to float the ground of the nRF solution and it will need to be well isolated for safety.  All global power systems utilize an earth ground with the corresponding safety issues. If you plan to ship a product, you will have some big safety hurdles there. Since it is floating, you will need to power off of the 220vac source.  Pretty trivial to do this and lots of shipping examples in the world.  The first example that comes to mind is zigbee/smarthome/z-wave/homekit light switches.

    On the zero crossing aspect, not sure what your application is, but hopefully you are aware that just because you have zero crossing voltage does not mean you have zero crossing current.  And, switching inductive loads during non-zero current times will result in very large voltages and the possibility of destructive arcing.

    If you want to avoid a lot of the safety/grounding issues, you should look at opto-couplers/isolators.  This is a common approach to provide feedback in mains powered DC/DC switchers so they can have a local DC ground that is safe.

Children
No Data
Related