TEP DOWNLOAD CENTER

Project Files of ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation)

Libraries Code Projects Simulation
tep://download-terminal 650ec173216740c893e3e95c5cb6a258.zip ZIP archiveV1.0Verified0 downloadsFree
ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation): the ESP32, the MAX485, two PZEM-017 meters, the bulbs and the MOSFET
Proteus library · File 1 of 1

ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) V1.0

ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) V1.0 comes as a ZIP archive of 27 files (4.5 MB, 9.9 MB unpacked) holding Proteus library files, simulation model DLLs, a Proteus simulation, an Arduino sketch and compiled HEX firmware.

  • LIBProteus library
  • DLLProteus model
  • DSNProteus simulation
  • INOArduino sketch
  • HEXHEX firmware

Description

ESP32-RS485-Modbus-Power-Monitor-PZEM-017-Proteus-Simulation-v1.0.zip: the complete Proteus simulation project (ESP32 DevKit V1, MAX485, two PZEM-017 meters, two P21W bulbs, a toggle switch, an IRLZ44N, resistors, the Laptop and Mobile WiFi Monitors), the Arduino sketch and its HEX file, every LIB and DLL the simulation needs and a README.

Read ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation)

File Structure

650ec173216740c893e3e95c5cb6a258.zip27 files · 5 folders · 9.9 MB unpacked
ESP32-RS485-Power-Monitor-TEP-v1.0/27 files · 9.9 MB
Arduino Code/1 file · 10.1 KB
ESP32_RS485_Power_Monitor/1 file · 10.1 KB
INO ESP32_RS485_Power_Monitor.inoArduino sketch 10.1 KB
Proteus Library Files/9 files · 526.3 KB
LIB TEPBULB.LIBProteus library 17.7 KB
LIB TEPESP32V1.LIBProteus library 36.6 KB
LIB TEPLAPTOP.LIBProteus library 39.5 KB
LIB TEPMAX485.LIBProteus library 59.2 KB
LIB TEPMOBILE.LIBProteus library 13.1 KB
LIB TEPNMOS.LIBProteus library 17.9 KB
LIB TEPPZEM017.LIBProteus library 17.3 KB
LIB TEPRESISTOR.LIBProteus library 306.9 KB
LIB TEPTOGGLE.LIBProteus library 18.2 KB
Proteus Model Files/7 files · 4.6 MB
DLL TEPBULB.DLLSimulation model 291 KB
DLL TEPMAX485.DLLSimulation model 281.5 KB
DLL TEPNET.DLLSimulation model 2.9 MB
DLL TEPNMOS.DLLSimulation model 295 KB
DLL TEPPZEM017.DLLSimulation model 315 KB
DLL TEPRESISTOR.DLLSimulation model 311 KB
DLL TEPTOGGLE.DLLSimulation model 276.5 KB
Proteus Simulation/9 files · 4.7 MB
DSN ESP32-RS485-Power-Monitor.pdsprjProteus simulation 35.6 KB
HEX ESP32_RS485_Power_Monitor.hexCompiled HEX file 67.2 KB
DLL TEPBULB.DLLSimulation model 291 KB
DLL TEPMAX485.DLLSimulation model 281.5 KB
DLL TEPNET.DLLSimulation model 2.9 MB
DLL TEPNMOS.DLLSimulation model 295 KB
DLL TEPPZEM017.DLLSimulation model 315 KB
DLL TEPRESISTOR.DLLSimulation model 311 KB
DLL TEPTOGGLE.DLLSimulation model 276.5 KB
TXT README.txtText file 10.3 KB

README

README.txt 141 lines
===============================================================================================================
  ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) - Project V1.0
  The Engineering Projects - www.TheEngineeringProjects.com
===============================================================================================================

