Protection circuit for high AC Voltage Sensor

Hello to all. First sorry if my English is poor.
I would like to sense AC voltage by ADC of arduino.
But to convert High voltage about 220AC to Low voltage 3.3v I use resistance division method also I use LM324 to shift voltage upwards between 0 to 3.3v.
Now I need to a good protection circuit to connect it to arduino.
What protection circuit do you suggest me?
Very thank you.

Are you just using the output of the LM324 as the input to your arduino? And are you already getting the signal you want out of the LM324?

could you post a circuit diagram?

Alan

Thanks.
This is my circuit, but it doesn't have any protection circuit.

What protections I need to protect arduino?
Very thank you

Apart from the problem having the Arduino connected directly to the electrical grid (everything will be dangerous to touch) - why no put in a simple transformer, like a 230V:6V standard thing?

This gives you isolation and you only need to scale the voltage down from 6V so no problems with special resistors being able to withstand the high voltage.

// Per.

Why not use an opto isolator? It eliminates a direct connection to mains power and can sink current on positive and negative going cycles

Zapro:
Apart from the problem having the Arduino connected directly to the electrical grid (everything will be dangerous to touch) - why no put in a simple transformer, like a 230V:6V standard thing?

This gives you isolation and you only need to scale the voltage down from 6V so no problems with special resistors being able to withstand the high voltage.

// Per.

Thanks. Transformer is a little big for my PCB.

tinman13kup:
Why not use an opto isolator? It eliminates a direct connection to mains power and can sink current on positive and negative going cycles

Could you tell me the part number of opto isolator to use it for this work.
Very thank you.

Also any resistor-divider from high voltages has to be designed with care to avoid flash-over risk and
single-component-failure catastrophe. You may need several high-voltage rated resistors in series to
achieve a safe design.

It is safest to use a “wall wart” AC adapter, and follow these directions.

Could you tell me the part number of opto isolator to use it for this work.
Very thank you.

Do you want to sense / detect the "presence" of AC voltage, or "measure" the AC voltage?