AC Measure

What is the best way to measure AC 220V with MCU? Is there some sensor, or maybe circuit? Just to take two wires N and L and check is there AC or not.

Do you want to measure the actual voltage or just know the voltage is present .

For the former you need a transformer to step the voltage down and isolate it , you can then bias the. AC waveform so it is above 0v and feed it into an analog port - this has been covered many times and google will find you circuits .
If it’s the later just use a relay switch by the AC mains and connect the contacts to a digital input .( like a push button )

Define "best way".

One way is to make an 'unregulated' full wave (with capacitor filtering) power supply and do a conversion to get 220VAC.

Do not feed more than 5V maximum into an analog input !

Lots of good advice at Learn | OpenEnergyMonitor

Other pages on that site offer instruction on measuring current and power.

My AC mains measuring device is connected directly to the mains and is powered through an isolated DC-DC converter. The output is serial data via an opto-coupler and the whole thing is inside an earthed metal box for safety.

I just need to see is there a power in the outlet.
Just find out ZMPT101B.

Hello guys,
having read your post with much interest to find a solution for my problem, but did not find one.

For a Windturbine 3 phase generator i installed 3 ZMPT101b to read the generated voltage on each phase but it did not give out any usefull data.

After some more research i found that the the ZMPT101b works only from 50-60Hz, is that limit true?
The windturbine however starts with 0 Hz up to about 70 on one phase. (3 phase 27 coils 36 magnets).

Is there any walkaround for that frequency limit available?

Thanks a lot

Where did you find the frequency limits?

Did you have any kind of load on the alternator while measuring the voltage? You HAVE to have a load of some kind to limit the voltage to below infinity.

70 Hz is not very far beyond the 60 Hz used in North America.

What actual values did you get from the sensor? Did you compute the voltage correctly?