IMPORTANT LINKS
  The project tutorial (circuit, code, simulation results):
    https://www.theengineeringprojects.com/2026/11/esp32-rs485-modbus-power-monitor-pzem-017-proteus-simulation.html
  The libraries this project is built from (each post has its own full download and tutorial):
    ESP32 DevKit V1 board:
      https://www.theengineeringprojects.com/2026/10/esp32-devkit-v1-library-for-proteus-v2-0.html
    MAX485 RS-485 module:
      https://www.theengineeringprojects.com/2026/10/max485-rs485-module-library-for-proteus-v1-0.html
    PZEM-017 DC energy meter:
      https://www.theengineeringprojects.com/2026/11/pzem-017-dc-energy-meter-library-for-proteus.html
    Filament bulb (P21W):
      https://www.theengineeringprojects.com/2026/11/filament-bulb-library-for-proteus.html
    N-MOSFET (IRLZ44N):
      https://www.theengineeringprojects.com/2026/11/n-mosfet-library-for-proteus.html
    Toggle switch:
      https://www.theengineeringprojects.com/2026/11/toggle-switch-library-for-proteus.html
    Resistor:
      https://www.theengineeringprojects.com/2026/11/resistor-library-for-proteus.html
    Laptop WiFi Monitor:
      https://www.theengineeringprojects.com/2026/10/laptop-wifi-monitor-library-for-proteus.html
    Mobile WiFi Monitor:
      https://www.theengineeringprojects.com/2026/10/mobile-wifi-monitor-library-for-proteus.html
  Support our free work: https://www.theengineeringprojects.com/donate

FILE STRUCTURE
ESP32-RS485-Power-Monitor-TEP-v1.0/
|-- Proteus Library Files/
|   |-- TEPBULB.LIB                                    17.7 KB   a part of the project -> LIBRARY folder
|   |-- TEPESP32V1.LIB                                 36.6 KB   a part of the project -> LIBRARY folder
|   |-- TEPLAPTOP.LIB                                  39.5 KB   a part of the project -> LIBRARY folder
|   |-- TEPMAX485.LIB                                  59.2 KB   a part of the project -> LIBRARY folder
|   |-- TEPMOBILE.LIB                                  13.1 KB   a part of the project -> LIBRARY folder
|   |-- TEPNMOS.LIB                                    17.9 KB   a part of the project -> LIBRARY folder
|   |-- TEPPZEM017.LIB                                 17.3 KB   a part of the project -> LIBRARY folder
|   |-- TEPRESISTOR.LIB                               306.9 KB   a part of the project -> LIBRARY folder
|   |-- TEPTOGGLE.LIB                                  18.2 KB   a part of the project -> LIBRARY folder
|-- Proteus Model Files/
|   |-- TEPBULB.DLL                                   291.0 KB   a model -> MODELS folder
|   |-- TEPMAX485.DLL                                 281.5 KB   a model -> MODELS folder
|   |-- TEPNET.DLL                                     2.89 MB   a model -> MODELS folder
|   |-- TEPNMOS.DLL                                   295.0 KB   a model -> MODELS folder
|   |-- TEPPZEM017.DLL                                315.0 KB   a model -> MODELS folder
|   |-- TEPRESISTOR.DLL                               311.0 KB   a model -> MODELS folder
|   |-- TEPTOGGLE.DLL                                 276.5 KB   a model -> MODELS folder
|-- Proteus Simulation/
|   |-- ESP32_RS485_Power_Monitor.hex                  67.2 KB   the firmware
|   |-- ESP32-RS485-Power-Monitor.pdsprj               35.6 KB   the project simulation
|   |-- TEPBULB.DLL                                   291.0 KB   copy of the model
|   |-- TEPMAX485.DLL                                 281.5 KB   copy of the model
|   |-- TEPNET.DLL                                     2.89 MB   copy of the model
|   |-- TEPNMOS.DLL                                   295.0 KB   copy of the model
|   |-- TEPPZEM017.DLL                                315.0 KB   copy of the model
|   |-- TEPRESISTOR.DLL                               311.0 KB   copy of the model
|   |-- TEPTOGGLE.DLL                                 276.5 KB   copy of the model
|-- Arduino Code/
|   |-- ESP32_RS485_Power_Monitor/ESP32_RS485_Power_Monitor.ino   10.1 KB   the sketch (source of the .hex)
|-- README.txt                                        ~10.0 KB   this file
Total: 9.88 MB (unzipped). The C++ source code of the models is not included.

