Proteus Library — Zmpt101b

Simulating AC voltage measurements is a crucial step in developing smart energy meters, overvoltage protection circuits, and IoT power monitors. The ZMPT101B is the go-to single-phase AC voltage transformer module for these applications due to its high precision and isolation.

Complete Guide to Integrating and Simulating the ZMPT101B Voltage Sensor in Proteus

Connect the terminals to the high-voltage inputs (L and N) of the ZMPT101B module.

Connect VCC to 5V, GND to GND, and the OUT pin to an analog pin (e.g., A0) on your microcontroller simulation model.

Search for a trusted "ZMPT101B Proteus Library zip" online. Ensure the downloaded zip folder contains two essential files: ZMPT101BLibrary.IDX ZMPT101BLibrary.LIB Step 2: Locate Your Proteus Library Folder zmpt101b proteus library

A Proteus simulation of the ZMPT101B is useful for functional verification (e.g., checking ADC scaling, firmware logic) but cannot replace real-world calibration using a known AC source and multimeter.

Because Labcenter Electronics does not include this sensor out-of-the-box, third-party developers have created custom library blocks. These blocks use standard .IDX and .LIB files to render the component visual model and its simulation properties. Steps to Find and Download

Wire the components according to this standard simulation configuration:

// Basic AC Voltage Sampling Code for Proteus Simulation const int sensorPin = A0; const float VREF = 5.0; const float CALIBRATION_FACTOR = 42.43; // Adjust based on your simulation scaling void setup() Serial.begin(9600); void loop() float maxCurrent = 0; float minCurrent = 1023; unsigned long startTime = millis(); // Sample for 20ms (one full 50Hz cycle) while((millis() - startTime) < 20) int readValue = analogRead(sensorPin); if (readValue > maxCurrent) maxCurrent = readValue; if (readValue < minCurrent) minCurrent = readValue; // Peak-to-peak value float peakToPeak = maxCurrent - minCurrent; // Convert to Voltage Amplitude float voltagePeak = (peakToPeak * VREF) / 1023.0; // Calculate RMS Voltage float voltageRMS = (voltagePeak / 2.0) * 0.707 * CALIBRATION_FACTOR; Serial.print("Simulated AC Voltage: "); Serial.print(voltageRMS); Serial.println(" V"); delay(500); Use code with caution. Running the Simulation Simulating AC voltage measurements is a crucial step

Assumed goals: simulate measurement chain to an MCU ADC (0–5 V single-supply), using a ZMPT101B-like module producing a centered sensor output.

Note: The ProgramData folder is hidden by default in Windows. Enable "Hidden items" in the File Explorer View tab to see it. Step 3: Copy and Paste the Files Extract the downloaded ZIP file. Copy both the .IDX and .LIB files.

Locate your Proteus installation directory. The path varies depending on your software version:

Connect the (Pin 0) of the Arduino to the TXD pin of the Virtual Terminal. Arduino Simulation Code Connect VCC to 5V, GND to GND, and

: Search for "ZMPT101B" or "Voltage Sensor" in the component picker. It typically features terminals for AC input and an analog output for microcontrollers like Arduino.

const int sensorPin = A0; // ZMPT101B OUT connected to A0 const float vCC = 5.0; // ADC reference voltage const float calibrationFactor = 42.5; // Adjust to match input RMS in simulation void setup() Serial.begin(9600); void loop() unsigned long startTime = millis(); float maxCurrent = 0; float minCurrent = 1023; float sampleVoltage = 0; float sumOfSquares = 0; long sampleCount = 0; // Sample the AC wave for 20 milliseconds (one full 50Hz cycle) while (millis() - startTime < 20) int rawValue = analogRead(sensorPin); // Convert raw ADC to voltage centered around VCC/2 offset float voltage = ((rawValue * vCC) / 1023.0) - (vCC / 2.0); sumOfSquares += sq(voltage); sampleCount++; // Calculate Mean Square and Root Mean Square (RMS) float meanSquare = sumOfSquares / sampleCount; float rmsVoltageOutput = sqrt(meanSquare); // Scale the output to reflect the actual primary AC Mains voltage float finalACVoltage = rmsVoltageOutput * calibrationFactor; Serial.print("Simulated AC RMS Voltage: "); Serial.print(finalACVoltage); Serial.println(" V"); delay(1000); Use code with caution. Troubleshooting Common Simulation Issues

is a high-precision single-phase AC voltage transformer, essential for monitoring electrical parameters in modern electronic design. Integrating this component into the Proteus Design Suite through a dedicated library is a critical step for engineers and students who need to simulate real-world power monitoring systems before physical prototyping. This integration allows for the accurate modeling of AC-to-DC signal conversion, ensuring that microcontroller-based systems can safely interpret high-voltage data.


Back to top

Copyright © 2026 Mystic Peak Vine. All rights reserved..