ADA-PN100 – P1 → S0 Pulse Generator

The ADA-PN100 is an ESP32-based device that generates S0 (countable) pulses from OBIS data read from the P1 port of smart meters. Its purpose is to provide compatible pulse signals from modern smart meter energy values to PLCs, measurement systems, data collectors, or SCADA systems.


In brief: P1 OBIS → processing → configurable duration (ms) and quantity (Wh/pulse) S0-like pulses on an isolated, potential-free PhotoMOS output (GAQY212GS).

What is it for?

  • Driving old S0 counters/PLC inputs from smart meter data.
  • Consumption/production pulse output (kWh-based), compatible with industrial 24 VDC digital inputs.
  • Separated PV export/import pulses with distinct OBIS codes (e.g. imported: 1-0:1.8.0, fed-in: 2-0:2.8.0).
  • Easy integration with data collectors, loggers, BMS/EMS/SCADA systems that expect pulses.

Main features

  • OBIS-based processing: 1-0:1.8.0 (default, kWh), other OBIS codes can be specified.
  • Configurable pulse length: 50–2000 ms (default: 300 ms).
  • Configurable Wh/pulse (e.g. 100 Wh → 0.1 kWh/pulse).
  • Stability: EEPROM-stored state (baseline + residual kWh), no doubling after power failure.
  • Built-in logging: memory buffer + LittleFS file (/pn100.log), viewable in browser.
  • Physical factory reset button (GPIO4): press for ≥5 s → factory reset.
  • Isolated output: PhotoMOS SSR (GAQY212GS), potential-free, SPST-NO, up to 60 VAC/DC, 500 mA.

Hardware – Output relay (GAQY212GS)

Relay typeSolid-state semiconductor relay (PhotoMOS), SPST-NO
Manufacturer codeGAQY212GS (SUPSIC), OptoMOS series
PackageSOP-4 (SMT)
Isolation1.5 kV (optical isolation on output)
Switching timeon: ~0.35 ms, off: ~0.1 ms
On-state resistance~0.8 Ω (when on)
Max. output current500 mA
Max. voltage60 VAC / 60 VDC
Control current (LED side)max. 50 mA (typically 5–10 mA suffices)
Operating temperature−40…+85 °C

Note: A small leakage current is natural in PhotoMOS relays (in the µA range). Standard PLC digital inputs are typically not disturbed by this.

Warning: the output can be used only in circuits up to 60 V AC/DC. Never connect directly to 230 VAC mains!


Switching logic (S0 / "dry contact")

  • The PhotoMOS output is normally open (NO). On pulse, it closes → the 24 V PLC input circuit short-circuits briefly.
  • The two terminals are polarity-independent (suitable for AC/DC up to 60 V limit).
  • Typical wiring: PLC +24V → input → PN100 PhotoMOS → 0V in series, or directly to PLC input S0+ / S0− terminals.

Simple wiring example (for 24 VDC PLC input)

+24V  ──► PLC DI+ ──► [ GAQY212GS (PN100) ] ──► 0V (GND)

Web setup (AP mode)

  1. After powering on, the device starts in AP mode: SSID: ADA-PN100, password: 12345678 (changeable).
  2. Connect to the AP, then open in browser: http://192.168.4.1.
  3. Main fields on the interface:
    • OBIS code – the read OBIS identifier (default: 1-0:1.8.0).
    • Pulse length (ms) – pulse duration (50–2000 ms; default: 300 ms).
    • Quantity (Wh/pulse) – Wh per pulse (e.g. 100 Wh → 0.1 kWh).
    • AP password – access password (8–63 characters). After saving, the AP restarts automatically.
  4. Save – save settings to EEPROM.
  5. Test pulse – test pulse (quick check of hardware and PLC input).
  6. Delete log – clear log.
  7. Log – newest entries on top, auto-updates every 5 s. Separate endpoint: /log?format=html|text&rev=1|0