WHAT IS IT?
  A 12 V power monitor for a camper van, a boat or a workshop that you can run in Proteus: an ESP32 is the Modbus-RTU
  master of an RS485 bus with two PZEM-017 DC energy meters on it, one for each circuit, trips the lights circuit like
  an electronic circuit breaker when it is overloaded, and serves a web dashboard.
    * MAX485 module (MAX485ADVTEP, U2): RO to RX2 (GPIO16), DI to TX2 (GPIO17), DE and RE together to D4; VCC 5 V; A and
      B are the bus.
    * PZEM-017 meters (PZEM017TEP, EM1 address 1 / EM2 address 2), RANGE 50, on the same A / B pair; 5V on 5 V. Each has
      V+ on +12V, V- and SH- on GND, SH+ on the load's side of its own 50 A / 75 mV shunt (R2 / R5, 0.0015 ohm) in the
      circuit's negative lead.
    * The 12 V supply: +12V terminals (a battery or a power supply).
    * The FRIDGE circuit: +12V - R1 6 ohm - SH1 - R2 - GND (EM1). The LIGHTS circuit: +12V - L1 (BULBP21WTEP, a 12 V
      21 W bulb), and L2, a second one, through SW1 (SWITCHTOGGLETEP, C / 3: open at the start) - Q1 (IRLZ44NTEP, gate
      D25 through R3 100 ohm, R4 10 kohm to GND) - SH2 - R5 - GND (EM2).
    * ESP32 DEVKIT V1 (U1) runs ESP32_RS485_Power_Monitor.hex on TEP-WiFi at 192.168.1.101 (port 80).
    * Laptop WiFi Monitor (PC1) and Mobile WiFi Monitor (MOB1) open http://192.168.1.101/.
  The rules (at the top of the sketch):
    * a Modbus-RTU master written out by hand on Serial2: 9600 baud 8N2, CRC-16 (low byte first), 5 ms of silence
      before every frame; at the start each meter is told its shunt (register 3 = 1: 50 A) and its low-voltage alarm
      (register 1 = 1100: 11.00 V); then function 0x04 reads each meter's eight registers once a second;
    * the ELECTRONIC CIRCUIT BREAKER: the lights circuit above 3.0 A in two readings in a row trips (Q1 off) - a cold
      bulb's switch-on surge lasts milliseconds, an overload does not; RE-ARM on the dashboard switches it back on.
  Its pages:
    /          the dashboard: the controls, the supply, both circuits (A, W, Wh), the breaker, the events
    /arm       re-arm the breaker (the lights on)            /off      the lights off
    /reset     both energy counters to 0 (function 0x42)       /data     everything as JSON
  No extra library: the Modbus frames are built byte by byte on Serial2.

TEST STATUS
  Tested in Proteus 8 Professional on Windows 11, the run that made the tutorial's screenshots (the sketch's times):
  - 0.2 / 0.3 s: "meter 1 (FRIDGE): shunt 50 A set, alarm 11.00 V set", the same for meter 2 (LIGHTS); then each meter
    read once a second: supply 12.00 V, FRIDGE 2.00 A 24.0 W, LIGHTS 1.75 A 21.0 W; the energy climbing (SPEED 120).
  - 11.4 s: SW1 plugs in the second lamp: LIGHTS 3.49 A 41.9 W at 12.1 s; 13.1 s "LIGHTS OFF - TRIPPED: over 3.0 A".
  - 16.8 s: RE-ARM from the phone with the lamp still in: 3.52 A, tripped again at 18.1 s (two readings).
  - 19.8 s: SW1 back; 21.3 s RE-ARM from the laptop: it holds at 1.75 A.
  - 25.7 s: RESET from the laptop: FRIDGE 20 Wh and LIGHTS 15 Wh back to 0.
  - The MAX485: 118 frames, 59 requests and 59 answers, 0 CRC errors. 29.1 s of simulation in 284 s.

