Power Peacefair PZEM 004 + ESP8266 & Arduino Nano

About: Share - Learn - Makers. Projects, Articles, #automation, #PLC, #Arduino, #IoT and More PDAControl

For some time I wanted to buy a single-phase electricity consumption meter, a few months ago I got Peacefair Reference PZEM-004 meter, its price seemed affordable, it has the advantages of being a non-invasive meter in the electrical circuit and has a communication protocol to request data such as Active Instantaneous Power "kW", Voltage "V", Amperage "A" and Active Power Accumulated "kWh".

We will perform some tests on the PZEM-004 Meter and integrate it with 2 platforms or plates already used before the ESP8266 12E module and an Arduino Nano.

Warning: Caution is recommended since this project involves electrical risk or electrocucion since 110 VAC -120 VAC connected equipment is used, basic knowledge is required, please be previously documented in this regard.

Complete Tutorial- Tutorial Completo
PDAControl Documentation & Downloads and More

test Electricity consumption meter Peacefair PZEM 004 + ESP8266 & Arduino Nano http://pdacontrolen.com/electricity-consumption-m...

Documentaciones & Descargas y mas pruebas

Medidor de consumo electrico Peacefair PZEM 004 + ESP8266 & Arduino Nano http://pdacontrolen.com/electricity-consumption-m...

Step 1: There Are 2 Versions

There are 2 versions:
This meter is very popular in electrical consumption measurement projects and there are 2 versions depending on the application required.

PZEM-004Tand PZEM-004with display 7segments

Step 2: ​Materials and Where to Buy Cheap!!!

Step 3: Disarm the Meter

Step 4: ​Test Arduino Nano

Of all the arduino, plates, the Nano version is my favorite since it is practical, small and has FTDI / usb included. With the modification we made to the UART ttl, we can use the arduino to 3.3v, making a direct connection.

In this case we use an Arduino Nano board, which only has a single serial port, the PZEM004T.h library has the ability to create another serial port with the SoftwareSerial.h library, we will use the D10 (RX) and D11 (TX) pins ) As communication port with the meter.

Step 5: Modification TTL UART From 5v to 3.3v

The UART interface of the meter is 5v. In the case of connecting the meter to an Arduino board, no problem will work correctly, in case of connecting with an ESP8266 module at 3.3v it will not work, since the optocouplers will not be activated with 3.3v, in that case a conditioning should be carried out of signal the simplest method that I have seen in the internet, to modify the voltage of one of the optocouplers with a resistance of 1kOhm, is the simplest and most economical way if a TTL converter of 5 to 3.3v is not available.

Note: Some forums indicate that caution should be used when connecting the TTL to a PC, I confess I was afraid to connect this meter to my pc, thinking about the isolation of the meter but in my case there were no problems.

Step 6: ​Test ESP8266 12E

For this test we will use an ESP8266 12e NodeMCU, Since it is only a revision, we will perform a basic test, taking into account that the PZEM004T.h library with the SoftwareSerial.h library that allows to configure pins in serial ports to 9600 bauds.

Step 7: Video Power Meter PZEM 004 Peacefair + Arduino & ESP8266

Step 8: ​Conclusions, Documents and Downloads

Conclusions

Initially, a lot of caution should be taken since this project involves electrical risk or electrocution since 110VAC -120 VAC is used, although some do not consider it high voltage, this does not minimize the danger, it is recommended to have basic knowledge or documentation, never make connections When hot, always de-energize the power circuits.

The PZEM 004 meter, is very practical, very basic and its low price meets good performance, I do not recommend it for industrial applications taking into account the environment, its point of measurement of VAC is the same point of feeding, allowing measurements between 80-260VAC. Current measurement from 0 to 100A, well I'm not sure that this transformer supports 100A, but I'll continue investigating.

Warning: Do not take either 5v or 3.3v directly from the source of the meter, if you feed your modules add an extra source, to avoid short circuits.

Complete Tutorial- Tutorial Completo

PDAControl

Documentation & Downloads and More test

Electricity consumption meter Peacefair PZEM 004 + ESP8266 & Arduino Nano

http://pdacontrolen.com/electricity-consumption-me...

Documentaciones & Descargas y mas pruebas

Medidor de consumo electrico Peacefair PZEM 004 + ESP8266 & Arduino Nano

http://pdacontroles.com/medidor-de-consumo-electri...

Share

    Recommendations

    • PCB Contest

      PCB Contest
    • Make it Glow Contest 2018

      Make it Glow Contest 2018
    • Big and Small Contest

      Big and Small Contest

    Discussions