Factory reset (physical button)

  • Button on GPIO4, INPUT_PULLUP mode.
  • Hold for ≥5 s → device resets all settings (OBIS, pulse parameters, AP password, log) and restarts to factory defaults.

OBIS ideas (not just the default)

OBISMeaningTypical use
1-0:1.8.0Total imported energy (kWh)Counting consumption (default)
2-0:2.8.0Total fed-in energy (kWh)Separate counter for PV export pulses
1-0:1.7.0Instantaneous import power (kW)“Power-proportional” pulse (requires kW→Wh integration)
2-0:2.7.0Instantaneous export power (kW)Export-dependent pulse densification (e.g. PV regulation)
1-0:21.7.0/41.7.0/61.7.0Instantaneous import (kW) on L1/L2/L3Phase-wise pulses (using three separate PN100 units)
1-0:32.7.0Phase voltage L1 (V)Counting voltage threshold events (for custom logic)

The ADA-PN100 firmware primarily outputs kWh-based pulses but can read arbitrary OBIS codes. If you specify a non-kWh type code (e.g. kW), then to correct the quantity (Wh/pulse), it is advisable to extend the firmware with integral logic (project-dependent).

Selecting pulse density

The Wh/pulse value determines how frequently pulses occur. Example:

  • Load: 3 kW (≈ 3000 W) → 3000 Wh of energy per hour.
  • If 100 Wh/pulse, then 3000/100 = 30 pulses/hour → on average, one every 2 minutes.
  • If 10 Wh/pulse, then 3000/10 = 300 pulses/hour → on average, one every 12 seconds.

General PLCs can definitely count pulse lengths of 30–300 ms. The firmware allows a range of 50–2000 ms.

Compatibility (examples, not exhaustive)

  • PLCs with 24 VDC digital inputs or dedicated S0 counter inputs: Siemens LOGO!/S7 DI, WAGO, Omron, Schneider, FATEK, Unitronics, etc.
  • Data collectors / energy monitors expecting potential-free contact inputs.
  • Impulse counters connecting to SCADA systems.

Key: the PN100 output emulates a dry contact (PhotoMOS), making it widely compatible with the 24 VDC industrial environment.

System architecture (overview)

Smart meter (P1, inverted DSMR 115200)  ──►  ADA-PN100 (ESP32)
                                           ├─ OBIS processing, EEPROM persistence
                                           ├─ Web UI (AP): \/, \/save, \/test, \/clear_log, \/log
                                           └─ PhotoMOS SSR pulses  ──► PLC/Logger/SCADA (24 VDC input)

Software features (web and API endpoints)

EndpointDescription
/Settings interface (OBIS, pulse ms, Wh/pulse, AP password) + live log
/save (POST)Save settings to EEPROM (AP password 8–63 characters)
/testSend single test pulse
/clear_logClear log file and RAM buffer
/log?format=html|text&rev=1|0Show log (also in reverse order)

Installation and commissioning

  1. Hardware wiring: Connect PN100 PhotoMOS output in series with the 24 V PLC input circuit. Pay attention to the max. 60 V and 500 mA limits.
  2. Power supply: USB or 5 V VIN to ESP32 module (typically < 200 mA).
  3. Web setup: Connect to AP → http://192.168.4.1 → fill fields → Save.
  4. Change AP password (optional): after saving, AP restarts, connect with new password.
  5. Testing: press Test pulse button → check PLC counter increments.

Troubleshooting

  • No pulses: Does Test pulse work? If yes, the issue may be with P1/OBIS processing (kWh not increasing). Check OBIS code and assure it actually changes.
  • PLC does not count: Is input type correct? 24 VDC DI or S0 counter is required. Minimum pulse length should be above 30–50 ms.
  • Occasional false pulses: At very high impedance inputs, PhotoMOS leakage may cause sensitivity. Add a weak pull-down resistor (e.g. 10–47 kΩ) between input and 0V.
  • Cannot connect to AP: hold RESET button ≥5 s and restart with factory password.

