Fluctuation in result

I have made voltmeter using arduino by this link

My problem is i am getting highly fluctuating results on serial monitor.plz help i am new to arduino.

Do you have the 1uF capacitor in the circuit? If an electrolytic capacitor, is it the polarity right?

Yes,i have connected 1uf capacitor and i have made sure that it is connected according to polarity.

Why don't you provide some info to go by, such as your actual code, a sketch of your actual circuit, overview of actual results you get, etc?

The cap is the component that smooths the half wave rectified (very bumpy) voltage to a smooth DC voltage.
So if it is not in the circuit or bad there will be a noisy output.

Check the rest of your wiring.

How much is the output fluctuating? Can you post a sample?

I am getting this…

This is my circuit

Please do not post pictures of the serial monitor. Copy the text from serial monitor and paste it into your post between code tags.

What you should post a picture of is your own circuit. Maybe you made an error and it is not the same as the circuit below. Check that your pictures are well focused and will lit, and that we can see where every wire and component is connected.

I think some AC interference is affecting the readings. You could try averaging over many readings.

This is my circuit

That is the diagram from the website. We need to see a clear photo of YOUR circuit.

Sorry i am new to this forum so i donot know how to use it formally ,this is my original circuit

Sorry i am new to this forum so i donot know how to use it formally

How to formally use the forum is not a secret. It is written in the "how to use this forum" post at the top of each forum section. Nothing prevents a new user from reading that before they post, except laziness.

Which hole is this white wire connected to?

White wire is connected to a hole just below the yellow wire,nodes are same

In that case I cannot see any obvious errors in your circuit (although it does look a little like you made it while wearing boxing gloves :wink: ).

Try replacing the capacitor for another of the same value. Also try a larger value.

Well,i have replaced capacitior with new one but i still getting those results,now i am improving code to get average of 100 readings ,hope this will work.Thanks(especially to you paul,i am dumb at making projects) to everyone for your time.

This picture from the address you pasted into your OP looks very suspicious to me. The results are too perfect. I would not expect to see such a stable value, consistent to 5 digits!


I'd call this consistent to three digits (the ADC reading), but that aside. Too perfect indeed. Even the ADC itself tends to have more noise.