EnAccess / EnAccess/micropowermanager

Add read-only OpenEMS data-source plugin

Open
#1,594 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
PHP
Stars
27
Forks
19
Avg merge
1d 18h
Merged PRs (30d)
27

Description

## Problem

MPM currently has no supported way to import customer energy usage from an OpenEMS-managed mini-grid. Operators need to map OpenEMS meter components to existing MPM meters and make interval consumption available in MPM without affecting billing or meter control.

## Proposed solution

Add a read-only OpenEMS plugin that:

- connects tenant configurations to one or more OpenEMS Backends through the Backend-to-Backend JSON-RPC API;
- maps multiple OpenEMS Edges to an MPM mini-grid;
- provides a customer-first workflow in which an operator selects a customer
and then explicitly selects one of that customer's existing MPM meters;
- persists the meter mapping as the reading identity and derives the customer
through MPM's existing device ownership relationship;
- imports 15-minute consumption into the existing meter-reading system;
- uses historical energy queries when supported and cumulative-counter polling otherwise;
- handles retries, duplicate delivery, counter resets, gaps, and partial failures;
- applies OpenEMS-only tiered retention;
- provides authenticated connection, mapping, synchronization, CSV import, health, and usage workflows;
- adds an operator dashboard filtered by mini-grid and date.

## Scope

V1 is informational only. Imported readings must not alter customer balances, tariffs, invoices, tokens, device state, or OpenEMS configuration. Live power, voltage, and remote connect/disconnect are excluded.

## Acceptance criteria

- Readings appear in MPM within 20 minutes of their interval.
- Duplicate or retried delivery creates no duplicate readings.
- Tenant data remains isolated.
- Disabling the plugin prevents new synchronization jobs.
- A target-instance pilot reconciles daily energy totals within 0.1% or 0.01 kWh, whichever is larger.
- The design supports up to 5,000 mapped meters per tenant.

## Rollout requirements

Before production rollout, capture anonymized fixtures from the target OpenEMS version, run the 5,000-meter scale check, and complete a seven-day mini-grid reconciliation pilot.

Contributor guide

Open the contributing guide

Research direction

Start by reviewing MPM’s existing meter-reading system and device ownership relationship, then the OpenEMS Backend-to-Backend JSON-RPC API. Define the plugin’s integration, persistence, synchronization, dashboard, and CSV workflows before implementation; done means the stated isolation, reliability, reconciliation, retention, and scale acceptance criteria are met.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
api, backend, database
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.