Home Assistant integration for Haverland (and other brands) heating smartboxes.
- Add this repository to your custom repositories
- Search for and install "Smartbox" in HACS.
- Restart Home Assistant.
- In the Home Assistant UI go to "Configuration" -> "Integrations" click "+" and search for "Smartbox"
- Using the tool of choice open the directory (folder) for your HA configuration (where you find
configuration.yaml
). - If you do not have a
custom_components
directory (folder) there, you need to create it. - In the
custom_components
directory (folder) create a new folder calledsmartbox
. - Download all the files from the
custom_components/smartbox/
directory (folder) in this repository. - Place the files you downloaded in the new directory (folder) you created.
- Restart Home Assistant
- In the Home Assistant UI go to "Configuration" -> "Integrations" click "+" and search for "Smartbox"
You will need the following items of information:
- Name of your resailer
- Your username and password used for the mobile app/web app.
If there is an issue during the process or authentication, the errors will be displayed.
You can also specify the following options (although they have reasonable defaults):
We are currently getting the consumption of device throuw the API and we inject it in statistics and TotalConsumption sensor
- start : we will get the last 3 years of consumption and set the option to auto.
- auto : every hour, we get the last 24 hours.
- off : stop the automatic collect. We will still update the sensor every hour.
By default, each sensor has in own icon depends on the type of the sensor. You can activate this option to display the logo of the resailer instead.
session_retry_attempts: 8 # how many times to retry session REST operations
session_backoff_factor: 0.1 # how much to backoff between REST retries
socket_reconnect_attempts: 3 # how many times to try reconnecting the socket.io socket
socket_backoff_factor: 0.1 # how much to backoff between initial socket connect attempts
These are modelled as Home Assistant Climate entities.
htr
andacm
(accumulator) nodes- Supported modes: 'manual' and 'auto'
- Supported presets: 'home and 'away'
htr_mod
- Supported modes: 'manual', 'auto', 'self_learn' and 'presence'
- Supported presets: 'away', 'comfort', 'eco', 'ice' and 'away'
The modes and presets for htr_mod heaters are mapped as follows:
htr_mod mode | htr_mod selected_temp | HA HVAC mode | HA preset |
---|---|---|---|
manual | comfort | HEAT | COMFORT |
eco | HEAT | ECO | |
ice | HEAT | ICE | |
auto | * | AUTO | SCHEDULE |
self_learn | * | AUTO | SELF_LEARN |
presence | * | AUTO | ACTIVITY |
The smartbox API is only giving the hourly consumption from a start and an end period of time. You can't have real time consumption of a device and this consumption is always increasing.
At every beginning of an hour, during around 15/20 minutes, the API do not provide data for the current hour. So we always get a period of two hour to have at least some data, and get the most recent one to not have drop of consumption.
Every hour, we are updating data sensor with the most recent data. You are able to see the consumption directly into the history graph of the sensor.
But to be sure we ensure the right data to the right hour, we also get the last 24 hours and upsert these data into statistics to avoid time difference and some data drop.
Tip
If you don't want to upsert these 24 hours, you have to set the option to off
.
The first time we create a config entry (or when the option of the config entry is set to start
) we get the last 3 years of consumption.
As it is not possible to add it directly to the sensor data, we insert it into the statistics of the sensor.
So it let the energy dashboard working with the current and back history.
Tip
If you want to reset all the data, you have to set the option to start
.
Debug logging can be enabled by increasing the log level for the smartbox custom
component and the underlying smartbox python module in the Home Assistant
configuration.yaml
:
logger:
...
logs:
custom_components.smartbox: debug
smartbox: debug
...
Warning
Currently logs might include credentials, so please be careful when sharing excerpts from logs
See the Home Assistant logger docs for how to view the actual logs. Please file a Github issue with any problems.
- Graceful cleanup/shutdown of update task
- use a coordinator to update data (and use the websocket to propagate data)
Note
The initial version of this integration was made by graham33 but it was not maintained.