Control NRGKick via Home Assistant and MQTT #11656
Replies: 5 comments 31 replies
-
NRGkick is already supported natively. What additional capability does the HA plugin provide? |
Beta Was this translation helpful? Give feedback.
-
Ist für maxcurrent von evcc nach mqtt die Benennung deiner Variablen exakt so? Ist für enable von evcc nach mqtt die Benennung deiner Variablen exakt so ? |
Beta Was this translation helpful? Give feedback.
-
@Nxtway es geht jetzt. Vielen Dank. Allerdings ist es super träge. Es dauert ewig, bis die Nachricht zum Laden an MqTT geht. 38sec. Und dann nochmal ewig bis EVCC realisiert, dass er angefangen hat zu laden. |
Beta Was this translation helpful? Give feedback.
-
Hi @FxQt ,
zu deiner Frage:
Da nun bei mir die NRGKick soweit hervorragend funktioniert, würde ich gerne die 1P/3P-Umschaltung der NRGKick nutzen. Im HA gibt es dazu eine Entität, das heißt ich brauch "nur" den Support auf der EVCC Seite.
Gibt es im custom charger die Möglichkeit die Phasenumschaltung anzusprechen?
Antwort:
Der custom charger unterstützt das nicht, soviel ich herausgelesen habe. Dadurch bin ich einen anderen Weg gegangen.
Da mein führendes System der Home Assistant ist, habe ich weitere Infos (Sensoren) von evcc über mqtt bereitgestellt.
Siehe Sensor Sammlung: [https://community.home-assistant.io/t/evcc-integration-via-mqtt-sensor-entity-config/407959/62?u=aichingerk]
Damit kannst du nun von HA aus das evcc zwischen 1/3 Phasen umschalten und das funktioniert super.
|
Beta Was this translation helpful? Give feedback.
-
Hallo,EVCC unterstützt jetzt nativ NRGkick. Das funktioniert super.Viele Grüße Carsten Am 01.10.2024 um 20:12 schrieb FxQt ***@***.***>:
Das Update Sept. 2024 hat das Setup kaputt gemacht. Es gibt nun eine WebAPI von NRGKick.
Das https://github.com/dupondje/nrgkick-ha Projekt hat das bereits angepasst.
Änderungen die vorzunehmen sind:
WebAPI aktivieren:
1.1. NRGKick App -> Erweitert -> Lokale API -> JSON API aktivieren
1.2. (gleiches Menü) Authentifizierung verwenden -> Nutzer und Passwort vergeben
Im HA die alte NRGKick entfernen; neu anlegen (Settings -> Devices & Services -> NRGKick (da wird Nutzer und Passwort gebraucht und natürlich wieder die IP))
automation.yaml anpassen: ACHTUNG! Identities anpassen, hier steckt nun der user-Name drin. Im Beispiel hier jeweils das "USER".
- alias: NRGKick Charging Stop Set
description: ''
trigger:
- platform: mqtt
topic: evcc/nrgkick/enable
payload: '0'
condition: []
action:
- service: switch.turn_on
target:
entity_id:
- switch.USER_charge_pause_disabled_enabled
data: {}
mode: single
- alias: NRGKick Charge Limit Set
description: ''
trigger:
- platform: mqtt
topic: evcc/nrgkick/maxcurrent
condition: []
action:
- service: number.set_value
metadata: {}
data:
value: '{{ trigger.payload }}'
target:
entity_id: number.USER_user_set_charging_current
mode: single
- alias: NRGKick Charging Start Set
description: 'Start charging'
trigger:
- platform: mqtt
topic: evcc/nrgkick/enable
payload: '1'
condition: []
action:
- service: switch.turn_off
target:
entity_id:
- switch.USER_charge_pause_disabled_enabled
data: {}
mode: single
- alias: EVCC NRGKick Charger chargerStatusValue
description: Charger Info an evcc von A bis F # https://evsim.gonium.net/#der-control-pilot-cp
trigger:
- platform: time_pattern
seconds: /15
condition: null
action:
- service: mqtt.publish
metadata: {}
data_template:
topic: evcc/nrgkick/chargerStatusValue
payload: >
{% if ("UNKNOWN" in states("sensor.USER_charging_status")) %}
{% set chargerStatusValue = "A" %}
{% elif ("STANDBY" in states("sensor.USER_charging_status")) %}
{% set chargerStatusValue = "B" %}
{% elif ("CONNECTED" in states("sensor.USER_charging_status")) %}
{% set chargerStatusValue = "B" %}
{% elif ("CHARGING" in states("sensor.USER_charging_status")) %}
{% set chargerStatusValue = "C" %}
{% elif ("CP_SIGNAL_VOLTAGE_ERROR" in states("sensor.USER_shows_currently_reported_error")) %}
{% set chargerStatusValue = "E" %}
{% elif ("CP_SIGNAL_IMPERMISSIBLE" in states("sensor.USER_shows_currently_reported_error")) %}
{% set chargerStatusValue = "F" %}
{% endif %} {{ chargerStatusValue }}
mode: single
- alias: EVCC NRGKick Charger chargingStateValue
description: NRGKick Charging State Value True/False
trigger:
- platform: time_pattern
seconds: /15
condition: null
action:
- service: mqtt.publish
metadata: {}
data_template:
topic: evcc/nrgkick/chargingStateValue
payload: >
{% if ("CHARGING" != states("sensor.USER_charging_status")) %}
{% set chargingStateValue = "false" %}
{% elif ("CHARGING" == states("sensor.USER_charging_status")) %}
{% set chargingStateValue = "true" %}
{% endif %} {{ chargingStateValue | string }}
mode: single
- alias: EVCC NRGKick Charger Phase1p3p set
description: Phasenumschaltung 1p3p von EVCC einstellen lassen
trigger:
- platform: mqtt
topic: evcc/nrgkick/phases
condition: []
action:
- service: number.set_value
metadata: {}
data:
value: "{{ trigger.payload }}"
target:
entity_id: number.USER_user_set_maximum_charge_phases_count
mode: single
Beim chargerStatusValue (A...F) bin ich mir sehr unsicher ob das so richtig ist. Ich korrigiere das gerne!
Tip: Falls ihr auch aus Neugierde die WebAPI per Browser geöffnet habt, schließt das, sonst kam HA/EVCC kaum durch um zu steuern.
Ich muss noch ausprobieren was es noch sein könnte, aber so ganz zuverlässig läuft es gerade noch nicht - daher bitte ich hier um Unterstützung!
@aichingerk nutzt Du das Update schon?
—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you were mentioned.Message ID: ***@***.***>
|
Beta Was this translation helpful? Give feedback.
-
Hi,
I would like to control my NRGKick charger via EVCC. In order to achieve this, I have installed the newly developed Home Assistant Integration for NRGKick:
https://github.com/dupondje/nrgkick-ha
I am able to control the NRGKick Charger via the plugin. This works well.
According to my understanding, MQTT should be best to integrate the HA charger control into EVCC. For this I have installed a Mosquito MQTT broker on my HA instance and connected EVCC to it. I have also written a few HA automations to publish sensor data to MQTT and retrieve commands (start/stop charging, set max Ampere) . I have tested this via MQTT Explorer. This works fine.
EVCC publishes data to MQTT and EVCC successfully reads the charger status from my MQTT broker. In other words, in status B, EVCC understands that the cable is connected and in status C EVCC shows that the car is charging. So far, so good.
1st Challenge:
Starting the charging process from EVCC does not work. I do not see anything being published to the MQTT broker.
@andig Can you point me to the missing piece?
2nd Challenge
EVCC complains "Stellplatz: charger: outdated". Do I have to publish the charger and charging status regularly to MQTT from HA?
Question
Shouldn't EVCC also receive the current charging rate? Do I miss something here?
Regards
Carsten
Beta Was this translation helpful? Give feedback.
All reactions