Safety and limits

  • Max. 60 VAC/DC output voltage! Do not connect to 230 VAC mains.
  • The pulse output is isolated PhotoMOS, potential-free, but in industrial environments pay attention to wiring (shielded or short cable, common reference with PLC if needed).
  • The firmware uses inverted DSMR 115200 8N1 setting for the P1 port.

Technical summary

MCUESP32 (UART2: RX=16, TX=17, inverted)
OutputGAQY212GS PhotoMOS, SPST-NO, 60 VAC/DC, 500 mA, ~0.8 Ω
Pulse length50–2000 ms (default: 300 ms)
ScaleWh/pulse (user adjustable; default: 100 Wh)
OBISDefault: 1-0:1.8.0; others configurable
LogRAM buffer 500 lines + LittleFS (/pn100.log), /log endpoint
AP modeSSID: ADA-PN100; password editable (8–63 chars)
Factory resetGPIO4 button ≥5 s → factory default
Power5 V (USB/VIN), typically < 200 mA

Hardware drive tips

  • For the SSR LED from 3.3 V, typically 180–470 Ω series resistor is enough (for 8 mA, ~270 Ω can be calculated as starting point).
  • On the PLC side, input filtering (debounce/pulse timing) should be set above 20–30 ms.


Commissioning



© GreenHESS / ADA-PN100 – technical documentation. The compatibility list is not exhaustive, the input specifications of individual PLCs may vary. The output is suitable only for max 60 VAC/DC circuits.

PZIOT-E02 consumption meter – with native okosvillanyora.hu support

PZIOT-E02 consumption meter – with native okosvillanyora.hu support

2025.10.16.    513

The Swiss army knife of phase measurement The PZIOT-E02 can provide great help in two situations: 1. If you don’t have an electricity meter with a P1 port In this case, the PZIOT-E02 functions as a…

More
Why is it important to also measure inverter production?

Why is it important to also measure inverter production?

2025.10.16.    430

For owners of household-scale small power plants (HMKE), it is natural to monitor the feedback to the grid. This value shows how much of the produced energy the house does not use immediately, but sen…

More
More than a thousand households already use the Hungarian-developed ADA P1 Meter for more conscious energy use

More than a thousand households already use the Hungarian-developed ADA P1 Meter for more conscious energy use

2025.12.22.    558

In recent times, it has become increasingly important for more Hungarian households not only to see their electricity bill but also to understand what is actually happening behind the scenes. The Debr…

More

Featured

ADA P1 Meter - smart meter for electricity meter +15 cm RJ12 data cable

ADA P1 Meter - smart meter for electricity meter +15 cm RJ12 data cable

The device collects nearly 40 data points (consumption, feedback, phase parameters, reactive energie..

15,900 Forint Ex Tax: 12,520 Forint

PZIOT-E02 – with native okosvillanyora.hu and hmke.app support

PZIOT-E02 – with native okosvillanyora.hu and hmke.app support

The PZIOT-E02 is a compact, DIN rail mountable consumption meter, capable of accurately measuring th..

9,900 Forint 12,899 Forint Ex Tax: 7,795 Forint

3pcs 1-phase PZIOT-E02 current meter – native okosvillanyora.hu support

3pcs 1-phase PZIOT-E02 current meter – native okosvillanyora.hu support

The package contains 3 pieces of PZIOT-E02 phase meters. The above price applies to 3 pcs.The PZIOT-..

24,900 Forint 29,900 Forint Ex Tax: 19,606 Forint

ADA P1 Bridge - Bridge for P1 reader +1m USB cable

ADA P1 Bridge - Bridge for P1 reader +1m USB cable

Compatible with any P1 meter that provides telegram/P1 data on the local network via HTTP GET (URL) ..

5,900 Forint Ex Tax: 4,646 Forint

Comments

No comments yet. Be the first!