Homeassistant integration to show many stats of Sonnenbatterie that should work with current versions of Sonnenbatterie.
Easiest way to install is to add this repository via HACS.
- eco 8.03 9010 ND
- eco 8.0 DE 9010 ND
- sonnenBatterie 10 performance
- ex. model 9.2 eco from 2014 not working
The main focus of the integration is to provide a comprehensive set of sensors for your SonnenBatterie. Right after installation the most relevant sensors are already activated.
Tip
If you want to dive deeper, just head over to your Sonnenbatterie device settings, click on "Entities" and enable the ones you're interested in.
Since version 2025.01.01 this integration also supports actions you can use to set some variables that influence the behaviour of your SonnenBatterie.
Currently supported actions are:
- Sets the operating mode of your SonnenBatterie.
- Supported values for
<mode>
are:"manual"
"automatic"
"timeofuse"
action: sonnenbatterie.set_operating_mode
data:
mode: "automatic"
An int
representing the mode that has been set:
- 1:
manual
- 2:
automatic
- 10:
timeofuse
Important
Requires the SonnenBatterie to be in manual
or auto
mode to have any
effect.
Disables power delivery from the battery to local consumers!
- Sets your battery to charge with
<power>
watts - Disables discharging to support local consumers while charging
- Supported values for
<power>
are:-
min. power = 0 (0 = disable functionality)
-
max. power = value of your battery's
inverter_max_power
value.The integration tries to determine the upper limit automatically and caps the input if a higher value than supported by the battery is given
-
action: sonnenbatterie.charge_battery
data:
power: 0
A bool
value, either True
if setting the value was successful or False
otherwise.
Important
Requires the SonnenBatterie to be in manual
or auto
mode to have any
effect.
Enables power delivery from the battery to local consumers and may result in sending power to the network if local demand is lower than the value given!
- Sets your battery to discharge with
<power>
watts - Disables charging of the battery while active
- Supported values for
<power>
are:-
min. power = 0 (0 = disable functionality)
-
max. power = value of your battery's
inverter_max_power
value.The integration tries to determine the upper limit automatically and caps the input if a higher value than supported by the battery is given
-
action: sonnenbatterie.discharge_battery
data:
power: 0
A bool
value, either True
if setting the value was successful or False
otherwise.
- Sets the percentage of energy that should be left in the battery
<value>
can be in the range from 0 - 100
action: sonnenbatterie.set_battery_reserve
data:
value: 10
An integer representing the current value of "battery reserve"
- Allows to set some selected configuration variables of the SonnenBattery.
- Currently supported
<item>
values:- "EM_OperatingMode"
- allowed values:
manual
automatic
timeofuse
- prefer
set_operating_mode
) over this
- allowed values:
- "EM_ToU_Schedule"
- set a scheulde for charging in ToU mode
- accepts JSON array as string of the format
[ { "start": "10:00", "stop": "11:00", "threshold_p_mac": 10000 }, ... ]
- time ranges must not overlap
- since there are only times, the schedules stay active if not deleted by
sending an empty array (
"[]"
) - prefer
set_tou_schedule
over this
- "EM_USOC"
- set the battery reserve in percent (0 - 100)
- accepts a string representing the value, like
"15"
for 15% reserve - prefer
set_battery_reserve
over this
- "EM_OperatingMode"
action: sonnenbatterie.set_config_item
data:
item: "EM_USOC"
value: "10"
{'EM_USOC': '10'}
Important
The SonnenBatterie must be in timeofuse
operating mode for any
submitted schedule to take effekt.
- Sets the shedule entries for the "Time of Use" operating mode
- The value for the schedule is a JSON array in string format
- The format is:
[ { "start": "10:00", "stop": "11:00", "threshold_p_mac": 10000 }, ... ]
- time ranges must not overlap
- since there are only times, the schedules stay active if not deleted by
sending an empty array (
"[]"
)
action: sonnenbatterie.set_tou_schedule_string
data:
schedule: '[{"start":"10:00", "stop":"10:00", "threshold_p_max": 20000}]'
{
"schedule": '[{"start": "10:00", "stop": "10:00", "threshold_p_max": 20000}]'
}
- Retrieves the current schedule as stored in your SonnenBatterie
action: sonnenbatterie.get_tou_schedule
data: {}
schedule: "[{\"start\":\"10:00\", \"stop\":\"10:00\", \"threshold_p_max\": 20000}]"
Depending on the software on and the operating mode of your Sonnenbatterie some sonsors may not be available. The integration does its best to collect as many values as possible.
If you feel that your Sonnenbatterie doesn't provide a sensor you think it should, you can enable a "Debug Mode" from
Settings -> Devices & Services -> Integrations -> Sonnenbatterie -> (...) -> Reconfigure
Then restart HomeAssistant and watch the logs. You'll get the full data that's returned by your Sonnenbatterie there. Please put those logs along with the setting you want monitored into a new issue.