Zmpt101b Proteus Library Patched 〈Mobile〉
If you cannot find a trusted library, you can create a sub-circuit in Proteus using:
For example, the library by r3mko provides the getVoltageAC() method, which returns the RMS voltage. The library by UterGrooll offers a set of examples for calibration and measurement. A minimal example (without an external library) would look like this:
Remember these key takeaways:
Upload the following optimized calibration code to your Proteus Arduino block (by compiling in the Arduino IDE and pointing the Proteus Arduino properties to the generated .hex file):
Because the output of the ZMPT101B is a low‑level AC waveform (often centred around half the supply voltage), it can be read directly by the ADC of an Arduino, ESP32, or any other microcontroller. Several Arduino libraries have been written to simplify the RMS voltage calculation and calibration, for example the libraries by r3mko and UterGrooll . In the physical world, the ZMPT101B is widely used in AC energy monitors, home automation projects, and industrial control systems. zmpt101b proteus library
Connect the two terminals of the ALTERNATER to the input pins ( L and N or In+ and In- ) of the ZMPT101B module block. Low-Voltage Side (Output)
Use the library for code development and logic testing . Always verify with real hardware before deploying to a live AC system. If you cannot find a trusted library, you
const int analogPin = A0; const float referenceVoltage = 5.0; const int adcResolution = 1024; const int samplesPerCycle = 100; const float frequency = 50.0; // Hz