Mains 220–230 V can kill. Work with the power off, use certified isolated modules in an enclosure, fuse the line, and ask a qualified electrician if you are not sure.
Your own meter, with your own tariff
The meter on the wall gives you one number a month. The PZEM-004T v3 gives voltage, current, power, frequency, power factor and accumulated energy once a second, and the ESP32 can turn it into daily kWh and a cost, including a night zone if your tariff has one.
Practical notes
The module talks Modbus-RTU over UART at 9600 baud and keeps the energy counter in its own non-volatile memory, so it survives restarts of the ESP32. Read it once or twice a second; faster polling only produces errors. The serial side is optically isolated, but its TX line is driven from the 5 V side, so put a divider or a level shifter before the ESP32 RX pin.
The 10 A version uses an internal shunt, the 100 A version uses a split-core current transformer that must clamp one conductor only, never both.
Stated accuracy is about 1 %, good for trends and costs, not for billing disputes.
Save a snapshot of the counter at midnight, then daily consumption is a simple difference.
Other countries: order these parts on AliExpress with the links below.
Some links are affiliate links: we may earn a commission at no extra cost to you.
Related ideas
⛔ High risk
Mains 220–230 V can kill. Work with the power off, use certified isolated modules in an enclosure, fuse the line, and ask a qualified electrician if you are not sure.
Mains 220–230 V can kill. Work with the power off, use certified isolated modules in an enclosure, fuse the line, and ask a qualified electrician if you are not sure.
Mains 220–230 V can kill. Work with the power off, use certified isolated modules in an enclosure, fuse the line, and ask a qualified electrician if you are not sure.
Comments
No comments yet. Share your experience or ask a question.