INSTALLATION
  1. Close Proteus. Extract the WHOLE zip file, for example to your Desktop.
  2. Copy the files from "Proteus Library Files" into the LIBRARY folder of Proteus, for example
     C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY
  3. Copy the files from "Proteus Model Files" into the MODELS folder (next to LIBRARY).
  4. Start Proteus. Press P in the schematic and search for ESP32 DEVKIT V1, MAX485ADVTEP or PZEM017TEP to check that
     the parts are there.

RUN THE SIMULATION
  1. Open "Proteus Simulation\ESP32-RS485-Power-Monitor.pdsprj". Keep the HEX and the DLL files beside it.
  2. Press Play. The ESP32 sets up both meters and reads them once a second; the serial monitor prints a line a second.
  3. Click SW1 to plug in the second lamp: the lights circuit goes over 3.0 A and trips.
  4. Open the Laptop WiFi Monitor (PC1) or the Mobile WiFi Monitor (MOB1) and press Go: RE-ARM, OFF, RESET.
  Your own sketch: compile it, export the compiled binary and set U1's PROGRAM property to the new file.

PROPERTIES USED IN THIS PROJECT
  U1 ESP32 DEVKIT V1           PROGRAM=ESP32_RS485_Power_Monitor.hex, AUTOOPEN=YES (TEP-WiFi, 192.168.1.101)
  U2 MAX485ADVTEP              (no changes)
  EM1, EM2 PZEM017TEP          ADDRESS=1 / 2, RANGE=50, USB=NO, SPEED=120 (the energy clock: 2 minutes each second)
  L1, L2 BULBP21WTEP, Q1 IRLZ44NTEP, SW1 SWITCHTOGGLETEP   (no changes)
  R1 6 ohm (the fridge), R2 / R5 0.0015 ohm (the 50 A shunts), R3 100 ohm, R4 10 kohm
  PC1, MOB1                    HOMEPAGE=http://192.168.1.101/

TROUBLESHOOTING
  * A meter does not answer: A and B swapped, two meters with the same ADDRESS, or no 5 V on its RS485 side.
  * Every reply fails its CRC: the frames sent too close together - keep the 5 ms gap before each request.
  * The current reads twice too high: the meter not told its 50 A shunt (register 3).
  * The breaker trips again at once after RE-ARM: the overload is still there - unplug the second lamp first.

LICENCES
  * The project, the sketch, the parts (LIB files) and the models (DLL files) are made by The Engineering Projects
    and are free for learning and for your own projects. The models use only standard Windows libraries.
    The C++ source code of the models is not included; the source code is not included for any model.
  * Proteus is a product of Labcenter Electronics and is not included. ESP32 is a product of Espressif Systems; the
    PZEM-017 of Peacefair; the MAX485 of Analog Devices (Maxim) and others.
    This project is not made or endorsed by them.

VERSION
  V1.0 - the first release of the project.
===============================================================================================================
Advertisement

Development1 release

  1. V1.0ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) V1.0this page

    V1.0 is the only release in the Download Center so far. When a newer version is published, it appears above with its own download page.

Installation8 steps

From the download to a working project, in order. The steps follow what the package contains.

You will need

  • Proteus Design SuiteProteus 8 or newer (Labcenter), on Windows
  • Arduino IDE1.8 or 2.x, with the board of the tutorial chosen under Tools → Board
  • Any archive toolWindows, macOS and Linux extract ZIP files on their own

