Utility monitoring in residential buildings and multi-flat complexes usually requires separate, closed-source meters for electricity, water, and gas. To solve this with a single open-source edge controller, I built OmniUtility — an AI-driven multi-utility monitoring platform running on a Raspberry Pi 5.

What OmniUtility Monitors

OmniUtility combines three utility streams into one Python deployment with local persistence and cloud telemetry:

  1. Electricity (PZEM-004T): Measures voltage, current, active power, cumulative energy, frequency, and power factor via USB-UART.
  2. Water Flow (YF-S201): Tracks real-time flow rate (L/min) and cumulative volume using pulse counting.
  3. Gas Leakage (MQ-4 + ADS1115): Reads raw ADC values, voltage, and %FSD to trigger early gas leak warnings.

System Architecture

Sensors (PZEM-004T · YF-S201 · MQ-4 + ADS1115) │ ▼ Raspberry Pi 5 Edge Controller (Python) ├── SQLite (Local timestamped persistence) ├── MQTT Broker (Multi-flat distributed coordination) ├── InfluxDB Cloud (Time-series telemetry) ├── Z-Score + IsolationForest (AI anomaly detection & sensor health) ├── Telegram Bot API (Instant push alerts with per-key cooldown) └── Flask + Chart.js (Live web dashboard) 

Why Edge AI + Multi-Flat MQTT?

  • AI Anomaly Detection: Using Z-score and IsolationForest models directly on the Raspberry Pi 5 flags abnormal water flow spikes, electrical overloads, or gradual sensor drift before hardware fails.
  • Multi-Flat Coordination: Designed for apartment buildings and housing societies, multiple edge nodes publish over MQTT to coordinate building-wide utility analytics.

Get Started & Explore

You can explore the full system overview, hardware list, and contact details on the official portal at www.omniutility.in, or clone the source code directly from GitHub.