Arduino Projects Solar Power

Arduino Mains Voltage and Current Logging

Measuring mains voltage and current using an Arduino

As part of the solar hot water system we have been installing onto our home we wanted to be able to keep track of the mains electric being used by the house. Based on the open source OpenEnergyMontor website we developed our own version of their mains logging system to log the mains voltage and current consumption. The circuit comprises of two circuits on the same printed circuit board.

The current logging is using the OpenEnergyMonitor code and circuit using CT Sensors. Visit the CT sensors - Interfacing with an Arduino page to view the circuit and code.

The image below shows the back of the PCB


The second part of this circuit is to monitor the mains voltage. The circuit is a basic power supply using a small 9v transformer which a bridge rectifier, smoothing capacitor and a voltage divider with one resistor using a multi turn pot (yellow one in image below) to adjust the output to be 2.4V when the mains input is 240V.

This is read via  one of the analogue ports on the Arduino board.




michael spain
26 September 2021 at 6:18 am
I am wondering the above project will monitor the mains voltage of our solar panels

Leave a reply

Your email address will not be published. Required fields are marked *

Share this post

Support the blog

AB Electronics Raspberry Pi shop