Steps

  1. 1

    Extract the archive

    Right-click 650ec173216740c893e3e95c5cb6a258.zip and choose Extract All (or open it with 7-Zip or WinRAR) into a folder you can find again. Keep its folder structure (ESP32-RS485-Power-Monitor-TEP-v1.0) as it is.

  2. 2

    Copy the library files into Proteus

    Move TEPBULB.LIB, TEPESP32V1.LIB and TEPLAPTOP.LIB and 6 more and the files into the LIBRARY folder of your Proteus installation: C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY for Proteus 8, or the matching Proteus 7 folder. Older versions keep it under ProgramData\Labcenter Electronics. If Proteus is open, close it first.

  3. 3

    Add the simulation model

    Copy TEPBULB.DLL, TEPMAX485.DLL and TEPNET.DLL and 4 more into the MODELS folder next to LIBRARY, so the component can run, not only be drawn.

  4. 4

    Restart Proteus and place the component

    Start Proteus, open a schematic, press P (Pick Devices) and search for the component by the name used in the tutorial. It appears with its pins ready to wire.

  5. 5

    Open the sketch in the Arduino IDE

    Open ESP32_RS485_Power_Monitor.ino, select your board and port under Tools, then Verify. Sketch → Export Compiled Binary writes the HEX file a simulation needs.

  6. 6

    Load the HEX file

    In Proteus double-click the microcontroller, set Program File to ESP32_RS485_Power_Monitor.hex and run the simulation. For real hardware, flash the same file with your programmer.

  7. 7

    Open the example simulation

    Open ESP32-RS485-Power-Monitor.pdsprj in Proteus to see the wiring exactly as in the tutorial. Check the controller's Program File path, then press Play.

  8. 8

    Follow the tutorial

    ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) explains every connection and setting in order; keep it open beside the files while you build.

How to add a library in Proteus 8

FAQs9 questionsContact TEP

How do I download ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) V1.0?

Wait for the 30-second guest countdown on this page, then press the download button; the file comes straight from our storage. Members who are logged in skip the wait. If the browser opens the file instead of saving it, use its Save as option. The download link is made for you when the countdown ends and works for 15 minutes; a saved or shared link stops working, so share this page instead.

What is inside the archive?

ESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation) V1.0 comes as a ZIP archive of 27 files (4.5 MB, 9.9 MB unpacked) holding Proteus library files, simulation model DLLs, a Proteus simulation, an Arduino sketch and compiled HEX firmware. Open the File Structure tab for the full list of 27 files.

What should I do if the download does not start?

Check the browser's download list first; an ad blocker or a company firewall can also hold it back, so try another browser or network. If the file arrives incomplete, download it again. For an installation problem, read the Install tab or tell us in the comments with your software version and the exact error message.

Is this file free?

Yes. Every file in the TEP Download Center is free for learning, personal and student projects. If you share it, link back to this page or the tutorial so others find the latest version.

How do I check that the file arrived complete?

Compare its SHA-256 with the one on this page, ce7e19d771dac873e1bb25755463ccf961884a6e22a56cda3853f64918389676. In PowerShell run Get-FileHash "650ec173216740c893e3e95c5cb6a258.zip"; on macOS or Linux run shasum -a 256 "650ec173216740c893e3e95c5cb6a258.zip". The same value means the file is exactly the one in our storage; a different one means the download broke off, so download it again.

Do I need WinRAR to open the ZIP file?

No. Windows, macOS and Linux open ZIP archives on their own (Extract All, or double-click). WinRAR and 7-Zip work too. Extract the whole archive before using the files.

Where do I put the LIB and IDX files?

Both files go into the LIBRARY folder of your Proteus installation (Proteus 8: C:\Program Files (x86)\Labcenter Electronics\Proteus 8 Professional\LIBRARY; Proteus 7 has the same folder under its own name). Restart Proteus afterwards and search for the component with P.

Which Proteus version does the library need?

The tutorial names the Proteus version the library was made and tested with. Most TEP libraries work in Proteus 7 and Proteus 8; if the component does not appear after a restart, check that both the LIB and the IDX file were copied and that Proteus was fully closed while copying.

How do I get the HEX file into the simulation?

Compile the sketch in the Arduino IDE (Sketch → Export Compiled Binary gives you the HEX next to the sketch), then in Proteus double-click the board, set Program File to that HEX and run.

preparing · 650ec173216740c893e3e95c5cb6a258.zip
Rating
Your download will be ready shortly
Preparing your download…

Members skip the wait. Log in or join TEP.

Last 14 days0 downloads
SHA-256 ce7e19d771dac873e1bb25755463ccf961884a6e22a56cda3853f64918389676
DocumentationESP32 RS485 Modbus Power Monitor with PZEM-017 (Proteus Simulation)
Need help with this file? Bug report Ask a question Download problemsGet updates
Advertisement

Comments

0

Join the conversation

Start the conversationAsk a question or share how you used this download.