Easee EV charger component for Home Assistant
Custom component to support Easee EV chargers and equalizers.
The status sensor is the default sensor and has the following values
disconnected
awaiting_start
charging
ready_to_charge
completed
error
Installation
There are 2 different methods of installing the custom component
HACS installation
- Add this repository from HACS->Integrations.
- Restart Home Assistant.
- Install the component from Settings->Integrations. You may have to clear the browser cache to make the Easee integration appear in the list.
Git installation
- Make sure you have git installed on your machine.
- Navigate to you home assistant configuration folder.
- Create a
custom_components
folder of it does not exist, navigate down into it after creation. - Execute the following command:
git clone https://github.com/fondberg/easee_hass.git easee
- Run
bash links.sh
Monitored chargers/equalizers
Since v0.9.47 the integration only includes the chargers and equalizers that has been added to the Easee official app, rather than showing all that are available to the logged in user. This change was done becuase in larger installations there could be 10s or 100s of chargers listed which in most cases does not make much sense. So if you do not see all your products in the integration, open the official app and make sure they are listed there first.
Configuration
Configuration is done through in Configuration > Integrations where you first configure it and then set the options for what you want to monitor.
Use
The basic use of the integrations from the UI should be self-explanatory. The integration defines a number of services that can be used from automations and scripts to control the charger and the charging process. The available services can be found in Home Assistant at Developer tools->Services.
The easiest way to set up services and their parameters is to use the automation editor or the developer tools. However, you can also write the code in plain yaml. The UI will use device_id as target for the services. This is a random string generated internally by HA and is not very user friendly. To simplify for hard-core coders and to be backward compatible with previous versions of this integration you can also use charger_id or circuit_id as targets. Three examples that will do the same thing:
service: easee.set_circuit_dynamic_limit
data:
device_id: b40f1f45d28b0891
currentP1: 10
service: easee.set_circuit_dynamic_limit
data:
charger_id: EVK1234
currentP1: 10
service: easee.set_circuit_dynamic_limit
data:
circuit_id: 30456
currentP1: 10
For details on the Easee API, please refer to https://developer.easee.cloud/reference
Debug logging
A full debug log can be enabled by entering following into configuration.yaml
and restarting Home Assistant
logger:
default: info
logs:
pyeasee: debug
custom_components.easee: debug
Development Container
One option for development is to use the VS Code Dev Container. You need to have Docker installed.
-
For best performance, make sure to clone the repo in WSL2 if running on Windows.
$ git clone https://github.com/{your_user}/easee_hass $ mkdir easee_hass_config
-
Open the repository in VS Code.
$ code easee_hass
-
VS Code will ask to reopen the folder in a container
- If not, press
Ctrl
+Shift
+P
and selectDev Containers: Reopen in Dev Container
.
- If not, press
-
Wait for the container to be built.
-
Press
Ctrl
+Shift
+P
and selectTasks: Run Task
>Run Home Assistant on port 9125
. -
Wait for Home Assistant to start and go to http://localhost:9125/.
-
Walk through the Home Assistant first-launch UI.
-
Go to http://localhost:9125/config/integrations, click
Add Integration
and add theEasee
integration. -
To debug, press
F5
to attach to the Home Assistant running in the container.
Always run
$ make lint
Before pushing your changes