# Cheap way for utility voltage detection

• hisham.i
In summary, the purpose of this project is to detect the utility voltage and get an output signal to enter to microcontroller. The optocoupler is used to get the voltage range of 50VAC to 250VAC. The resistor is used to get the current at 250VAC. The optocoupler is able to handle 250VAC when it is reversed biased. Another way to detect the utility voltage is to use a diode in parallel to the optocoupler LED. The amc1100 has 4500V isolation and is able to solve the same divider issues regardless of the approach.

#### hisham.i

Hello,

I am designing electronic circuit board, and i want to only detect that the utility voltage is on. I don't want to measure the rms value of the voltage, only i wan to make voltage detection.

The voltage range should be from 50VAC to 250VAC.

I am looking for a cheap, small size, and a way where there could be isolation also.

So i thought to use a resistor and optocoupler as in the attached drawing.

In order to get the value of the resistor R, i used 1.2 v for the optocoupler, and 20mA will pass on the optocoupler for a minimum voltage of 50VAC.
The resistor R value was 3.5K. For this value the current at 250VAC will be 0.1A. -> the resistor power should be 35 watt, which is a very huge resistor.

Also bearing in mind that the optocoupler should handle 250√2 V when it is reversed biased. So i don't know if i can find an optocoupler that can hold this value also.

If some one has any idea to share about the cheapest way to detect utility voltage.

#### Attachments

• Schematic.jpg
20.4 KB · Views: 606
A small light bulb is better than the LED - it can operate with 250V and does not need additional resistors. I think there are commercial devices for that.

Assuming your line frequency is 50 Hz why not substitute a 0.9 or 1uF 500 VAC, non-polarized capacitor in place of the 3.5K resistor? To avoid the high reverse voltage of the LED, put an LEDs in parallel with reversed polarity.

Last edited:
http://www.test-meter.co.uk/products/voltage-detectors-proving/dilog-pl107n-test-meter/

This one is pretty cheap.

I would not do a light bulb. Filaments burn out easily compared to the lifetime of an LED.
-
Also, what do you consider 'isolation'? Optocouplers, relays, transformers and these type of devices generally are considered isolating devices. However, a pair of tracks run next to each other on a PCB form a capacitor. Put line voltage on one and sense the other. Is this isolated? Depends on how you define it.

skeptic2,

I agree with you, it is a good idea to use a diode in parallel to optocoupler led in reverse direction.

mfb, SteamKing,

The purpose is to detect the utility voltage and get an output signal to enter to microcontroller, neither lamp nor capacitive detection could be used.

Averagesupernova,

I want to make isolation in order to reduce shock hazard, and to increase safety for the operator, and not to reduce noise.
Do you have any other approach that could be used to detect utility voltage?

1N4004 one amp power diodes are cheap. If you put a reversed power diode in parallel with the opto-isolator's LED then that will clamp the reverse voltage. It will double the power dissipation in the resistor.
Alternatively a rectifier bridge of four diodes around the opto-isolator's LED will drive the LED on both phases.

Thanks meBigGuy for the usefull links.

Now i am thinking about different approach. I think that when there is grounding connection (to earth) on circuit board, then isolation will be important for safety reasons, but in case there is no grounding so there is no need for isolation. (Share your info./ comments for this please).

So now i am thinking to use op amp in differential mode configuration as the attached drawing, and then sense utility voltage.

#### Attachments

• photo(3).jpg
23 KB · Views: 581
I don't know the details enough to comment on the safety issues. Personally I feel all electronic equipment needs to be grounded for safty reasons. The amc1100 has 4500V isolation and it seems like you need to solve the same divider issues regardless.

hisham.i said:
Now i am thinking about different approach. I think that when there is grounding connection (to earth) on circuit board, then isolation will be important for safety reasons, but in case there is no grounding so there is no need for isolation. (Share your info./ comments for this please).
That sounds really dangerous. Isolation is always necessary for high voltage applications, especially if you have no ground to use as shield around the HV area.

So now i am thinking to use op amp in differential mode configuration as the attached drawing, and then sense utility voltage.
op amp for 250V? With really large resistors in front of it... hmm, maybe.

Last edited:
Why its important to make isolation if there is no grounding connection?

Grounding is the only point in common, so without grounding why u need isolation( assuming we are not taking noise immunity into account, just considering safety issues)

A human, touching the setup, can have a ground connection, or at least some capacitance versus ground (which is dangerous together with AC).