Integración domótica OpenEVSE, gratuita y de código abierto

OpenEVSE chargers over their local HTTP API: state, current, energy, temperature; optional commands.
La documentación de esta integración la escribe su autor y, por ahora, solo está disponible en inglés.
Shows your OpenEVSE charger (ESP32 WiFi module, firmware 4.x or 5.x) in Gladys through its local HTTP API: no cloud, no account, straight on your network.
Never tested with a real charger. Not affiliated with OpenEVSE. The integration talks to the charger as the python-openevse-http library (used by Home Assistant) does. A firmware update may change the API.
What you get
One device per charger, with:
| Feature | Content |
|---|---|
| Status | No vehicle, plugged in waiting, charging, paused, disabled, faults |
| Connector | Available, occupied, faulted or unavailable ("charging station" category) |
| Charging state | Charging, vehicle connected, paused by the charger, idle |
| Vehicle plugged in | Yes / no |
| Power | In W (given by the charger, else voltage × current) |
| Current, voltage | In A, in V |
| Current offered to the vehicle | In A (the pilot signal) |
| Energy of the session | In kWh, a plain sensor |
| Energy index | In kWh, the total counter of the charger, guarded (see below) |
| Temperature of the charger | In °C |
| Manual override | None (the charger decides), charge forced on, charge paused |
| Fault reported | Yes / no (ground fault, stuck relay, over temperature…) |
| Start charging | Button (commands allowed only) |
| Pause charging | Button (commands allowed only) |
| Set the charging current | List from 6 A to the ceiling (commands allowed only) |
Read every 30 seconds by default (10 s to 10 min, configurable).
Energy index (guarded)
The energy index is the total counter of the charger (total_energy):
Gladys turns it into the consumption and the cost of the charger in its
Energy tab. Since Gladys counts every rise in full, the index goes through a
guard (the one of the P1 Monitor integration):
- an index of 0 is never published;
- a plausible rise (25 kW on average at most since the last value) goes through;
- a jump up or a drop (counter reset, another charger at the same
address) is held back: the last accepted value is sent again, the
status of the integration shows it, and the hold is kept in
/dataacross a restart. Neither time nor repetition confirms it; - only the Accept the held index button of the configuration takes it, in two clicks: the first shows the value and the kWh at stake, the second (within 2 minutes) takes exactly that value (plus what the charger may have drawn since). A drop accepted bills nothing.
The charger is already counted by your main meter: in the Energy settings of Gladys, put it under your main meter so it is not counted twice. No daily consumption is published.
Installation
- Give the charger a fixed IP address in your router (or use its name
openevse-xxxx.local). - Check in its web interface that the WiFi firmware is 4.0 or later (4.1.2 to start the charge and set the current). Firmwares 2.x and 3.x give no serial number: they are not supported.
- Install the integration from the Gladys store. In its configuration, enter the IP address of the charger, and, only if its web interface asks for them, the user name and the password (HTTP authentication).
- Save, then add the charger from the Discovery tab.
The password is kept by Gladys in its database, never shown again, and
sent only to the charger (HTTP Basic authentication). The charger only speaks
plain HTTP: the user name and the password travel in clear on your local
network, as with the web interface itself. Keep the charger on a trusted
network. They are never written to the logs, to /data, nor to a state. The
configuration of the charger also holds its own passwords (WiFi, MQTT…): the
integration only reads its identity, versions and currents (minimum,
maximum, its own current) from it, nothing else is kept. Never paste an
address with user:password@: it is refused, and never shown.
The Test the connection button reads the charger once (at most every 10 seconds).
Commands (off by default)
"Start charging", "Pause charging" and "Set the charging current" refuse
every command while Allow the commands is off. On, they go through the
manual override of the charger (/override):
- Pause sets a "paused" override: the charger stops charging. The
settings of the override in force (current, session limits, auto release)
are kept. The pause is never held back: it goes at once, in one
request, without a read, even during another command (which gives way if
it has not left yet; otherwise the pause is sent once more when it
settles), even within the minute after a start, even during a 429 or 5xx
pause, even right after the credentials were refused, whatever the
firmware, and even right after a restart of the integration, before any
read of the charger (its serial is kept in
/data); - Start sets a "charge" override (the settings of the override in force
are kept); never above the ceiling: the current of the override in
force, else the charger's own current (
max_current_soft), is lowered to it; refused when the charger does not give its current; refused without a vehicle plugged in, or on a fault or an unknown state; no effect (not sent) when the charger already charges without a pause; after a restart, it waits for a first read of the charger; - Charging current: from 6 A (or the hardware minimum of the charger) to the ceiling: the lower of the "Ceiling of the charging current" of the configuration (16 A by default, 80 A at most) and the hardware maximum read from the charger. The state of the override in force is kept: a pause stays a pause, changing the current never starts the charge again. WiFi firmware 4.1.2 or later.
- One start or current change a minute at most: no fine regulation from Gladys.
They are buttons and a list, never switches: a "turn everything off" (from Gladys, Google Home, Alexa or HomeKit) never reaches them. A scene may trigger them, only through an explicit action, and only when the commands are allowed. Note that the AI chat of Gladys (MCP) can create and run such a scene: while the commands are allowed, it can start or pause the charge.
Before a start or a current change, the integration reads the charger again (state and override) and decides on that read only; the option is checked again right before sending. A command that cannot leave within 3.5 seconds is refused unsent. When the charger does not confirm (silence, a 5xx, an answer not understood), Gladys shows "Command sent, without confirmation": check the state, read again 5 then 20 seconds later. When a command stayed without confirmation, it may still reach the charger later: a pause sent within the next 90 seconds is watched, and sent again (twice at most) if a read shows the charge allowed again while no other command left.
The manual override keeps the behaviour of the charger: with "auto release" (a setting of the override), it ends when the vehicle is unplugged; a pause is then never reaffirmed without a vehicle. When the charger cannot say there is no override (a 404 without the firmware's message), start and the current are refused.
Errors and limits
- Charger unreachable: only the connector ("unavailable") and the status ("Charger unreachable") change; the other values keep their last one. New try after 30 s, 1, 2, then 5 minutes, never faster than the interval.
- Credentials refused (or asked for while none is given): the status says
so; new tries after 15 minutes, 1 hour, then every 6 hours, never sooner
(kept in
/dataacross a restart); saving new credentials tries again at once. - 429 (too many requests) or 5xx: a pause (1 minute to 6 hours for a 429) for the reads and the commands but the pause of the charge, never
shorter than the interval, kept in
/dataacross a restart. - One charger per integration. Neither the solar mode (divert), the schedule, the session limits, a restart nor the firmware can be changed from Gladys. The websocket of the charger is not used (periodic reads).
- An OpenEVSE charger linked to an OCPP server (for example sescandell's OCPP integration) may be driven from both sides: the last command wins. Pick one driver.
- The logs never hold the text of the charger's answers, the user name nor the password.
Credits
Port of python-openevse-http (firstof9, Apache-2.0, version 1.9.0), the library of Home Assistant's OpenEVSE integration. Apache-2.0 license.
Parámetros de configuración
Estos son los parámetros que OpenEVSE te pide en su pantalla de configuración en Gladys.
| Parámetro | Tipo | Obligatorio | Descripción |
|---|---|---|---|
| Your OpenEVSE charger | section | No | Shows your OpenEVSE charger (WiFi firmware 4.0 or later) in Gladys through its local HTTP API, without any cloud: state, vehicle plugged in, power, current, voltage, current offered, energy of the session, energy index, temperature, manual override. Enter the IP address of the charger (give it a fixed address in your router), and the user name and password of its web interface if you set some, save, then add it from the Discovery tab. Starting, pausing and the charging current can be changed from Gladys only if you allow the commands below. Never tested with a real charger. Not affiliated with OpenEVSE. |
| IP address of the charger | string | Sí | An IPv4 address or a host name (openevse-xxxx.local), optionally followed by a port (80 by default). |
| User name of the web interface | string | No | Only if the web interface of the charger asks for one (Settings, HTTP authentication). Leave empty otherwise. Never in the address field. |
| Password of the web interface | secret | No | With the user name above. Kept by Gladys in its database, never shown again, sent only to the charger, in clear (HTTP Basic authentication) on the local network. Refused credentials are tried again after 15 min, 1 h, then every 6 h. |
| Allow the commands | boolean | No | Off by default. On: Gladys may start and pause the charge (buttons) and set the charging current (list, 6 A to the ceiling below). Off: these three features refuse every command. Once on, the pause is never held back. |
| Ceiling of the charging current (A) | number | No | The highest current Gladys may ask for, the start included: the lower of this value (16 A by default) and the hardware maximum read from the charger. |
| Refresh interval (s) | number | No | How often the charger is read, in seconds. |
| Language of the feature names | select | No | Used for the feature names of the devices added from now on, for the status texts and for the command errors. |
Cómo instalar OpenEVSE en Gladys
- En Gladys, abre Integraciones: OpenEVSE aparece en el catálogo junto a las integraciones nativas, con una insignia de comunidad.
- Haz clic en Instalar. Gladys descarga la imagen Docker (
ghcr.io/lm1lc3n7/gladys-openevse:0.1.1), la ejecuta en un entorno aislado del núcleo y genera la interfaz de la integración (dispositivos, descubrimiento y configuración). - Abre la pantalla de Configuración de la integración, rellena los parámetros y guarda.
- También puedes instalarla directamente desde la URL de su repositorio: https://github.com/LM1LC3N7/gladys-openevse.
OpenEVSE requiere Gladys >=5.1.0. El catálogo de Gladys se actualiza cada hora, así que una nueva versión está disponible como máximo una hora después de publicarse.
¿Todavía no usas Gladys? Es gratuito y de código abierto: sigue la guía de instalación para empezar.
Sobre las integraciones externas
OpenEVSE es una integración externa: una integración comunitaria empaquetada como contenedor Docker y publicada en GitHub. Gladys la instala con un clic y la ejecuta en un entorno aislado del núcleo. La publica y mantiene LM1LC3N7, no el equipo principal de Gladys.
- Explorar todas las integraciones, nativas y de la comunidad
- Crear y publicar tu propia integración externa
- Código fuente en GitHub — fuente de esta documentación